Documentation ¶
Overview ¶
Package webhooks contains auto-generated files. DO NOT MODIFY
Package webhooks contains auto-generated files. DO NOT MODIFY
Package webhooks contains auto-generated files. DO NOT MODIFY
Index ¶
- type Client
- func (c Client) Create(input *CreateConversationWebhookInput) (*CreateConversationWebhookResponse, error)
- func (c Client) CreateWithContext(context context.Context, input *CreateConversationWebhookInput) (*CreateConversationWebhookResponse, error)
- func (c *Client) NewConversationWebhooksPaginator() *ConversationWebhooksPaginator
- func (c *Client) NewConversationWebhooksPaginatorWithOptions(options *ConversationWebhooksPageOptions) *ConversationWebhooksPaginator
- func (c Client) Page(options *ConversationWebhooksPageOptions) (*ConversationWebhooksPageResponse, error)
- func (c Client) PageWithContext(context context.Context, options *ConversationWebhooksPageOptions) (*ConversationWebhooksPageResponse, error)
- type ClientProperties
- type ConversationWebhooksPage
- type ConversationWebhooksPageOptions
- type ConversationWebhooksPageResponse
- type ConversationWebhooksPaginator
- type CreateConversationWebhookInput
- type CreateConversationWebhookResponse
- type CreateConversationWebhookResponseConfiguration
- type PageConversationWebhookResponse
- type PageConversationWebhookResponseConfiguration
- type PageMetaResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client for managing webhook resources See https://www.twilio.com/docs/conversations/api/conversation-scoped-webhook-resource for more details
func New ¶
func New(client *client.Client, properties ClientProperties) *Client
New creates a new instance of the webhooks client
func (Client) Create ¶
func (c Client) Create(input *CreateConversationWebhookInput) (*CreateConversationWebhookResponse, error)
Create creates a new webhook See https://www.twilio.com/docs/conversations/api/conversation-scoped-webhook-resource#create-a-conversationscopedwebhook-resource for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information
func (Client) CreateWithContext ¶
func (c Client) CreateWithContext(context context.Context, input *CreateConversationWebhookInput) (*CreateConversationWebhookResponse, error)
CreateWithContext creates a new webhook See https://www.twilio.com/docs/conversations/api/conversation-scoped-webhook-resource#create-a-conversationscopedwebhook-resource for more details
func (*Client) NewConversationWebhooksPaginator ¶
func (c *Client) NewConversationWebhooksPaginator() *ConversationWebhooksPaginator
NewConversationWebhooksPaginator creates a new instance of the paginator for Page.
func (*Client) NewConversationWebhooksPaginatorWithOptions ¶
func (c *Client) NewConversationWebhooksPaginatorWithOptions(options *ConversationWebhooksPageOptions) *ConversationWebhooksPaginator
NewConversationWebhooksPaginatorWithOptions creates a new instance of the paginator for Page with options.
func (Client) Page ¶
func (c Client) Page(options *ConversationWebhooksPageOptions) (*ConversationWebhooksPageResponse, error)
Page retrieves a page of webhooks See https://www.twilio.com/docs/conversations/api/conversation-scoped-webhook-resource#read-multiple-conversationscopedwebhook-resources for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information
func (Client) PageWithContext ¶
func (c Client) PageWithContext(context context.Context, options *ConversationWebhooksPageOptions) (*ConversationWebhooksPageResponse, error)
PageWithContext retrieves a page of webhooks See https://www.twilio.com/docs/conversations/api/conversation-scoped-webhook-resource#read-multiple-conversationscopedwebhook-resources for more details
type ClientProperties ¶
type ClientProperties struct {
ConversationSid string
}
ClientProperties are the properties required to manage the webhooks resources
type ConversationWebhooksPage ¶
type ConversationWebhooksPage struct { CurrentPage *ConversationWebhooksPageResponse Error error // contains filtered or unexported fields }
ConversationWebhooksPage defines the fields for the page The CurrentPage and Error fields can be used to access the PageConversationWebhookResponse or error that is returned from the api call(s)
type ConversationWebhooksPageOptions ¶
ConversationWebhooksPageOptions defines the query options for the api operation
type ConversationWebhooksPageResponse ¶
type ConversationWebhooksPageResponse struct { Meta PageMetaResponse `json:"meta"` Webhooks []PageConversationWebhookResponse `json:"webhooks"` }
ConversationWebhooksPageResponse defines the response fields for the webhooks page
type ConversationWebhooksPaginator ¶
type ConversationWebhooksPaginator struct { Page *ConversationWebhooksPage Webhooks []PageConversationWebhookResponse // contains filtered or unexported fields }
ConversationWebhooksPaginator defines the fields for makings paginated api calls Webhooks is an array of webhooks that have been returned from all of the page calls
func (*ConversationWebhooksPaginator) CurrentPage ¶
func (p *ConversationWebhooksPaginator) CurrentPage() *ConversationWebhooksPageResponse
CurrentPage retrieves the results for the current page
func (*ConversationWebhooksPaginator) Error ¶
func (p *ConversationWebhooksPaginator) Error() error
Error retrieves the error returned from the page
func (*ConversationWebhooksPaginator) Next ¶
func (p *ConversationWebhooksPaginator) Next() bool
Next retrieves the next page of results. Next will return false when either an error occurs or there are no more pages to iterate Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information
func (*ConversationWebhooksPaginator) NextWithContext ¶
func (p *ConversationWebhooksPaginator) NextWithContext(context context.Context) bool
NextWithContext retrieves the next page of results. NextWithContext will return false when either an error occurs or there are no more pages to iterate
type CreateConversationWebhookInput ¶
type CreateConversationWebhookInput struct { ConfigurationFilters *[]string `form:"Configuration.Filters,omitempty"` ConfigurationFlowSid *string `form:"Configuration.FlowSid,omitempty"` ConfigurationMethod *string `form:"Configuration.Method,omitempty"` ConfigurationReplayAfter *int `form:"Configuration.ReplayAfter,omitempty"` ConfigurationTriggers *[]string `form:"Configuration.Triggers,omitempty"` ConfigurationURL *string `form:"Configuration.Url,omitempty"` Target string `validate:"required" form:"Target"` }
CreateConversationWebhookInput defines the input fields for creating a new webhook resource
type CreateConversationWebhookResponse ¶
type CreateConversationWebhookResponse struct { AccountSid string `json:"account_sid"` Configuration CreateConversationWebhookResponseConfiguration `json:"configuration"` ConversationSid string `json:"conversation_sid"` DateCreated time.Time `json:"date_created"` DateUpdated *time.Time `json:"date_updated,omitempty"` Sid string `json:"sid"` Target string `json:"target"` URL string `json:"url"` }
CreateConversationWebhookResponse defines the response fields for the created webhook
type CreateConversationWebhookResponseConfiguration ¶
type CreateConversationWebhookResponseConfiguration struct { Filters *[]string `json:"filters,omitempty"` FlowSid *string `json:"flow_sid,omitempty"` Method *string `json:"method,omitempty"` ReplayAfter *int `json:"replay_after,omitempty"` Triggers *[]string `json:"triggers,omitempty"` URL *string `json:"url,omitempty"` }
type PageConversationWebhookResponse ¶
type PageConversationWebhookResponse struct { AccountSid string `json:"account_sid"` Configuration PageConversationWebhookResponseConfiguration `json:"configuration"` ConversationSid string `json:"conversation_sid"` DateCreated time.Time `json:"date_created"` DateUpdated *time.Time `json:"date_updated,omitempty"` Sid string `json:"sid"` Target string `json:"target"` URL string `json:"url"` }
type PageConversationWebhookResponseConfiguration ¶
type PageConversationWebhookResponseConfiguration struct { Filters *[]string `json:"filters,omitempty"` FlowSid *string `json:"flow_sid,omitempty"` Method *string `json:"method,omitempty"` ReplayAfter *int `json:"replay_after,omitempty"` Triggers *[]string `json:"triggers,omitempty"` URL *string `json:"url,omitempty"` }