简要描述:

  • 创建订单

请求URL:

  • createOrder

请求参数:

此数据为业务数据,作为调用参数中data字段的内容。

订单信息表 data

参数名 是否必须 类型 说明
LineId int 线路ID
TeamId string(50) 团Id,当线路分类LineCate=1时,TeamId请填写开团日期(Date)
AdultCount int 成人人数,没有请填写0,人数必须于游客列表中的成人人数一致(对应游客信息中的TouristType=1)
ElderCount int 长者人数,没有请填写0,人数必须于游客列表中的长者人数一致(对应游客信息中的TouristType=4)
ChildCount int 小童人数,没有请填写0,人数必须于游客列表中的小童人数一致(对应游客信息中的TouristType=2)
AdultNoBedCount int 成人不占床人数,没有请填写0,人数必须于游客列表中的成人不占床人数一致(对应游客信息中的TouristType=5)
ElderNoBedCount int 长者不占床人数,没有请填写0,人数必须于游客列表中的长者不占床人数一致(对应游客信息中的TouristType=7)
ChildNoBedCount int 小童不占床人数,没有请填写0,人数必须于游客列表中的小童不占床人数一致(对应游客信息中的TouristType=6)
BabyCount int 婴儿人数,没有请填写0,人数必须于游客列表中的婴儿人数一致(对应游客信息中的TouristType=3)
SingleRoomCount int 单房差数,没有请填写0
ContactName string(50) 联系人姓名
ContactMobile string(20) 联系人电话
ContactEmail string(50) 联系人Email
StartTime string(50) 出发日期(团的出发日期),格式(yyyy-MM-dd)
SaleId int 销售员ID
Remark string(64) 备注,此字段只有B2B的产品才有效
Distributors string(100) api接入方的分销商信息,此字段只有B2B的产品才有效
SaleInfo string(100) api接入商的销售员信息,此字段只有B2B的产品才有效
ExtendedField string 扩展字段,此字段只有B2B的产品才有效
ReserveId int 预留位Id
TouristList List< Tourist> 游客列表
AbatePolicy List< Promotional> 优惠政策
AbateAmount decimal 优惠金额
TripDate datetime 出行日期
TrafficInfo string(100) 交通信息 航班号\高铁班次
PayType string(32) 支付方式 BBMSL,Allinpay
PayAmount decimal 支付金额

游客信息表Tourist

参数名 是否必须 类型 说明
CustName string(20) 游客姓名
RightsCardNo string(50) 权益卡卡号
Firstname string 英文名的名,Firstname+’ ‘+Lastname的长度为32
Lastname string 英文名的姓,Firstname+’ ‘+Lastname的长度为32
SexType int 性别:1男,2女
TouristType int 游客类型:1成才,2小童,3婴儿,4长者,5成人不占床,6小童不占床,7长者不占床
PaperType int 证件类型,LineCate为1,2,3时必填,1身份证,2护照,3军官证
PaperNum string(32) 证件号码
Tel string(20) 游客电话
VenueId int 集合地ID,没有可不填,此地段只有B2B的产品才有效
Title string 客人称谓(只有T2的才需要)
GuestCredential string 客人证件类型,LineCate为80,90,100时必填(公共代码=GUESTCREDENTIALTYPE)
InsuranceProId int 保险Id
TeamPrice decimal 团费
AttachItemName string 销售台附加项目名称
AttachItemPrice decimal 销售台附加项目价格
TeamOpenAddFeeIds int[] 附加费id列表

入参示例:

  1. {
  2. "apiKey" : "test1",
  3. "Apisecret" : "78FBB3D68B40A347644619ACF902CED3",
  4. "currentTimeStamp" : "20171128134215",
  5. "sign" : "147C2CEEC3C0F19A854A55B90F26DB8C",
  6. "uri": "http://localhost:39450/yjapi/createOrder",
  7. "data" :
  8. {
  9. "LineId" : 8657,
  10. "TeamId" : "1",
  11. "AdultCount" : 2,
  12. "ElderCount" : 0,
  13. "ChildCount" : 0,
  14. "AdultNoBedCount" : 0,
  15. "ElderNoBedCount" : 0,
  16. "ChildNoBedCount" : 0,
  17. "BabyCount" : 0,
  18. "SingleRoomCount": 0,
  19. "ContactName" : "张三",
  20. "ContactMobile" : "13254625625",
  21. "ContactEmail" : "abc@qq.com",
  22. "StartTime" : "2017-11-22",
  23. "SaleId" : 0,
  24. "Remark": "订单备注信息",
  25. "Distributors": "供应商",
  26. "SaleInfo": "销售员",
  27. "ExtendedField": "扩展字段",
  28. "ReserveId":null,
  29. "AbateAmount":null,
  30. "AbatePolicy":[
  31. {
  32. "PromoteMode":"1",
  33. "Start":"2",
  34. "ToEnd":null,
  35. "Reduce":"1",
  36. "TravelGuestType":"1",
  37. "ExceptBaby":false
  38. }
  39. ],
  40. "TouristList":
  41. [
  42. {
  43. "CustName" : "李四",
  44. "Firstname" : "",
  45. "Lastname" : "",
  46. "SexType" : "1",
  47. "TouristType" : "1",
  48. "PaperType" : "1",
  49. "PaperNum" : "4416521325252325",
  50. "Tel" : "13523252635"
  51. "VenueId" : 1,
  52. "Title" : "MS",
  53. "GuestCredential" : "IdentityCard",
  54. "InsuranceProId" : 5,
  55. "TeamOpenAddFeeIds" :
  56. [
  57. 34
  58. ]
  59. },
  60. {
  61. "CustName" : "王五",
  62. "Firstname" : "",
  63. "Lastname" : "",
  64. "SexType" : "2",
  65. "TouristType" : "1",
  66. "PaperType" : "1",
  67. "PaperNum" : "4412352562525231215",
  68. "Tel" : "13526252326"
  69. }
  70. ]
  71. }
  72. }

返回示例:

正确时返回:

  1. {
  2. "Code" : 0,
  3. "Success" : true,
  4. "Message" : "",
  5. "Data" : "1004456271"
  6. }

错误时返回:

  1. {
  2. "Code" : 100002,
  3. "Success" : false,
  4. "Message" : "应用认证错误",
  5. "Data" : ""
  6. }

返回参数说明:

参数名 是否必须 类型 说明
Success boolean 是否成功,成功返回true,失败返回false
Message String 错误信息,成功返回空
Data String 订单编号,成功返回订单编号,失败返回空

备注:

-