Documentation
¶
Index ¶
- func SendSMS(c context.Context, to string, body string) error
- func SmsHandler(w http.ResponseWriter, r *http.Request)
- type ApplicationSid
- type AreaCode
- type Body
- type Callback
- type Client
- type DateSent
- type Error
- type FallbackMethod
- type FallbackUrl
- type FriendlyName
- type From
- type IfMachine
- type MediaUrl
- type Message
- type Method
- type Optional
- type ParentCallSid
- type PhoneNumber
- type Record
- type SendDigits
- type StartTime
- type Status
- type StatusCallback
- type StatusCallbackMethod
- type Timeout
- type To
- type TwilioClient
- type TwilioError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SmsHandler ¶
func SmsHandler(w http.ResponseWriter, r *http.Request)
Types ¶
type ApplicationSid ¶
type ApplicationSid string
func (ApplicationSid) GetParam ¶
func (applicationSid ApplicationSid) GetParam() (string, string)
type FallbackMethod ¶
type FallbackMethod string
func (FallbackMethod) GetParam ¶
func (fallbackMethod FallbackMethod) GetParam() (string, string)
type FallbackUrl ¶
type FallbackUrl string
func (FallbackUrl) GetParam ¶
func (fallbackUrl FallbackUrl) GetParam() (string, string)
type FriendlyName ¶
type FriendlyName string
func (FriendlyName) GetParam ¶
func (friendlyName FriendlyName) GetParam() (string, string)
type Message ¶
type Message struct {
Sid string `json:"sid"`
DateCreated string `json:"date_created"`
DateUpdated string `json:"date_updated"`
DateSent string `json:"date_sent"`
AccountSid string `json:"account_sid"`
From string `json:"from"`
To string `json:"to"`
Body string `json:"body"`
NumSegments string `json:"num_segments"`
Status string `json:"status"`
Direction string `json:"direction"`
Price string `json:"price"`
PriceUnit string `json:"price_unit"`
ApiVersion string `json:"api_version"`
Uri string `json:"uri"`
}
type ParentCallSid ¶
type ParentCallSid string
func (ParentCallSid) GetParam ¶
func (parentCallSid ParentCallSid) GetParam() (string, string)
type PhoneNumber ¶
type PhoneNumber string
func (PhoneNumber) GetParam ¶
func (phoneNumber PhoneNumber) GetParam() (string, string)
type SendDigits ¶
type SendDigits string
func (SendDigits) GetParam ¶
func (sendDigits SendDigits) GetParam() (string, string)
type StatusCallback ¶
type StatusCallback string
func (StatusCallback) GetParam ¶
func (statusCallback StatusCallback) GetParam() (string, string)
type StatusCallbackMethod ¶
type StatusCallbackMethod string
func (StatusCallbackMethod) GetParam ¶
func (statusCallbackMethod StatusCallbackMethod) GetParam() (string, string)
type TwilioClient ¶
type TwilioClient struct {
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient(accountSid, authToken string) *TwilioClient
func (*TwilioClient) AccountSid ¶
func (client *TwilioClient) AccountSid() string
func (*TwilioClient) AuthToken ¶
func (client *TwilioClient) AuthToken() string
func (*TwilioClient) RootUrl ¶
func (client *TwilioClient) RootUrl() string
type TwilioError ¶
type TwilioError struct {
Status int `json:"status"`
Message string `json:"message"`
Code int `json:"code"`
MoreInfo string `json:"more_info"`
}
func (TwilioError) Error ¶
func (e TwilioError) Error() string
Click to show internal directories.
Click to hide internal directories.