Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Attachment ¶
type Client ¶
type Client interface { CreateForm(ctx context.Context, val *Form) (*Form, error) UpdateForm(ctx context.Context, val *Form) error GetForm(ctx context.Context, id string) (*Form, error) DeleteForm(ctx context.Context, id string) error }
func NewClient ¶
func NewClient(opts ClientOpts) Client
type ClientOpts ¶
type Errors ¶
type Field ¶
type Field struct { ID string `json:"id,omitempty"` Type string `json:"type"` Title string `json:"title"` Ref string `json:"ref,omitempty"` Properties Properties `json:"properties,omitempty"` Validations *Validations `json:"validations,omitempty"` Layout *Layout `json:"layout,omitempty"` }
type Form ¶
type Form struct { ID string `json:"id,omitempty"` Title string `json:"title"` Type string `json:"type"` Settings *Settings `json:"settings,omitempty"` WelcomeScreens []WelcomeScreen `json:"welcome_screens,omitempty"` ThankyouScreens []ThankyouScreen `json:"thankyou_screens,omitempty"` Theme *struct { Href string `json:"href"` } `json:"theme,omitempty"` Fields []Field `json:"fields,omitempty"` Links *struct { Display string `json:"display"` } `json:"_links,omitempty"` }
type Layout ¶
type Layout struct { Attachment Attachment `json:"attachment,omitempty"` Placement string `json:"placement,omitempty"` Type string `json:"type,omitempty"` }
type Properties ¶
type Properties struct { AllowMultipleSelection *bool `json:"allow_multiple_selection,omitempty"` AllowOtherChoice *bool `json:"allow_other_choice,omitempty"` AlphabeticalOrder *bool `json:"alphabetical_order,omitempty"` ButtonText string `json:"button_text,omitempty"` Choices []Choice `json:"choices,omitempty"` Description *string `json:"description,omitempty"` HideMarks *bool `json:"hide_marks,omitempty"` Labels *Labels `json:"labels,omitempty"` Randomize *bool `json:"randomize,omitempty"` StartAtOne *bool `json:"start_at_one,omitempty"` Steps *int `json:"steps,omitempty"` Shape *string `json:"shape,omitempty"` }
type ThankyouScreen ¶
type ThankyouScreen struct { Title string `json:"title"` Ref string `json:"ref,omitempty"` Attachment *Attachment `json:"attachment,omitempty"` Properties *ThankYouScreenProperties `json:"properties,omitempty"` Layout *Layout `json:"layout,omitempty"` }
type Validations ¶
type Validations struct { MaxLength *int `json:"max_length,omitempty"` MaxSelection *int `json:"max_selection,omitempty"` MaxValue *int `json:"max_value,omitempty"` MinSelection *int `json:"min_selection,omitempty"` MinValue *int `json:"min_value,omitempty"` Required *bool `json:"required,omitempty"` }
type WelcomeScreen ¶
type WelcomeScreen struct { Ref string `json:"ref,omitempty"` Title string `json:"title"` Layout *Layout `json:"layout,omitempty"` Properties *WelcomeScreenProperties `json:"properties,omitempty"` Attachment *Attachment `json:"attachment,omitempty"` }
type WelcomeScreenProperties ¶
Click to show internal directories.
Click to hide internal directories.