添加模板
开发环境
http://dev-cn.your-api-server.com
开发环境
http://dev-cn.your-api-server.com
POST
https://developer.toutiao.com/api/apps/v1/capacity/add_app_subscribe_notification_tpl
使用限制
错误码
错误码 | 描述 | 排查建议 |
---|---|---|
-1 | 系统错误 | 建议重试 |
11001 | appid 无法解析 | 建议重试 |
11009 | 参数不合法或缺少参数 | 检查参数合法性 |
11016 | access_token 不正确或者已过期 | 检查 access_token 合法性 |
40006 | 非法请求,请求 IP 不在第三方小程序应用 IP 地址白名单内 | 添加 IP 地址到白名单内或者配置白名单为空 |
40036 | 授权小程序未授予该接口对应的权限 | 引导商家授予相关权限集 |
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://developer.toutiao.com/api/apps/v1/capacity/add_app_subscribe_notification_tpl' \
--header 'access-token;' \
--header 'content-type: application/json' \
--data-raw '{
"template_id": 12259,
"keyword_list": ["时间", "风格"]
}'
响应示例响应示例
200 - 示例 1
{
"err_no": 0,
"err_msg": "string",
"data": {
"msg_id": "string"
}
}
请求参数
Header 参数
content-type
string
必需
access-token
string
必需
Body 参数application/json
返回响应
修改于 2023-12-05 06:00:39