更新房型售卖规则

一、接口名称:

setRoomSaleRule

测试环境 http://m.fat.ctripqa.com/restapi/soa2/13353/setRoomSaleRule

生产环境 http://m.ctrip.com/restapi/soa2/13353/setRoomSaleRule

二、输入参数:

父节点 名称 编码 类型 必填 描述
请求者信息 requestor
requestor 版本号 invoker string
requestor 操作人名称 operatorName string
requestor 操作IP opClientIP string
requestor 用户ID userId int
requestor 语言 languageType string
供应商ID supplierId int
子酒店ID hotelId int
RoomTypeList 售卖房型ID roomTypeId long
售卖房型名称 RoomTypeName string 用于记录日志
SaleRuleList 渠道规则列表
渠道 ChannelType string ctrip,qunar, channela(分销A),b2b
Ctrip渠道专用
是否修改最晚预订时间 isSetLastBookTime bool true为修改,false为不改,传具体值
提前几天 lastBookDay int isSetLastBookTime是true时才用
支持设置Ctrip凌晨房,传入-1代表设置凌晨售卖昨日房; 请不要超过180,超过180则按照180天设置!)
提前几天的几点 lastBookTime string isSetLastBookTime是true时才用,小时数,
lastBookDay=2,lastBookTime="12",表示2天前的12点之前才可预订,
lastBookDay>=0时,值支持1~24,
, lastBookDay=-1(凌晨房时),支持1~7
是否修改最晚立即确认时间 isSetLastConfirmTime bool true为修改,false为不改,传具体值
提前几天 lastConfirmDay int isSetLastConfirmTime为true时才用,范围为0-180,超过180则按照180天设置
提前几天的几点 lastConfirmTime string isSetLastConfirmTime为true时才用,时间点 1-24,lastConfirmDay=2,lastConfirmTime="12",表示2天前的12点之前才可立即确认
只有一条,checkInDay天前的checkInTime点前免费取消,逾期扣款deductType2。
是否修改取消规则 isSetCancel bool true为修改,false为不改,传具体值
是否可取消 canCancel bool isSetCancel=true时才用,true为可取消, false为不可取消
提前几天取消 checkInDay int isSetCancel=true,canCancel=true时才用, 0~999天
几天前的几点前取消 checkInTime string "00:00"~"23:00"
是否修改提前售卖限制 deductType2 int 逾期扣款规则,1扣全款,2(扣首晚)
非Ctrip渠道专用
是否修改售卖时段 isSetSaleTime bool true为修改,false为不改,传具体值
开始售卖时间点 startTime string isSetSaleTime=true时才用,最小单位是分钟,从"00:00" - "23:59"
结束售卖时间点 endTime string isSetSaleTime=true时才用,最小单位是分钟,从"00:00" - "23:59"
结束售卖时间点是当日还是次日 endDateType int isSetSaleTime=true时才用,
0是当日,1是次日,
0时,startTime 必须小于endTime,
1时,startTime 必须大于endTime
是否修改提前售卖限制 isSetLimit bool true为修改,false为不改,传具体值
是否限制提前预售时间 limitType int isSetLimit=true时才用,限制类型:1 限制 0 不限制
提前天数 advanceDay int isSetSaleTime=true,limitType=1时才用,围0~180(请不要超过180,超过180则按照180天设置!)
提前时间点数 advanceTime string isSetSaleTime=true,limitType=1时才用,"00:00"-"24:00
可有2条,checkInDay天前的几点前checkInTime取消,扣款deductType; checkInDay2天前的checkInTime2点前取消,扣款deductType2;第二条时间要晚于第一条时间
是否修改取消规则 isSetCancel bool true为修改,false为不改,传具体值
是否可取消 canCancel bool isSetCancel=true时才用,true为可取消, false为不可取消
提前几天取消 checkInDay int isSetCancel=true,canCancel=true时才用, 0~999天
几天前的几点前取消 checkInTime string "00:00"~"24:00"
是否修改提前售卖限制 deductType int 0(不扣款),2(扣首晚),3(按百分比扣款)
提前几天取消 deductProportion int deductType=3(按百分比扣款时才用) 1~99,50时表示 50%
提前几天取消 checkInDay2 int 0~999天,必须小于 checkInDay
几天前的几点前取消 checkInTime2 string "00:00"~"23:00"
是否修改提前售卖限制 deductType2 int 0(不扣款),2(扣首晚),3(按百分比扣款)
提前几天取消 deductProportion2 int deductType=3(按百分比扣款时才用) 1~99,50时表示 50%
渠道通用
是否修改渠道间跟价 isSetAutoChange bool true为修改,false为不改,传具体值
是否跟价 autoChange bool isSetSaleTime=true时才用,true为跟价,false为不跟
跟价计算符 formula int isSetAutoChange=true,autoChange=true时才用,1:加 2:减 3:乘 4:除
跟价计算值 modifyValue double isSetSaleTime=true时才用,
值为参与计算的数值
价格基准渠道 baseChannel string 跟哪个渠道的价格, ctrip,quanr, channela,b2b,purchase(采购价)不传为 跟采购渠道,

示例

{

        "supplierId":0,
        "hotelId":0,
        "RoomTypeList":[
            {
                "RoomTypeId":0,
                "RoomTypeName":"string"
            }
        ],
        "SaleRuleList":[
            {
                "ChannelType":"string",
                "IsSetSaleTime":false,
                "StartTime":"string",
                "EndTime":"string",
                "EndDateType":0,
                "IsSetLimit":false,
                "LimitType":0,
                "AdvanceDay":0,
                "AdvanceTime":"string",
                "AdvanceType":0,
                "IsSetLast":false,
                "MinLastDay":0,
                "MaxLastDay":0,
                "IsSetBookRoomNum":false,
                "MinBookRoomNum":0,
                "MaxBookRoomNum":0,
                "IsSetCancel":false,
                "CanCancel":false,
                "CheckInDay":0,
                "CheckInTime":"string",
                "DeductType":0,
                "DeductProportion":0,
                "CheckInDay2":0,
                "CheckInTime2":"string",
                "DeductType2":0,
                "DeductProportion2":0,
                "IsSetAutoChange":false,
                "AutoChange":false,
                "Formula":0,
                "ModifyValue":0,
                "baseChannel":"string",
                "IsSetLastBookTime":false,
                "LastBookDay":0,
                "LastBookTime":"string",
                "IsSetLastConfirmTime":false,
                "LastConfirmDay":0,
                "LastConfirmTime":"string"
            }
        ],
        "requestor":{
            "invoker":"string",
            "operatorName":"string",
            "opClientIP":"string",
            "userId":0,
            "languageType":"string"
        }

}

三、输出参数:

{
  "ResponseStatus": {
    "Timestamp": "/Date(1517993113714+0800)/",
    "Ack": "Success",
    "Errors": null,
    "Build": null,
    "Version": "v2",
    "Extension": null
  },
  "resultStatus": {
    "resultCode": 0, //0为成功,-1为失败
    "resultMsg": "" //发生错误时,显示错误信息
  }
}

results matching ""

    No results matching ""