phone_number

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2020 License: Apache-2.0 Imports: 4 Imported by: 1

Documentation

Overview

This is an autogenerated file. DO NOT MODIFY

This is an autogenerated file. DO NOT MODIFY

This is an autogenerated file. DO NOT MODIFY

This is an autogenerated file. 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 {
	// contains filtered or unexported fields
}

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

func New

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

New creates a new instance of the phone number client

func (Client) Delete

func (c Client) Delete() error

Delete removes a phone number resource from the proxy service See https://www.twilio.com/docs/proxy/api/phone-number#remove-a-phone-number-from-a-proxy-service 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 phone number resource from the proxy service See https://www.twilio.com/docs/proxy/api/phone-number#remove-a-phone-number-from-a-proxy-service for more details

func (Client) Fetch

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

Fetch retrieves a phone number resource See https://www.twilio.com/docs/proxy/api/phone-number#fetch-a-phonenumber-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) (*FetchPhoneNumberResponse, error)

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

func (Client) Update

Update modifies a phone number resource See https://www.twilio.com/docs/proxy/api/phone-number#update-a-phonenumber-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 *UpdatePhoneNumberInput) (*UpdatePhoneNumberResponse, error)

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

type ClientProperties

type ClientProperties struct {
	ServiceSid string
	Sid        string
}

ClientProperties are the properties required to manage the phone number resources

type FetchPhoneNumberResponse

type FetchPhoneNumberResponse struct {
	AccountSid   string                                `json:"account_sid"`
	Capabilities *FetchPhoneNumberResponseCapabilities `json:"capabilities,omitempty"`
	DateCreated  time.Time                             `json:"date_created"`
	DateUpdated  *time.Time                            `json:"date_updated,omitempty"`
	FriendlyName *string                               `json:"friendly_name,omitempty"`
	InUse        *int                                  `json:"in_use,omitempty"`
	IsReserved   *bool                                 `json:"is_reserved,omitempty"`
	IsoCountry   *string                               `json:"iso_country,omitempty"`
	PhoneNumber  *string                               `json:"phone_number,omitempty"`
	ServiceSid   string                                `json:"service_sid"`
	Sid          string                                `json:"sid"`
	URL          string                                `json:"url"`
}

FetchPhoneNumberResponse defines the response fields for the retrieved phone number

type FetchPhoneNumberResponseCapabilities

type FetchPhoneNumberResponseCapabilities struct {
	FaxInbound               *bool `json:"fax_inbound,omitempty"`
	FaxOutbound              *bool `json:"fax_outbound,omitempty"`
	MmsInbound               *bool `json:"mms_inbound,omitempty"`
	MmsOutbound              *bool `json:"mms_outbound,omitempty"`
	RestrictionFaxDomestic   *bool `json:"restriction_fax_domestic,omitempty"`
	RestrictionMmsDomestic   *bool `json:"restriction_mms_domestic,omitempty"`
	RestrictionSmsDomestic   *bool `json:"restriction_sms_domestic,omitempty"`
	RestrictionVoiceDomestic *bool `json:"restriction_voice_domestic,omitempty"`
	SipTrunking              *bool `json:"sip_trunking,omitempty"`
	SmsInbound               *bool `json:"sms_inbound,omitempty"`
	SmsOutbound              *bool `json:"sms_outbound,omitempty"`
	VoiceInbound             *bool `json:"voice_inbound,omitempty"`
	VoiceOutbound            *bool `json:"voice_outbound,omitempty"`
}

type UpdatePhoneNumberInput

type UpdatePhoneNumberInput struct {
	IsReserved *bool `form:"IsReserved,omitempty"`
}

UpdatePhoneNumberInput defines input fields for updating a phone number resource

type UpdatePhoneNumberResponse

type UpdatePhoneNumberResponse struct {
	AccountSid   string                                 `json:"account_sid"`
	Capabilities *UpdatePhoneNumberResponseCapabilities `json:"capabilities,omitempty"`
	DateCreated  time.Time                              `json:"date_created"`
	DateUpdated  *time.Time                             `json:"date_updated,omitempty"`
	FriendlyName *string                                `json:"friendly_name,omitempty"`
	InUse        *int                                   `json:"in_use,omitempty"`
	IsReserved   *bool                                  `json:"is_reserved,omitempty"`
	IsoCountry   *string                                `json:"iso_country,omitempty"`
	PhoneNumber  *string                                `json:"phone_number,omitempty"`
	ServiceSid   string                                 `json:"service_sid"`
	Sid          string                                 `json:"sid"`
	URL          string                                 `json:"url"`
}

UpdatePhoneNumberResponse defines the response fields for the updated phone number

type UpdatePhoneNumberResponseCapabilities

type UpdatePhoneNumberResponseCapabilities struct {
	FaxInbound               *bool `json:"fax_inbound,omitempty"`
	FaxOutbound              *bool `json:"fax_outbound,omitempty"`
	MmsInbound               *bool `json:"mms_inbound,omitempty"`
	MmsOutbound              *bool `json:"mms_outbound,omitempty"`
	RestrictionFaxDomestic   *bool `json:"restriction_fax_domestic,omitempty"`
	RestrictionMmsDomestic   *bool `json:"restriction_mms_domestic,omitempty"`
	RestrictionSmsDomestic   *bool `json:"restriction_sms_domestic,omitempty"`
	RestrictionVoiceDomestic *bool `json:"restriction_voice_domestic,omitempty"`
	SipTrunking              *bool `json:"sip_trunking,omitempty"`
	SmsInbound               *bool `json:"sms_inbound,omitempty"`
	SmsOutbound              *bool `json:"sms_outbound,omitempty"`
	VoiceInbound             *bool `json:"voice_inbound,omitempty"`
	VoiceOutbound            *bool `json:"voice_outbound,omitempty"`
}

Jump to

Keyboard shortcuts

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