Documentation ¶
Index ¶
- type ApiService
- func (c *ApiService) CreateMediaProcessor(params *CreateMediaProcessorParams) (*MediaV1MediaProcessor, error)
- func (c *ApiService) CreatePlayerStreamer(params *CreatePlayerStreamerParams) (*MediaV1PlayerStreamer, error)
- func (c *ApiService) CreatePlayerStreamerPlaybackGrant(Sid string, params *CreatePlayerStreamerPlaybackGrantParams) (*MediaV1PlayerStreamerPlaybackGrant, error)
- func (c *ApiService) FetchMediaProcessor(Sid string) (*MediaV1MediaProcessor, error)
- func (c *ApiService) FetchPlayerStreamer(Sid string) (*MediaV1PlayerStreamer, error)
- func (c *ApiService) FetchPlayerStreamerPlaybackGrant(Sid string) (*MediaV1PlayerStreamerPlaybackGrant, error)
- func (c *ApiService) ListMediaProcessor(params *ListMediaProcessorParams) ([]MediaV1MediaProcessor, error)
- func (c *ApiService) ListPlayerStreamer(params *ListPlayerStreamerParams) ([]MediaV1PlayerStreamer, error)
- func (c *ApiService) PageMediaProcessor(params *ListMediaProcessorParams, pageToken, pageNumber string) (*ListMediaProcessorResponse, error)
- func (c *ApiService) PagePlayerStreamer(params *ListPlayerStreamerParams, pageToken, pageNumber string) (*ListPlayerStreamerResponse, error)
- func (c *ApiService) StreamMediaProcessor(params *ListMediaProcessorParams) (chan MediaV1MediaProcessor, error)
- func (c *ApiService) StreamPlayerStreamer(params *ListPlayerStreamerParams) (chan MediaV1PlayerStreamer, error)
- func (c *ApiService) UpdateMediaProcessor(Sid string, params *UpdateMediaProcessorParams) (*MediaV1MediaProcessor, error)
- func (c *ApiService) UpdatePlayerStreamer(Sid string, params *UpdatePlayerStreamerParams) (*MediaV1PlayerStreamer, error)
- type CreateMediaProcessorParams
- func (params *CreateMediaProcessorParams) SetExtension(Extension string) *CreateMediaProcessorParams
- func (params *CreateMediaProcessorParams) SetExtensionContext(ExtensionContext string) *CreateMediaProcessorParams
- func (params *CreateMediaProcessorParams) SetExtensionEnvironment(ExtensionEnvironment map[string]interface{}) *CreateMediaProcessorParams
- func (params *CreateMediaProcessorParams) SetMaxDuration(MaxDuration int) *CreateMediaProcessorParams
- func (params *CreateMediaProcessorParams) SetStatusCallback(StatusCallback string) *CreateMediaProcessorParams
- func (params *CreateMediaProcessorParams) SetStatusCallbackMethod(StatusCallbackMethod string) *CreateMediaProcessorParams
- type CreatePlayerStreamerParams
- func (params *CreatePlayerStreamerParams) SetStatusCallback(StatusCallback string) *CreatePlayerStreamerParams
- func (params *CreatePlayerStreamerParams) SetStatusCallbackMethod(StatusCallbackMethod string) *CreatePlayerStreamerParams
- func (params *CreatePlayerStreamerParams) SetVideo(Video bool) *CreatePlayerStreamerParams
- type CreatePlayerStreamerPlaybackGrantParams
- type ListMediaProcessorParams
- func (params *ListMediaProcessorParams) SetLimit(Limit int) *ListMediaProcessorParams
- func (params *ListMediaProcessorParams) SetOrder(Order string) *ListMediaProcessorParams
- func (params *ListMediaProcessorParams) SetPageSize(PageSize int) *ListMediaProcessorParams
- func (params *ListMediaProcessorParams) SetStatus(Status string) *ListMediaProcessorParams
- type ListMediaProcessorResponse
- type ListMediaProcessorResponseMeta
- type ListPlayerStreamerParams
- func (params *ListPlayerStreamerParams) SetLimit(Limit int) *ListPlayerStreamerParams
- func (params *ListPlayerStreamerParams) SetOrder(Order string) *ListPlayerStreamerParams
- func (params *ListPlayerStreamerParams) SetPageSize(PageSize int) *ListPlayerStreamerParams
- func (params *ListPlayerStreamerParams) SetStatus(Status string) *ListPlayerStreamerParams
- type ListPlayerStreamerResponse
- type MediaV1MediaProcessor
- type MediaV1PlayerStreamer
- type MediaV1PlayerStreamerPlaybackGrant
- type UpdateMediaProcessorParams
- type UpdatePlayerStreamerParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ApiService ¶
type ApiService struct {
// contains filtered or unexported fields
}
func NewApiService ¶
func NewApiService(requestHandler *twilio.RequestHandler) *ApiService
func NewApiServiceWithClient ¶
func NewApiServiceWithClient(client twilio.BaseClient) *ApiService
func (*ApiService) CreateMediaProcessor ¶
func (c *ApiService) CreateMediaProcessor(params *CreateMediaProcessorParams) (*MediaV1MediaProcessor, error)
func (*ApiService) CreatePlayerStreamer ¶
func (c *ApiService) CreatePlayerStreamer(params *CreatePlayerStreamerParams) (*MediaV1PlayerStreamer, error)
func (*ApiService) CreatePlayerStreamerPlaybackGrant ¶
func (c *ApiService) CreatePlayerStreamerPlaybackGrant(Sid string, params *CreatePlayerStreamerPlaybackGrantParams) (*MediaV1PlayerStreamerPlaybackGrant, error)
func (*ApiService) FetchMediaProcessor ¶
func (c *ApiService) FetchMediaProcessor(Sid string) (*MediaV1MediaProcessor, error)
Returns a single MediaProcessor resource identified by a SID.
func (*ApiService) FetchPlayerStreamer ¶
func (c *ApiService) FetchPlayerStreamer(Sid string) (*MediaV1PlayerStreamer, error)
Returns a single PlayerStreamer resource identified by a SID.
func (*ApiService) FetchPlayerStreamerPlaybackGrant ¶
func (c *ApiService) FetchPlayerStreamerPlaybackGrant(Sid string) (*MediaV1PlayerStreamerPlaybackGrant, error)
**This method is not enabled.** Returns a single PlaybackGrant resource identified by a SID.
func (*ApiService) ListMediaProcessor ¶
func (c *ApiService) ListMediaProcessor(params *ListMediaProcessorParams) ([]MediaV1MediaProcessor, error)
Lists MediaProcessor records from the API as a list. Unlike stream, this operation is eager and loads 'limit' records into memory before returning.
func (*ApiService) ListPlayerStreamer ¶
func (c *ApiService) ListPlayerStreamer(params *ListPlayerStreamerParams) ([]MediaV1PlayerStreamer, error)
Lists PlayerStreamer records from the API as a list. Unlike stream, this operation is eager and loads 'limit' records into memory before returning.
func (*ApiService) PageMediaProcessor ¶
func (c *ApiService) PageMediaProcessor(params *ListMediaProcessorParams, pageToken, pageNumber string) (*ListMediaProcessorResponse, error)
Retrieve a single page of MediaProcessor records from the API. Request is executed immediately.
func (*ApiService) PagePlayerStreamer ¶
func (c *ApiService) PagePlayerStreamer(params *ListPlayerStreamerParams, pageToken, pageNumber string) (*ListPlayerStreamerResponse, error)
Retrieve a single page of PlayerStreamer records from the API. Request is executed immediately.
func (*ApiService) StreamMediaProcessor ¶
func (c *ApiService) StreamMediaProcessor(params *ListMediaProcessorParams) (chan MediaV1MediaProcessor, error)
Streams MediaProcessor records from the API as a channel stream. This operation lazily loads records as efficiently as possible until the limit is reached.
func (*ApiService) StreamPlayerStreamer ¶
func (c *ApiService) StreamPlayerStreamer(params *ListPlayerStreamerParams) (chan MediaV1PlayerStreamer, error)
Streams PlayerStreamer records from the API as a channel stream. This operation lazily loads records as efficiently as possible until the limit is reached.
func (*ApiService) UpdateMediaProcessor ¶
func (c *ApiService) UpdateMediaProcessor(Sid string, params *UpdateMediaProcessorParams) (*MediaV1MediaProcessor, error)
Updates a MediaProcessor resource identified by a SID.
func (*ApiService) UpdatePlayerStreamer ¶
func (c *ApiService) UpdatePlayerStreamer(Sid string, params *UpdatePlayerStreamerParams) (*MediaV1PlayerStreamer, error)
Updates a PlayerStreamer resource identified by a SID.
type CreateMediaProcessorParams ¶
type CreateMediaProcessorParams struct { // The [Media Extension](/docs/live/api/media-extensions-overview) name or URL. Ex: `video-composer-v1` Extension *string `json:"Extension,omitempty"` // The context of the Media Extension, represented as a JSON dictionary. See the documentation for the specific [Media Extension](/docs/live/api/media-extensions-overview) you are using for more information about the context to send. ExtensionContext *string `json:"ExtensionContext,omitempty"` // User-defined environment variables for the Media Extension, represented as a JSON dictionary of key/value strings. See the documentation for the specific [Media Extension](/docs/live/api/media-extensions-overview) you are using for more information about whether you need to provide this. ExtensionEnvironment *map[string]interface{} `json:"ExtensionEnvironment,omitempty"` // The maximum time, in seconds, that the MediaProcessor can run before automatically ends. The default value is 300 seconds, and the maximum value is 90000 seconds. Once this maximum duration is reached, Twilio will end the MediaProcessor, regardless of whether media is still streaming. MaxDuration *int `json:"MaxDuration,omitempty"` // The URL to which Twilio will send asynchronous webhook requests for every MediaProcessor event. See [Status Callbacks](/docs/live/status-callbacks) for details. StatusCallback *string `json:"StatusCallback,omitempty"` // The HTTP method Twilio should use to call the `status_callback` URL. Can be `POST` or `GET` and the default is `POST`. StatusCallbackMethod *string `json:"StatusCallbackMethod,omitempty"` }
Optional parameters for the method 'CreateMediaProcessor'
func (*CreateMediaProcessorParams) SetExtension ¶
func (params *CreateMediaProcessorParams) SetExtension(Extension string) *CreateMediaProcessorParams
func (*CreateMediaProcessorParams) SetExtensionContext ¶
func (params *CreateMediaProcessorParams) SetExtensionContext(ExtensionContext string) *CreateMediaProcessorParams
func (*CreateMediaProcessorParams) SetExtensionEnvironment ¶
func (params *CreateMediaProcessorParams) SetExtensionEnvironment(ExtensionEnvironment map[string]interface{}) *CreateMediaProcessorParams
func (*CreateMediaProcessorParams) SetMaxDuration ¶ added in v0.19.0
func (params *CreateMediaProcessorParams) SetMaxDuration(MaxDuration int) *CreateMediaProcessorParams
func (*CreateMediaProcessorParams) SetStatusCallback ¶
func (params *CreateMediaProcessorParams) SetStatusCallback(StatusCallback string) *CreateMediaProcessorParams
func (*CreateMediaProcessorParams) SetStatusCallbackMethod ¶
func (params *CreateMediaProcessorParams) SetStatusCallbackMethod(StatusCallbackMethod string) *CreateMediaProcessorParams
type CreatePlayerStreamerParams ¶
type CreatePlayerStreamerParams struct { // The URL to which Twilio will send asynchronous webhook requests for every PlayerStreamer event. See [Status Callbacks](/docs/live/status-callbacks) for more details. StatusCallback *string `json:"StatusCallback,omitempty"` // The HTTP method Twilio should use to call the `status_callback` URL. Can be `POST` or `GET` and the default is `POST`. StatusCallbackMethod *string `json:"StatusCallbackMethod,omitempty"` // Specifies whether the PlayerStreamer is configured to stream video. Defaults to `true`. Video *bool `json:"Video,omitempty"` }
Optional parameters for the method 'CreatePlayerStreamer'
func (*CreatePlayerStreamerParams) SetStatusCallback ¶
func (params *CreatePlayerStreamerParams) SetStatusCallback(StatusCallback string) *CreatePlayerStreamerParams
func (*CreatePlayerStreamerParams) SetStatusCallbackMethod ¶
func (params *CreatePlayerStreamerParams) SetStatusCallbackMethod(StatusCallbackMethod string) *CreatePlayerStreamerParams
func (*CreatePlayerStreamerParams) SetVideo ¶
func (params *CreatePlayerStreamerParams) SetVideo(Video bool) *CreatePlayerStreamerParams
type CreatePlayerStreamerPlaybackGrantParams ¶
type CreatePlayerStreamerPlaybackGrantParams struct { // The full origin URL where the livestream can be streamed. If this is not provided, it can be streamed from any domain. AccessControlAllowOrigin *string `json:"AccessControlAllowOrigin,omitempty"` // The time to live of the PlaybackGrant. Default value is 15 seconds. Maximum value is 60 seconds. Ttl *int `json:"Ttl,omitempty"` }
Optional parameters for the method 'CreatePlayerStreamerPlaybackGrant'
func (*CreatePlayerStreamerPlaybackGrantParams) SetAccessControlAllowOrigin ¶
func (params *CreatePlayerStreamerPlaybackGrantParams) SetAccessControlAllowOrigin(AccessControlAllowOrigin string) *CreatePlayerStreamerPlaybackGrantParams
func (*CreatePlayerStreamerPlaybackGrantParams) SetTtl ¶
func (params *CreatePlayerStreamerPlaybackGrantParams) SetTtl(Ttl int) *CreatePlayerStreamerPlaybackGrantParams
type ListMediaProcessorParams ¶
type ListMediaProcessorParams struct { // The sort order of the list by `date_created`. Can be: `asc` (ascending) or `desc` (descending) with `desc` as the default. Order *string `json:"Order,omitempty"` // Status to filter by, with possible values `started`, `ended` or `failed`. Status *string `json:"Status,omitempty"` // How many resources to return in each list page. The default is 50, and the maximum is 1000. PageSize *int `json:"PageSize,omitempty"` // Max number of records to return. Limit *int `json:"limit,omitempty"` }
Optional parameters for the method 'ListMediaProcessor'
func (*ListMediaProcessorParams) SetLimit ¶
func (params *ListMediaProcessorParams) SetLimit(Limit int) *ListMediaProcessorParams
func (*ListMediaProcessorParams) SetOrder ¶
func (params *ListMediaProcessorParams) SetOrder(Order string) *ListMediaProcessorParams
func (*ListMediaProcessorParams) SetPageSize ¶
func (params *ListMediaProcessorParams) SetPageSize(PageSize int) *ListMediaProcessorParams
func (*ListMediaProcessorParams) SetStatus ¶
func (params *ListMediaProcessorParams) SetStatus(Status string) *ListMediaProcessorParams
type ListMediaProcessorResponse ¶
type ListMediaProcessorResponse struct { MediaProcessors []MediaV1MediaProcessor `json:"media_processors,omitempty"` Meta ListMediaProcessorResponseMeta `json:"meta,omitempty"` }
ListMediaProcessorResponse struct for ListMediaProcessorResponse
type ListMediaProcessorResponseMeta ¶
type ListMediaProcessorResponseMeta struct { FirstPageUrl string `json:"first_page_url,omitempty"` Key string `json:"key,omitempty"` NextPageUrl string `json:"next_page_url,omitempty"` Page int `json:"page,omitempty"` PageSize int `json:"page_size,omitempty"` PreviousPageUrl string `json:"previous_page_url,omitempty"` Url string `json:"url,omitempty"` }
ListMediaProcessorResponseMeta struct for ListMediaProcessorResponseMeta
type ListPlayerStreamerParams ¶
type ListPlayerStreamerParams struct { // The sort order of the list by `date_created`. Can be: `asc` (ascending) or `desc` (descending) with `desc` as the default. Order *string `json:"Order,omitempty"` // Status to filter by, with possible values `created`, `started`, `ended`, or `failed`. Status *string `json:"Status,omitempty"` // How many resources to return in each list page. The default is 50, and the maximum is 1000. PageSize *int `json:"PageSize,omitempty"` // Max number of records to return. Limit *int `json:"limit,omitempty"` }
Optional parameters for the method 'ListPlayerStreamer'
func (*ListPlayerStreamerParams) SetLimit ¶
func (params *ListPlayerStreamerParams) SetLimit(Limit int) *ListPlayerStreamerParams
func (*ListPlayerStreamerParams) SetOrder ¶
func (params *ListPlayerStreamerParams) SetOrder(Order string) *ListPlayerStreamerParams
func (*ListPlayerStreamerParams) SetPageSize ¶
func (params *ListPlayerStreamerParams) SetPageSize(PageSize int) *ListPlayerStreamerParams
func (*ListPlayerStreamerParams) SetStatus ¶
func (params *ListPlayerStreamerParams) SetStatus(Status string) *ListPlayerStreamerParams
type ListPlayerStreamerResponse ¶
type ListPlayerStreamerResponse struct { Meta ListMediaProcessorResponseMeta `json:"meta,omitempty"` PlayerStreamers []MediaV1PlayerStreamer `json:"player_streamers,omitempty"` }
ListPlayerStreamerResponse struct for ListPlayerStreamerResponse
type MediaV1MediaProcessor ¶
type MediaV1MediaProcessor struct { // The SID of the Account that created the resource AccountSid *string `json:"account_sid,omitempty"` // The ISO 8601 date and time in GMT when the resource was created DateCreated *time.Time `json:"date_created,omitempty"` // The ISO 8601 date and time in GMT when the resource was last updated DateUpdated *time.Time `json:"date_updated,omitempty"` // The reason why a MediaProcessor ended EndedReason *string `json:"ended_reason,omitempty"` // The Media Extension name or URL Extension *string `json:"extension,omitempty"` // The Media Extension context ExtensionContext *string `json:"extension_context,omitempty"` // Maximum MediaProcessor duration in minutes MaxDuration *int `json:"max_duration,omitempty"` // The unique string that identifies the resource Sid *string `json:"sid,omitempty"` // The status of the MediaProcessor Status *string `json:"status,omitempty"` // The URL to which Twilio will send MediaProcessor event updates StatusCallback *string `json:"status_callback,omitempty"` // The HTTP method Twilio should use to call the `status_callback` URL StatusCallbackMethod *string `json:"status_callback_method,omitempty"` // The absolute URL of the resource Url *string `json:"url,omitempty"` }
MediaV1MediaProcessor struct for MediaV1MediaProcessor
type MediaV1PlayerStreamer ¶
type MediaV1PlayerStreamer struct { // The SID of the Account that created the resource AccountSid *string `json:"account_sid,omitempty"` // The ISO 8601 date and time in GMT when the resource was created DateCreated *time.Time `json:"date_created,omitempty"` // The ISO 8601 date and time in GMT when the resource was last updated DateUpdated *time.Time `json:"date_updated,omitempty"` // The reason why a PlayerStreamer ended EndedReason *string `json:"ended_reason,omitempty"` // The URLs of related resources Links *map[string]interface{} `json:"links,omitempty"` // The unique string that identifies the resource Sid *string `json:"sid,omitempty"` // The status of the PlayerStreamer Status *string `json:"status,omitempty"` // The URL to which Twilio will send PlayerStreamer event updates StatusCallback *string `json:"status_callback,omitempty"` // The HTTP method Twilio should use to call the `status_callback` URL StatusCallbackMethod *string `json:"status_callback_method,omitempty"` // The absolute URL of the resource Url *string `json:"url,omitempty"` // Whether the PlayerStreamer is configured to stream video Video *bool `json:"video,omitempty"` }
MediaV1PlayerStreamer struct for MediaV1PlayerStreamer
type MediaV1PlayerStreamerPlaybackGrant ¶
type MediaV1PlayerStreamerPlaybackGrant struct { // The SID of the Account that created the resource AccountSid *string `json:"account_sid,omitempty"` // The ISO 8601 date and time in GMT when the resource was created DateCreated *time.Time `json:"date_created,omitempty"` // The grant that authorizes the player sdk to connect to the livestream Grant *map[string]interface{} `json:"grant,omitempty"` // The unique string that identifies the PlayerStreamer associated with this PlaybackGrant. Sid *string `json:"sid,omitempty"` // The absolute URL of the resource Url *string `json:"url,omitempty"` }
MediaV1PlayerStreamerPlaybackGrant struct for MediaV1PlayerStreamerPlaybackGrant
type UpdateMediaProcessorParams ¶
type UpdateMediaProcessorParams struct { // The status of the MediaProcessor. Can be `ended`. Status *string `json:"Status,omitempty"` }
Optional parameters for the method 'UpdateMediaProcessor'
func (*UpdateMediaProcessorParams) SetStatus ¶
func (params *UpdateMediaProcessorParams) SetStatus(Status string) *UpdateMediaProcessorParams
type UpdatePlayerStreamerParams ¶
type UpdatePlayerStreamerParams struct { // The status the PlayerStreamer should be transitioned to. Can be: `ended`. Status *string `json:"Status,omitempty"` }
Optional parameters for the method 'UpdatePlayerStreamer'
func (*UpdatePlayerStreamerParams) SetStatus ¶
func (params *UpdatePlayerStreamerParams) SetStatus(Status string) *UpdatePlayerStreamerParams
Source Files ¶
- api_service.go
- media_processors.go
- model_list_media_processor_response.go
- model_list_media_processor_response_meta.go
- model_list_player_streamer_response.go
- model_media_v1_media_processor.go
- model_media_v1_player_streamer.go
- model_media_v1_player_streamer_playback_grant.go
- player_streamers.go
- player_streamers_playback_grant.go