asset

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: 6 Imported by: 1

Documentation

Overview

Package asset contains auto-generated files. DO NOT MODIFY

Package asset contains auto-generated files. DO NOT MODIFY

Package asset contains auto-generated files. DO NOT MODIFY

Package asset 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 {
	Version  func(string) *version.Client
	Versions *versions.Client
	// contains filtered or unexported fields
}

Client for managing a specific asset resource See https://www.twilio.com/docs/runtime/functions-assets-api/api/asset for more details

func New

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

New creates a new instance of the asset client

func (Client) Delete

func (c Client) Delete() error

Delete removes a asset resource from the account See https://www.twilio.com/docs/runtime/functions-assets-api/api/asset#delete-an-asset-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 asset resource from the account See https://www.twilio.com/docs/runtime/functions-assets-api/api/asset#delete-an-asset-resource for more details

func (Client) Fetch

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

Fetch retrieves a asset resource See https://www.twilio.com/docs/runtime/functions-assets-api/api/asset#fetch-an-asset-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) (*FetchAssetResponse, error)

FetchWithContext retrieves a asset resource See https://www.twilio.com/docs/runtime/functions-assets-api/api/asset#fetch-an-asset-resource for more details

func (Client) Update

func (c Client) Update(input *UpdateAssetInput) (*UpdateAssetResponse, error)

Update modifies a asset resource See https://www.twilio.com/docs/runtime/functions-assets-api/api/asset#update-an-asset-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 *UpdateAssetInput) (*UpdateAssetResponse, error)

UpdateWithContext modifies a asset resource See https://www.twilio.com/docs/runtime/functions-assets-api/api/asset#update-an-asset-resource for more details

type ClientProperties

type ClientProperties struct {
	ServiceSid string
	Sid        string
}

ClientProperties are the properties required to manage the asset resources

type FetchAssetResponse

type FetchAssetResponse struct {
	AccountSid   string     `json:"account_sid"`
	DateCreated  time.Time  `json:"date_created"`
	DateUpdated  *time.Time `json:"date_updated,omitempty"`
	FriendlyName string     `json:"friendly_name"`
	ServiceSid   string     `json:"service_sid"`
	Sid          string     `json:"sid"`
	URL          string     `json:"url"`
}

FetchAssetResponse defines the response fields for the retrieved asset

type UpdateAssetInput

type UpdateAssetInput struct {
	FriendlyName string `validate:"required" form:"FriendlyName"`
}

UpdateAssetInput defines input fields for updating a asset resource

type UpdateAssetResponse

type UpdateAssetResponse struct {
	AccountSid   string     `json:"account_sid"`
	DateCreated  time.Time  `json:"date_created"`
	DateUpdated  *time.Time `json:"date_updated,omitempty"`
	FriendlyName string     `json:"friendly_name"`
	ServiceSid   string     `json:"service_sid"`
	Sid          string     `json:"sid"`
	URL          string     `json:"url"`
}

UpdateAssetResponse defines the response fields for the updated asset

Directories

Path Synopsis
Package version contains auto-generated files.
Package version contains auto-generated files.
Package versions contains auto-generated files.
Package versions contains auto-generated files.

Jump to

Keyboard shortcuts

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