steps

package
v0.16.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 22, 2021 License: Apache-2.0 Imports: 7 Imported by: 1

Documentation

Overview

Package steps contains auto-generated files. DO NOT MODIFY

Package steps contains auto-generated files. DO NOT MODIFY

Index

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 step resources See https://www.twilio.com/docs/studio/rest-api/v2/step for more details

func New

func New(client *client.Client, properties ClientProperties) *Client

New creates a new instance of the steps client

func (*Client) NewStepsPaginator

func (c *Client) NewStepsPaginator() *StepsPaginator

NewStepsPaginator creates a new instance of the paginator for Page.

func (*Client) NewStepsPaginatorWithOptions

func (c *Client) NewStepsPaginatorWithOptions(options *StepsPageOptions) *StepsPaginator

NewStepsPaginatorWithOptions creates a new instance of the paginator for Page with options.

func (Client) Page

func (c Client) Page(options *StepsPageOptions) (*StepsPageResponse, error)

Page retrieves a page of steps See https://www.twilio.com/docs/studio/rest-api/v2/step#read-a-list-of-step-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 *StepsPageOptions) (*StepsPageResponse, error)

PageWithContext retrieves a page of steps See https://www.twilio.com/docs/studio/rest-api/v2/step#read-a-list-of-step-resources for more details

type ClientProperties

type ClientProperties struct {
	ExecutionSid string
	FlowSid      string
}

ClientProperties are the properties required to manage the steps resources

type PageMetaResponse

type PageMetaResponse struct {
	FirstPageURL    string  `json:"first_page_url"`
	Key             string  `json:"key"`
	NextPageURL     *string `json:"next_page_url,omitempty"`
	Page            int     `json:"page"`
	PageSize        int     `json:"page_size"`
	PreviousPageURL *string `json:"previous_page_url,omitempty"`
	URL             string  `json:"url"`
}

type PageStepResponse

type PageStepResponse struct {
	AccountSid       string      `json:"account_sid"`
	Context          interface{} `json:"context"`
	DateCreated      time.Time   `json:"date_created"`
	DateUpdated      *time.Time  `json:"date_updated,omitempty"`
	ExecutionSid     string      `json:"execution_sid"`
	FlowSid          string      `json:"flow_sid"`
	Name             string      `json:"name"`
	Sid              string      `json:"sid"`
	TransitionedFrom string      `json:"transitioned_from"`
	TransitionedTo   string      `json:"transitioned_to"`
	URL              string      `json:"url"`
}

type StepsPage

type StepsPage struct {
	CurrentPage *StepsPageResponse
	Error       error
	// contains filtered or unexported fields
}

StepsPage defines the fields for the page The CurrentPage and Error fields can be used to access the PageStepResponse or error that is returned from the api call(s)

type StepsPageOptions

type StepsPageOptions struct {
	PageSize  *int
	Page      *int
	PageToken *string
}

StepsPageOptions defines the query options for the api operation

type StepsPageResponse

type StepsPageResponse struct {
	Meta  PageMetaResponse   `json:"meta"`
	Steps []PageStepResponse `json:"steps"`
}

StepsPageResponse defines the response fields for the steps page

type StepsPaginator

type StepsPaginator struct {
	Page  *StepsPage
	Steps []PageStepResponse
	// contains filtered or unexported fields
}

StepsPaginator defines the fields for makings paginated api calls Steps is an array of steps that have been returned from all of the page calls

func (*StepsPaginator) CurrentPage

func (p *StepsPaginator) CurrentPage() *StepsPageResponse

CurrentPage retrieves the results for the current page

func (*StepsPaginator) Error

func (p *StepsPaginator) Error() error

Error retrieves the error returned from the page

func (*StepsPaginator) Next

func (p *StepsPaginator) 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 (*StepsPaginator) NextWithContext

func (p *StepsPaginator) 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

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL