Documentation
¶
Overview ¶
Package role contains auto-generated files. DO NOT MODIFY
Package role contains auto-generated files. DO NOT MODIFY
Package role contains auto-generated files. DO NOT MODIFY
Package role contains auto-generated files. DO NOT MODIFY
Index ¶
- type Client
- func (c Client) Delete() error
- func (c Client) DeleteWithContext(context context.Context) error
- func (c Client) Fetch() (*FetchRoleResponse, error)
- func (c Client) FetchWithContext(context context.Context) (*FetchRoleResponse, error)
- func (c Client) Update(input *UpdateRoleInput) (*UpdateRoleResponse, error)
- func (c Client) UpdateWithContext(context context.Context, input *UpdateRoleInput) (*UpdateRoleResponse, error)
- type ClientProperties
- type FetchRoleResponse
- type UpdateRoleInput
- type UpdateRoleResponse
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 a specific role resource See https://www.twilio.com/docs/conversations/api/role-resource for more details
func New ¶
func New(client *client.Client, properties ClientProperties) *Client
New creates a new instance of the role client
func (Client) Delete ¶
Delete removes a role resource from the account See https://www.twilio.com/docs/conversations/api/role-resource#delete-a-role-resource for more details Context is defaulted to Background. See https://golang.org/pkg/context/#Background for more information
func (Client) DeleteWithContext ¶
DeleteWithContext removes a role resource from the account See https://www.twilio.com/docs/conversations/api/role-resource#delete-a-role-resource for more details
func (Client) Fetch ¶
func (c Client) Fetch() (*FetchRoleResponse, error)
Fetch retrieves a role resource See https://www.twilio.com/docs/conversations/api/role-resource#fetch-a-role-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) (*FetchRoleResponse, error)
FetchWithContext retrieves a role resource See https://www.twilio.com/docs/conversations/api/role-resource#fetch-a-role-resource for more details
func (Client) Update ¶
func (c Client) Update(input *UpdateRoleInput) (*UpdateRoleResponse, error)
Update modifies a role resource See https://www.twilio.com/docs/conversations/api/role-resource#update-a-role-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 *UpdateRoleInput) (*UpdateRoleResponse, error)
UpdateWithContext modifies a role resource See https://www.twilio.com/docs/conversations/api/role-resource#update-a-role-resource for more details
type ClientProperties ¶
type ClientProperties struct {
Sid string
}
ClientProperties are the properties required to manage the role resources
type FetchRoleResponse ¶
type FetchRoleResponse struct { AccountSid string `json:"account_sid"` ChatServiceSid string `json:"chat_service_sid"` DateCreated time.Time `json:"date_created"` DateUpdated *time.Time `json:"date_updated,omitempty"` FriendlyName string `json:"friendly_name"` Permissions []string `json:"permissions"` Sid string `json:"sid"` Type string `json:"type"` URL string `json:"url"` }
FetchRoleResponse defines the response fields for the retrieved role
type UpdateRoleInput ¶
type UpdateRoleInput struct {
Permissions []string `validate:"required" form:"Permission"`
}
UpdateRoleInput defines input fields for updating a role resource
type UpdateRoleResponse ¶
type UpdateRoleResponse struct { AccountSid string `json:"account_sid"` ChatServiceSid string `json:"chat_service_sid"` DateCreated time.Time `json:"date_created"` DateUpdated *time.Time `json:"date_updated,omitempty"` FriendlyName string `json:"friendly_name"` Permissions []string `json:"permissions"` Sid string `json:"sid"` Type string `json:"type"` URL string `json:"url"` }
UpdateRoleResponse defines the response fields for the updated role