营销规则接口(价格模式)
收藏
我的收藏接口说明
营销规则创建和更新
基本信息
名称 | 描述 |
---|---|
HTTP URL | https://open.douyin.com/goodlife/v1/trip/promotion/price/rule/push/ |
HTTP Method | POST |
Scope | life.capacity.trip_hotel_price_rule_promotion_push |
权限要求 | 酒店行业日历房解决方案-营销规则价格模式推送 |
请求参数
请求头
access-token必填String
示例:clt.943da17996fb5cebfbc70c044c3fc25a57T54DcjT6HNKGqnUdxzy1KcxFnZ
content-type必填String
固定值"application/json"
Body展开全部子属性
account_id必填String
商户account_id
applicable_date必填Struct
营销适用日期
展开子属性
applicable_resource必填Struct
营销适用资源
展开子属性
is_auto_extension必填Bool
是否自动延期
promotion_basic_info必填Struct
营销基础信息
展开子属性
activeBool
活动是否生效,如果非生效,下面所有的售卖房型也失效,默认生效(false时需要传promotion_id)
full_pattern_promotionStruct
全模式促销
展开子属性
promotion_idString
营销ID,当传入营销ID时,即为更新营销信息;否则为新增
unapplicable_dateStruct
营销不适用日期
展开子属性
请求示例
curl --location --request POST 'https:// open.douyin.com/goodlife/v1/trip/promotion/price/rule/push/' \ --header 'content-type: application/json' \ --header 'access-token: 0801121846735352506a356a6' \ --data '{"promotion_id":"njggNhU01x","full_pattern_promotion":{"full_pattern_promotion_detail":{"is_hotel_new_customer":false,"discount_type":1,"member_promotion":[4154037609830590570],"consecutive_days":9154332370237640493,"advance_days":4182396336233317675,"start_hour":2912978942327505717,"end_hour":824279028456098941}},"applicable_date":{"start_days":"JYGVqopb1f","end_days":"7LeJZxP7Vu","days_of_week":[1113318831465966843]},"is_auto_extension":false,"account_id":"BzcpEaVzNl","active":false,"unapplicable_date":{"unapplicable_date_range":[{"end_days":"9VdgPeDUUT","start_days":"GoahVCQrBr"}]},"promotion_basic_info":{"type_name":"5MgbaRPa4R","sub_type_code":"MmwLooqdHs","sub_type_code_name":"7kXPo5nu6j","out_type":"T2y36URKsk","type_code":"eCrjWwDVAl"},"base":{"log_i_d":"AC0CT9TCCw","caller":"7bucBjNH6Y","addr":"hCKxGFmnod","client":"zNe97WfOrQ","traffic_env":{"open":false,"env":"9LTu2sNP2T"},"extra":{"14IJy4HIWm":"fnNptiq5ZU"}},"applicable_resource":{"resources":[{"rate_plan_id":"L7wS05c3OR","rate_plan_status":7857824168938927935}]}}'
响应参数
Body展开全部子属性
dataStruct
展开子属性
extraStruct
展开子属性
响应示例
正常响应示例异常响应示例
{ "extra": { "error_code": 0, "description": "", "sub_error_code": 0, "sub_description": "", "logid": "2024120501181190E7E177050EF6767A61", "now": 1733332691 }, "base_resp": { "extra": { "iRdXjz9iQr": "D1kiGqhH4z" }, "status_message": "axhsmMSLnz", "status_code": 310618265191215700 }, "data": { "promotion_id": "cGrNK5nLyB", "status": 1, "message_detail": [ { "error_message": "60MLtorFXs", "rate_plan_id": "ap8DolnR4E" } ], "error_code": 0, "description": "" } }
切换单列布局
错误码
HTTP 状态码 | 错误码 | 错误码描述 | 排查建议 |
---|---|---|---|
200 | 2100001 | 未知错误 | 重试接口,重试3次仍报错联系抖音生活服务技术支持 |
200 | 2100004 | 系统繁忙,此时请开发者稍候再试 | 重试接口,重试3次仍报错联系抖音生活服务技术支持 |
200 | 2100005 | 参数不合法 | 更换参数 |
200 | 2190002 | access_token无效 | 调用接口重新生成access_token |
200 | 2190004 | 应用未获得该能力, 请去https://open.douyin.com/申请 | 应用申请接口权限 |
200 | 2190008 | access_token过期,请刷新或重新授权 | 规范token刷新机制,检查是否有测试环境在同步刷新token |
200 | 2119001 | 参数不合法 | 更换参数 |
200 | 2119002 | 系统繁忙,请稍候再试 | 重试 |
200 | 2119003 | 请求太过频繁,请稍后再试 | 重试 |
200 | 2119005 | 应用未获商家授权 | 联系合作商家在商家后台发起授权,并在服务商后台同意授权 |
200 | 3000001 | 根据实际业务错误返回 | 对照接口文档规范参数并重试 |
200 | 4000001 | 根据实际业务错误返回 | 补充参数 |
200 | 4000002 | 根据实际业务错误返回 | 对照接口文档规范参数并重试 |
200 | 5000001 | 根据实际业务错误返回 | 联系抖音处理 |
200 | 5000001 | 服务器打瞌睡了,请稍后再试。 | |
200 | 3000001 | 以实际错误信息为准 |
点击纠错