Documentation ¶
Index ¶
- Constants
- func GetCC(t ccFormat, code string, color string, text string, icon icon, ...) ([]byte, error)
- type CC
- func (c *CC) Send() (NewCC, error)
- func (c *CC) SetCaptionText(captionText string) *CC
- func (c *CC) SetColor(color string) *CC
- func (c *CC) SetDialogIframeConfig(dialogIframeConfig string) *CC
- func (c *CC) SetDialogIframeUrl(dialogIframeUrl string) *CC
- func (c *CC) SetIcon(icon icon) *CC
- func (c *CC) SetMessageBefore(messageBefore string) *CC
- func (c *CC) SetMessageFailure(messageFailure string) *CC
- func (c *CC) SetMessageSuccess(messageSuccess string) *CC
- func (c *CC) SetName(name string) *CC
- func (c *CC) SetRequestBody(requestBody string) *CC
- func (c *CC) SetRequestUrl(requestUrl string) *CC
- func (c *CC) SetSite(sid string) *CC
- func (c *CC) SetTappId(tappId int) *CC
- func (c *CC) SetType(t ccType) *CC
- func (c *CC) SetUrl(url string) *CC
- type Client
- func (c *Client) AssignToGroup(gid int, cid string) error
- func (c *Client) ChangeCaptiontext(sid string, code string, captionText string) error
- func (c *Client) ChangeColor(sid string, code string, color string) error
- func (c *Client) ChangeIcon(sid string, code string, icon icon) error
- func (c *Client) DeleteCC(code string) error
- func (c *Client) DeleteGroup(gid int, deleteCodes bool) error
- func (c *Client) NewCC(sid string, t ccType, name string) *CC
- func (c *Client) NewGroup(name string, sid string) (Group, error)
- func (c *Client) RenameGroup(gid int, name string, sid string) (Group, error)
- func (c *Client) SetToken(token string) *Client
- func (c *Client) UpdateCC(sid string, code string, key string, value any) error
- type Group
- type NewCC
Constants ¶
View Source
const ( BASE_URL = "https://webapi.tobit.com/ChaynsCodeAdministration/v1.0/Chaynscode/" UA = "github.com/Lukas-Nielsen/go-chayns/callingcode" POST method = "POST" GET method = "GET" PUT method = "PUT" DELETE method = "DELETE" PATCH method = "PATCH" TOBITLOGO icon = "tobitlogo" SPACEINVADER icon = "spaceinvader" PACMNAGHOST icon = "pacmnaghost" BUBBLE_1 icon = "bubble1" BUBBLE_2 icon = "bubble2" EXCLAMATIONMARK_1 icon = "exclamationmark1" EXCLAMATIONMARK_2 icon = "exclamationmark2" HEART icon = "heart" LOCATION_1 icon = "location1" LOCATION_2 icon = "location2" PENCIL icon = "pencil" PRICETAG icon = "pricetag" QUESTIONMARK_1 icon = "questionmark1" QUESTIONMARK_2 icon = "questionmark2" SMILEY_1 icon = "smiley1" SMILEY_2 icon = "smiley2" SWITCH icon = "switch" THUMBSUP icon = "thumbsup" THUMBSDOWN icon = "thumbsdown" TABLENUMBER icon = "tablenumber" SVG ccFormat = "SVG" PNG ccFormat = "PNG" JPG ccFormat = "JPG" PDF ccFormat = "PDF" CC_SITE ccType = 1 CC_PAGE ccType = 2 CC_URL ccType = 3 CC_POST ccType = 4 CC_DIALOG_IFRAME ccType = 11 APP_WITHOUT ccApp = 0 APP_RECOMMENDED ccApp = 1 APP_REQUIRED ccApp = 2 )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CC ¶
type CC struct {
// contains filtered or unexported fields
}
func (*CC) SetCaptionText ¶
func (*CC) SetDialogIframeConfig ¶
func (*CC) SetDialogIframeUrl ¶
func (*CC) SetMessageBefore ¶
func (*CC) SetMessageFailure ¶
func (*CC) SetMessageSuccess ¶
func (*CC) SetRequestBody ¶
func (*CC) SetRequestUrl ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) ChangeCaptiontext ¶
site id, calling code, captionText
func (*Client) ChangeColor ¶
site id, calling code, color (hex)
func (*Client) ChangeIcon ¶
site id, calling code, icon
func (*Client) DeleteGroup ¶
gid = id of group
Source Files ¶
Click to show internal directories.
Click to hide internal directories.