Documentation
¶
Index ¶
- type Actions
- type Attachment
- type AttachmentProperties
- type Background
- type Choices
- type ChoicesAttachment
- type Colors
- type Condition
- type CreateImageRequestBody
- type CuiSettings
- type CustomFormMessages
- type Details
- type Fields
- type FieldsProperties
- type Form
- type FormItems
- type FormLinks
- type FormQueryParams
- type Forms
- type Image
- type ImageHref
- type Images
- type Labels
- type Layout
- type Logic
- type Members
- type Meta
- type Notifications
- type NotificationsSelf
- type Options
- type Price
- type Respondent
- type Screens
- type Self
- type Settings
- type Target
- type ThankYouScreenProperties
- type ThankyouScreen
- type Theme
- type ThemeFields
- type ThemeHref
- type ThemeQueryParams
- type Themes
- type To
- type Typeform
- func (t *Typeform) CreateForm(formdata Form) (*Form, error)
- func (t *Typeform) CreateImage(img CreateImageRequestBody) (*Image, error)
- func (t *Typeform) CreateTheme(themedata Theme) (*Theme, error)
- func (t *Typeform) CreateWorkspace(name string) (*Workspace, error)
- func (t *Typeform) DeleteForm(id string) error
- func (t *Typeform) DeleteImage(id string) error
- func (t *Typeform) DeleteTheme(id string) error
- func (t *Typeform) DeleteWorkspace(id string) error
- func (t *Typeform) GetAllForms(params FormQueryParams) (*Forms, error)
- func (t *Typeform) GetAllImages() (*[]Images, error)
- func (t *Typeform) GetAllThemes(params ThemeQueryParams) (*Themes, error)
- func (t *Typeform) GetAllWorkspaces(params WorkspaceQueryParams) (*Workspaces, error)
- func (t *Typeform) GetAllWorkspacesInAccount(id string, params WorkspaceQueryParams) (*Workspaces, error)
- func (t *Typeform) GetCustomFormMessages(id string) (*CustomFormMessages, error)
- func (t *Typeform) GetForm(id string) (*Form, error)
- func (t *Typeform) GetImage(id string) (*Image, error)
- func (t *Typeform) GetTheme(id string) (*Theme, error)
- func (t *Typeform) GetUser() (*User, error)
- func (t *Typeform) GetWorkspace(id string) (*Workspace, error)
- func (t *Typeform) UpdateCustomFormMessages(id string, messages CustomFormMessages) error
- func (t *Typeform) UpdateForm(id string, updates []UpdateRequestBody) error
- func (t *Typeform) UpdateTheme(id string, theme Theme) error
- func (t *Typeform) UpdateWorkspace(id string, updates []UpdateRequestBody) error
- type UpdateRequestBody
- type User
- type Validations
- type Value
- type Variables
- type Vars
- type WelcomeScreen
- type WelcomeScreenProperties
- type Workspace
- type WorkspaceForms
- type WorkspaceHref
- type WorkspaceName
- type WorkspaceQueryParams
- type Workspaces
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Attachment ¶
type Attachment struct { Href string `json:"href,omitempty"` Type string `json:"type,omitempty"` Scale int `json:"scale,omitempty"` Properties AttachmentProperties `json:"properties,omitempty"` }
type AttachmentProperties ¶
type AttachmentProperties struct {
Description string `json:"description,omitempty"`
}
type Background ¶
type Choices ¶
type Choices struct { Label string `json:"label,omitempty"` Ref string `json:"ref,omitempty"` Attachment ChoicesAttachment `json:"attachment,omitempty"` }
type ChoicesAttachment ¶
type CreateImageRequestBody ¶
type CuiSettings ¶
type CuiSettings struct { Avatar string `json:"avatar,omitempty"` IsTypingEmulationDisabled bool `json:"is_typing_emulation_disabled,omitempty"` TypingEmulationSpeed string `json:"typing_emulation_speed,omitempty"` }
ToDo : Fields in Form
type CustomFormMessages ¶
type CustomFormMessages struct { LabelButtonHintDefault string `json:"label.buttonHint.default,omitempty"` LabelButtonHintLongtext string `json:"label.buttonHint.longtext,omitempty"` LabelWarningConnection string `json:"label.warning.connection,omitempty"` LabelButtonNoAnswerDefault string `json:"label.buttonNoAnswer.default,omitempty"` LabelWarningCorrection string `json:"label.warning.correction,omitempty"` BlockPaymentCardNameTitle string `json:"block.payment.cardNameTitle,omitempty"` BlockPaymentCardNumberTitle string `json:"block.payment.cardNumberTitle,omitempty"` BlockPaymentCvcDescription string `json:"block.payment.cvcDescription,omitempty"` BlockPaymentCvcNumberTitle string `json:"block.payment.cvcNumberTitle,omitempty"` BlockShortTextPlaceholder string `json:"block.shortText.placeholder,omitempty"` LabelErrorEmailAddress string `json:"label.error.emailAddress,omitempty"` LabelErrorExpiryMonthTitle string `json:"label.error.expiryMonthTitle,omitempty"` LabelErrorExpiryYearTitle string `json:"label.error.expiryYearTitle,omitempty"` LabelWarningFallbackAlert string `json:"label.warning.fallbackAlert,omitempty"` BlockFileUploadChoose string `json:"block.fileUpload.choose,omitempty"` BlockFileUploadDrag string `json:"block.fileUpload.drag,omitempty"` BlockFileUploadUploadingProgress string `json:"block.fileUpload.uploadingProgress,omitempty"` LabelErrorSizeLimit string `json:"label.error.sizeLimit,omitempty"` LabelErrorIncompleteForm string `json:"label.error.incompleteForm,omitempty"` LabelHintKey string `json:"label.hint.key,omitempty"` BlockLegalReject string `json:"block.legal.reject,omitempty"` BlockLegalAccept string `json:"block.legal.accept,omitempty"` LabelErrorMaxValue string `json:"label.error.maxValue,omitempty"` LabelErrorMaxLength string `json:"label.error.maxLength,omitempty"` LabelErrorMinValue string `json:"label.error.minValue,omitempty"` LabelErrorRange string `json:"label.error.range,omitempty"` BlockMultipleChoiceHint string `json:"block.multipleChoice.hint,omitempty"` LabelErrorMustEnter string `json:"label.error.mustEnter,omitempty"` LabelErrorMustSelect string `json:"label.error.mustSelect,omitempty"` LabelNoShortcut string `json:"label.no.shortcut,omitempty"` LabelNoDefault string `json:"label.no.default,omitempty"` BlockDropdownHint string `json:"block.dropdown.hint,omitempty"` BlockMultipleChoiceOther string `json:"block.multipleChoice.other,omitempty"` LabelProgressPercent string `json:"label.progress.percent,omitempty"` LabelProgressProportion string `json:"label.progress.proportion,omitempty"` LabelErrorRequired string `json:"label.error.required,omitempty"` LabelPreview string `json:"label.preview,omitempty"` LabelButtonReview string `json:"label.button.review,omitempty"` LabelErrorServer string `json:"label.error.server,omitempty"` LabelButtonSubmit string `json:"label.button.submit,omitempty"` LabelWarningSuccess string `json:"label.warning.success,omitempty"` LabelButtonOk string `json:"label.button.ok,omitempty"` LabelErrorMustAccept string `json:"label.error.mustAccept,omitempty"` BlockLongtextHint string `json:"block.longtext.hint,omitempty"` BlockDropdownPlaceholder string `json:"block.dropdown.placeholder,omitempty"` BlockDropdownPlaceholderTouch string `json:"block.dropdown.placeholderTouch,omitempty"` LabelErrorURL string `json:"label.error.url,omitempty"` LabelYesShortcut string `json:"label.yes.shortcut,omitempty"` LabelYesDefault string `json:"label.yes.default,omitempty"` }
type Fields ¶
type Fields struct { Attachment Attachment `json:"attachment,omitempty"` FieldType string `json:"field_type,omitempty"` ID string `json:"id,omitempty"` Layout Layout `json:"layout,omitempty"` Name string `json:"name,omitempty"` Options Options `json:"options,omitempty"` Properties FieldsProperties `json:"properties,omitempty"` Ref string `json:"ref,omitempty"` Required bool `json:"required,omitempty"` Title string `json:"title"` Type string `json:"type"` Validations Validations `json:"validations,omitempty"` }
type FieldsProperties ¶
type FieldsProperties struct { AllowMultipleSelection bool `json:"allow_multiple_selection"` AllowOtherChoice bool `json:"allow_other_choice"` AlphabeticalOrder bool `json:"alphabetical_order"` ButtonText string `json:"button_text"` Choices []Choices `json:"choices"` Currency string `json:"currency"` DefaultCountryCode string `json:"default_country_code"` Description string `json:"description"` Fields *Fields `json:"fields"` HideMarks bool `json:"hide_marks"` Labels Labels `json:"labels"` Price Price `json:"price"` Randomize bool `json:"randomize"` Separator string `json:"separator"` Shape string `json:"shape"` ShowButton bool `json:"show_button"` ShowLabels bool `json:"show_labels"` StartAtOne bool `json:"start_at_one"` Steps int `json:"steps"` Structure string `json:"structure"` Supersized bool `json:"supersized"` VerticalAlignment bool `json:"vertical_alignment"` }
type Form ¶
type Form struct { CuiSettings *CuiSettings `json:"cui_settings,omitempty"` Fields *[]Fields `json:"fields,omitempty"` Hidden *[]string `json:"hidden,omitempty"` Logic *[]Logic `json:"logic,omitempty"` Settings *Settings `json:"settings,omitempty"` ThankyouScreens *[]ThankyouScreen `json:"thankyou_screens,omitempty"` Theme *ThemeHref `json:"theme,omitempty"` Title string `json:"title"` Type string `json:"type"` Variables *Variables `json:"variables,omitempty"` WelcomeScreens *[]WelcomeScreen `json:"welcome_screens,omitempty"` Workspace *WorkspaceHref `json:"workspace,omitempty"` }
type FormQueryParams ¶
type Layout ¶
type Layout struct { Attachment Attachment `json:"attachment,omitempty"` Placement string `json:"placement,omitempty"` Type string `json:"type,omitempty"` }
type Notifications ¶
type Notifications struct { Respondent Respondent `json:"respondent,omitempty"` Self NotificationsSelf `json:"self,omitempty"` }
type NotificationsSelf ¶
type Respondent ¶
type Settings ¶
type Settings struct { FacebookPixel string `json:"facebook_pixel,omitempty"` GoogleAnalytics string `json:"google_analytics,omitempty"` GoogleTagManager string `json:"google_tag_manager,omitempty"` IsPublic bool `json:"is_public,omitempty"` Language string `json:"language,omitempty"` Meta Meta `json:"meta,omitempty"` Notifications Notifications `json:"notifications,omitempty"` ProgressBar string `json:"progress_bar,omitempty"` RedirectAfterSubmitURL string `json:"redirect_after_submit_url,omitempty"` ShowProgressBar bool `json:"show_progress_bar,omitempty"` ShowTimeToComplete bool `json:"show_time_to_complete,omitempty"` ShowTypeformBranding bool `json:"show_typeform_branding,omitempty"` }
type ThankyouScreen ¶
type ThankyouScreen struct { Attachment Attachment `json:"attachment,omitempty"` Properties ThankYouScreenProperties `json:"properties,omitempty"` Ref string `json:"ref,omitempty"` Title string `json:"title"` Layout Layout `json:"layout,omitempty"` }
type Theme ¶
type Theme struct { Background *Background `json:"background,omitempty"` Colors *Colors `json:"colors,omitempty"` Fields *ThemeFields `json:"fields,omitempty"` Font string `json:"font,omitempty"` HasTransparentButton bool `json:"has_transparent_button"` ID string `json:"id,omitempty"` Name string `json:"name"` Screens *Screens `json:"screens,omitempty"` Visibility string `json:"visibility,omitempty"` }
type ThemeFields ¶
type ThemeQueryParams ¶
type Typeform ¶
type Typeform struct {
// contains filtered or unexported fields
}
func TypeformClient ¶
func (*Typeform) CreateImage ¶
func (t *Typeform) CreateImage(img CreateImageRequestBody) (*Image, error)
func (*Typeform) CreateWorkspace ¶
func (*Typeform) DeleteForm ¶
func (*Typeform) DeleteImage ¶
func (*Typeform) DeleteTheme ¶
func (*Typeform) DeleteWorkspace ¶
func (*Typeform) GetAllForms ¶
func (t *Typeform) GetAllForms(params FormQueryParams) (*Forms, error)
func (*Typeform) GetAllImages ¶
func (*Typeform) GetAllThemes ¶
func (t *Typeform) GetAllThemes(params ThemeQueryParams) (*Themes, error)
func (*Typeform) GetAllWorkspaces ¶
func (t *Typeform) GetAllWorkspaces(params WorkspaceQueryParams) (*Workspaces, error)
func (*Typeform) GetAllWorkspacesInAccount ¶
func (t *Typeform) GetAllWorkspacesInAccount(id string, params WorkspaceQueryParams) (*Workspaces, error)
func (*Typeform) GetCustomFormMessages ¶
func (t *Typeform) GetCustomFormMessages(id string) (*CustomFormMessages, error)
func (*Typeform) UpdateCustomFormMessages ¶
func (t *Typeform) UpdateCustomFormMessages(id string, messages CustomFormMessages) error
func (*Typeform) UpdateForm ¶
func (t *Typeform) UpdateForm(id string, updates []UpdateRequestBody) error
func (*Typeform) UpdateWorkspace ¶
func (t *Typeform) UpdateWorkspace(id string, updates []UpdateRequestBody) error
type UpdateRequestBody ¶
type Validations ¶
type WelcomeScreen ¶
type WelcomeScreen struct { Layout Layout `json:"layout,omitempty"` Properties WelcomeScreenProperties `json:"properties,omitempty"` Ref string `json:"ref,omitempty"` Title string `json:"title"` Attachment Attachment `json:"attachment,omitempty"` }
type WelcomeScreenProperties ¶
type WorkspaceForms ¶
type WorkspaceHref ¶
type WorkspaceHref struct {
Href string `json:"href,omitempty"`
}
type WorkspaceName ¶
type WorkspaceName struct {
Name string `json:"name"`
}
type WorkspaceQueryParams ¶
type Workspaces ¶
Source Files
¶
Click to show internal directories.
Click to hide internal directories.