接口简介

  • 本接口查询指定推送信息的推送结果

接口请求说明

请求方式

GET https://站点接口域名/openapi/pushes/{id}

请求参数

请求示例

# GET请求
curl -X GET  'https://站点接口域名/openapi/pushes/111' \
  -H 'Authorization: Bearer 5d39164d1f281' \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json'

接口响应说明

响应示例

{
    "code": 0,
    "text": "",
    "data": {
        "id": 1,
        "title": "常州的高温天还要持续!",
        "content": "告诉常州人一条坏消息:今天我市最高气温仍可达37℃以上,且高温天还将持续4天!本周天气基本是这样....详情请戳》》》",
        "image": "",
        "target_type": 10,
        "target_value": "12157277",
        "direct": "",
        "is_delay": false,
        "created_time": "2016-08-11 09:13:00",
        "start_time": "2016-08-11 09:13:00",
        "result": {
            "ios": [
                {
                    "group_id": 10,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "total_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 10:53:46",
                    "start_time": "2016-08-11 09:13:00"
                }
            ],
            "android": [
                {
                    "group_id": 0,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "dismiss_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 11:52:25",
                    "start_time": "2016-08-11 09:12:56"
                },
                {
                    "group_id": 1,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "dismiss_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 10:53:57",
                    "start_time": "2016-08-11 09:12:56"
                },
                {
                    "group_id": 2,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "dismiss_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 10:54:06",
                    "start_time": "2016-08-11 09:12:56"
                },
                {
                    "group_id": 3,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "dismiss_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 10:54:19",
                    "start_time": "2016-08-11 09:12:56"
                },
                {
                    "group_id": 4,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "dismiss_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 11:52:00",
                    "start_time": "2016-08-11 09:12:56"
                },
                {
                    "group_id": 5,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "dismiss_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 10:54:38",
                    "start_time": "2016-08-11 09:12:56"
                },
                {
                    "group_id": 6,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "dismiss_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 10:54:48",
                    "start_time": "2016-08-11 09:12:59"
                },
                {
                    "group_id": 7,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "dismiss_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 10:49:11",
                    "start_time": "2016-08-11 09:13:00"
                },
                {
                    "group_id": 8,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "dismiss_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 10:55:07",
                    "start_time": "2016-08-11 09:13:00"
                },
                {
                    "group_id": 9,
                    "status": 0,
                    "sent_count": 0,
                    "open_count": 0,
                    "dismiss_count": 0,
                    "open_rate": "0%",
                    "created_time": "2017-12-01 10:55:16",
                    "start_time": "2016-08-11 09:13:00"
                }
            ]
        }
    },
    "time": 1565666950
}

响应结果说明

基础字段详见推送记录接口,下面主要介绍result中的统计数据字典

推送结果统计说明:分为ios和android两个平台,(若创建推送时只选择了某个平台,则只返回该平台数据)。每个平台下会具体的推送任务结果,若创建推送时选择的是广播量推送,则只会返回一条推送结果,且其group_id为10。若创建推送选择的为分组推送则会返回0~9共10个分组group_id

android和ios平台存在一些差异,所以返回的数据也有所不同。

ios返回字段 类型 说明
group_id int 0-9表示用户分组 10表示广播推送
status int 推送状态 0-排队中, 1-发送中,2-发送完成,3-发送失败,4-消息被撤销,5-消息过期, 6-筛选结果为空,7-定时任务尚未开始处理
sent_count int APNs返回SUCCESS的设备数(实际发送)
open_count int 打开数
total_count int ios独有字段 投递APNs设备数(计划发送)
open_rate string 打开率
created_time string 创建时间
start_time string 推送开始时间
android返回字段 类型 说明
group_id int 0-9表示用户分组 10表示广播推送
status int 推送状态 0-排队中, 1-发送中,2-发送完成,3-发送失败,4-消息被撤销,5-消息过期, 6-筛选结果为空,7-定时任务尚未开始处理
sent_count int 消息收到数(实际发送)
open_count int 打开数
dismiss_count int 忽略数
open_rate string 打开率
created_time string 创建时间
start_time string 推送开始时间

打开率:(open_count/sent_count)*100%

打开率作为最核心的运营指标,其数值是不停变化的,特别是刚推送之后,数据会逐渐增加。至少两道三天之后数据才会区域稳定。

文档更新时间: 2019-09-10 16:21   作者:千帆云