华为云用户手册

  • 前提条件 需要具备AppStage服务运维岗位权限,权限申请操作请参见申请权限。 规划隔离域 隔离域是一个逻辑上的安全分组,为具有相同安全保护需求并互相信任的服务提供访问策略,当服务器加入到隔离域后,即受到这些访问规则的保护。在创建实例时,需要选择实例所属的隔离域,请提前规划好隔离域,具体操作请参见隔离域规划。 新服务或租户确认是否配置EPS信息。 通过AppStage申请对应服务华为云账号下的资源时,需要获取租户的EPS,如果租户没有绑定EPS,会导致在AppStage上申请资源失败。具体介绍请参见录入EPS配置。
  • 更多操作 微服务注册完成后,您可以执行如表1的操作。 表1 操作说明 操作 说明 修改微服务注册信息 单击微服务列表操作列的“修改”,可以配置如下信息: 访问能力表 ACL列表 如果业务要使用ACMS的认证功能,需要在被调用方(Provider)端配置ACL列表,让相应的调用方(Consumer)端微服务可以获取Provider端微服务的认证凭据。 在ACL列表区域,单击“添加”,选择服务名称和微服务名称,单击操作列的“提交”,添加一条ACL配置。 单击ACL列表操作列的“删除”,即可删除ACL配置。 说明: 添加ACL配置时,服务名称需要输入全称进行搜索,不支持模糊查询。 添加ACL配置后,由于存在缓存机制,配置需要等待10分钟左右生效。 仅在需要使用ACMS认证的情况下才配置ACL,如果业务使用ACMS签发的证书进行HTTPS双向认证,或者仅使用了敏感配置项管理的功能,则不需要配置ACL。 删除微服务 单击微服务列表操作列的“删除”,删除微服务。
  • 更多操作 创建微服务信息完成后,您还可以执行如下表1的操作。 表1 更多操作 操作 步骤 查看微服务信息 单击微服务列表中的服务中文名称,可查看微服务详情。 编辑微服务信息 说明: 仅可编辑“状态”为“草稿”的微服务的信息。 单击微服务列表“操作”列的“编辑”。 在“编辑微服务”页面编辑微服务中文名(不可编辑微服务所属服务和微服务英文名)。 单击“确认”。 删除微服务信息 说明: 仅可删除“状态”为“草稿”的微服务的信息。 单击微服务列表中“状态”为“草稿”的微服务“操作”列的“删除”。 单击“确定”。 发布微服务信息 说明: 仅可发布“状态”为“草稿”或“已下线”的微服务信息。 单击微服务列表“操作”列的“发布”(发布后服务无法删除,请谨慎操作)。 单击“确定”,该微服务信息将发布到已购买的AppStage相关中心。 同步微服务信息 说明: 发布服务信息后,如果在AppStage相关中心未同步到该微服务信息,可使用此“同步”功能重新同步微服务信息。 仅可同步非“草稿”状态的微服务信息。 单击微服务列表“操作”列的“同步”。 单击“确定”,该微服务信息将同步到已购买的AppStage相关中心。 下线微服务信息 说明: 下线微服务后AppStage的开发中心、运维中心等中心无法使用该微服务,请谨慎操作;下线后可以在“操作”列再次单击“发布”重新上线该微服务信息。 单击微服务所在行“操作列”列“下线”。 在“下线微服务”对话框输入“确定下线”,并单击“确定”。
  • 初始化配置 灰度服务创建完成后,需要进行初始化配置。 单击灰度服务列表中当前状态列的“初始化”,配置灰度服务信息。 在基础信息页面,确认灰度服务的基本信息,单击“下一步”。 在风险等级页面,选择发布类型。 当发布类型选择为“一阶段发布”时,直接单击“下一步”配置当前的分流规则。 当发布类型选择为“N阶段发布”时,需要确定风险等级及建议的发布阶段。 配置评估参数,单击“开始评估”。 系统会根据不同的风险等级评估结果,生成推荐的多个阶段分流规则模板,并且每个阶段的分流规则也将不同。 您可以在下一步的选择模板按钮中查看和选择推荐的N阶段分流规则模板。 单击“下一步”。 在分流配置页面,输入分流名称,填写各个阶段的分流配置项,分流配置项的参数说明如表2所示。 表2 分流配置参数说明 参数 说明 分流名称 配置分流名称。 字符长度0~50,可以由字母、数字、下划线、短横线、点组成,不能包含特殊字符,例:Rule_home-001。 第N阶段分流配置项 分流配置子项间关系 与、或 设置当前阶段下多个分流配置子项之间的关系。 类型 选择分流类型,支持的类型为path、REMOTE-ADDR、X-Forwarded-For、省、市、国家区域、自定义参数、自定义表达式。 参数 当分流类型为“自定义参数”时,需要配置此参数。 参数字符长度不能大于50,参数可以由数字、字母、下划线、短横线组成,不能包含特殊字符。 位置 当分流类型为“自定义参数”时,需要配置此参数。 query String body-json body-form header resource 匹配条件 pattern sha256 当匹配类型为sha256时,上传的值会自动转化为加密后的结果。 equal tailEqual rangeIP 值 单击“文件上传”,上传txt格式文件,文件中多个数据以英文逗号分隔。 操作 删除:单击“删除”对应的子项。每个分流规则至少保留一个有效的子项。 新增子项 单击“新增子项”,新增一条分流配置子项,每个子项有参数、类型、位置、匹配、值。 选择模板 单击“选择模板”,可以选择某个系统推荐的分流规则作为值填充到指定阶段。 插入无流量阶段 将在第一阶段前插入阶段作为无流量阶段,原来的第一阶段变为第二阶段。 插入无流量阶段只能在灰度服务初始化或灰度完成时操作。 如果不需要无流量阶段,可以修改规则或删除阶段。 导入分流配置 单击“导入分流配置”。 在弹出的窗口中单击“导入分流配置”,导入本地分流配置文件。 一键应用模板 单击“一键应用模板”,可以直接应用系统推荐的分流规则数据,推荐后可以修改。 应用区域模板,会根据区域进行分流。第一阶段分流可以选择市,第二阶段选择省。 应用用户模板,可以选择根据不同的用户做分流,在第二阶段可以自定义规则。 公共灰度策略 配置完成后,单击“下一步”。 配置的信息在发布成功前将保存在本地,可以单击“重置所有”按钮清空。 预览配置信息,确认无误后,单击“去发布”。 预览界面也可以单击“编辑”修改信息。 在发布页面,选择相关配置项,单击“发布”。参数说明如表3所示。 表3 发布相关参数说明 参数 说明 是否启用灰度 当选择“是”时,分流规则在SLB生效,满足分流规则条件的消息分发到灰度机器群组,不满足分流规则条件的消息分发到生产机器群组。 当选择“否”时,分流规则在SLB不生效。消息会在生产机器+灰度机器的整个群组中负载均衡分发。 全网发布时的路由策略 当选择“默认路由”时,全网发布时在生产+灰度的大集群中负载均衡。 当选择“特殊路由”时,全网发布时只在生产集群中负载均衡。
  • 更多操作 表6 相关操作 操作 说明 发布流控服务 单击流控服务列表操作列的“发布”。 您也可以在流控服务列表页面,单击待发布的服务名称,在流控服务详情页面,单击右上角的“发布”。 在弹出的提示框中单击“确定”。 发布成功后,服务发布状态列显示“已发布”。 编辑流控服务 单击流控服务列表操作列的“编辑”,在弹出的编辑窗口,单击认证密钥后的“重置”,可以重置认证密钥。 删除流控服务 单击流控服务列表操作列的“删除”,在弹出的提示框中单击“确定”,即可删除服务。 查看流控服务详情 单击流控服务名称,在流控服务详情页面,查看服务详情。
  • 更多操作 创建任务后,支持实例级、Schema级、sql文件级的任务执行,操作说明如表1所示。 表1 操作说明 操作 说明 批量执行 - 批量风险评估 - 刷新 - 查看详情 单击“详情”,可以执行单个sql文件,包括风险评估和对应执行的sql文件和sql语句。 风险评估:风险评估状态有高危、中危、低危、无四种状态,如果存在高危语句,请用户自行评估风险在确定是否要执行。 执行任务 执行选项: 并行执行:默认关闭,默认SQL变更任务下所有子任务都会串行执行。 预检查:默认关闭,主要是检查是否存在长事务和锁,此时任务状态为“预检查中”。 忽略重复执行的错误:默认关闭,默认在执行中遇到任何错误都会停止执行。 说明: SQL变更工具在用户单击执行按钮后会花费1分钟左右的时间对数据库进行预检查,此过程时间较长, 自行评估是否要选择。 主要是检查是否存在长事务和锁,此时任务状态为“预检查中”。 预检查成功后会自动执行,预检查失败会报出提示信息,并且任务状态重新退回“准备就绪”。 此时用户需要对数据库进行检查,是否此时负载较高,或者存在长事务,或者是否有大数据量的查询语句一直在执行未结束等等。 检查完毕后可重新单击“执行”,如果确定该问题不影响SQL语句的执行,则可单击“执行(忽略预检查)”。
  • 更多操作 创建产品信息完成后,您还可以执行如表1所示的操作。 表1 更多操作 操作 步骤 查看产品信息 单击产品列表中产品中文名,可查看产品详情。 编辑产品信息 说明: 仅可编辑“状态”为“草稿”的产品信息。 单击产品列表“操作”列的“编辑”。 在“编辑产品”页面编辑产品中文名(不可以编辑产品归属部门和产品英文名)。 删除产品信息 说明: 仅可删除“状态”为“草稿”的产品信息。 单击产品列表中“状态”为“草稿”的产品“操作”列的“删除”。 单击“确定”。 发布产品信息 说明: 仅可发布“状态”为“草稿”或“已下线”的产品信息。 单击产品列表“操作”列的“发布”(发布后产品无法删除,请谨慎操作)。 单击“确定”,该产品信息将发布到已购买的AppStage相关中心。 同步产品信息 说明: 发布产品信息后,如果在AppStage相关中心未同步到该产品信息,可使用此“同步”功能重新同步产品信息。 仅可同步非“草稿”状态的产品信息。 单击产品列表“操作”列的“同步”。 单击“确定”,该产品信息将同步到已购买的AppStage相关中心。 下线产品信息 说明: 下线产品需确保该产品下的服务及微服务已下线,下线后AppStage的开发中心、运维中心等中心无法使用该产品,请谨慎操作;下线后可以在“操作”列再次单击“发布”重新上线该产品信息。 单击产品列表“操作”列的“下线”。 在“下线产品”对话框输入“确定下线”,并单击“确定”。
  • 前提条件 需要具备AppStage服务运维岗位权限,权限申请操作请参见申请权限。 确保服务B已经注册。 如果服务B下有一个微服务C,是服务B自带的,不是迁移过来的,微服务A是需要迁移的微服务,则使用微服务C注册服务B。 如果服务B下只有两个微服务,微服务A和微服务B都是需要迁移的,那么随机选择微服务A或微服务B注册,然后删除该微服务(删除微服务不会删除服务),即可成功注册服务B。 确保新服务下没有注册要迁移的微服务。 如果新服务下已经注册了需要迁移的微服务,在确保新微服务还没有被部署的情况下,需要删除该微服务,再做迁移。 如果业务已经提前在新服务下注册了需要迁移的微服务,并且已经被部署,则业务需要评估是否有必要保持密钥一致,如果不需要保持密钥一致,则可以做敏感配置迁移,不需要做微服务迁移。如果必须保持密钥一致,则需要评估删除微服务再迁移微服务对业务的影响。是否需要保持秘钥一致的评估标准如下: 如果作为被调用方,提供服务给云服务内多个业务,其他业务和该微服务之间使用STS认证,那么需要保持密钥不变。 如果只是作为调用方使用STS认证访问其他微服务,用STS托管敏感配置项,加密中间件口令等,那就不需要保持密钥不变。
  • 更多操作 表3 相关操作 操作 说明 查看账号权限 在“账号清单”页签中,单击账号列表前的,查看账号权限。 删除账号 在“账号清单”页签中,单击账号列表操作列的“删除”,所有删除的账号在“回收站”子页签展示。 说明: 删除账号只是从WiseDBA账号列表中进行软删除,要想从数据库上完全进行清理,需要在回收站中进行永久删除。 不支持删除系统默认的账号。 列定制 在“账号清单”页签中,单击,定制账号列表显示的列。 还原账号 在“回收站”页签中,单击操作列的“还原”,已删除的账号可被还原并重新回到账号清单。 永久删除账号 在“回收站”页签中,单击操作列的“永久删除”,账号从回收站中删除,同时也从业务数据库中删除。 说明: 数据库账号关系到业务是否能正常访问数据库,请仔细辨别需要删除的账号具体信息:包括用户名和白名单主机。 高危操作,谨慎处理,一经删除,难以在短时间内恢复。 批量还原账号 在“回收站”页签中,选择一个或多个已删除的账号,单击“批量还原”,批量还原账号。
  • 告警类型说明 告警在列表中总共有五种状态,实际上告警本身只有告警中和已解决两种状态,根据这两种状态在系统中不同的标记又细分为五种状态,具体告警类型如表2所示。 表2 告警类型说明 告警类型 告警说明 当前告警 告警进入系统后如果没有被屏蔽规则屏蔽就会进入该页签,表示当前仍然是告警中状态且未被清除和屏蔽的告警。 屏蔽告警 告警进入系统后被设置的屏蔽规则自动屏蔽或者人为在界面上手动单击屏蔽的告警。屏蔽的告警分为两种,一种是有具体屏蔽时间的,到了屏蔽时间结束后会作为一条新的告警再次出现在当前告警的列表中,一种是没有屏蔽时间的,将会被永久屏蔽。 历史告警 历史告警都是已解决的告警,让告警进入已解决的状态的方式有两种,一种是上报的告警已解决,这条告警就会被清除进入历史告警,或者是在界面上直接清除告警也会进入历史告警。 未确认已恢复告警 系统接收到已解决或自动清除的告警,非界面操作影响的告警。 归档告警 历史告警中,告警级别在严重和紧急的告警且是已解决状态的,每个小时会被定时任务扫描到转移至归档告警。
  • 查询告警参数说明 可以用不同参数对告警进行查询,参数说明如表3所示。 表3 查询告警参数说明 告警参数 参数说明 应用/服务 告警所属的自有服务,不选则默认展示用户拥有权限下的所有告警。 告警级别 告警上报时所带的level字段。 显示模式 显示模式分为三种,告警收敛,原始告警和仅收敛告警。 告警收敛:展示未参与收敛的告警与收敛的告警是默认的显示模式,当告警被收敛后,收敛告警的正文中会统计当前收敛的子告警的状态。单击告警收敛后可以操作和查看具体子告警。 原始告警:原始告警展示除了收敛告警外的所有告警,包括已经被收敛了的原始告警也会展示。 仅收敛告警:仅展示已经被收敛了的告警。 状态 支持对未确认、已确认、已通知、处理中和处理完成的告警进行查询。 语音呼叫状态 告警当前的语音呼叫的状态。 告警类型 告警上报时的category字段。 入库时间 告警进入系统的时间。 区域 告警涉及的区域。 告警单发 选择是否查看属于告警单发的告警。
  • 更多操作 创建服务信息完成后,您还可以执行如下表1的操作。 表1 更多操作 操作 步骤 查看服务详情 单击服务列表中服务中文名,可查看服务详情。 编辑服务信息 说明: 仅可编辑“状态”为“草稿”的服务信息。 单击服务列表“操作”列的“编辑”。 在“编辑服务”页面编辑服务中文名(不可编辑服务所属产品和服务英文名),然后单击“确定”。 删除服务信息 说明: 仅可删除“状态”为“草稿”的服务信息。 单击服务列表中“状态”为“草稿”的服务“操作”列的“删除”。 单击“确定”。 发布服务信息 说明: 仅可发布“状态”为“草稿”或“已下线”的服务信息。 单击服务列表“操作”列的“发布”(发布后服务无法删除,请谨慎操作)。 单击“确定”,该服务信息将发布到已购买的AppStage相关中心。 同步服务信息 说明: 发布服务信息后,如果在AppStage相关中心未同步到该服务信息,可使用此“同步”功能重新同步服务信息。 仅可同步非“草稿”状态的服务信息。 单击服务列表“操作”列的“同步”。 单击“确定”,该服务信息将同步到已购买的AppStage相关中心。 下线服务信息 说明: 下线服务需确保该服务下的微服务已下线,下线后AppStage的开发中心、运维中心等中心无法使用该服务,请谨慎操作;下线后可以在“操作”列再次单击“发布”重新上线该服务信息。 单击服务列表“操作”列的“下线”。 在“下线服务”对话框输入“确定下线”,并单击“确定”。
  • 修订记录 发布日期 修订记录 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_ LOG O的大小由“不超过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:小米”改为“XI AOM I:小米”;删除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_PA RAM ETER:表示复制 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
  • 支持的云服务 企业项目管理支持的云服务及对应资源类型请以控制台界面显示为准。 进入“企业项目管理”页面,在企业项目列表中单击任一企业项目操作列的“查看资源”,系统进入企业项目详情页面,在“资源”页签下可查看企业项目支持的服务及其对应资源类型等信息。 目前企业项目支持管理的云服务及对应资源如下: 表1 企业项目当前支持的资源 云服务 资源类型 云专线 DC 物理连接 虚拟网关 虚拟接口 链路聚合组 弹性云服务器 E CS 弹性云服务器 裸金属服务器 BMS 裸金属服务器 弹性伸缩 AS 弹性伸缩组 镜像服务 IMS 私有镜像 专属主机 DeH 专属主机 函数工作流 FunctionGraph 函数 对象存储服务 OBS 桶 云硬盘 EVS 磁盘 云备份服务 CBR 存储库 内容分发网络 CDN 域名 弹性文件服务 SFS 文件系统 sfs-turbo 虚拟私有云 VPC 虚拟私有云 安全组 IP地址组 网络ACL 公网带宽 Bandwidth 共享带宽 弹性公网IP EIP 弹性公网IP 弹性负载均衡 ELB 负载均衡器 NAT网关 NAT Gateway 公网NAT网关 云解析服务 DNS 内网域名 反向解析 公网域名 云容器引擎服务 CCE 集群 Autopilot集群 云容器实例 CCI 命名空间 基因测序服务 GCS 环境 DDoS高防服务 AAD 实例 Web应用防火墙 WAF Web应用防火墙独享实例 Web应用防火墙 Web应用防火墙域名扩展包 Web应用防火墙带宽扩展包 企业主机安全 HSS 主机安全 密钥管理 KMS 密钥管理 分布式缓存服务 DCS 实例 分布式消息服务 DMS Kafka实例 RabbitMQ实例 RocketMQ实例 消息通知 服务 SMN 主题 区块链 服务 BCS 区块链(Hyperledger Fabric增强版) 华为云区块链引擎 API网关 APIG 专享版实例 云监控服务 CES 告警规则 监控面板 资源分组 应用运维管理 AOM 资源分组 应用性能管理 APM 应用 云日志 服务 LTS 日志流 云连接 CC 云连接 带宽包 关系型数据库 RDS 实例 文档数据库服务 DDS 实例 分布式数据库 中间件 DDM 实例 数据复制服务 DRS 实时同步任务 实时迁移任务 备份迁移任务 数据订阅任务 实时灾备任务 云数据库 GaussDB GaussDB实例 云数据迁移 CDM 集群 ModelArts 工作空间 MapReduce服务 MRS 集群 数据湖探索 DLI 集群 队列 数据库 弹性资源池 云搜索服务 CSS 集群 数据仓库服务 DWS DWS集群 数据接入服务 DIS 通道 表格存储服务 CloudTable CloudTable集群 图引擎服务 GES GES集群 推荐系统 RES 工作空间 数据可视化 DLV DLV实例 软件开发云 DevCloud 项目管理 应用与 数据集成平台 ROMA ROMA实例 ROMA任务 支持计划 SupportPlan 支持计划 微服务引擎 CSE 引擎 隐私保护通话 PrivateNumber 应用 SSL证书管理 SCM 证书 数据治理中心 DataArts Studio (原 智能数据湖 运营平台 DAYU) DAYU实例 专属分布式存储 DSS 磁盘 存储池 专属计算集群 DCC 专属计算集群 主机迁移服务 SMS 源端服务器 应用服务网格 ASM 网格 数据库安全服务 DBSS 数据库审计实例 虚拟专用网络 VPN VPN网关 视频点播 VOD 域名 数据库和应用迁移 UGO 对象迁移任务 对象评估任务 云速建站 CloudSite 站点 多云高可用服务 MAS MAS多活管理 MAS命名空间 企业路由器 ER 企业路由器 变更管理服务 CMS 任务 作业 文件 脚本 私有证书管理 PCA 私有CA 私有证书 云手机服务器 CPH 云手机服务器 开天集成工作台 MSSI 云审计 服务 CTS 追踪器 云堡垒机 CBH 堡垒机 云防火墙 CFW 云防火墙 视频直播 LIVE 域名 云原生DDoS防护 CNAD 云原生DDoS防护 设备接入 IOTDA 实例 专属加密服务 DHSM 加密机 凭据管理服务 CSMS 凭据 湖仓构建 LakeFormation 实例 边缘安全 EdgeSec 边缘DDOS域名扩展包 边缘WAF域名扩展包 边缘DDOS 边缘WAF 云桌面 Workspace 云办公桌面 企业连接 EC 企业连接网络 智能企业网关 事件网格 EG 通道 全域弹性公网IP GEIP 全域弹性公网IP 全域公网带宽 工业数字模型驱动引擎 iDME 数字主线引擎 数字化制造基础服务 基础版数据建模引擎节点 iDMEStudio基础版 全球加速 GA 加速器 工业仿真工具链云服务 CraftArtsSIM 工业仿真云平台 云原生仿真服务 仿真求解计算 仿真前后处理计算 工业数据管理及协同云服务 IPDCenter 产品数字化协同服务 应用管理与运维平台 ServiceStage ServiceStage环境 ServiceStage应用 云数据库 GeminiDB 实例 父主题: 项目管理
  • 修订记录 版本日期 变更说明 2024-03-29 本次变更如下: 更新支持的云服务章节。 2023-07-26 本次变更如下: 新增约束与限制章节。 2023-06-15 本次变更如下: 新增管理资源标签章节。 2022-10-30 本次变更如下: 新增安全章节。 2021-09-10 本次变更如下: 新增: 新增最多可以创建多少个企业项目?章节。 新增资源迁入/迁出企业项目会影响资源所在的VPC和网段吗?章节。 新增如何实现同账号下不同子用户只能看到特定的企业项目而看不到该账号下的其他企业项目?章节。 2021-07-16 本次变更如下: Console产品目录变更:中文“管理与部署”入口更名为“管理与监管”,英文“计算”入口更名。 2021-04-30 本次变更如下: 新增:关于配额。 2021-01-21 本次变更如下: 更新“如何开通企业项目”章节:开通企业项目入口不支持从账号基本信息进入,支持从项目管理入口进入。 2021-01-11 本次变更如下: 新增“多项目管理实践案例”章节。 新增常见问题“IAM用户和企业子账号的区别”章节。 2020-10-30 本次变更如下: 项目类型新增测试类项目特性:新增“测试类项目转商用生产项目”章节。 资源管理新增用户特性:新增“如何管理企业项目用户”章节。 2020-09-30 本次变更如下: 增加常见问题:使用企业管理Java Python SDK获取不到企业项目的排查方式。 父主题: 项目管理
  • 操作场景 云数据库RDS for MySQL支持单个按需实例转为包周期(包年/包月)实例,也支持批量按需实例转为包周期实例。由于按需资源费用较高,需要长期使用资源的按需用户可以选择对按需资源进行转包周期,继续使用这些资源的同时,享受包周期的优惠资费。 运行状态为冻结、创建失败、规格变更中、扩容中的实例不支持按需实例转包周期。 专属云RDS目前仅支持按需计费。 按需实例转包周期不会影响业务。 除华北-乌兰察布一外的其他区域均支持按需实例转包周期。华北-乌兰察布一区域可联系客服开通该功能。 主实例按需转包周期时,如果主实例下创建了按需计费的数据库代理,那么数据库代理也会同步转包周期,该功能目前仅支持华南-广州、华东-上海一、中国-香港区域。如果主实例下的代理不支持转包周期,主实例也不支持按需转包周期。
  • 请求示例 https://{endpoint}/v3/0483b6b16e954cb88930a360d2c4e663/instances/f569f1358436479dbcba8603c32cc4aein03/proxy/weight { "master_weight":"0", "readonly_instances":[ { "id":"83251d1398594b9fbfc8f1ab8b8228b2in03", "weight":100 } ] }
  • 请求消息 参数说明 表2 参数说明 名称 是否必选 参数类型 说明 master_weight 是 String 主实例权重,取值范围为0~1000。 readonly_instances 是 Array of objects 只读实例信息。 详情请参见表3。 表3 readonly_instances字段数据结构说明 名称 是否必选 参数类型 说明 id 是 String 只读实例ID。 weight 是 Integer 只读实例权重,取值范围为0~1000。
  • URI URI格式 GET /v3/{project_id}/instances/{instance_id}/proxy/scale/flavors URI样例 https://{endpoint}/v3/0483b6b16e954cb88930a360d2c4e663/instances/f569f1358436479dbcba8603c32cc4aein03/proxy/scale/flavors 参数说明 表1 参数说明 名称 是否必选 说明 project_id 是 租户在某一region下的project ID。 获取方法请参见获取项目ID。 instance_id 是 实例ID。
  • 响应消息 正常响应要素说明 表2 要素说明 名称 参数类型 说明 compute_flavor_groups Array of objects 计算规格列表对象。 详情请参见表3。 表3 compute_flavor_groups元素数据结构说明 名称 参数类型 说明 group_type String 群组类型。 X86:X86架构。 ARM:ARM架构。 compute_flavors Array of objects 计算规格信息。 详情请参见表4 表4 ScaleFlavors元素数据结构说明 名称 参数类型 说明 code String 规格码。 cpu String CPU个数。 mem String 内存大小(单位:GB)。 正常响应样例 { "compute_flavor_groups" : { "group_type" : "X86", "compute_flavors" : { "code" : "rds.pg.proxy.c6.large.2.ha", "cpu" : 2, "mem" : 4 } } } 异常响应 请参见异常请求结果。
  • 请求消息 请求参数 无。 URI样例 查询所有实例列表 GET https://{endpoint}/v3/97b026aa9cc4417888c14c84a1ad9860/instances 根据指定条件查询实例列表 GET https://{endpoint}/v3/97b026aa9cc4417888c14c84a1ad9860/instances?id=ed7cc6166ec24360a5ed5c5c9c2ed726in01&name=hy&type=Ha&datastore_type=MySQL&vpc_id=19e5d45d-70fd-4a91-87e9-b27e71c9891f&subnet_id=bd51fb45-2dcb-4296-8783-8623bfe89bb7&offset=0&limit=10&tags=rds001=001,rds002=002
  • URI URI格式 GET /v3/{project_id}/instances?id={id}&name={name}&type={type}&datastore_type={datastore_type}&vpc_id={vpc_id}&subnet_id={subnet_id}&offset={offset}&limit={limit}&tags={key}={value} 参数说明 表1 参数说明 名称 参数类型 是否必选 说明 project_id String 是 租户在某一Region下的项目ID。 获取方法请参见获取项目ID。 id String 否 实例ID。 “*”为系统保留字符,如果id是以“*”起始,表示按照*后面的值模糊匹配,否则,按照id精确匹配查询。不能只传入“*”。 name String 否 实例名称。 “*”为系统保留字符,如果name是以“*”起始,表示按照*后面的值模糊匹配,否则,按照name精确匹配查询。不能只传入“*”。 type String 否 按照实例类型查询。取值Single、Ha、Replica、Enterprise,分别对应于单实例、主备实例和只读实例、分布式实例(企业版)。 datastore_type String 否 数据库类型,区分大小写。 MySQL PostgreSQL SQLServer vpc_id String 否 虚拟私有云ID,获取方法如下: 方法1:登录虚拟私有云服务的控制台界面,在虚拟私有云的详情页面查找VPC ID。 方法2:通过虚拟私有云服务的API接口查询,具体操作可参考查询VPC列表。 subnet_id String 否 子网的网络ID信息,获取方法如下: 方法1:登录虚拟私有云服务的控制台界面,单击VPC下的子网,进入子网详情页面,查找网络ID。 方法2:通过虚拟私有云服务的API接口查询,具体操作可参考查询子网列表。 offset Integer 否 索引位置,偏移量。从第一条数据偏移offset条数据后开始查询,默认为0(偏移0条数据,表示从第一条数据开始查询),必须为数字,不能为负数。 limit Integer 否 查询记录数。默认为100,不能为负数,最小值为1,最大值为100。 tags Array of objects 否 根据实例标签键值对进行查询。 {key}表示标签键,不可以为空或重复。 {value}表示标签值,可以为空。 如果同时使用多个标签键值对进行查询,中间使用逗号分隔开,最多包含10组。 详情请参见表2。 表2 tags字段数据结构说明 名称 参数类型 是否必选 说明 key String 是 标签键。长度为1-128个unicode字符。 可以包含任何语种字母、数字、空格和_.:=+-@,但首尾不能含有空格,不能以_sys_开头。 value String 否 标签值。最大长度255个unicode字符,可以为空字符串。 可以包含任何语种字母、数字、空格和_.:=+-@。
  • URI URI格式 DELETE /v3/{project_id}/instances/{instance_id}/proxy URI样例 https://{endpoint}/v3/0483b6b16e954cb88930a360d2c4e663/instances/f569f1358436479dbcba8603c32cc4aein03/proxy 参数说明 表1 参数说明 名称 是否必选 说明 project_id 是 租户在某一region下的project ID。 获取方法请参见获取项目ID。 instance_id 是 实例ID。
  • 请求示例 创建MySQL单机实例。 POST https://{endpoint}/v3/0483b6b16e954cb88930a360d2c4e663/instances { "name": "rds-instance-rep2", "datastore": { "type": "MySQL", "version": "5.7" }, "flavor_ref": "rds.mysql.s1.large", "volume": { "type": "ULTRAHIGH", "size": 100 }, "disk_encryption_id": "2gfdsh-844a-4023-a776-fc5c5fb71fb4", "region": "aaa", "availability_zone": "bbb", "vpc_id": "490a4a08-ef4b-44c5-94be-3051ef9e4fce", "subnet_id": "0e2eda62-1d42-4d64-a9d1-4e9aa9cd994f", "data_vip": "192.168.0.1", "security_group_id": "2a1f7fc8-3307-42a7-aa6f-42c8b9b8f8c5", "port": 8635, "backup_strategy": { "start_time": "08:15-09:15", "keep_days": 12 }, "charge_info": { "charge_mode": "postPaid" }, "password": "****", "configuration_id": "452408-ef4b-44c5-94be-305145fg", "enterprise_project_id": "fdsa-3rds", "time_zone": "UTC+04:00", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ], "dry_run": false, "count": 12 } 创建PostgreSQL单机实例。 { "name": "rds-instance-rep2", "datastore": { "type": "PostgreSQL", "version": "10" }, "flavor_ref": "rds.pg.s1.large", "volume": { "type": "ULTRAHIGH", "size": 100 }, "disk_encryption_id": "2gfdsh-844a-4023-a776-fc5c5fb71fb4", "region": "aaa", "availability_zone": "bbb", "vpc_id": "490a4a08-ef4b-44c5-94be-3051ef9e4fce", "subnet_id": "0e2eda62-1d42-4d64-a9d1-4e9aa9cd994f", "data_vip": "192.168.0.147", "security_group_id": "2a1f7fc8-3307-42a7-aa6f-42c8b9b8f8c5", "port": 8635, "backup_strategy": { "start_time": "08:15-09:15", "keep_days": 12 }, "charge_info": { "charge_mode": "postPaid" }, "password": "Test@12345678", "configuration_id": "452408-ef4b-44c5-94be-305145fg", "enterprise_project_id": "fdsa-3rds", "time_zone": "UTC+04:00", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ] } 创建MySQL 8.0单机实例指定初始化参数。 { "name": "rds-instance-rep2", "datastore": { "type": "MySQL", "version": "8.0" }, "flavor_ref": "rds.mysql.s1.large", "volume": { "type": "ULTRAHIGH", "size": 100 }, "disk_encryption_id": "2gfdsh-844a-4023-a776-fc5c5fb71fb4", "region": "aaa", "availability_zone": "bbb", "vpc_id": "490a4a08-ef4b-44c5-94be-3051ef9e4fce", "subnet_id": "0e2eda62-1d42-4d64-a9d1-4e9aa9cd994f", "data_vip": "192.168.0.1", "security_group_id": "2a1f7fc8-3307-42a7-aa6f-42c8b9b8f8c5", "port": 8635, "backup_strategy": { "start_time": "08:15-09:15", "keep_days": 12 }, "charge_info": { "charge_mode": "postPaid" }, "password": "****", "configuration_id": "452408-ef4b-44c5-94be-305145fg", "enterprise_project_id": "fdsa-3rds", "time_zone": "UTC+04:00", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ], "unchangeable_param": { "lower_case_table_names": "1" }, "dry_run": false, "count": 12 } 创建SQL Server单机实例支持指定字符集。 { "name": "rds-instance-rep2", "datastore": { "type": "SQLServer", "version": "2014_SE" }, "flavor_ref": "rds.mssql.se.m3.large.8", "volume": { "type": "ULTRAHIGH", "size": 100 }, "disk_encryption_id": "2gfdsh-844a-4023-a776-fc5c5fb71fb4", "region": "aaa", "availability_zone": "bbb", "vpc_id": "490a4a08-ef4b-44c5-94be-3051ef9e4fce", "subnet_id": "0e2eda62-1d42-4d64-a9d1-4e9aa9cd994f", "data_vip": "192.168.0.1", "security_group_id": "2a1f7fc8-3307-42a7-aa6f-42c8b9b8f8c5", "port": 8635, "backup_strategy": { "start_time": "08:15-09:15", "keep_days": 12 }, "charge_info": { "charge_mode": "postPaid" }, "collation": "Cyrillic_General_CI_AS", "password": "****", "configuration_id": "452408-ef4b-44c5-94be-305145fg", "enterprise_project_id": "fdsa-3rds", "time_zone": "UTC+04:00", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ], } DeC用户创建MySQL单机实例。 { "name": "rds-instance-rep2", "datastore": { "type": "MySQL", "version": "5.6" }, "flavor_ref": "rds.mysql.s1.large", "volume": { "type": "ULTRAHIGH", "size": 100 }, "disk_encryption_id": "2gfdsh-844a-4023-a776-fc5c5fb71fb4", "region": "aaa", "availability_zone": "bbb", "vpc_id": "490a4a08-ef4b-44c5-94be-3051ef9e4fce", "subnet_id": "0e2eda62-1d42-4d64-a9d1-4e9aa9cd994f", "data_vip": "192.168.0.1", "security_group_id": "2a1f7fc8-3307-42a7-aa6f-42c8b9b8f8c5", "port": 8635, "backup_strategy": { "start_time": "08:15-09:15", "keep_days": 12 }, "charge_info": { "charge_mode": "postPaid" }, "password": "****", "configuration_id": "452408-ef4b-44c5-94be-305145fg", "enterprise_project_id": "fdsa-3rds", "time_zone": "UTC+04:00", "dsspool_id":"3278327382738217382173872183721837213", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ], "dry_run": false, "count": 12 } 创建主备实例。 { "name": "rds-instance-rep2", "datastore": { "type": "MySQL", "version": "5.6" }, "ha": { "mode": "ha", "replication_mode": "semisync" }, "flavor_ref": "rds.mysql.s1.large.ha", "volume": { "type": "ULTRAHIGH", "size": 100 }, "disk_encryption_id": "2gfdsh-844a-4023-a776-fc5c5fb71fb4", "region": "aaa", "availability_zone": "bbb,ccc", "vpc_id": "490a4a08-ef4b-44c5-94be-3051ef9e4fce", "subnet_id": "0e2eda62-1d42-4d64-a9d1-4e9aa9cd994f", "data_vip": "192.168.0.1", "security_group_id": "2a1f7fc8-3307-42a7-aa6f-42c8b9b8f8c5", "port": 8635, "backup_strategy": { "start_time": "08:15-09:15", "keep_days": 12 }, "charge_info": { "charge_mode": "postPaid" }, "password": "****", "configuration_id": "452408-ef4b-44c5-94be-305145fg", "enterprise_project_id": "fdsa-3rds", "time_zone": "UTC+04:00", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ], "dry_run": false, "count": 12 } DeC用户创建MySQL主备实例。 { "name": "rds-instance-rep2", "datastore": { "type": "MySQL", "version": "5.6" }, "ha": { "mode": "ha", "replication_mode": "semisync" }, "flavor_ref": "rds.mysql.s1.large.ha", "volume": { "type": "ULTRAHIGH", "size": 100 }, "disk_encryption_id": "2gfdsh-844a-4023-a776-fc5c5fb71fb4", "region": "aaa", "availability_zone": "bbb,ccc", "vpc_id": "490a4a08-ef4b-44c5-94be-3051ef9e4fce", "subnet_id": "0e2eda62-1d42-4d64-a9d1-4e9aa9cd994f", "data_vip": "192.168.0.1", "security_group_id": "2a1f7fc8-3307-42a7-aa6f-42c8b9b8f8c5", "port": 8635, "backup_strategy": { "start_time": "08:15-09:15", "keep_days": 12 }, "charge_info": { "charge_mode": "postPaid" }, "password": "****", "configuration_id": "452408-ef4b-44c5-94be-305145fg", "enterprise_project_id": "fdsa-3rds", "time_zone": "UTC+04:00", "dsspool_id":"327832738273821772133432,21489938273821772133432", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ], "dry_run": false, "count": 12 } 创建只读实例。 { "name": "rds-instance-rep2", "replica_of_id": "afdsad-fds-fdsagin01", "flavor_ref": "rds.mysql.s1.large.rr", "volume": { "type": "ULTRAHIGH" }, "disk_encryption_id": "2gfdsh-844a-4023-a776-fc5c5fb71fb4", "region": "aaa", "availability_zone": "bbb", "enterprise_project_id": "fdsa-3rds", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ] } DeC用户创建只读实例。 { "name": "rds-instance-rep2", "replica_of_id": "afdsad-fds-fdsagin01", "flavor_ref": "rds.mysql.s1.large.rr", "volume": { "type": "ULTRAHIGH" }, "disk_encryption_id": "2gfdsh-844a-4023-a776-fc5c5fb71fb4", "region": "aaa", "availability_zone": "bbb", "enterprise_project_id": "fdsa-3rds" "dsspool_id":"3278327382738217382173872183721837213", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ] 创建MySQL Serverless型单机实例。 { "name": "rds-instance-serverless1", "datastore": { "type": "MySQL", "version": "5.7" }, "flavor_ref": "rds.mysql.serverless", "volume": { "type": "CLOUDSSD", "size": 40 }, "region": "aaa", "availability_zone": "bbb", "vpc_id": "490a4a08-ef4b-44c5-94be-3051ef9e4fce", "subnet_id": "0e2eda62-1d42-4d64-a9d1-4e9aa9cd994f", "security_group_id": "2a1f7fc8-3307-42a7-aa6f-42c8b9b8f8c5", "port": 3306, "backup_strategy": { "start_time": "08:15-09:15", "keep_days": 12 }, "password": "****", "time_zone": "UTC+04:00", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ], "dry_run": false, "count": 1, "serverless_info": { "min_cap": "0.5", "max_cap": "1" } } 创建MySQL Serverless型主备实例。 { "name": "rds-instance-serverless2", "datastore": { "type": "MySQL", "version": "5.7" }, "ha": { "mode": "ha", "replication_mode": "semisync" }, "flavor_ref": "rds.mysql.serverless.ha", "volume": { "type": "CLOUDSSD", "size": 40 }, "region": "aaa", "availability_zone": "aaa,bbb", "vpc_id": "490a4a08-ef4b-44c5-94be-3051ef9e4fce", "subnet_id": "0e2eda62-1d42-4d64-a9d1-4e9aa9cd994f", "security_group_id": "2a1f7fc8-3307-42a7-aa6f-42c8b9b8f8c5", "port":3306, "backup_strategy": { "start_time": "08:15-09:15", "keep_days": 12 }, "password": "****", "time_zone": "UTC+08:00", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value2" } ], "dry_run": false, "count": 1, "serverless_info": { "min_cap": "0.5", "max_cap": "1" } }
  • URI URI格式 GET /v3.1/{project_id}/instances/{instance_id}/proxy/scale/flavors URI样例 https://{endpoint}/v3.1/0483b6b16e954cb88930a360d2c4e663/instances/f569f1358436479dbcba8603c32cc4aein03/proxy/scale/flavors 参数说明 表1 参数说明 名称 是否必选 说明 project_id 是 租户在某一region下的project ID。 获取方法请参见获取项目ID。 instance_id 是 实例ID。 offset 否 索引位置,偏移量。从第一条数据偏移offset条数据后开始查询,默认为0(偏移0条数据,表示从第一条数据开始查询),必须为数字,不能为负数。 limit 否 查询记录数。默认为100,不能为负数,最小值为1,最大值为100。
  • 响应消息 正常响应要素说明 表2 要素说明 名称 参数类型 说明 compute_flavor_groups Array of objects 计算规格列表对象。 详情请参见表3。 表3 compute_flavor_groups元素数据结构说明 名称 参数类型 说明 group_type String 群组类型。 X86:X86架构。 ARM:ARM架构。 compute_flavors Array of objects 计算规格信息。 详情请参见表4 表4 ScaleFlavors元素数据结构说明 名称 参数类型 说明 code String 规格码。 cpu String CPU个数。 mem String 内存大小(单位:GB)。 正常响应样例 { "compute_flavor_groups" : { "group_type" : "X86", "compute_flavors" : { "code" : "rds.pg.proxy.c6.large.2.ha", "cpu" : 2, "mem" : 4 } } } 异常响应 请参见异常请求结果。
  • 请求消息 表2 参数说明 名称 是否必选 参数类型 说明 port 是 Integer 端口号。 RDS for MySQL端口号范围:大于等于1024,小于等于65535,不包含12017和33071。 RDS for PostgreSQL端口号范围:2100~9500。 对于RDS for SQL Server 2022 EE、2022 SE、2022 Web版、2019 EE、2019 SE、2019 Web版、2017 EE、2017 SE、2017 Web版:端口设置范围为1433和2100~9500(其中5050、5353、5355、5985和5986不可设置)。 除此之外的其他版本:端口设置范围为1433和2100~9500(其中5355、5985和5986不可设置)。
共100000条