Documentation
¶
Index ¶
Constants ¶
View Source
const (
// DEFAULT_TENCENT_SMS_ENDPOINT todo
DEFAULT_TENCENT_SMS_ENDPOINT = "sms.tencentcloudapi.com"
)
Variables ¶
This section is empty.
Functions ¶
func NewSender ¶
func NewSender(conf *Config) (sms_provider.SmsNotifyer, error)
Types ¶
type Config ¶
type Config struct { Endpoint string `bson:"endpoint" json:"endpoint" env:"SMS_TENCENT_ENDPOINT"` SecretID string `bson:"secret_id" json:"secret_id" validate:"required,lte=64" env:"SMS_TENCENT_SECRET_ID"` SecretKey string `bson:"secret_key" json:"secret_key" validate:"required,lte=64" env:"SMS_TENCENT_SECRET_KEY"` AppID string `bson:"app_id" json:"app_id" validate:"required,lte=64" env:"SMS_TENCENT_APPID"` Sign string `bson:"sign" json:"sign" validate:"required,lte=128" env:"SMS_TENCENT_SIGN"` }
接口和相关文档请参考https://console.cloud.tencent.com/api/explorer?Product=sms&Version=2019-07-11&Action=SendSms&SignVersion=
type Sender ¶
type Sender struct {
// contains filtered or unexported fields
}
func (*Sender) Send ¶
func (s *Sender) Send(ctx context.Context, req *sms_provider.SendSMSRequest) error
Send todo
Click to show internal directories.
Click to hide internal directories.