bindings

package
v0.18.0 Latest Latest
Warning

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

Go to latest
Published: Jul 25, 2021 License: Apache-2.0 Imports: 7 Imported by: 2

Documentation

Overview

Package bindings contains auto-generated files. DO NOT MODIFY

Package bindings contains auto-generated files. DO NOT MODIFY

Package bindings 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 BindingsPage

type BindingsPage struct {
	CurrentPage *BindingsPageResponse
	Error       error
	// contains filtered or unexported fields
}

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

type BindingsPageOptions

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

BindingsPageOptions defines the query options for the api operation

type BindingsPageResponse

type BindingsPageResponse struct {
	Bindings []PageBindingResponse `json:"bindings"`
	Meta     PageMetaResponse      `json:"meta"`
}

BindingsPageResponse defines the response fields for the service bindings page

type BindingsPaginator

type BindingsPaginator struct {
	Page     *BindingsPage
	Bindings []PageBindingResponse
	// contains filtered or unexported fields
}

BindingsPaginator defines the fields for makings paginated api calls Bindings is an array of bindings that have been returned from all of the page calls

func (*BindingsPaginator) CurrentPage

func (p *BindingsPaginator) CurrentPage() *BindingsPageResponse

CurrentPage retrieves the results for the current page

func (*BindingsPaginator) Error

func (p *BindingsPaginator) Error() error

Error retrieves the error returned from the page

func (*BindingsPaginator) Next

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

func (p *BindingsPaginator) 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 service bindings resources See https://www.twilio.com/docs/notify/api/binding-resource for more details

func New

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

New creates a new instance of the bindings client

func (Client) Create

Create creates a service binding resource See https://www.twilio.com/docs/notify/api/binding-resource#create-a-binding-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 *CreateBindingInput) (*CreateBindingResponse, error)

CreateWithContext creates a service binding resource See https://www.twilio.com/docs/notify/api/binding-resource#create-a-binding-resource for more details

func (*Client) NewBindingsPaginator

func (c *Client) NewBindingsPaginator() *BindingsPaginator

NewBindingsPaginator creates a new instance of the paginator for Page.

func (*Client) NewBindingsPaginatorWithOptions

func (c *Client) NewBindingsPaginatorWithOptions(options *BindingsPageOptions) *BindingsPaginator

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

func (Client) Page

Page retrieves a page of service bindings See https://www.twilio.com/docs/notify/api/binding-resource#read-multiple-binding-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 *BindingsPageOptions) (*BindingsPageResponse, error)

PageWithContext retrieves a page of service bindings See https://www.twilio.com/docs/notify/api/binding-resource#read-multiple-binding-resources for more details

type ClientProperties

type ClientProperties struct {
	ServiceSid string
}

ClientProperties are the properties required to manage the bindings resources

type CreateBindingInput

type CreateBindingInput struct {
	Address                     string    `validate:"required" form:"Address"`
	BindingType                 string    `validate:"required" form:"BindingType"`
	CredentialSid               *string   `form:"CredentialSid,omitempty"`
	Identity                    string    `validate:"required" form:"Identity"`
	NotificationProtocolVersion *string   `form:"NotificationProtocolVersion,omitempty"`
	Tags                        *[]string `form:"Tag,omitempty"`
}

CreateBindingInput defines the input fields for creating a new service binding

type CreateBindingResponse

type CreateBindingResponse struct {
	AccountSid                  string     `json:"account_sid"`
	Address                     string     `json:"address"`
	BindingType                 string     `json:"binding_type"`
	CredentialSid               *string    `json:"credential_sid,omitempty"`
	DateCreated                 time.Time  `json:"date_created"`
	DateUpdated                 *time.Time `json:"date_updated,omitempty"`
	Identity                    string     `json:"identity"`
	NotificationProtocolVersion string     `json:"notification_protocol_version"`
	ServiceSid                  string     `json:"service_sid"`
	Sid                         string     `json:"sid"`
	Tags                        []string   `json:"tags"`
	URL                         string     `json:"url"`
}

CreateBindingResponse defines the response fields for the retrieved service binding

type PageBindingResponse

type PageBindingResponse struct {
	AccountSid                  string     `json:"account_sid"`
	Address                     string     `json:"address"`
	BindingType                 string     `json:"binding_type"`
	CredentialSid               *string    `json:"credential_sid,omitempty"`
	DateCreated                 time.Time  `json:"date_created"`
	DateUpdated                 *time.Time `json:"date_updated,omitempty"`
	Identity                    string     `json:"identity"`
	NotificationProtocolVersion string     `json:"notification_protocol_version"`
	ServiceSid                  string     `json:"service_sid"`
	Sid                         string     `json:"sid"`
	Tags                        []string   `json:"tags"`
	URL                         string     `json:"url"`
}

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"`
}

Jump to

Keyboard shortcuts

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