Documentation ¶
Overview ¶
Package challenges contains auto-generated files. DO NOT MODIFY
Package challenges contains auto-generated files. DO NOT MODIFY
Package challenges contains auto-generated files. DO NOT MODIFY
Index ¶
- type ChallengesPage
- type ChallengesPageOptions
- type ChallengesPageResponse
- type ChallengesPaginator
- type Client
- func (c Client) Create(input *CreateChallengeInput) (*CreateChallengeResponse, error)
- func (c Client) CreateWithContext(context context.Context, input *CreateChallengeInput) (*CreateChallengeResponse, error)
- func (c *Client) NewChallengesPaginator() *ChallengesPaginator
- func (c *Client) NewChallengesPaginatorWithOptions(options *ChallengesPageOptions) *ChallengesPaginator
- func (c Client) Page(options *ChallengesPageOptions) (*ChallengesPageResponse, error)
- func (c Client) PageWithContext(context context.Context, options *ChallengesPageOptions) (*ChallengesPageResponse, error)
- type ClientProperties
- type CreateChallengeDetailsInput
- type CreateChallengeDetailsResponse
- type CreateChallengeInput
- type CreateChallengeResponse
- type PageChallengeDetailsResponse
- type PageChallengeResponse
- type PageMetaResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChallengesPage ¶
type ChallengesPage struct { CurrentPage *ChallengesPageResponse Error error // contains filtered or unexported fields }
ChallengesPage defines the fields for the page The CurrentPage and Error fields can be used to access the PageChallengeResponse or error that is returned from the api call(s)
type ChallengesPageOptions ¶
type ChallengesPageOptions struct { PageSize *int Page *int PageToken *string FactorSid *string Status *string }
ChallengesPageOptions defines the query options for the api operation
type ChallengesPageResponse ¶
type ChallengesPageResponse struct { Challenges []PageChallengeResponse `json:"challenges"` Meta PageMetaResponse `json:"meta"` }
ChallengesPageResponse defines the response fields for the challenges page
type ChallengesPaginator ¶
type ChallengesPaginator struct { Page *ChallengesPage Challenges []PageChallengeResponse // contains filtered or unexported fields }
ChallengesPaginator defines the fields for makings paginated api calls Challenges is an array of challenges that have been returned from all of the page calls
func (*ChallengesPaginator) CurrentPage ¶
func (p *ChallengesPaginator) CurrentPage() *ChallengesPageResponse
CurrentPage retrieves the results for the current page
func (*ChallengesPaginator) Error ¶
func (p *ChallengesPaginator) Error() error
Error retrieves the error returned from the page
func (*ChallengesPaginator) Next ¶
func (p *ChallengesPaginator) 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 (*ChallengesPaginator) NextWithContext ¶
func (p *ChallengesPaginator) 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 Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client for managing challenge resources See https://www.twilio.com/docs/verify/api/challenge for more details This client is currently in beta and subject to change. Please use with caution
func New ¶
func New(client *client.Client, properties ClientProperties) *Client
New creates a new instance of the challenges client
func (Client) Create ¶
func (c Client) Create(input *CreateChallengeInput) (*CreateChallengeResponse, error)
Create creates a new challenge See https://www.twilio.com/docs/verify/api/challenge#create-a-challenge-resource for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information This resource is currently in beta and subject to change. Please use with caution
func (Client) CreateWithContext ¶
func (c Client) CreateWithContext(context context.Context, input *CreateChallengeInput) (*CreateChallengeResponse, error)
CreateWithContext creates a new challenge See https://www.twilio.com/docs/verify/api/challenge#create-a-challenge-resource for more details This resource is currently in beta and subject to change. Please use with caution
func (*Client) NewChallengesPaginator ¶
func (c *Client) NewChallengesPaginator() *ChallengesPaginator
NewChallengesPaginator creates a new instance of the paginator for Page.
func (*Client) NewChallengesPaginatorWithOptions ¶
func (c *Client) NewChallengesPaginatorWithOptions(options *ChallengesPageOptions) *ChallengesPaginator
NewChallengesPaginatorWithOptions creates a new instance of the paginator for Page with options.
func (Client) Page ¶
func (c Client) Page(options *ChallengesPageOptions) (*ChallengesPageResponse, error)
Page retrieves a page of challenges See https://www.twilio.com/docs/verify/api/challenge#read-multiple-challenge-resources for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information This resource is currently in beta and subject to change. Please use with caution
func (Client) PageWithContext ¶
func (c Client) PageWithContext(context context.Context, options *ChallengesPageOptions) (*ChallengesPageResponse, error)
PageWithContext retrieves a page of challenges See https://www.twilio.com/docs/verify/api/challenge#read-multiple-challenge-resources for more details This resource is currently in beta and subject to change. Please use with caution
type ClientProperties ¶
ClientProperties are the properties required to manage the challenges resources
type CreateChallengeInput ¶
type CreateChallengeInput struct { Details *CreateChallengeDetailsInput `form:"Details,omitempty"` ExpirationDate *time.Time `form:"ExpirationDate,omitempty"` FactorSid string `validate:"required" form:"FactorSid"` HiddenDetails *string `form:"HiddenDetails,omitempty"` }
CreateChallengeInput defines the input fields for creating a new challenge
type CreateChallengeResponse ¶
type CreateChallengeResponse struct { AccountSid string `json:"account_sid"` DateCreated time.Time `json:"date_created"` DateResponded *time.Time `json:"date_responded,omitempty"` DateUpdated *time.Time `json:"date_updated,omitempty"` Details *CreateChallengeDetailsResponse `json:"details,omitempty"` EntitySid string `json:"entity_sid"` ExpirationDate time.Time `json:"expiration_date"` FactorSid string `json:"factor_sid"` FactorType string `json:"factor_type"` HiddenDetails *map[string]interface{} `json:"hidden_details,omitempty"` Identity string `json:"identity"` RespondedReason *string `json:"responded_reason,omitempty"` ServiceSid string `json:"service_sid"` Sid string `json:"sid"` Status string `json:"status"` URL string `json:"url"` }
CreateChallengeResponse defines the response fields for the created challenge
type PageChallengeResponse ¶
type PageChallengeResponse struct { AccountSid string `json:"account_sid"` DateCreated time.Time `json:"date_created"` DateResponded *time.Time `json:"date_responded,omitempty"` DateUpdated *time.Time `json:"date_updated,omitempty"` Details *PageChallengeDetailsResponse `json:"details,omitempty"` EntitySid string `json:"entity_sid"` ExpirationDate time.Time `json:"expiration_date"` FactorSid string `json:"factor_sid"` FactorType string `json:"factor_type"` HiddenDetails *map[string]interface{} `json:"hidden_details,omitempty"` Identity string `json:"identity"` RespondedReason *string `json:"responded_reason,omitempty"` ServiceSid string `json:"service_sid"` Sid string `json:"sid"` Status string `json:"status"` URL string `json:"url"` }