Documentation
¶
Overview ¶
Package uvms include resources of ucloud uvms product
See also
- API: https://docs.ucloud.cn/api/uvms-api/index
- Product: https://www.ucloud.cn/site/product/uvms.html
for detail.
Index ¶
- type GetUVMSSendRecordRequest
- type GetUVMSSendRecordResponse
- type SendRecordItem
- type SendUVMSMessageRequest
- type SendUVMSMessageResponse
- type UVMSClient
- func (c *UVMSClient) GetUVMSSendRecord(req *GetUVMSSendRecordRequest) (*GetUVMSSendRecordResponse, error)
- func (c *UVMSClient) NewGetUVMSSendRecordRequest() *GetUVMSSendRecordRequest
- func (c *UVMSClient) NewSendUVMSMessageRequest() *SendUVMSMessageRequest
- func (c *UVMSClient) SendUVMSMessage(req *SendUVMSMessageRequest) (*SendUVMSMessageResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GetUVMSSendRecordRequest ¶ added in v0.22.26
type GetUVMSSendRecordRequest struct {
request.CommonBase
// 国际码,国内CN
BrevityCode *string `required:"false"`
// 被叫城市编码
CalledCityCode *string `required:"false"`
// 被叫运营商 cmcc中国移动,cucc中国联通,ctcc中国电信
CalledOperatorCode *string `required:"false"`
// 主叫城市编码
CallingCityCode *string `required:"false"`
// 结束时间-拨打时间,时间戳(秒),默认当前
EndTime *float64 `required:"false"`
// 排除国际码
ExcludeBrevityCode *string `required:"false"`
// 模糊搜索,支持 主叫号码和被叫号码
FuzzySearch *string `required:"false"`
// 每页数量,默认10
NumPerPage *int `required:"false"`
// call_start_time(拨打时间)/receive_time(回执时间)
OrderBy *string `required:"false"`
// asc\desc
OrderType *string `required:"false"`
// 页码,默认0
Page *int `required:"false"`
// 被叫号码,精确查询
PhoneNumber *string `required:"false"`
// 目标1验证码2通知3营销
Purpose *int `required:"false"`
// 开始时间-拨打时间,时间戳(秒),默认最近7天
StartTime *float64 `required:"false"`
// 任务编号
TaskNo *string `required:"false"`
// 目标ID
TemplateId *string `required:"false"`
}
GetUVMSSendRecordRequest is request schema for GetUVMSSendRecord action
type GetUVMSSendRecordResponse ¶ added in v0.22.26
type GetUVMSSendRecordResponse struct {
response.CommonBase
// 发送数据
Data []SendRecordItem
// 总数
Total int
}
GetUVMSSendRecordResponse is response schema for GetUVMSSendRecord action
type SendRecordItem ¶ added in v0.22.26
type SendRecordItem struct {
// 计费周期(秒)
BillPeriod int
// 计费时长(秒)
BillSecond int
// 国际码
BrevityCode string
// 呼叫结束时间(毫秒时间戳)
CallEndTime float64
// 呼叫开始时间(毫秒时间戳)
CallStartTime float64
// 被叫所属城市码
CalledCityCode string
// 被叫供应商码 cmcc中国移动,cucc中国联通,ctcc中国电信
CalledOperatorCode string
// 主叫所属城市码
CallingCityCode string
// 通道ID
ChannelId string
// 国家码
CountryCode string
// 呼叫持续时间
Duration int
// 1随机号码组2专属号码组
GroupType int
// 被叫号码
Phone string
// 预扣量
PreCost int
// 目标1验证码2通知3营销
Purpose int
// 回执描述
ReceiptDesc string
// 回执结果1成功2失败3未知
ReceiptResult int
// 回执时间
ReceiveTime float64
// 主叫号码,如果是随机,可能为空
ShowNumber string
// 客户提交时间
SubmitTime float64
// 任务编号
TaskNo string
// 模板ID
TemplateId string
}
SendRecordItem - 发送记录条目
type SendUVMSMessageRequest ¶
type SendUVMSMessageRequest struct {
request.CommonBase
// 被叫号码,采用 E.164 标准,格式为+[国家代码][用户号码]。例如:+8613512345678, 其中前面有一个+号 ,86为国家码,13512345678为手机号
CalledNumber *string `required:"true"`
// 调度规则,0-默认(归属地优先),1-随机。当不指定外显号码(主叫号码为空)时生效。如不填写,默认为归属地优先。
DispatchRule *int `required:"false"`
// 主叫号码,号码随机时不填。专属号码时传入已购买的号码,仅支持一个号码,在控制台查看已购买的号码。
FromNumber *string `required:"false"`
// 号码组类型,1-随机组,2-专属组。如不填写则根据主叫号码判断,若主叫号码为空,则为随机组,若不为空,则为专属组。
GroupType *int `required:"false"`
// 模板 ID,在控制台审核通过的模板 ID。
TemplateId *string `required:"true"`
// 模板可变参数,以数组的方式填写,举例,TemplateParams.0,TemplateParams.1,... 若模板中无可变参数,则该项可不填写;若模板中有可变参数,则该项为必填项,参数个数需与变量个数保持一致,否则无法发送;
TemplateParams []string `required:"false"`
// 自定义的业务标识ID,字符串( 长度不能超过32 位),不支持 单引号、表情包符号等特殊字符
UserId *string `required:"false"`
}
SendUVMSMessageRequest is request schema for SendUVMSMessage action
type SendUVMSMessageResponse ¶
type SendUVMSMessageResponse struct {
response.CommonBase
// 状态码的描述
Message string
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 ReqUuid。
ReqUuid string
// 本次提交发送语音的唯一ID,可根据该值查询本次发送详情
SessionNo string
// 本次提交的自定义业务标识ID,仅当发送时传入有效的UserId,才返回该字段。
UserId string
}
SendUVMSMessageResponse is response schema for SendUVMSMessage action
type UVMSClient ¶
UVMSClient is the client of UVMS
func NewClient ¶
func NewClient(config *ucloud.Config, credential *auth.Credential) *UVMSClient
NewClient will return a instance of UVMSClient
func (*UVMSClient) GetUVMSSendRecord ¶ added in v0.22.26
func (c *UVMSClient) GetUVMSSendRecord(req *GetUVMSSendRecordRequest) (*GetUVMSSendRecordResponse, error)
API: GetUVMSSendRecord
获取语音发送记录
func (*UVMSClient) NewGetUVMSSendRecordRequest ¶ added in v0.22.26
func (c *UVMSClient) NewGetUVMSSendRecordRequest() *GetUVMSSendRecordRequest
NewGetUVMSSendRecordRequest will create request of GetUVMSSendRecord action.
func (*UVMSClient) NewSendUVMSMessageRequest ¶
func (c *UVMSClient) NewSendUVMSMessageRequest() *SendUVMSMessageRequest
NewSendUVMSMessageRequest will create request of SendUVMSMessage action.
func (*UVMSClient) SendUVMSMessage ¶
func (c *UVMSClient) SendUVMSMessage(req *SendUVMSMessageRequest) (*SendUVMSMessageResponse, error)
API: SendUVMSMessage
向指定号码拨打电话