云服务器内容精选

  • 请求示例 查询模板报表。模板ID为"600000001",查询时间范围从"2022-06-01 07:20:50" 到 "2022-07-01 07:20:50"。 https://koomessage.myhuaweicloud.cn/v1/aim/template-reports/query { "tpl_ids" : [ "600000001" ], "begin_time" : "2022-06-01T07:20:50.522Z", "end_time" : "2022-07-01T07:20:50.522Z", "offset" : 0, "limit" : 10 }
  • 响应示例 状态码: 200 返回信息。 { "template_reports" : [ { "tpl_id" : "600000001", "start_time" : "2022-06-30T00:00:00Z", "resolving_times" : 0, "end_time" : "2022-07-18T17:56:08Z", "expose_uv" : 3, "expose_pv" : 33, "click_uv" : 3, "click_pv" : 6 } ], "page_info" : { "offset" : 0, "limit" : 10, "total" : 1 } }
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 template_reports Array of AIMTemplateReport objects 查询模板报表结果集。 page_info Page object 分页信息。 表4 AIMTemplateReport 参数 参数类型 描述 tpl_id String 智能信息模板ID。 start_time String 统计开始时间。样例为:1970-01-01T00:00:00Z。 resolving_times Integer 实际已解析数。 end_time String 统计结束时间。样例为:1970-01-01T00:00:00Z。 expose_uv Long 消息曝光数。 expose_pv Long 消息曝光次数。 click_uv Long 消息点击数。 click_pv Long 消息点击次数。 表5 Page 参数 参数类型 描述 offset Integer 偏移量,表示从此偏移量开始查询,offset大于等于0。 limit Integer 每页显示的条目数量。 total Integer 总条数。 状态码: 400 表6 响应Body参数 参数 参数类型 描述 error_code String 结果状态码。 error_msg String 结果详情。 error_message Object 结果详情。 说明: 该字段在以后可能会废弃,建议使用error_msg字段对接。 状态码: 500 表7 响应Body参数 参数 参数类型 描述 error_code String 结果状态码。 error_msg String 结果详情。 error_message Object 结果详情。 说明: 该字段在以后可能会废弃,建议使用error_msg字段对接。
  • 请求参数 表1 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 是 String 用户Token。通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 Content-Type 是 String 请求体参数类型,该字段必须设置为:application/json。 表2 请求Body参数 参数 是否必选 参数类型 描述 tpl_ids 是 Array of strings 智能信息模板ID列表,一次最多请求100个。 数组长度:1 - 100 begin_time 是 String 模板报表查询开始时间。样例:2019-10-12T07:20:50.522Z。 说明: 开始时间和结束时间最多间隔90天,超出时间限制返回为空。 最小长度:1 最大长度:30 end_time 是 String 模板报表查询结束时间。样例:2019-10-12T07:20:50.522Z。 说明: 开始时间和结束时间最多间隔90天,超出时间限制返回为空。 最小长度:1 最大长度:30 offset 否 Integer 偏移量,表示从此偏移量开始查询,offset大于等于0。 最小值:0 最大值:2147483647 缺省值:0 limit 否 Integer 每页显示的条目数量。 最小值:1 最大值:100 缺省值:20 factory_type 否 Array of strings 厂商类型。不填时默认全厂商。列举值:"huawei", "vivo", "oppo", "xiaomi", "meizu", "samsung"。
  • 请求示例 生成解析任务-个性化。模板ID为"600000001",短链最大解析次数为1次,过期时间为7天。 https://koomessage.myhuaweicloud.cn/v1/aim/resolve-tasks { "tpl_id" : "600000001", "sms_signs" : [ "华为云KooMessage" ], "aim_code_type" : "individual", "resolving_times" : 1, "domain" : null, "expiration_time" : 7, "params" : [ { "cust_flag" : "131****0000", "dync_params" : { "param1" : "参数1", "param2" : "参数2", "param3" : "参数3", "param4" : "参数4" }, "custom_url" : "https://www.example.com" }, { "cust_flag" : "131****0001", "dync_params" : { "param1" : "参数1", "param2" : "参数2", "param3" : "参数3", "param4" : "参数4" }, "custom_url" : "https://www.example.com" } ] } 生成解析任务-群发。模板ID为"600000002",短链最大解析次数为5次,过期时间为7天,域名为"km2g.cn"。 https://koomessage.myhuaweicloud.cn/v1/aim/resolve-tasks { "tpl_id" : "600000002", "sms_signs" : [ "华为云KooMessage" ], "aim_code_type" : "group", "resolving_times" : 5, "domain" : "km2g.cn", "expiration_time" : 7, "params" : [ { "cust_flag" : "131****0000", "custom_url" : "https://www.example.com" } ] } 生成解析任务-自定义短码。模板ID为"600000002",短链最大解析次数为5次,过期时间为7天,自定义短码为"abc123"。 https://koomessage.myhuaweicloud.cn/v1/aim/resolve-tasks { "tpl_id" : "600000002", "sms_signs" : [ "华为云KooMessage" ], "aim_code_type" : "group", "resolving_times" : 5, "domain" : "km3g.cn", "expiration_time" : 7, "generation_type" : "2", "params" : [ { "cust_flag" : "131****0000", "custom_short_code" : "abc123" } ] }
  • 响应示例 状态码: 200 返回信息。 { "task_id" : "80959fd0-dc23-42e3-9595-59a49ee6cccc", "tpl_id" : "600000002", "sms_signs" : [ "华为云KooMessage" ], "resolving_times" : 5, "aim_code_type" : "group", "domain" : "km2g.cn", "expiration_time" : 7, "params" : [ { "cust_flag" : "131****0000", "cust_id" : "231724915a62455ca356e10a085c9a23", "dync_params" : null, "custom_url" : "https://www.example.com", "aim_url" : "km2g.cn/PDARc6", "aim_code" : "PDARc6", "result_code" : "0", "error_message" : null, "generate_date" : "2022-07-18T21:02:44Z", "expire_date" : "2022-07-25T21:02:44Z", "custom_short_code" : null } ] }
  • 响应示例 状态码: 200 返回200状态码仅代表接口请求成功,任务提交结果由task_state字段来区分,此结果仅代表任务提交结果,并非智能信息发送结果。用户手机接收智能信息结果请以收到的回执结果为准,也可通过查询智能信息发送明细API获取或登录KooMessage控制台查看。 { "task_name" : "智能信息发送", "sms_channel" : { "channel_number" : "8822053111111", "sms_tpl_id" : 15010661, "sms_sign" : "华为云KooMessage", "sms_app_name" : "KooMessage" }, "resolve_task" : { "tpl_id" : "600000001", "resolve_times" : 1, "aim_code_type" : "individual", "domain" : null, "expiration_time" : 7, "generation_type" : "1", "params" : [ { "cust_flag" : "131****0000", "dync_params" : null, "custom_url" : "https://www.example.com", "custom_short_code" : null, "sms_params" : [ ] } ] }, "task_id" : "c3d7659d-06b0-4fa0-9eed-9225389ecccc", "task_state" : "Success", "creation_time" : "2022-07-19T14:37:34.00Z", "submission_count" : 1, "send_count" : 1, "resolve_count" : 0, "failed_short_chains" : [ ] }
  • 请求示例 发送智能信息。模板ID为"600000001",短链最大解析次数为1次,过期时间为7天,发送手机号码如"131****0000";通道号为"8822053111111",短信模板ID为"15010661"。 https://koomessage.myhuaweicloud.cn/v1/aim/send-tasks { "task_name" : "智能信息发送", "sms_channel" : { "channel_number" : "8822053111111", "sms_tpl_id" : 15010661, "sms_sign" : "华为云KooMessage", "sms_app_name" : "KooMessage" }, "resolve_task" : { "tpl_id" : "600000001", "resolve_times" : 1, "aim_code_type" : "individual", "domain" : null, "expiration_time" : 7, "params" : [ { "cust_flag" : "131****0000", "custom_url" : "https://www.example.com" } ] } } 发送智能信息-动态参数。模板ID为"600000002",短链最大解析次数为1次,过期时间为7天,发送手机号码如"131****0000",分别设置动态参数;通道号为"8822053111111",短信模板ID为"15010661"。 https://koomessage.myhuaweicloud.cn/v1/aim/send-tasks { "task_name" : "智能信息发送-动态参数", "sms_channel" : { "channel_number" : "8822053111111", "sms_tpl_id" : 15010661, "sms_sign" : "华为云KooMessage", "sms_app_name" : "KooMessage" }, "resolve_task" : { "tpl_id" : "600000002", "resolve_times" : 1, "aim_code_type" : "individual", "domain" : null, "expiration_time" : 7, "params" : [ { "cust_flag" : "131****0000", "dync_params" : { "param1" : "参数1", "param2" : "参数2", "param3" : "参数3", "param4" : "参数4" }, "custom_url" : "https://www.example.com", "sms_params" : [ "参数1", "参数2" ] }, { "cust_flag" : "131****0001", "dync_params" : { "param1" : "参数1", "param2" : "参数2", "param3" : "参数3", "param4" : "参数4" }, "custom_url" : "https://www.example.com", "sms_params" : [ "参数1", "参数2" ] } ] } }
  • 修订记录 发布日期 修订记录 2024-05-22 第三十次正式发布。 修改: 查询模板报表,更新API的URI,同时更新请求示例。 生成解析任务,修改请求Body参数resolving_time参数说明,增加“群发短链设置解析次数需要大于等于2”。 发送智能信息,修改aim_code_type、expiration_time、params参数描述,删除群发(group)短链相关信息。 2024-04-01 第二十九次正式发布。 修改: 创建个人模板,修改sub_type请求参数描述,增加card_id为CarouselVerticalImage、CardVoucher和ShortVideoImage时的sub_type参数规格,刷新card_id为RedPacket和RedPacketPersonal、ECImageAndText时的sub_type参数规格。 2024-01-31 第二十八次正式发布。 修改: 查询模板报表,修改tpl_ids请求参数数组长度,由“0-100”改为“1-100”;增加请求参数factory_type,厂商类型。 创建个人模板,修改功能介绍说明,模板内容需加“拒收请回复R”;请求示例中,content值末尾增加“拒收请回复R”。 上传智能信息模板素材,修改resource_type请求参数说明,视频大小由不超过“10M”改为“7M”。 生成解析任务,修改sms_signs请求参数描述,最多传入签名个数由“10”改为“5”,数组长度由“0-10”改为“1-5”;修改params请求参数说明,增加“群发短链每次调用最多申请一条”;修改custom_url请求参数描述,长度要求由不超过“2048”改为“256”。 新建智能信息基础版模板,增加请求参数is_draft,以草稿状态提交模板,同时更新请求示例。 查询智能信息基础版模板状态,修改Query参数offset、limit的必选性,由“是”改为“否”。 2024-01-16 第二十七次正式发布。 修改: 一站式服务号创建、查询智能信息服务号菜单、修改智能信息服务号菜单,修改third_service_name请求参数说明,增加“action_type=OPEN_APP”。 查询解析任务,修改Query参数begin_time参数说明,增加“仅支持查询最近1年内创建的解析任务”。 查询解析明细,修改Query参数begin_time参数说明,增加“仅支持查询最近1年内创建的短链”。 查询智能信息发送任务,修改Query参数begin_time参数说明,增加“仅支持查询最近1年内创建的智能信息发送任务”。 查询智能信息发送明细,修改Query参数begin_time参数说明,增加“仅支持查询最近1年内的发送明细”。 2023-12-13 第二十六次正式发布。 修改: 创建个人模板,修改card_id请求参数描述,增加“EcommerceCouponHorizontal:电商领券类横版”布局类型;修改sub_type请求参数说明,当card_id为EcommerceCouponHorizontal时,sub_type用于设置卡券区是否隐藏;修改请求参数button_type描述,当模板为电商领券类横版时,用于指定按钮类型;修改factory_type请求参数描述,HUAWEI厂商增加“电商领券类横版(EcommerceCouponHorizontal)”布局类型;增加“创建电商领券类横版模板(EcommerceCouponHorizontal)”请求示例。 2023-11-16 第二十五次正式发布。 修改: 创建个人模板,修改card_id请求参数描述,增加“EcommerceCouponVertical:电商领券类竖版”布局类型;修改sub_type请求参数说明,当card_id为EcommerceCouponVertical时,sub_type用于设置卡券区是否隐藏;增加请求参数button_type,当模板为电商领券类竖版时,用于指定按钮类型;修改factory_type请求参数描述,HUAWEI厂商增加“电商领券类竖版(EcommerceCouponVertical)”布局类型;增加“创建电商领券类竖版模板(EcommerceCouponVertical)”请求示例。 2023-10-18 第二十四次正式发布。 修改: 上传智能信息服务号图片资源,修改file_type请求参数描述,PUB_LOGO的大小由“不超过4M”改为“不超过100k”。 查询模板,修改Query参数factory_type,增加三星厂商类型,同时数组长度由“0-5”改为“0-6”。 创建个人模板,修改action_type请求参数说明,增加“三星厂商点击事件类型不支持新建日程、打开大图”;修改floor_type请求参数说明,增加三星厂商不支持的兜底类型说明;修改factory_type请求参数描述,增加三星厂商类型,同时增加三星厂商支持的布局类型。 发送智能信息,修改expiration_time请求参数描述,aim_code_type为group时,expiration_time取值范围从“1~100”修改为“1~180”。 定义模板状态回执,修改factory_type请求参数描述,增加三星厂商类型。 2023-09-27 第二十三次正式发布。 修改: 生成解析任务,修改expiration_time请求参数描述,aim_code_type为group时,expiration_time取值范围从“1~100”修改为“1~180”。 2023-08-29 第二十二次正式发布。 新增: 设置视频模板封面图 查询视频模板封面图 修改: 创建个人模板,修改功能介绍说明,增加“&”;修改src_type请求参数描述,增加说明“src_type为2,即资源地址时,src或cover内容必须是存储在客户侧服务器上的资源地址”;修改cover请求参数说明,增加“通过设置视频模板封面图接口设置视频封面”;修改创建电商类多商品模板(Ecommerce)(显示货币符号)请求示例,当type为text、content为按钮时,visible由“0”改为“1”。 2023-08-21 第二十一次正式发布。 新增: 短信应用,包含短信应用的创建、查询、修改等接口。 短信签名,包含短信签名的创建、查询、修改等接口。 短信模板,包含短信模板的创建、查询、修改等接口。 短信发送,包含短信发送的分批发送等接口。 修改: 一站式服务号创建、修改主页信息,修改logo_img请求参数说明,删除“比例+-0.15”,将“大小不超过5M”改为“大小不超过4M”。 上传智能信息服务号图片资源,修改file_type请求参数描述,PUB_LOGO、BG_IMAGE和FASTAPP_LOGO增加图片规格。 查询解析任务、查询解析明细,增加Query参数和响应参数,该参数为task_name,任务名称,并同步修改响应示例。 注册智能信息回执URL,修改url_type参数描述,修改“0:智能信息发送回调”为“0:智能信息单条发送回调”,增加“2:智能信息批量发送回调”;修改请求示例描述,修改“注册回执-智能信息发送回执”为“注册回执-智能信息单条发送回执”;增加“注册回执-智能信息批量发送回执”请求示例。 定义智能信息发送回执,修改body请求参数描述,增加参数约束“回调类型为智能信息单条发送/短链回调”和“回调类型为智能信息批量发送/短链回调”;增加请求参数total、sequence和extend;增加“定义短信批量回执”和“定义短链批量回执”请求示例。 错误码,新增短信接口相关的错误码。 2023-08-03 第二十次正式发布。 创建个人模板,修改card_id请求参数描述,增加“ShortVideoImage:短剧图片类”布局类型;修改factory_type请求参数描述,厂商“HUAWEI”支持的布局类型增加“短剧图片类(ShortVideoImage)”;增加“创建短剧图片模板(ShortVideoImage)”请求示例。 2023-07-27 第十九次正式发布。 修改: 创建个人模板,修改请求示例,包括示例描述和示例代码。 2023-07-20 第十八次正式发布。 修改: 查询模板,修改factory_type参数描述,“Xiaomi:小米”改为“XIAOMI:小米”;删除tpl_state响应参数说明,删除“智能信息模板启动、禁用暂为运营管理功能,Console页面与API暂未开放此功能”。 定义智能信息基础版发送回执,修改请求示例描述,将“手机用户下行消息接受成功”改为“手机用户下行消息接收成功”。 2023-07-14 第十七次正式发布。 修改: 解冻服务号,增加响应示例。 冻结服务号,修改响应参数结构体,并同步修改响应示例。 查询解析明细,修改resolved_status响应参数类型,“Object”改为“String”。 查询智能信息基础版模板状态,修改tpl_size和status响应参数类型,“String”改为“Integer”。 API,根据统一的要求,优化接口请求示例描述。 2023-06-16 第十六次正式发布。 修改: 创建个人模板,修改oppo_background请求参数描述,增加参数描述“OPPO红包背景图要求宽高比为3:4,建议尺寸为342px*456px”。 生成解析任务,修改aim_code_type请求参数描述,删除参数说明“使用动态参数模板时,该字段只能为individual”。 2023-05-30 第十五次正式发布。 新增: 启用或禁用模板实例 修改: 创建个人模板,修改sub_type请求参数描述,当card_id为ECImageAndText时,sub_type用于设置左右按钮组合颜色;增加请求参数ratio,短视频模板视频和封面的宽高比;增加创建电商类模板(ECImageAndText)(设置按钮颜色)请求示例。 发送智能信息基础版任务,修改mobiles请求参数描述和可选性,非必选,mobiles和individual_params字段只能二选一;修改dync_params请求参数描述,群发动态参数数组;增加请求参数individual_params,个性化手机号码及动态参数数组;增加发送智能信息基础版任务-个性化动态参数请求示例。 2023-05-26 第十四次正式发布。 修改: 创建个人模板,修改card_id请求参数描述,增加海报类(SimplePoster)、超文本普通类(NativePureText)、超文本增强类(NativeImageAndText)和短视频类(ShortVideo)模板类型;修改factory_type请求参数描述,HUAWEI厂商增加海报类(SimplePoster)、超文本普通类(NativePureText)、超文本增强(NativeImageAndText)和短视频类(ShortVideo)布局类型;增加创建海报类模板(SimplePoster)、创建超文本普通类模板(NativePureText)、创建超文本增强类模板(NativeImageAndText)和创建短视频模板(ShortVideo)请求示例。 查询智能信息基础版发送任务,修改请求示例名称,“查询视频短信发送任务”改为“查询智能信息基础版发送任务”。 发送智能信息基础版任务,修改请求示例名称,“发送视频短信任务-动态参数”改为“发送智能信息基础版任务-动态参数”。 2023-05-17 第十三次正式发布。 修改: 定义智能信息基础版模板状态回执,修改type请求参数描述,动参变量类型删除图片、音频和视频。 新建智能信息基础版模板,修改type请求参数描述,增加mp4视频资源类型;修改content请求参数说明,图片不支持使用#p_n#参数变量,故删除“图片”描述字样。 2023-05-10 第十二次正式发布。 修改: 生成解析任务、查询智能信息发送任务、发送智能信息,修改custom_url参数描述,长度要求不超过2048。 2023-04-23 第十一次正式发布。 修改: 查询模板,增加Query参数is_only_status,响应里只返回状态信息,不返回pages和params。 创建个人模板,增加visible请求参数说明,目前仅针对电商多商品(Ecommerce)、多卡券(CardVouchers)、增强机票类(PlaneTrip)这三种版式起效。 定义模板状态回执,修改audit_state请求参数说明,模板审核状态补充说明;修改state请求参数约束,厂商审核状态。 2023-03-31 第十次正式发布。 修改: 创建个人模板,增加请求参数sub_type,版式子类型;增加个性化红包类模板请求示例,创建个性化红包类模板(RedPacketPersonal)(样式2)。 定义模板状态回执,修改factory_type请求参数描述,同时修改对应的请求示例,华为厂商改为“HuaWei”、小米厂商改为“XiaoMi”。 2023-03-13 第九次正式发布。 修改: 创建个人模板,增加card_id请求参数说明,当送审厂商包含vivo时,各布局类型上传的图片最小像素。 新建智能信息基础版模板,修改index请求参数说明,最大帧数为8帧,2个元素的帧最多2个,index只能全部填或全为空。 2023-03-03 第八次正式发布。 修改: 发送智能信息,修改sms_params参数描述,增加短信模板参数的变量格式和限制信息。 新建智能信息基础版模板,修改title请求参数描述,智能信息基础版模板主题最大不超过20个字。 查询智能信息基础版模板状态,修改tpl_size响应参数说明,删除“audit_status非0时tpl_size为0”。 2023-02-24 第七次正式发布。 修改: 发送智能信息基础版任务,修改tpl_id请求参数约束,智能信息基础版模板ID最大长度是10;增加mobiles请求参数说明,长度指的是单个号码的长度。 2023-02-17 第六次正式发布。 修改: 查询模板报表,修改expose_uv、expose_pv、click_uv、click_pv响应参数描述,删除“暂时不提供”。 创建个人模板,修改card_id请求参数描述,增加Ecommerce(电商多商品类)、Trip1(机票类)、Trip2(火车票类)、Trip3(汽车票类)和PlaneTrip(增强机票类)五种布局类型,同时增加各类型对应的请求示例;增加请求参数content_child;修改factory_type请求参数说明,增加华为厂商(HUAWEI)支持的布局类型。 发送智能信息,修改dync_params参数描述,智能信息模板动态参数;增加参数sms_params,短信模板参数。 2023-02-07 第五次正式发布。 修改: 查询通道号列表,增加响应参数is_bind、pub_list、pub_name和pub_reference。 创建个人模板,修改sms_template请求参数说明,历史遗留字段,建议不再使用。 查询智能信息发送报表,修改report_type请求参数说明与必选性,非必选,默认查询日报表。 2023-01-13 第四次正式发布。 修改: 创建个人模板,增加type请求参数说明,图片轮播类模板最多可以放5张图片。 查询解析任务、生成解析任务、查询智能信息发送任务、发送智能信息,修改domain参数样例,带路径的短链域名结尾不能带“/”。 2023-01-11 第三次正式发布。 修改: 创建个人模板,删除创建横滑类1模板(Carousel)、创建横滑类2模板(CarouselTitle)请求示例中的参数src_type。 上传智能信息模板素材,修改功能介绍说明,增加删除资源的条件和逻辑。 生成解析任务,修改params请求参数说明,OPPO模板一次最多申请10个短链。 新建智能信息基础版模板,修改index请求参数说明,补充说明最大帧数。 查询智能信息基础版模板状态,增加Query参数begin_time与end_time。 2022-11-28 第二次正式发布。 新增: 注册智能信息基础版回执URL 查询用户已注册智能信息基础版回执接口 定义智能信息基础版发送回执 定义智能信息基础版上行消息回执 修改: API,修改接口参数与示例,两者一一对应。 查询模板,增加begin_time、end_time参数约束说明;修改factory_type请求参数描述。 创建个人模板,增加功能介绍说明;新增请求参数sms_signs、sms_template和vivo_background;修改action_type、factory_type请求参数描述。 上传智能信息模板素材,增加功能介绍说明。 查询解析任务,修改domain参数描述。 生成解析任务,修改custom_url参数说明;修改custom_short_code参数描述;修改domain、params参数描述。 查询手机号智能信息解析能力,增加tpl_id参数描述。 查询解析明细,修改aim_url参数约束描述。 查询智能信息发送任务,修改task_name参数描述;新增failed_short_chains、 success_number响应参数;修改domain参数描述。 发送智能信息,修改task_name、expiration_time参数描述;增加请求参数task_name描述说明;修改custom_url参数说明;新增failed_short_chains响应参数;修改custom_short_code参数描述;修改domain、params参数描述。 注册智能信息回执URL,修改callback_url参数说明。 新建智能信息基础版模板,删除请求参数reminders。 错误码 2022-11-04 第一次正式发布。
  • 请求示例 创建红包类模板(RedPacket)。模板为试商用,分别设置image、text和button模板组件,支持厂商为"HUAWEI, XIAOMI, OPPO"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "RedPacket", "tpl_name" : "测试:红包专用模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "704716117981000001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1, "oppo_background" : "709001482208300001" }, { "type" : "text", "content" : "京西商城", "is_text_title" : "false", "position_number" : 2 }, { "type" : "text", "content" : "全球狂欢节", "is_text_title" : "false", "position_number" : 3 }, { "type" : "text", "content" : "春风十里,不如红包送你!拒收请回复R", "is_text_title" : "false", "position_number" : 4 }, { "type" : "button", "content" : "领取红包", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 5 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "XIAOMI" }, { "state" : 1, "factory_type" : "OPPO" } ] } 创建个人红包类模板(RedPacketPersonal)(样式1:显示文本)。模板为试商用,分别设置image、text和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "RedPacketPersonal", "tpl_name" : "测试:新年红包模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "704994098020300001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "text", "content" : "京西商城", "is_text_title" : "false", "position_number" : 2 }, { "type" : "text", "content" : "京西祝您虎年大吉!", "is_text_title" : "false", "position_number" : 3 }, { "type" : "text", "content" : "新年快乐,大年大吉!拒收请回复R", "is_text_title" : "false", "position_number" : 4 }, { "type" : "image", "src" : "709192070996200001", "src_type" : 1, "position_number" : 5 }, { "type" : "button", "content" : "拆", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 6 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ] } 创建横滑类1模板(Carousel)。模板为试商用,共有3页,每页分别设置image、title、text和button模板组件,支持厂商为"HUAWEI, OPPO, MEIZU"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "Carousel", "tpl_name" : "测试:商品推荐模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "709294526124000001", "src_type" : 1, "position_number" : 1 }, { "type" : "text", "content" : "测试工业风车载收纳箱", "is_text_title" : "true", "position_number" : 2 }, { "type" : "text", "content" : "户外车生活,趋势爆款,全民围观。拒收请回复R", "is_text_title" : "false", "position_number" : 3 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_URL", "position_number" : 4 } ], "page_order" : 1 }, { "contents" : [ { "type" : "image", "src" : "709294596722500001", "src_type" : 1, "position_number" : 1 }, { "type" : "text", "content" : "测试BOC 4K超清电竞显示器", "is_text_title" : "true", "position_number" : 2 }, { "type" : "text", "content" : "阿伟,你怎么还在用灰白屏的显示器,换一个好不好!", "is_text_title" : "false", "position_number" : 3 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_URL", "position_number" : 4 } ], "page_order" : 2 }, { "contents" : [ { "type" : "image", "src" : "709206231474000001", "src_type" : 1, "position_number" : 1 }, { "type" : "text", "content" : "测试小猫咪", "is_text_title" : "true", "position_number" : 2 }, { "type" : "text", "content" : "我没词了,看到这只小猫咪了没,它比你还震惊", "is_text_title" : "false", "position_number" : 3 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_URL", "position_number" : 4 } ], "page_order" : 3 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "OPPO" }, { "state" : 1, "factory_type" : "MEIZU" } ] } 创建增强通知类模板(Notification2)。模板为试商用,分别设置title、text、button和image模板组件,支持动态参数设置,支持厂商为"HUAWEI, XIAOMI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "Notification2", "tpl_name" : "测试:交易提醒模板", "pages" : [ { "contents" : [ { "type" : "text", "content" : "测试交易提醒", "visible" : 1, "is_text_title" : "true", "position_number" : 1 }, { "type" : "text", "content" : "您尾号为${param6}的账户支出。拒收请回复R", "visible" : 1, "is_text_title" : "false", "position_number" : 2 }, { "type" : "text", "content" : "${param1}", "visible" : 1, "is_text_title" : "false", "position_number" : 3 }, { "type" : "text", "content" : "元", "visible" : 1, "is_text_title" : "false", "position_number" : 4 }, { "type" : "text", "content" : "交易时间", "visible" : 1, "is_text_title" : "false", "position_number" : 5 }, { "type" : "text", "content" : "${param2}", "visible" : 1, "is_text_title" : "false", "position_number" : 6 }, { "type" : "text", "content" : "交易类型", "visible" : 1, "is_text_title" : "false", "position_number" : 7 }, { "type" : "text", "content" : "${param3}", "visible" : 1, "is_text_title" : "false", "position_number" : 8 }, { "type" : "text", "content" : "交易金额", "visible" : 1, "is_text_title" : "false", "position_number" : 9 }, { "type" : "text", "content" : "${param4}", "visible" : 1, "is_text_title" : "false", "position_number" : 10 }, { "type" : "text", "content" : "剩余金额", "visible" : 1, "is_text_title" : "false", "position_number" : 11 }, { "type" : "text", "content" : "${param5}", "visible" : 1, "is_text_title" : "false", "position_number" : 12 }, { "type" : "button", "content" : "联系客服", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_URL", "position_number" : 13 }, { "type" : "button", "content" : "查看详情", "visible" : 1, "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_URL", "position_number" : 14 }, { "type" : "image", "src" : "709626274649200001", "visible" : 1, "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_URL", "position_number" : 15 } ], "page_order" : 1 } ], "params" : [ { "type" : 1, "name" : "${param1}", "example" : "26880.60" }, { "type" : 1, "name" : "${param2}", "example" : "2020年12月31日 18:00" }, { "type" : 1, "name" : "${param3}", "example" : "某信支付" }, { "name" : "${param4}", "example" : "8554.00", "type" : 1 }, { "name" : "${param5}", "example" : "5418385.00", "type" : 1 }, { "name" : "${param6}", "example" : "8888", "type" : 1 } ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "XIAOMI" } ] } 创建图文类模板(StandardImageAndText)。模板为试商用,分别设置image、title、text和button模板组件,支持厂商为"HUAWEI, XIAOMI, OPPO, MEIZU"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "StandardImageAndText", "tpl_name" : "测试:文章推送模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "709278003095400001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "text", "content" : "测试:摆脱“他练的比我好”魔咒", "is_text_title" : "true", "position_number" : 2 }, { "type" : "text", "content" : "一线头部健身红人携手推荐的铁血联盟GoldenMusle分离乳清蛋白。少年想变大变强吗?来,干了这碗粉再来一组颈前。拒收请回复R", "is_text_title" : "false", "position_number" : 3 }, { "type" : "button", "content" : "文章详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 4 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "XIAOMI" }, { "state" : 1, "factory_type" : "OPPO" }, { "state" : 1, "factory_type" : "MEIZU" } ] } 创建多图文模板(MultipleImageAndText)。模板为试商用,分别设置image、title、text和button模板组件,支持厂商为"HUAWEI, XIAOMI, OPPO, MEIZU"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "MultipleImageAndText", "tpl_name" : "测试:文章推送模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "709274211138400001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "text", "content" : "测试618企划第2弹 | 夏日热浪小分队!", "is_text_title" : "true", "position_number" : 2 }, { "type" : "image", "src" : "709274708910000001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 3 }, { "type" : "text", "content" : "新体验 | 爽滑质感,格外有‘型’。拒收请回复R", "is_text_title" : "false", "position_number" : 4 }, { "type" : "image", "src" : "709205988959300001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 5 }, { "type" : "text", "content" : "两种穿法,随心选择", "is_text_title" : "false", "position_number" : 6 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "XIAOMI" }, { "state" : 1, "factory_type" : "OPPO" }, { "state" : 1, "factory_type" : "MEIZU" } ] } 创建长文本类模板(PureText)-增强样式。模板为试商用,分别设置image、title、text和button模板组件,支持厂商为"HUAWEI, OPPO"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "PureText", "tpl_name" : "测试:通知类模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "709280852332200001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "text", "content" : "测试宝驴", "is_text_title" : "true", "position_number" : 2 }, { "type" : "text", "content" : "测试宝驴2022新车型试驾邀请", "is_text_title" : "true", "position_number" : 3 }, { "type" : "text", "content" : "快快快,冲冲冲,宝驴战士在行动!\n作为世界上最成功的豪华汽车品牌之一,我们从未停下脚步,不能说风驰电掣吧,只能说五秒一米。", "is_text_title" : "false", "position_number" : 4 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 5 }, { "type" : "button", "content" : "立即预约", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 6 }, { "type" : "image", "src" : "709284435094100001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 7 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "OPPO" } ] } 创建视频类模板(Video)。模板为试商用,分别创建video、title、text、和button模板组件,支持厂商为"HUAWEI, OPPO"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "Video", "tpl_name" : "测试:新品视频推荐模板", "pages" : [ { "contents" : [ { "type" : "video", "src" : "709329169166600001", "cover" : "709329184257700001", "src_type" : 1, "position_number" : 1 }, { "type" : "text", "content" : "测试月巴克 挚爱回归 | 威士忌", "is_text_title" : "true", "position_number" : 2 }, { "type" : "text", "content" : "月巴克甄选,威士忌桶酿冷萃,20Hr慢萃,烟熏酒感。让人年年不忘的风味密码,就藏在这颗咖啡豆中。拒收请回复R", "is_text_title" : "false", "position_number" : 3 }, { "type" : "button", "content" : "了解详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 4 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "OPPO" } ] } 创建视频图文类模板(VideoImageAndText)。模板为试商用,分别设置video、image、title、text和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "VideoImageAndText", "tpl_name" : "测试:视频图文模板", "pages" : [ { "contents" : [ { "type" : "video", "src" : "706316737703800001", "cover" : "706316757404500001", "src_type" : 1, "position_number" : 1 }, { "type" : "image", "src" : "709339781871400001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 2 }, { "type" : "text", "content" : "测试老伦敦鱼肉派仰望星空9块9", "is_text_title" : "true", "position_number" : 3 }, { "type" : "text", "content" : "像是来自异次元的食物,除了他的名字,无论是品相还是味道都令人难以接受,你要不要尝试一下?拒收请回复R", "is_text_title" : "false", "position_number" : 4 }, { "type" : "button", "content" : "立即了解", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 5 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ] } 创建电商类模板(ECImageAndText)-图文模式(显示货币符号)。模板为试商用,分别设置image、title、text和button模板组件,支持厂商为"HUAWEI, OPPO"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "ECImageAndText", "tpl_name" : "测试:电商模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "709206231474000001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "image", "src" : "709258670432600001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 2 }, { "type" : "image", "src" : "709206119700000001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 3 }, { "type" : "text", "content" : "160.00", "is_text_title" : "true", "position_number" : 4, "currency_display" : 1 }, { "type" : "text", "content" : "满减", "is_text_title" : "true", "position_number" : 5 }, { "type" : "text", "content" : "测试猫车模拟驾驶", "is_text_title" : "true", "position_number" : 6 }, { "type" : "text", "content" : "您的体力已耗尽!拒收请回复R", "is_text_title" : "false", "position_number" : 7 }, { "type" : "button", "content" : "添加购物车", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 8 }, { "type" : "button", "content" : "立即购买", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 9 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "OPPO" } ] } 创建电商类模板(ECImageAndText)-视频模式(不显示货币符号)。模板为试商用,分别设置video、title、text和button模板组件,支持厂商为"HUAWEI, OPPO"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "ECImageAndText", "tpl_name" : "测试:创建电商模板", "pages" : [ { "contents" : [ { "type" : "video", "src" : "706316737703800001", "cover" : "706316757404500001", "src_type" : 1, "position_number" : 1 }, { "type" : "text", "content" : "500", "is_text_title" : "true", "position_number" : 2, "currency_display" : 0 }, { "type" : "text", "content" : "电子换新季", "is_text_title" : "true", "position_number" : 3 }, { "type" : "text", "content" : "测试RVIDIA/ntx 13700F/老矿工级显卡", "is_text_title" : "true", "position_number" : 4 }, { "type" : "text", "content" : "刀法精湛,唯我皮衣刀客黄伟达!CMD,YES!拒收请回复R", "is_text_title" : "false", "position_number" : 5 }, { "type" : "button", "content" : "加入购物车", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 6 }, { "type" : "button", "content" : "立即购买", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 7 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "OPPO" } ] } 创建图片轮播类模板(CarouselSquareImage)(比例1:1)。模板为试商用,分别设置image、title、text和button模板组件,支持厂商为"HUAWEI, OPPO"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "CarouselSquareImage", "tpl_name" : "测试:消息推送模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "709329780880700001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "image", "src" : "709330167360600001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 2 }, { "type" : "image", "src" : "709322435765200001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 3 }, { "type" : "text", "content" : "测试对钱不感兴趣", "is_text_title" : "true", "position_number" : 4 }, { "type" : "text", "content" : "“我对钱不感兴趣,我平生最后悔的事就是创立了现在的公司”,拥有261911640000元资产的首富马雨先生如是说到。拒收请回复R", "is_text_title" : "false", "position_number" : 5 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_URL", "position_number" : 6 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "OPPO" } ] } 创建图文视频类模板(ImageTextAndVideo)。模板为试商用,分别设置image、video、title、text和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "ImageTextAndVideo", "tpl_name" : "测试:图文视频模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "708935153673600001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_URL", "position_number" : 1 }, { "type" : "video", "src" : "706316737703800001", "cover" : "706316757404500001", "src_type" : 1, "position_number" : 2 }, { "type" : "text", "content" : "测试一级标题", "is_text_title" : "true", "position_number" : 3 }, { "type" : "text", "content" : "文本内容。拒收请回复R", "is_text_title" : "false", "position_number" : 4 }, { "type" : "button", "content" : "打开链接", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_URL", "position_number" : 5 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ] } 创建一般通知类模板(Notification1)。模板为试商用,分别设置title、text、button和image模板组件,支持动态参数设置,支持厂商为"HUAWEI, XIAOMI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "Notification1", "tpl_name" : "测试:购票通知模板", "pages" : [ { "contents" : [ { "type" : "text", "content" : "测试乘车通知", "is_text_title" : "true", "position_number" : 1 }, { "type" : "text", "content" : "欢迎乘坐xx市地铁。拒收请回复R", "is_text_title" : "false", "position_number" : 2 }, { "type" : "text", "content" : "乘车路线", "is_text_title" : "false", "position_number" : 3 }, { "type" : "text", "content" : "${param1}", "is_text_title" : "false", "position_number" : 4 }, { "type" : "text", "content" : "乘车时间", "is_text_title" : "false", "position_number" : 5 }, { "type" : "text", "content" : "${param2}", "is_text_title" : "false", "position_number" : 6 }, { "type" : "text", "content" : "行程单号", "is_text_title" : "false", "position_number" : 7 }, { "type" : "text", "content" : "${param3}", "is_text_title" : "false", "position_number" : 8 }, { "type" : "button", "content" : "地铁路线", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_URL", "position_number" : 9 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_URL", "position_number" : 10 }, { "type" : "image", "src" : "708938538225200001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_URL", "position_number" : 11 } ], "page_order" : 1 } ], "params" : [ { "type" : 1, "name" : "${param1}", "example" : "北京-深圳" }, { "type" : 1, "name" : "${param2}", "example" : "2020年12月31日 18:00" }, { "type" : 1, "name" : "${param3}", "example" : 1364000000000001 } ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "XIAOMI" } ] } 创建多图文类模板(MultipleImageAndText):1对。模板为试商用,分别设置image、title和text模板组件,支持厂商为"HUAWEI, XIAOMI, OPPO, MEIZU"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "MultipleImageAndText", "tpl_name" : "测试:创建文章推送模板(1对)", "pages" : [ { "contents" : [ { "type" : "image", "src" : "709996126698200001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "text", "content" : "测试2022年上半年中国游戏产业报告!", "is_text_title" : "true", "position_number" : 2 }, { "type" : "image", "src" : "709823764258400001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 3 }, { "type" : "text", "content" : "【那个游戏5】600多个小时在那个游戏OL里能做什么?拒收请回复R", "is_text_title" : "false", "position_number" : 4 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "XIAOMI" }, { "state" : 1, "factory_type" : "OPPO" }, { "state" : 1, "factory_type" : "MEIZU" } ] } 创建多图文模板(MultipleImageAndText):3对。模板为试商用,分别设置image、title和text模板组件,可设置3组图文,支持厂商为"HUAWEI, XIAOMI, OPPO, MEIZU"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "MultipleImageAndText", "tpl_name" : "测试:文章推送模板(3对)", "pages" : [ { "contents" : [ { "type" : "image", "src" : "710002667975300001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "text", "content" : "测试阿玛呢 | 高定私仓香氛清新系列", "is_text_title" : "true", "position_number" : 2 }, { "type" : "image", "src" : "709322435765200001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 3 }, { "type" : "text", "content" : "中有 | BITO问际 M7 · 路演来啦!拒收请回复R", "is_text_title" : "false", "position_number" : 4 }, { "type" : "image", "src" : "709823764258400001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 5 }, { "type" : "text", "content" : "少侠留步!十件可以提升生活品质的小物件就在这里", "is_text_title" : "false", "position_number" : 6 }, { "type" : "image", "src" : "710004338436600001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 7 }, { "type" : "text", "content" : "唇齿留香,女神们都在用的秘密牙膏!", "is_text_title" : "false", "position_number" : 8 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "XIAOMI" }, { "state" : 1, "factory_type" : "OPPO" }, { "state" : 1, "factory_type" : "MEIZU" } ] } 创建横滑类2模板(CarouselTitle)。模板为试商用,共有3页,每页分别设置image、title和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "CarouselTitle", "tpl_name" : "测试:商品推荐模板(样式2)", "pages" : [ { "contents" : [ { "type" : "image", "src" : "710007346331400001", "src_type" : 1, "position_number" : 1 }, { "type" : "text", "content" : "测试玩咖周末漫游指南。拒收请回复R", "is_text_title" : "true", "position_number" : 2 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 3 } ], "page_order" : 1 }, { "contents" : [ { "type" : "image", "src" : "710008006313500001", "src_type" : 1, "position_number" : 1 }, { "type" : "text", "content" : "测试月球商店555号~", "is_text_title" : "true", "position_number" : 2 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 3 } ], "page_order" : 2 }, { "contents" : [ { "type" : "image", "src" : "710004338436600001", "src_type" : 1, "position_number" : 1 }, { "type" : "text", "content" : "测试爆款单品不止六折!", "is_text_title" : "true", "position_number" : 2 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 3 } ], "page_order" : 3 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ] } 创建图片轮播类模板(CarouselSquareImage)(比例16:9)。模板为试商用,分别设置image、title、text和button模板组件,支持厂商为"HUAWEI, OPPO"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "CarouselImageSixteenToNine", "tpl_name" : "测试:培训推荐模板(16:9)", "pages" : [ { "contents" : [ { "type" : "image", "src" : "710013258135800001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "image", "src" : "710013320555400001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 2 }, { "type" : "image", "src" : "710013369414800001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 3 }, { "type" : "text", "content" : "测试课程招生 | 艺术相伴,写意", "is_text_title" : "true", "position_number" : 4 }, { "type" : "text", "content" : "丰富的师资、现金的课程体系,全面对接剧院资源,提供一站式教学服务体系和广阔的演出交流平台,打造全新的艺术交易品牌。为丰富地方文化教育资源,培养潜在观众群体,提升市民文化修养发挥重要作用。拒收请回复R", "is_text_title" : "false", "position_number" : 5 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 6 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "OPPO" } ] } 创建图片轮播类模板(CarouselSquareImage)(比例48:65)。模板为试商用,分别设置image、title、text和button模板组件,支持厂商为"HUAWEI, OPPO"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "CarouselVerticalImage", "tpl_name" : "测试:创建图片轮播模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "710017105923100001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "image", "src" : "710016994975400001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 2 }, { "type" : "image", "src" : "710016702179400001", "action" : { "target" : "https://www.example.com/" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 3 }, { "type" : "text", "content" : "测试一级标题", "is_text_title" : "true", "position_number" : 4 }, { "type" : "text", "content" : "正文文本。拒收请回复R", "is_text_title" : "false", "position_number" : 5 }, { "type" : "button", "content" : "查看详情", "action" : { "target" : "https://www.example.com/" }, "action_type" : "OPEN_BROWSER", "position_number" : 6 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" }, { "state" : 1, "factory_type" : "OPPO" } ] } 创建单卡券(CardVoucher)(折扣券)。模板为试商用,分别设置text、title、image和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "card_id" : "CardVoucher", "tpl_name" : "测试-折扣券", "use_id" : 2, "pages" : [ { "page_order" : 1, "contents" : [ { "type" : "text", "content" : "8.6折", "is_text_title" : "false", "position_number" : 1 }, { "type" : "text", "content" : "折扣券", "is_text_title" : "false", "position_number" : 2 }, { "type" : "text", "content" : " 满 1000 可用", "is_text_title" : "false", "position_number" : 3 }, { "type" : "text", "content" : "双节活动。拒收请回复R", "is_text_title" : "false", "position_number" : 4 }, { "type" : "text", "content" : "2022-01-01~2022-12-31", "is_text_title" : "false", "position_number" : 5 }, { "type" : "image", "src_type" : 1, "src" : "713355798843010000", "action_type" : "OPEN_URL", "position_number" : 6, "action" : { "target" : "https://www.example.com" } }, { "type" : "button", "content" : "点击前往", "action_type" : "OPEN_URL", "position_number" : 7, "action" : { "target" : "https://www.example.com" } } ] } ], "params" : [ ], "factorys" : [ { "factory_type" : "HUAWEI", "state" : 1 } ] } 创建单卡券(CardVoucher)(满减券)。模板为试商用,分别设置text、title、image和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "card_id" : "CardVoucher", "tpl_name" : "测试-满减券", "use_id" : 2, "pages" : [ { "page_order" : 1, "contents" : [ { "type" : "text", "content" : "¥100", "is_text_title" : "false", "position_number" : 1 }, { "type" : "text", "content" : "满减券", "is_text_title" : "false", "position_number" : 2 }, { "type" : "text", "content" : " 满 1000 可用", "is_text_title" : "false", "position_number" : 3 }, { "type" : "text", "content" : "欢迎选购。拒收请回复R", "is_text_title" : "false", "position_number" : 4 }, { "type" : "text", "content" : "2022-01-01~2022-12-31", "is_text_title" : "false", "position_number" : 5 }, { "type" : "image", "src_type" : 1, "src" : "714366886086740000", "action_type" : "OPEN_URL", "position_number" : 6, "action" : { "target" : "https://www.example.com" } }, { "type" : "button", "content" : "点击前往", "action_type" : "OPEN_URL", "position_number" : 7, "action" : { "target" : "https://www.example.com" } } ] } ], "params" : [ ], "factorys" : [ { "factory_type" : "HUAWEI", "state" : 1 } ] } 创建单卡券(CardVoucher)(自定义)。模板为试商用,分别创建text、title、image和button组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "card_id" : "CardVoucher", "tpl_name" : "测试-自定义卡券", "use_id" : 2, "pages" : [ { "page_order" : 1, "contents" : [ { "type" : "text", "content" : "优惠活动", "is_text_title" : "false", "position_number" : 1 }, { "type" : "text", "content" : "卡券类型", "is_text_title" : "false", "position_number" : 2 }, { "type" : "text", "content" : "使用门槛", "is_text_title" : "false", "position_number" : 3 }, { "type" : "text", "content" : "自定义卡券。拒收请回复R", "is_text_title" : "false", "position_number" : 4 }, { "type" : "text", "content" : "2022-01-01~2022-12-31", "is_text_title" : "false", "position_number" : 5 }, { "type" : "image", "src_type" : 1, "src" : "714366886086740000", "action_type" : "OPEN_URL", "position_number" : 6, "action" : { "target" : "https://www.example.com" } }, { "type" : "button", "content" : "点击前往", "action_type" : "OPEN_URL", "position_number" : 7, "action" : { "target" : "https://www.example.com" } } ] } ], "params" : [ ], "factorys" : [ { "factory_type" : "HUAWEI", "state" : 1 } ] } 创建多卡券(CardVouchers)(多卡券单按钮)。模板为试商用,分别创建text和button模板组件,支持多组卡券,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "card_id" : "CardVouchers", "tpl_name" : "测试-多卡券单按钮", "use_id" : 2, "pages" : [ { "page_order" : 1, "contents" : [ { "type" : "text", "content" : "测试-满减优惠", "position_number" : 1 }, { "type" : "text", "content" : "卡券类型", "position_number" : 2 }, { "type" : "text", "content" : "免单", "position_number" : 3 }, { "type" : "text", "content" : "使用门槛", "position_number" : 4 }, { "type" : "text", "content" : "测试-自定义卡券。拒收请回复R", "position_number" : 5 }, { "type" : "text", "content" : "领取30天后有效", "position_number" : 6 }, { "type" : "button", "content" : "去领取", "action_type" : "OPEN_URL", "position_number" : 7, "visible" : 0, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "折扣券", "position_number" : 8 }, { "type" : "text", "content" : "8.6折", "position_number" : 9 }, { "type" : "text", "content" : "满1000可用", "position_number" : 10 }, { "type" : "text", "content" : "测试-折扣优惠", "position_number" : 11 }, { "type" : "text", "content" : "2022-01-01~2022-12-31", "position_number" : 12 }, { "type" : "button", "content" : "去领取", "action_type" : "OPEN_URL", "position_number" : 13, "visible" : 0, "action" : { "target" : "https://button" } }, { "type" : "text", "content" : "满减券", "position_number" : 14 }, { "type" : "text", "content" : "¥280", "position_number" : 15 }, { "type" : "text", "content" : "满2000可用", "position_number" : 16 }, { "type" : "text", "content" : "测试-满减优惠", "position_number" : 17 }, { "type" : "text", "content" : "2022-01-01~2022-12-31", "position_number" : 18 }, { "type" : "button", "content" : "去领取", "action_type" : "OPEN_URL", "position_number" : 19, "visible" : 0, "action" : { "target" : "https://button" } }, { "type" : "text", "content" : "满减券", "position_number" : 20 }, { "type" : "text", "content" : "¥380", "position_number" : 21 }, { "type" : "text", "content" : "满2000可用", "position_number" : 22 }, { "type" : "text", "content" : "测试-满减优惠", "position_number" : 23 }, { "type" : "text", "content" : "2022-01-01~2022-12-31", "position_number" : 24 }, { "type" : "button", "content" : "去领取", "action_type" : "OPEN_URL", "position_number" : 25, "visible" : 0, "action" : { "target" : "https://button" } }, { "type" : "button", "content" : "立即领取", "action_type" : "OPEN_URL", "position_number" : 26, "visible" : 1, "action" : { "target" : "https://www.example.com" } } ] } ], "params" : [ ], "factorys" : [ { "factory_type" : "HUAWEI", "state" : 1 } ] } 创建多卡券(CardVouchers)(多卡券多按钮)。模板为试商用,分别创建text和button模板组件,支持多组卡券,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "card_id" : "CardVouchers", "tpl_name" : "测试-多卡券多按钮", "use_id" : 2, "pages" : [ { "page_order" : 1, "contents" : [ { "type" : "text", "content" : "测试-满减优惠", "position_number" : 1 }, { "type" : "text", "content" : "卡券类型", "position_number" : 2 }, { "type" : "text", "content" : "优惠活动", "position_number" : 3 }, { "type" : "text", "content" : "使用门槛", "position_number" : 4 }, { "type" : "text", "content" : "测试-自定义卡券。拒收请回复R", "position_number" : 5 }, { "type" : "text", "content" : "领取30天后有效", "position_number" : 6 }, { "type" : "button", "content" : "去领取", "action_type" : "OPEN_URL", "position_number" : 7, "visible" : 1, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "折扣券", "position_number" : 8 }, { "type" : "text", "content" : "8.6折", "position_number" : 9 }, { "type" : "text", "content" : "满1000可用", "position_number" : 10 }, { "type" : "text", "content" : "测试-折扣优惠", "position_number" : 11 }, { "type" : "text", "content" : "2022-01-01~2022-12-31", "position_number" : 12 }, { "type" : "button", "content" : "去领取", "action_type" : "OPEN_URL", "position_number" : 13, "visible" : 1, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "满减券", "position_number" : 14 }, { "type" : "text", "content" : "¥280", "position_number" : 15 }, { "type" : "text", "content" : "满2000可用", "position_number" : 16 }, { "type" : "text", "content" : "测试-满减优惠", "position_number" : 17 }, { "type" : "text", "content" : "2022-01-01~2022-12-31", "position_number" : 18 }, { "type" : "button", "content" : "去领取", "action_type" : "OPEN_URL", "position_number" : 19, "visible" : 1, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "满减券", "position_number" : 20 }, { "type" : "text", "content" : "¥380", "position_number" : 21 }, { "type" : "text", "content" : "满2000可用", "position_number" : 22 }, { "type" : "text", "content" : "测试-满减优惠", "position_number" : 23 }, { "type" : "text", "content" : "2022-01-01~2022-12-31", "position_number" : 24 }, { "type" : "button", "content" : "去领取", "action_type" : "OPEN_URL", "position_number" : 25, "visible" : 1, "action" : { "target" : "https://www.example.com" } }, { "type" : "button", "content" : "立即领取", "action_type" : "OPEN_URL", "position_number" : 26, "visible" : 0, "action" : { "target" : "https://www.example.com" } } ] } ], "params" : [ ], "factorys" : [ { "factory_type" : "HUAWEI", "state" : 1 } ] } 创建图文类模板(StandardImageAndText)(VIVO厂商)。模板为试商用,分别设置image、title、text和button模板组件,支持厂商为"VIVO",不支持厂商为"HUAWEI, XIAOMI, OPPO, MEIZU",短信签名为"koomessage"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "pages" : [ { "contents" : [ { "type" : "image", "src" : "756036238808491111", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "text", "content" : "测试-活动通知", "visible" : 1, "is_text_title" : "true", "position_number" : 2 }, { "type" : "text", "content" : "你相信光吗,你在哪里,光就在哪里。拒收请回复R", "visible" : 1, "is_text_title" : "false", "position_number" : 3 }, { "type" : "button", "content" : "点击进入", "visible" : 1, "action" : { "target" : "https://www.baidu.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 4 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 0, "factory_type" : "HUAWEI" }, { "state" : 0, "factory_type" : "XIAOMI" }, { "state" : 0, "factory_type" : "OPPO" }, { "state" : 0, "factory_type" : "MEIZU" }, { "state" : 1, "factory_type" : "VIVO" } ], "card_id" : "StandardImageAndText", "tpl_name" : "测试-VIVO", "scene" : "", "use_id" : 2, "sms_example" : "你好尊贵的X先生,点击查看优惠k2mg.cn/adc123", "sms_signs" : [ "koomessage" ], "sms_template" : "你好尊贵的[文本0-20]点击进入[字母0-20]" } 创建电商类多商品模板(Ecommerce)(显示货币符号)。模板为试商用,分别设置text、image、title和button模板组件,组件可设置为隐藏,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "Ecommerce", "tpl_name" : "测试-电商多商品模板", "pages" : [ { "contents" : [ { "type" : "text", "content" : "测试标题", "visible" : 1, "position_number" : 1 }, { "type" : "text", "content" : "内容描述。拒收请回复R", "visible" : 1, "position_number" : 2 }, { "type" : "button", "content" : "图片按钮点击跳转", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 3 }, { "type" : "image", "src" : "722372808671272960", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 4 }, { "type" : "text", "content" : "隐藏价格背景", "visible" : 0, "position_number" : 5 }, { "type" : "text", "content" : "隐藏价格99", "visible" : 0, "position_number" : 6 }, { "type" : "text", "content" : "商品1标题", "position_number" : 7 }, { "type" : "text", "content" : "商品1描述", "visible" : 1, "position_number" : 8 }, { "type" : "text", "content" : "Label2", "visible" : 0, "position_number" : 9 }, { "type" : "text", "content" : "货币单位", "visible" : 1, "position_number" : 10 }, { "type" : "text", "content" : 100.0, "visible" : 1, "position_number" : 11 }, { "type" : "text", "content" : "按钮1", "visible" : 1, "position_number" : 12 }, { "type" : "button", "content" : "按钮1", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 13 }, { "type" : "image", "src" : "722372826597732352", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 14 }, { "type" : "text", "content" : "隐藏优惠价格", "visible" : 0, "position_number" : 15 }, { "type" : "text", "content" : "隐藏优惠价格99", "visible" : 0, "position_number" : 16 }, { "type" : "text", "content" : "商品2标题", "visible" : 1, "position_number" : 17 }, { "type" : "text", "content" : "商品2描述", "position_number" : 18 }, { "type" : "text", "content" : "Edit Text", "visible" : 0, "position_number" : 19 }, { "type" : "text", "content" : "货币单位", "visible" : 1, "position_number" : 20 }, { "type" : "text", "content" : 100.0, "visible" : 1, "position_number" : 21 }, { "type" : "text", "content" : "按钮2", "visible" : 1, "position_number" : 22 }, { "type" : "button", "content" : "按钮2", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 23 }, { "type" : "image", "src" : "722372826597732352", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 24 }, { "type" : "text", "content" : "隐藏优惠价格", "visible" : 0, "position_number" : 25 }, { "type" : "text", "content" : "隐藏优惠价格999", "position_number" : 26 }, { "type" : "text", "content" : "商品3标题", "is_text_title" : false, "position_number" : 27 }, { "type" : "text", "content" : "商品3描述", "visible" : 1, "position_number" : 28 }, { "type" : "text", "src" : "Edit text", "visible" : 0, "position_number" : 29 }, { "type" : "text", "content" : "货币单位", "visible" : 1, "position_number" : 30 }, { "type" : "text", "content" : 100.0, "visible" : 1, "position_number" : 31 }, { "type" : "text", "content" : "按钮3", "visible" : 1, "position_number" : 32 }, { "type" : "button", "content" : "按钮3", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 33 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ] } 创建机票类模板(Trip1)。模板为试商用,分别设置image、text、和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "pages" : [ { "contents" : [ { "type" : "image", "src" : "729178704084770816", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "text", "content" : "行程通知-测试机票类", "position_number" : 2 }, { "type" : "text", "content" : "订单号:12095888888。拒收请回复R", "is_text_title" : "false", "position_number" : 3 }, { "type" : "text", "content" : "深圳", "position_number" : 4 }, { "type" : "text", "content" : "武汉", "position_number" : 5 }, { "type" : "text", "content" : "17:40", "position_number" : 6 }, { "type" : "text", "content" : "19:35", "position_number" : 7 }, { "type" : "text", "content" : "2022/04/20", "position_number" : 8 }, { "type" : "text", "content" : "MU2558", "visible" : 1, "position_number" : 9 }, { "type" : "text", "content" : "2022/04/20", "visible" : 1, "position_number" : 10 }, { "type" : "text", "content" : "乘车人", "visible" : 1, "position_number" : 11 }, { "type" : "text", "content" : "舱位", "visible" : 1, "position_number" : 12 }, { "type" : "text", "content" : "登机口", "position_number" : 13 }, { "type" : "text", "content" : "徐乐", "position_number" : 14 }, { "type" : "text", "content" : "商务舱", "position_number" : 15 }, { "type" : "text", "content" : "A15", "position_number" : 16 }, { "type" : "button", "content" : "联系客服", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 17 }, { "type" : "button", "content" : "订单详情", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 18 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ], "card_id" : "Trip1", "tpl_name" : "测试-机票类", "scene" : "data", "use_id" : 2, "sms_example" : "" } 创建火车票类模板(Trip2)。模板为试商用,分别设置image、text和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "pages" : [ { "contents" : [ { "type" : "image", "src" : "729178704084770816", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "text", "content" : "火车票出票成功-测试", "position_number" : 2 }, { "type" : "text", "content" : "订单号:SZ88888888。拒收请回复R", "is_text_title" : "false", "position_number" : 3 }, { "type" : "text", "content" : "深圳", "position_number" : 4 }, { "type" : "text", "content" : "北京", "position_number" : 5 }, { "type" : "text", "content" : "18:30", "position_number" : 6 }, { "type" : "text", "content" : "02:55", "position_number" : 7 }, { "type" : "text", "content" : "2022/04/11", "position_number" : 8 }, { "type" : "text", "content" : "G888", "visible" : 1, "position_number" : 9 }, { "type" : "text", "content" : "2022/04/12", "visible" : 1, "position_number" : 10 }, { "type" : "text", "content" : "乘车人", "visible" : 1, "position_number" : 11 }, { "type" : "text", "content" : "成人票", "visible" : 1, "position_number" : 12 }, { "type" : "text", "content" : "二等座", "position_number" : 13 }, { "type" : "text", "content" : "许可", "position_number" : 14 }, { "type" : "text", "content" : 568.88, "position_number" : 15 }, { "type" : "text", "content" : "12车12F", "position_number" : 16 }, { "type" : "button", "content" : "咨询客服", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 17 }, { "type" : "button", "content" : "查看改签", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 18 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ], "card_id" : "Trip2", "tpl_name" : "测试-火车票类", "scene" : "", "use_id" : 2, "sms_example" : "" } 创建汽车票类模板(Trip3)。模板为试商用,分别设置image、text和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "pages" : [ { "contents" : [ { "type" : "image", "src" : "729178704084770816", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "text", "content" : "汽车票出票-测试", "position_number" : 2 }, { "type" : "text", "content" : "订单号:S88888866。拒收请回复R", "is_text_title" : "false", "position_number" : 3 }, { "type" : "text", "content" : "深圳", "position_number" : 4 }, { "type" : "text", "content" : "汕头", "position_number" : 5 }, { "type" : "text", "content" : "9:00", "position_number" : 6 }, { "type" : "text", "content" : "14:00", "position_number" : 7 }, { "type" : "text", "content" : "2022/04/11", "position_number" : 8 }, { "type" : "text", "content" : "粤X-999999", "visible" : 1, "position_number" : 9 }, { "type" : "text", "content" : "2022/04/11", "visible" : 1, "position_number" : 10 }, { "type" : "text", "content" : "乘车人", "visible" : 1, "position_number" : 11 }, { "type" : "text", "content" : "票价", "visible" : 1, "position_number" : 12 }, { "type" : "text", "content" : "座位", "position_number" : 13 }, { "type" : "text", "content" : "许可", "position_number" : 14 }, { "type" : "text", "content" : 180, "position_number" : 15 }, { "type" : "text", "content" : "5F", "position_number" : 16 }, { "type" : "button", "content" : "联系客服", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 17 }, { "type" : "button", "content" : "退票", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 18 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ], "card_id" : "Trip3", "tpl_name" : "测试-汽车票类", "scene" : "", "use_id" : 2, "sms_example" : "" } 创建增强机票类模板(PlaneTrip)。模板为试商用,分别设置title、text、image和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "pages" : [ { "contents" : [ { "type" : "text", "content" : "测试机票出票成功", "is_text_title" : "true", "position_number" : 1 }, { "type" : "text", "content" : "06:50", "position_number" : 2 }, { "type" : "text", "content" : "12:00", "position_number" : 3 }, { "type" : "text", "content" : "12月30日", "position_number" : 4 }, { "type" : "text", "content" : "经停杭州", "position_number" : 5 }, { "type" : "text", "content" : "12月30日", "position_number" : 6 }, { "type" : "text", "content" : "深圳宝安国际机场T3", "position_number" : 7 }, { "type" : "text", "content" : "乌鲁木齐地窝堡机场T2", "position_number" : 8 }, { "type" : "image", "content" : "选座升舱", "src" : "747402037796315136", "cover" : null, "src_type" : 1, "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 9 }, { "type" : "image", "content" : "托运购买", "src" : "747402037796315136", "src_type" : 1, "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 10 }, { "type" : "image", "content" : "客服电话", "src" : "747402037796315136", "visible" : 1, "content_child" : null, "src_type" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 11 }, { "type" : "image", "content" : "航班改期", "src" : "747402037796315136", "visible" : 1, "content_child" : null, "src_type" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 12 }, { "type" : "text", "content" : "航班号", "content_child" : "海航HU7851", "position_number" : 13 }, { "type" : "text", "content" : "登机口", "content_child" : "A3", "position_number" : 14 }, { "type" : "text", "content" : "座位号", "content_child" : "13A,13B,13C", "position_number" : 15 }, { "type" : "text", "content" : "舱位类型", "content_child" : "经济舱", "position_number" : 16 }, { "type" : "text", "content" : "经停时长", "content_child" : "2时5分", "position_number" : 17 }, { "type" : "text", "content" : "总金额", "content_child" : 3320.0, "position_number" : 18 }, { "type" : "text", "content" : "左边标题", "visible" : 1, "content_child" : "左边内容", "position_number" : 19 }, { "type" : "text", "content" : "中间标题", "content_child" : "中间内容", "visible" : 1, "position_number" : 20 }, { "type" : "text", "content" : "右边标题", "visible" : 1, "content_child" : "右边内容", "position_number" : 21 }, { "type" : "text", "content" : "乘机人", "content_child" : "张毅,李小明,王赫赫", "position_number" : 22 }, { "type" : "text", "content" : "票号", "content_child" : "784-6736858234782", "position_number" : 23 }, { "type" : "text", "content" : "附属标题", "content_child" : "附属内容", "position_number" : 24 }, { "type" : "text", "content" : "请您至少提前2小时至机场办理乘机手续,以免误机!", "position_number" : 25 }, { "type" : "button", "content" : "立即打车", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 26 }, { "type" : "button", "content" : "点击进入", "visible" : 1, "action" : { "target" : "https://www.baidu.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 27 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ], "card_id" : "PlaneTrip", "tpl_name" : "测试-增强机票类", "scene" : "", "use_id" : 2, "sms_example" : "" } 创建个性化红包类模板(RedPacketPersonal)(样式2)。模板为试商用,设置button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "RedPacketPersonal", "tpl_name" : "测试:个性化红包模板", "sub_type" : 2, "pages" : [ { "contents" : [ { "type" : "button", "content" : "抢", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ] } 创建海报类模板(SimplePoster)。模板为试商用,设置image模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "SimplePoster", "tpl_name" : "测试:海报模板", "pages" : [ { "contents" : [ { "type" : "image", "src" : "747402037796315136", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_BROWSER", "src_type" : 1, "position_number" : 1 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ], "scene" : "", "sms_example" : "" } 创建超文本普通类模板(NativePureText)。模板为试商用,分别设置text和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "NativePureText", "tpl_name" : "测试:超文本普通", "pages" : [ { "contents" : [ { "type" : "text", "content" : "文本内容", "visible" : 1, "is_text_title" : false, "position_number" : 1 }, { "type" : "button", "content" : "按钮1", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 2 }, { "type" : "button", "content" : "按钮2", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 3 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ], "scene" : "", "sms_example" : "" } 创建超文本增强类模板(NativeImageAndText)。模板为试商用,分别设置title、image、text和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "NativeImageAndText", "tpl_name" : "测试:超文本增强", "pages" : [ { "contents" : [ { "type" : "text", "content" : "测试标题", "visible" : 1, "is_text_title" : true, "position_number" : 1 }, { "type" : "image", "src" : "747402037796315136", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_BROWSER", "src_type" : 1, "position_number" : 2 }, { "type" : "text", "content" : "内容", "visible" : 1, "is_text_title" : false, "position_number" : 3 }, { "type" : "button", "content" : "按钮1", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 4 }, { "type" : "button", "content" : "按钮2", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 5 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ], "scene" : "", "sms_example" : "" } 创建短剧视频模板(ShortVideo)。模板为试商用,分别设置video、title、text和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "ShortVideo", "tpl_name" : "测试:短视频模板", "pages" : [ { "contents" : [ { "type" : "video", "src" : "747402037796315135", "cover" : "747402037796315135", "visible" : 1, "src_type" : 1, "position_number" : 1, "ratio" : "threeToFour", "action_type" : "OPEN_URL", "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "测试标题", "content_child" : "短视频模板", "is_text_title" : true, "visible" : 1, "position_number" : 2 }, { "type" : "text", "content" : "内容。拒收请回复R", "content_child" : "短视频模板", "visible" : 1, "is_text_title" : false, "position_number" : 3 }, { "type" : "button", "content" : "按钮1", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 4 }, { "type" : "button", "content" : "按钮2", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 5 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ], "scene" : "", "sms_example" : "" } 创建电商类模板(ECImageAndText)(设置按钮颜色)。模板为试商用,分别设置image、title、text和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "ECImageAndText", "tpl_name" : "测试:电商类模板", "sub_type" : 1, "pages" : [ { "contents" : [ { "type" : "image", "src" : "709206231474000001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 1 }, { "type" : "image", "src" : "709258670432600001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 2 }, { "type" : "image", "src" : "709206119700000001", "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 3 }, { "type" : "text", "content" : "160.00", "is_text_title" : "true", "position_number" : 4, "currency_display" : 1 }, { "type" : "text", "content" : "满减", "is_text_title" : "true", "position_number" : 5 }, { "type" : "text", "content" : "测试猫车模拟驾驶", "is_text_title" : "true", "position_number" : 6 }, { "type" : "text", "content" : "您的体力已耗尽!拒收请回复R", "is_text_title" : "false", "position_number" : 7 }, { "type" : "button", "content" : "添加购物车", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 8 }, { "type" : "button", "content" : "立即购买", "action" : { "target" : "https://www.example.com" }, "action_type" : "OPEN_BROWSER", "position_number" : 9 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ], "scene" : "", "sms_example" : "" } 创建短剧图片模板(ShortVideoImage)。模板为试商用,分别设置image、title、text和button模板组件,支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "use_id" : 2, "card_id" : "ShortVideoImage", "tpl_name" : "短剧图片测试1:1有按钮-一体化", "scene" : "智能信息模版", "sub_type" : 2, "sms_example" : "你有一条新消息请查收", "pages" : [ { "contents" : [ { "type" : "image", "src" : "HWR100044608", "cover" : "747402037796315135", "visible" : 1, "src_type" : 1, "position_number" : 1, "ratio" : "oneToOne", "action_type" : "OPEN_BROWSER", "currency_display" : 1, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "短剧图片测试1:1", "is_text_title" : true, "visible" : 1, "position_number" : 2, "currency_display" : 1 }, { "type" : "text", "content" : "编辑文本描述,最多显示69个字。编辑文本描述,最多显示69个字。拒收请回复R", "visible" : 1, "is_text_title" : false, "position_number" : 3, "currency_display" : 1 }, { "type" : "button", "content" : "链接", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_URL", "position_number" : 4, "currency_display" : 1 }, { "type" : "button", "content" : "小程序链接", "action" : { "target" : "https://www.example.com" }, "visible" : 1, "action_type" : "OPEN_BROWSER", "position_number" : 5, "currency_display" : 1 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ] } 创建电商领券类竖版模板(EcommerceCouponVertical)。模板为试商用,根据position_number从1到7分别创建logo图、标题、副标题、券金额、券标题、券副标题、券按钮组件;position_number从8到13为商品1、从14到19为商品2、从20到25为商品3。支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "card_id" : "EcommerceCouponVertical", "tpl_name" : "测试电商领券", "use_id" : 2, "sub_type" : 1, "pages" : [ { "page_order" : 1, "contents" : [ { "type" : "image", "src_type" : 1, "visible" : 1, "src" : "HWR100003769", "action_type" : "OPEN_URL", "position_number" : 1, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "测试新客专享福利", "is_text_title" : "true", "visible" : 1, "position_number" : 2 }, { "type" : "text", "content" : "店铺新人超值礼包等你拿", "is_text_title" : "false", "visible" : 1, "position_number" : 3 }, { "type" : "text", "content" : "100", "is_text_title" : "false", "visible" : 1, "position_number" : 4 }, { "type" : "text", "content" : "测试-最高减50元", "is_text_title" : "false", "visible" : 1, "position_number" : 5 }, { "type" : "text", "content" : "同类商品仅限享受一次优惠活动。拒收请回复R", "is_text_title" : "false", "visible" : 1, "position_number" : 6 }, { "type" : "button", "content" : "领", "visible" : 1, "button_type" : "static", "action_type" : "OPEN_URL", "position_number" : 7, "action" : { "target" : "https://www.example.com" } }, { "type" : "image", "src_type" : 1, "visible" : 1, "src" : "HWR100003915", "action_type" : "OPEN_URL", "position_number" : 8, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "测试***唇膏新色1966红色持续保湿滋润", "is_text_title" : "false", "visible" : 1, "position_number" : 9 }, { "type" : "text", "content" : "正品保证", "is_text_title" : "false", "visible" : 1, "position_number" : 10 }, { "type" : "text", "content" : "全国包邮", "is_text_title" : "false", "visible" : 1, "position_number" : 11 }, { "type" : "text", "content" : "300", "is_text_title" : "false", "visible" : 1, "position_number" : 12 }, { "type" : "button", "content" : "前往购买", "action_type" : "OPEN_URL", "visible" : 1, "position_number" : 13, "action" : { "target" : "https://www.example.com" } }, { "type" : "image", "src_type" : 1, "visible" : 1, "src" : "HWR100003897", "action_type" : "OPEN_URL", "position_number" : 14, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "测试***唇膏新品,小辣椒色", "is_text_title" : "false", "visible" : 1, "position_number" : 15 }, { "type" : "text", "content" : "超值好物", "is_text_title" : "false", "visible" : 1, "position_number" : 16 }, { "type" : "text", "content" : "内部包邮", "is_text_title" : "false", "visible" : 1, "position_number" : 17 }, { "type" : "text", "content" : "320", "is_text_title" : "false", "visible" : 1, "position_number" : 18 }, { "type" : "button", "content" : "前往购买", "action_type" : "OPEN_URL", "visible" : 1, "position_number" : 19, "action" : { "target" : "https://www.example.com" } }, { "type" : "image", "src_type" : 1, "src" : "HWR100003915", "visible" : 1, "action_type" : "OPEN_URL", "position_number" : 20, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "测试***唇膏持久显色,不拔干,外观优雅,时尚美丽", "is_text_title" : "false", "visible" : 1, "position_number" : 21 }, { "type" : "text", "content" : "优雅时尚", "is_text_title" : "false", "visible" : 1, "position_number" : 22 }, { "type" : "text", "content" : "全国包邮", "is_text_title" : "false", "visible" : 1, "position_number" : 23 }, { "type" : "text", "content" : "360", "is_text_title" : "false", "visible" : 1, "position_number" : 24 }, { "type" : "button", "content" : "前往购买", "action_type" : "OPEN_URL", "visible" : 1, "position_number" : 25, "action" : { "target" : "https://www.example.com" } } ] } ], "params" : [ ], "factorys" : [ { "factory_type" : "HUAWEI", "state" : 1 } ] } 创建电商领券类横版模板(EcommerceCouponHorizontal)。模板为试商用,根据position_number由1到7分别创建logo图、标题、副标题、券金额、券标题、券副标题、券按钮组件;position_number从8到11为商品1、从12到15为商品2、从16到19为商品3。支持厂商为"HUAWEI"。 https://koomessage.myhuaweicloud.cn/v1/aim/templates { "card_id" : "EcommerceCouponHorizontal", "tpl_name" : "测试-电商领券横版", "use_id" : 2, "sub_type" : 1, "pages" : [ { "contents" : [ { "type" : "image", "src" : "HWR100058888", "visible" : 1, "action" : { "target" : "https://www.example.com" }, "src_type" : 1, "action_type" : "OPEN_URL", "position_number" : 1 }, { "type" : "text", "content" : "测试新客专享福利", "is_text_title" : "true", "visible" : 1, "position_number" : 2 }, { "type" : "text", "content" : "店铺新人超值礼包等你拿", "is_text_title" : "false", "visible" : 1, "position_number" : 3 }, { "type" : "text", "content" : "100", "is_text_title" : "false", "visible" : 1, "position_number" : 4 }, { "type" : "text", "content" : "测试-最高减50元", "is_text_title" : "false", "visible" : 1, "position_number" : 5 }, { "type" : "text", "content" : "同类商品仅限享受一次优惠活动。拒收请回复R", "is_text_title" : "false", "visible" : 1, "position_number" : 6 }, { "type" : "button", "content" : "领", "visible" : 1, "button_type" : "static", "action_type" : "OPEN_URL", "position_number" : 7, "action" : { "target" : "https://www.example.com" } }, { "type" : "image", "src_type" : 1, "visible" : 1, "src" : "HWR100058888", "action_type" : "OPEN_URL", "position_number" : 8, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "299", "is_text_title" : "false", "visible" : 1, "position_number" : 9 }, { "type" : "text", "content" : "***唇膏", "is_text_title" : "false", "visible" : 1, "position_number" : 10 }, { "type" : "text", "content" : "质地丝滑", "is_text_title" : "false", "visible" : 1, "position_number" : 11 }, { "type" : "image", "src_type" : 1, "visible" : 1, "src" : "HWR100058888", "action_type" : "OPEN_URL", "position_number" : 12, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "199", "is_text_title" : "false", "visible" : 1, "position_number" : 13 }, { "type" : "text", "content" : "***小辣椒色唇膏", "is_text_title" : "false", "visible" : 1, "position_number" : 14 }, { "type" : "text", "content" : "光泽亮丽", "is_text_title" : "false", "visible" : 1, "position_number" : 15 }, { "type" : "image", "src_type" : 1, "visible" : 1, "src" : "HWR100058888", "action_type" : "OPEN_URL", "position_number" : 16, "action" : { "target" : "https://www.example.com" } }, { "type" : "text", "content" : "329", "is_text_title" : "false", "visible" : 1, "position_number" : 17 }, { "type" : "text", "content" : "***哑光口红", "is_text_title" : "false", "visible" : 1, "position_number" : 18 }, { "type" : "text", "content" : "持久光泽", "is_text_title" : "false", "visible" : 1, "position_number" : 19 } ], "page_order" : 1 } ], "params" : [ ], "factorys" : [ { "state" : 1, "factory_type" : "HUAWEI" } ] }
  • 响应参数 状态码: 200 表8 响应Body参数 参数 参数类型 描述 status String 请求状态,固定200。 message String 状态描述。 data CreatePersonalTemplateDataResponse object 创建模板响应。 表9 CreatePersonalTemplateDataResponse 参数 参数类型 描述 tpl_id String 智能信息模板ID。 状态码: 400 表10 响应Body参数 参数 参数类型 描述 error_code String 结果状态码。 error_msg String 结果详情。 状态码: 500 表11 响应Body参数 参数 参数类型 描述 error_code String 结果状态码。 error_msg String 结果详情。
  • 请求参数 表1 请求Header参数 参数 是否必选 参数类型 描述 Content-Type 是 String 请求体参数类型,该字段必须设置为:application/json。 X-Auth-Token 是 String 用户Token。通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 表2 请求Body参数 参数 是否必选 参数类型 描述 card_id 是 String 布局类型。 MultipleImageAndText:多图文类 StandardImageAndText:图文类 PureText:长文本类 VideoImageAndText:视频图文类 Video:视频类 ECImageAndText:电商类 RedPacket:红包类 RedPacketPersonal:个性化红包类 ImageTextAndVideo:图文视频类 Notification1:一般通知类 Notification2:增强通知类 Carousel:横滑类1 CarouselTitle:横滑类2 CarouselSquareImage:图片轮播类(1:1) CarouselImageSixteenToNine:图片轮播类(16:9) CarouselVerticalImage:图片轮播类(48:65) CardVoucher:单卡券 CardVouchers:多卡券(最多支持四张卡券) Ecommerce:电商多商品类 Trip1:机票类 Trip2:火车票类 Trip3:汽车票类 PlaneTrip:增强机票类 SimplePoster:海报类 NativePureText:超文本普通类 NativeImageAndText:超文本增强类 ShortVideo:短剧视频类 ShortVideoImage:短剧图片类 EcommerceCouponVertical:电商领券类竖版 EcommerceCouponHorizontal:电商领券类横版 说明: 当送审厂商包含vivo时,各布局类型上传的图片最小像素要求如下: card_id为StandardImageAndText,宽高比为16:9时,图片的最小像素为1088px*612px。 card_id为MultipleImageAndText,宽高比为16:9时,图片的最小像素为1088px*612px。 card_id为MultipleImageAndText,宽高比为1:1时,图片的最小像素为320px*320px。 card_id为Video,宽高比为16:9时,视频封面图片的最小像素为1088px*612px。 card_id为RedPacket,宽高比为1:1时,图片的最小像素为320px*320px。 card_id为CarouselImageSixteenToNine,宽高比为16:9时,图片的最小像素为1088px*612px。 card_id为CarouselSquareImage,宽高比为1:1时,图片的最小像素为1088px*1088px。 card_id为CarouselVerticalImage,宽高比为48:65时,图片的最小像素为960px*1300px。 card_id为Notification1,宽高比为3:1时,图片的最小像素为576px*192px。 card_id为Notification2,宽高比为3:1时,图片的最小像素为576px*192px。 card_id为ECImageAndText,宽高比为1:1时,图片的最小像素为1088px*1088px。 tpl_name 是 String 智能信息模板名称。 最小长度:1 最大长度:17 scene 否 String 模板使用场景类型。 最小长度:0 最大长度:10 use_id 是 Integer 模板用途。 1:表示商用 2:表示试商用 说明: 模板用途为1,即“商用”时,所有字段中不允许有测试字样,否则影响送审。 模板用途为2,即“试商用”时,请在模板名称(tpl_name)、模板主标题中增加测试字样。 sub_type 否 Integer 版式子类型。 说明: 当card_id为RedPacket和RedPacketPersonal时,sub_type用于设置按钮样式,1表示静态按钮,2表示动态按钮。目前仅华为厂商支持动态按钮。 当card_id为ECImageAndText时,sub_type用于设置左右按钮组合颜色,默认值为1,1表示左边按钮为橙色,右边按钮为红色;2表示左边按钮为绿色,右边按钮为黄色;3表示左边按钮为绿色,右边按钮为蓝色;4表示左边按钮为紫色,右边按钮为蓝色;5表示左边按钮为黑色,右边按钮为玫粉色。仅华为厂商支持sub_type取值为2、3、4、5。 当card_id为CarouselVerticalImage时,sub_type用于设置按钮颜色,1表示蓝色(默认颜色)、2表示黑色、3表示紫色、4表示金色、5表示粉色、6表示玫粉。仅华为厂商支持sub_type取值为2、3、4、5、6。 当card_id为CardVoucher时,sub_type用于设置按钮样式,1表示静态按钮,2表示动态按钮。目前仅华为厂商支持动态按钮。 当card_id为ShortVideoImage时,sub_type用于设置是否显示播放图标,1表示不显示,2表示显示。 当card_id为EcommerceCouponVertical和EcommerceCouponHorizontal时,sub_type用于设置卡券区是否隐藏。sub_type设置为1,卡券区(position_number为4~7)的visible设置为1,且卡券区(position_number为7)的button_type设置为static或dynamic时,显示卡券区;sub_type设置为2,卡券区(position_number为4~7)的visible设置为0,且卡券区(position_number为7)的button_type设置为空值或不带该字段时,卡券区被隐藏。 sms_example 否 String 要发送的原始文本消息示例。 最小长度:0 最大长度:70 sms_signs 否 Array of strings 短信签名。最多可以传三个签名,发送短信时,只要能匹配其中一个即可。填写的短信签名为企业绑定的签名,每个签名最多20个字,支持输入中文,英文,数字,符号,单个签名内容不包括中括号。 说明: 选择厂商包含VIVO时,此参数必填。 最小长度:1 最大长度:20 数组长度:0 - 3 sms_template 否 String 短信原文模板。参数示例:尊敬的客户,截至[文本0-20],您本月国内通用流量已使用[数字0-4]GB,使用到[数字0-4]GB,整体上网速度将不高于[数字0-2]Mbps。您可点击[字母0-20]获取[文本0-20]。 说明: 正则类型仅支持文本、字母、数字三种,且长度最大为99,且中括号为英文中括号。静态短信文案加正则动态文案最大值的总字数不超过370个字符 历史遗留字段,建议不再使用 pages 是 Array of PersonalTemplatePage objects 模板协议,最大支持10页协议。 params 否 Array of PersonalTemplateParam objects 模板参数集。 factorys 否 Array of PersonalTemplateFactory objects 需要提交的厂商列表。 表3 PersonalTemplatePage 参数 是否必选 参数类型 描述 page_order 是 Integer 分页显示,指示当前展示第几页,从1开始,最大支持10页。 contents 是 Array of PersonalTemplateFactoryContent objects 该page下的协议内容。 表4 PersonalTemplateFactoryContent 参数 是否必选 参数类型 描述 type 是 String 模板资源类型。 text:表示文本 image:表示图片 video:表示视频 button:表示按钮 followPub:表示华为服务号,暂不支持 说明: 图片轮播类模板最多可以放5张图片,即card_id为CarouselSquareImage、CarouselImageSixteenToNine、CarouselVerticalImage时,type为image的资源最多有5个。 最小长度:1 最大长度:18 content 否 String 资源类型为Text或Button时,为必填。文本长度限制请参考智能信息模板标准版式要求。 说明: 智能信息模板标准版式要求可登录KooMessage控制台,在创建智能信息模板中查看。 最小长度:0 最大长度:1000 content_child 否 String 子内容。非必填,文本长度限制请参考智能信息模板标准版式要求。 说明: 智能信息模板标准版式要求可登录KooMessage控制台,在创建智能信息模板中查看。 src_type 否 Integer src类型。资源类型为Image或Video时,该项为必填项。 1:指资源ID 2:指资源地址 说明: src_type为2,即资源地址时,src或cover内容必须是存储在客户侧服务器上的资源地址。 最小值:1 最大值:10 src 否 String 资源来源,资源类型为Image或Video时,为必填。 说明: 如上src_type为1,即资源ID时,参数填入上传模板素材接口中返回的aim_resource_id,如:691996319597764608 如上src_type为2,即资源地址时,参数填写资源完整的URL,最大长度不超过1000个字符 cover 否 String 视频封面。 说明: 资源类型为Video时,为必填,通过设置视频模板封面图接口设置视频封面。 如上src_type为1,即资源ID时,参数填入上传模板素材接口中返回的aim_resource_id,如:691996319597764608 如上src_type为2,即资源地址时,参数填写资源完整的URL,最大长度不超过1000个字符 最小长度:0 最大长度:1000 is_text_title 否 String 是否为文本标题。 true:是 false:不是 说明: 不填默认为false。 最小长度:0 最大长度:10 action_type 否 String 功能类型。 OPEN_URL:表示跳转H5 OPEN_QUICK:表示跳转快应用 OPEN_APP:表示跳转APP DIAL_PHONE:表示拉起拨号盘 OPEN_SMS:表示新建短信息 OPEN_EMAIL:表示打开邮箱 OPEN_SCHEDULE:表示新建日程 OPEN_MAP:表示位置定位 OPEN_BROWSER:表示打开浏览器 OPEN_POPUP:表示弹窗 COPY_PARAMETER:表示复制 VIEW_PIC:表示打开大图 说明: type为Image和Button时为必填项,必须绑定事件 type为其他类型时则不必填 OPPO厂商点击事件类型只支持打开浏览器、打开快应用、打开APP、跳转H5 VIVO厂商点击事件类型不支持打开邮箱、打开地图 MEIZU厂商点击事件类型不支持打开大图 横滑类1、横滑类2版式的图片不支持绑定事件,默认与按钮事件一致 三星厂商点击事件类型不支持新建日程、打开大图 position_number 是 Integer 卡片组件的位置序号。 说明: 资源在卡片上相对的位置序号,按照优先从左到右,再从上到下的编排原则,统一编号。 visible 否 Integer 组件是否可见。 0:隐藏(某些组件可设置隐藏) 1:可见 说明: 目前仅针对电商多商品(Ecommerce)、多卡券(CardVouchers)、增强机票类(PlaneTrip)这三种版式起效。 currency_display 否 Integer 是否显示货币符号。 0:隐藏 1:可见 说明: 当模板为电商类时是否显示¥符号,默认可见。 oppo_background 否 String OPPO红包背景。 当模板为红包类,即card_id为RedPacket时用于指定OPPO厂商红包背景图,具体使用可参考创建红包类模板请求示例。OPPO红包背景图要求宽高比为3:4,建议尺寸为342px*456px。 说明: 当src_type为1时,即资源ID时,参数填入上传模板素材接口中返回的aim_resource_id,如:691996319597764608 当src_type为2时,即资源地址时,参数填写资源完整的URL,最大长度不超过1000个字符 最小长度:0 最大长度:1000 vivo_background 否 String VIVO红包背景。 说明: 当src_type为1时,即资源ID时,参数填入上传模板素材接口中返回的aim_resource_id,如:691996319597764608 当src_type为2时,即资源地址时,参数填写资源完整的URL,最大长度不超过1000个字符 最小长度:0 最大长度:1000 ratio 否 String 表示短视频模板视频和封面的宽高比。即card_id为ShortVideo时,此项有值。 threeToFour:宽高比为3:4 oneToOne:宽高比为1:1 action 否 PersonalTemplateFactoryContentAction object 个人模板事件对象。 button_type 否 String 当模板为电商领券类(竖版和横版),即card_id为EcommerceCouponVertical和EcommerceCouponHorizontal时用于指定按钮类型,具体使用可参考创建电商领券类(竖版和横版)模板请求示例。 static:静态按钮 dynamic:动态按钮 表5 PersonalTemplateFactoryContentAction 参数 是否必选 参数类型 描述 target 是 String 此字段根据action_type对应不同的含义,具体对应如下。 action_type=OPEN_URL:表示H5访问地址。必须为HTTPS,支持含动态参数。字符长度为1-1000。示例:https://XXXXX/${param1} action_type=OPEN_QUICK:表示快应用deeplink地址。支持含动态参数,字符长度为1-1000。示例:hap://app/xxx/${param1} action_type=OPEN_APP:表示APP的deeplink地址。支持含动态参数,字符长度为1-1000。示例:weixin:// action_type=DIAL_PHONE:表示电话号码。不能超过20个字符。示例:18600000000 action_type=OPEN_SMS:表示电话号码。不能超过20个字符。示例:18600000000 action_type=OPEN_EMAIL:表示邮箱地址。不能超过100个字符。示例:1046520406@qq.com action_type=OPEN_SCHEDULE:表示日程标题。不能超过100个字符。示例:日常需求评审 action_type=OPEN_MAP:表示位置名。不能超过100个字符。示例:龙泰利科技大厦 action_type=OPEN_BROWSER:表示网址。支持HTTPS或HTTP,支持含动态参数,不能超过1000个字符。示例:https://XXXXX/${param1} action_type=OPEN_POPUP:表示弹窗标题。不能超过30个字符。参数示例:xxx商品 action_type=COPY_PARAMETER:表示复制的内容。支持含动态参数,不能超过20个字符。复制验证码示例:83721 action_type=VIEW_PIC:表示要打开的大图ID。配置在打开大图的资源地址与模板上的图片资源地址一致。如果模板资源类型是ID,则传ID,如果是资源地址,则使用资源地址。最大长度不能超过1000个字符。例如:当src_type为1时,传入ID:691996319597764608。当src_type为2时,使用资源地址:https://www.xxxx.cn/src/image/head.jpg content 否 String 弹窗内容。 说明: action_type=OPEN_POPUP为必填。不能超过100个字符。示例:是否喜欢该商品。 最小长度:0 最大长度:100 package_name 否 String 包名。 说明: action_type=OPEN_APP为必填。不能超过50个字符。示例:com.xxxx.service.koomsg。 最小长度:0 最大长度:50 floor_url 否 String 兜底URL。支持快应用deeplink或H5的HTTPS网址,不能超过1000个字。 说明: action_type=OPEN_APP为选填,其他类型不填 兜底类型为0时,可不填 当兜底类型为2并且提交厂商列表中包含OPPO厂商时为必填 最小长度:0 最大长度:1000 floor_type 否 Integer 兜底类型。如果传入的厂商不支持该兜底类型,接口会返回错误。如果不传入厂商,则不对兜底类型进行校。 0:打开应用市场 1:打开H5页面(通过收件箱内置浏览器打开) 2:打开浏览器 3:打开快应用 说明: action_type=OPEN_APP为选填,其他类型不填;action_type=OPEN_APP时此参数不填则默认打开应用市场。打开链接为http格式时必须选择打开浏览器;打开链接为https格式且内容只是一个普通页面时,可以使用打开H5页面,当链接中有下载指引或打开小程序由于部分内置浏览器功能不全可能导致打开异常,建议使用打开浏览器,请按需选择兜底类型。 华为:支持以上4种兜底 魅族:支持以上4种兜底 小米:不支持打开H5页面兜底 OPPO:不支持打开H5页面和打开快应用兜底 VIVO:不支持打开H5页面和打开快应用兜底 三星:不支持打开应用市场和打开浏览器。当创建的模板仅包含三星厂商时,兜底URL不支持打开浏览器和打开应用市场;当创建的模板包含三星和其它厂商时,以其它厂商的限制为准,三星的兜底链接将不生效 最小值:0 最大值:3 subject 否 String 邮件标题。 说明: action_type=OPEN_EMAIL为必填。不能超过100个字符。示例:618活动促销。 body 否 String 邮件正文/短信正文。 说明: action_type=OPEN_SMS或OPEN_EMAIL为必填。不能超过100个字符。 短信正文示例1:今天回家吃饭吗; 邮件正文示例2:您有一张优惠券领取。 description 否 String 日程内容描述。 说明: action_type=OPEN_SCHEDULE为必填。不能超过100个字符。示例:评审这个月版本需求。 最小长度:0 最大长度:100 begin_time 否 String 日程开始时间。格式为:yyyy-MM-dd HH:mm:ss。 说明: 当action_type=OPEN_SCHEDULE时为必填。 最小长度:0 最大长度:100 end_time 否 String 日程结束时间。格式为:yyyy-MM-dd HH:mm:ss。 说明: 当action_type=OPEN_SCHEDULE时为必填。 最小长度:0 最大长度:100 address 否 String 地址的详细说明。 说明: action_type=OPEN_MAP为必填。不能超过100个字符。示例:高新中四道龙泰利科技大厦。 最小长度:0 最大长度:100 longitude 否 String 地图经度。 说明: action_type=OPEN_MAP为必填。不能超过20个字符。示例:113.941618。 最小长度:0 最大长度:20 latitude 否 String 地图纬度。 说明: action_type=OPEN_MAP为必填。不能超过20个字符。示例:22.548804。 最小长度:0 最大长度:20 text_button 否 String 按钮展示文本。 说明: action_type=OPEN_POPUP为必填。不能超过12个字符。示例:确定。 最小长度:0 最大长度:12 mode 否 Integer 弹窗模态。 0:模态(默认) 1:非模态(暂不支持) 说明: action_type=OPEN_POPUP为必填。 表6 PersonalTemplateParam 参数 是否必选 参数类型 描述 type 是 Integer 动态参数类型。1:表示文本类型。 最小值:0 最大值:100 name 是 String 动态参数名称。示例:${param1}。 最小长度:1 最大长度:20 example 是 String 参数示例,动态参数对应的示例,不能大于100个字符。 最小长度:1 最大长度:100 表7 PersonalTemplateFactory 参数 是否必选 参数类型 描述 factory_type 是 String 厂商类型。 HUAWEI:华为 XIAOMI:小米 OPPO:OPPO VIVO:VIVO MEIZU:魅族 SAMSUNG:三星 各厂商支持的布局类型,布局类型与card_id字段相对应。分别如下: HUAWEI:多图文类(MultipleImageAndText)、图文类(StandardImageAndText)、长文本类(PureText)、横滑类1(Carousel)、横滑类2(CarouselTitle)、视频图文类(VideoImageAndText)、视频类(Video)、电商类(ECImageAndText)、红包类(RedPacket)、个性化红包类(RedPacketPersonal)、增强通知类(Notification2)、图片轮播类1:1(CarouselSquareImage)、图片轮播类16:9(CarouselImageSixteenToNine)、图片轮播类48:65(CarouselVerticalImage)、图文视频类(ImageTextAndVideo)、一般通知类(Notification1)、单卡券(CardVoucher)、多卡券(CardVouchers)、电商多商品类(Ecommerce)、电商领券类竖版(EcommerceCouponVertical)、电商领券类横版(EcommerceCouponHorizontal)、机票类(Trip1)、火车票类(Trip2)、汽车票类(Trip3)、增强机票类(PlaneTrip)、海报类(SimplePoster)、超文本普通类(NativePureText)、超文本增强类(NativeImageAndText)、短剧视频类(ShortVideo)、短剧图片类(ShortVideoImage) XIAOMI:多图文类(MultipleImageAndText)、图文类(StandardImageAndText)、红包类(RedPacket)、增强通知类(Notification2)、一般通知类(Notification1) OPPO:多图文类(MultipleImageAndText)、图文类(StandardImageAndText)、长文本类(PureText)、横滑类(Carousel)、视频类(Video)、电商类(ECImageAndText)、红包类(RedPacket)、图片轮播类1:1(CarouselSquareImage)、图片轮播类16:9(CarouselImageSixteenToNine)、图片轮播类48:65(CarouselVerticalImage) MEIZU:多图文类(MultipleImageAndText)、图文类(StandardImageAndText)、横滑类1(Carousel)、横滑类2(CarouselTitle) VIVO:多图文类(MultipleImageAndText)、图文类(StandardImageAndText)、图片轮播类1:1(CarouselSquareImage)、图片轮播类16:9(CarouselImageSixteenToNine)、图片轮播类48:65(CarouselVerticalImage)、视频类(Video)、电商类(ECImageAndText)、红包类(RedPacket)、增强通知类(Notification2)、一般通知类(Notification1) 三星:多图文类(MultipleImageAndText)、图文类(StandardImageAndText)、长文本类(PureText)、横滑类1(Carousel)、横滑类2(CarouselTitle)、视频图文类(VideoImageAndText)、视频类(Video)、电商类(ECImageAndText)、红包类(RedPacket)、图片轮播类1:1(CarouselSquareImage)、图片轮播类16:9(CarouselImageSixteenToNine)、图片轮播类48:65(CarouselVerticalImage)、图文视频类(ImageTextAndVideo)、一般通知类(Notification1)、机票类(Trip1)、火车票类(Trip2)、汽车票类(Trip3) 最小长度:1 最大长度:16 state 是 Integer 支持状态。 1:支持 0:不支持 最小值:0 最大值:1
  • KooMessage Basic Edition CommonOperations策略内容 { "Version": "1.1", "Statement": [ { "Action": [ "KooMessage:*imBasic*:list*", "KooMessage:aimBasic*:create", "KooMessage:aimBasic*:download" ], "Effect": "Allow" } ] }
  • KooMessage CommonOperations策略内容 { "Version": "1.1", "Statement": [ { "Action": [ "KooMessage:*:list*", "KooMessage:*:create", "KooMessage:*:check", "KooMessage:*:start", "KooMessage:*:download" ], "Effect": "Allow" } ] }
  • KooMessage SA CommonOperations策略内容 { "Version": "1.1", "Statement": [ { "Action": [ "KooMessage:aimSa*:list*", "KooMessage:aimSa*:create", "KooMessage:aimSa*:update", "KooMessage:aimSa*:upload" ], "Effect": "Allow" } ] }