session

package
v0.23.1 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2022 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Overview

Package session contains auto-generated files. DO NOT MODIFY

Package session contains auto-generated files. DO NOT MODIFY

Package session contains auto-generated files. DO NOT MODIFY

Package session 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 {
	Interaction  func(string) *interaction.Client
	Interactions *interactions.Client
	Participant  func(string) *participant.Client
	Participants *participants.Client
	// contains filtered or unexported fields
}

Client for managing a specific session resource See https://www.twilio.com/docs/proxy/api/session for more details

func New

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

New creates a new instance of the session client

func (Client) Delete

func (c Client) Delete() error

Delete removes a session resource from the account See https://www.twilio.com/docs/proxy/api/session#delete-a-session-resource for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information

func (Client) DeleteWithContext

func (c Client) DeleteWithContext(context context.Context) error

DeleteWithContext removes a session resource from the account See https://www.twilio.com/docs/proxy/api/session#delete-a-session-resource for more details

func (Client) Fetch

func (c Client) Fetch() (*FetchSessionResponse, error)

Fetch retrieves a session resource See https://www.twilio.com/docs/proxy/api/session#fetch-a-session-resource for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information

func (Client) FetchWithContext

func (c Client) FetchWithContext(context context.Context) (*FetchSessionResponse, error)

FetchWithContext retrieves a session resource See https://www.twilio.com/docs/proxy/api/session#fetch-a-session-resource for more details

func (Client) Update

Update modifies a session resource See https://www.twilio.com/docs/proxy/api/session#update-a-session-resource for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information

func (Client) UpdateWithContext

func (c Client) UpdateWithContext(context context.Context, input *UpdateSessionInput) (*UpdateSessionResponse, error)

UpdateWithContext modifies a session resource See https://www.twilio.com/docs/proxy/api/session#update-a-session-resource for more details

type ClientProperties

type ClientProperties struct {
	ServiceSid string
	Sid        string
}

ClientProperties are the properties required to manage the session resources

type FetchSessionResponse

type FetchSessionResponse struct {
	AccountSid          string     `json:"account_sid"`
	ClosedReason        *string    `json:"closed_reason,omitempty"`
	DateCreated         time.Time  `json:"date_created"`
	DateEnded           *time.Time `json:"date_ended,omitempty"`
	DateExpiry          *time.Time `json:"date_expiry,omitempty"`
	DateLastInteraction *time.Time `json:"date_last_interaction,omitempty"`
	DateStarted         *time.Time `json:"date_started,omitempty"`
	DateUpdated         *time.Time `json:"date_updated,omitempty"`
	Mode                *string    `json:"mode,omitempty"`
	ServiceSid          string     `json:"service_sid"`
	Sid                 string     `json:"sid"`
	Status              *string    `json:"status,omitempty"`
	Ttl                 *int       `json:"ttl,omitempty"`
	URL                 string     `json:"url"`
	UniqueName          string     `json:"unique_name"`
}

FetchSessionResponse defines the response fields for the retrieved session

type UpdateSessionInput

type UpdateSessionInput struct {
	DateExpiry *time.Time `form:"DateExpiry,omitempty"`
	Status     *string    `form:"Status,omitempty"`
	Ttl        *int       `form:"Ttl,omitempty"`
}

UpdateSessionInput defines input fields for updating a session resource

type UpdateSessionResponse

type UpdateSessionResponse struct {
	AccountSid          string     `json:"account_sid"`
	ClosedReason        *string    `json:"closed_reason,omitempty"`
	DateCreated         time.Time  `json:"date_created"`
	DateEnded           *time.Time `json:"date_ended,omitempty"`
	DateExpiry          *time.Time `json:"date_expiry,omitempty"`
	DateLastInteraction *time.Time `json:"date_last_interaction,omitempty"`
	DateStarted         *time.Time `json:"date_started,omitempty"`
	DateUpdated         *time.Time `json:"date_updated,omitempty"`
	Mode                *string    `json:"mode,omitempty"`
	ServiceSid          string     `json:"service_sid"`
	Sid                 string     `json:"sid"`
	Status              *string    `json:"status,omitempty"`
	Ttl                 *int       `json:"ttl,omitempty"`
	URL                 string     `json:"url"`
	UniqueName          string     `json:"unique_name"`
}

UpdateSessionResponse defines the response fields for the updated session

Directories

Path Synopsis
Package interaction contains auto-generated files.
Package interaction contains auto-generated files.
Package interactions contains auto-generated files.
Package interactions contains auto-generated files.
Package participant contains auto-generated files.
Package participant contains auto-generated files.
message_interactions
Package message_interactions contains auto-generated files.
Package message_interactions contains auto-generated files.
Package participants contains auto-generated files.
Package participants contains auto-generated files.

Jump to

Keyboard shortcuts

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