Documentation ¶
Index ¶
- Constants
- type AWSKit
- func (ak *AWSKit) SendEMail(ctx context.Context, msg *EMailMsg) (*string, error)
- func (ak *AWSKit) SendSMS(ctx context.Context, msg *SMSMsg) (*string, error)
- func (ak *AWSKit) UploadBuf(bucketName string, objectKey string, buf []byte, size int64, ...) error
- func (ak *AWSKit) UploadFile(bucketName string, objectKey string, fileName string) error
- type EMailMsg
- type MessageType
- type SMSMsg
Constants ¶
View Source
const ( // Subject is the subject line for the email Subject = "Amazon SES Test (AWS SDK for Go)" // HTMLBody is the HTML body for the email HTMLBody = "<h1>Amazon SES Test Email (AWS SDK for Go)</h1><p>This email was sent with " + "<a href='https://aws.amazon.com/ses/'>Amazon SES</a> using the " + "<a href='https://aws.amazon.com/sdk-for-go/'>AWS SDK for Go</a>.</p>" // TextBody is the email body for recipients with non-HTML email clients TextBody = "This email was sent with Amazon SES using the AWS SDK for Go." // CharSet is the character encoding for the email CharSet = "UTF-8" )
View Source
const ( // SenderIDSMSAttribute a custom name that's displayed as the message sender on the receiving device. SenderIDSMSAttribute = "SenderID" // MaxPriceSMSAttribute a maximum price in USD that you are willing to pay to send the message. MaxPriceSMSAttribute = "MaxPrice" // MessageTypeSMSAttribute a SMS type, can be either Promotional or Transactional. MessageTypeSMSAttribute = "MessageType" // Promotional message type used for promotional purposes that are noncritical, won't be delivered // to DND (Do Not Disturb) numbers. Promotional MessageType = "Promotional" // Transactional message type used for transactional purposes which includes critical messages as multi-factor // authentication. This message type might be more expensive than Promotional message type. Will be delivered to // to DND numbers. Transactional MessageType = "Transactional" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AWSKit ¶
type AWSKit struct {
// contains filtered or unexported fields
}
type EMailMsg ¶
type MessageType ¶
type MessageType string
MessageType SNS SMS type
func (MessageType) IsValid ¶
func (mt MessageType) IsValid() bool
IsValid returns true if the message type is either transactional or promotional used to validate that a valid message type is being provided.
func (MessageType) String ¶
func (mt MessageType) String() string
String returns message type string value
Click to show internal directories.
Click to hide internal directories.