- 查短信发送记录
- 请求
- 请求参数
- 响应
- Json响应示例:
查短信发送记录
HTTP头信息:
Accept:application/json;charset=utf-8;Content-Type:application/x-www-form-urlencoded;charset=utf-8;
请求
URL:https://sms.yunpian.com/v2/sms/get_record.json
注意:海外服务器地址 us.yunpian.com
访问方式:POST
请求参数
| 参数名 | 类型 | 是否必须 | 描述 | 示例 |
|---|---|---|---|---|
| apikey | String | 是 | 用户唯一标识 | 9b11127a9701975c734b8aee81ee3526 |
| mobile | String | 否 | 需要查询的手机号 | +93701234567 |
| start_time | String | 是 | 短信发送开始时间 | 2013-08-11 00:00:00 |
| end_time | String | 是 | 短信发送结束时间 | 2013-08-12 00:00:00 |
| page_num | integer | 否 | 页码,默认值为1 | 1 |
| page_size | integer | 否 | 每页个数,最大100个 | 20 |
| type | String | 否 | 选择短信类型,默认为空,只获取国内短信记录;global,只能获取国际短信记录;all,国内与国际记录均可获取。 | global |
响应
| 名称 | 类型 | 描述 |
|---|---|---|
| sid | long(64位) | 短信id,64位整型, 对应Java和C#的long,不可用int解析 |
| mobile | string | 接收手机号 |
| send_time | string | 发送时间 |
| text | string | 短信的内容 |
| send_status | string | 发送状态 |
| report_status | string | 报告状态 |
| fee | integer | 发送成功短信的计费条数(计费条数:70个字一条,超出70个字时按每67字一条计费) |
| user_receive_time | string | 用户接收时间 |
| error_msg | string | 运营商返回的代码,如:"DB:0103" |
| uid | string | 用户自定义的id |
Json响应示例:
[{"sid": "1234567890","mobile": "+93701234567","send_time": "2015-11-02 16:34:56","text": "【云片网】你的验证码是1234","send_status": "SUCCESS","report_status": "FAIL","fee": 1,"user_receive_time": null,"error_msg": "1:1","uid": null},{"sid": "1234567891","mobile": "+93701234567","send_time": "2015-11-02 15:34:42","text": "【云片网】你的验证码是4321","send_status": "SUCCESS","report_status": "FAIL","fee": 1,"user_receive_time": null,"error_msg": "1:1","uid": null}]
