POST api/hotel/agentsys/prebook

预book

Request Information

URI Parameters

None.

Body Parameters

TC_HotelPreBookRQContract
NameDescriptionTypeAdditional information
lang

语言

string

None.

citycode

城市编码

string

None.

hotelcode

酒店编码

string

None.

checkindate

开始时间

date

None.

checkoutdate

结束时间

date

None.

nationality

国籍

string

None.

rooms

预定信息

Collection of TC_RoomTermContract

None.

searchsource

搜索来源(ts,sun)

string

None.

customersessionid

客户sessionid

string

None.

customeripaddress

客户Ip地址

string

None.

customeruseragent

客户浏览器信息

string

None.

authuser

用户身份信息

TC_UserContract

None.

Request Formats

application/json, text/json

Sample:
{
  "lang": "sample string 1",
  "citycode": "sample string 2",
  "hotelcode": "sample string 3",
  "checkindate": "2024-12-23T20:06:04.1351316+08:00",
  "checkoutdate": "2024-12-23T20:06:04.1351316+08:00",
  "nationality": "sample string 6",
  "rooms": [
    {
      "plansessionid": "sample string 1",
      "adultcount": 2,
      "infantcount": 3,
      "childages": [
        1,
        2
      ],
      "optionids": [
        "sample string 1",
        "sample string 2"
      ]
    },
    {
      "plansessionid": "sample string 1",
      "adultcount": 2,
      "infantcount": 3,
      "childages": [
        1,
        2
      ],
      "optionids": [
        "sample string 1",
        "sample string 2"
      ]
    }
  ],
  "searchsource": "sample string 9",
  "customersessionid": "sample string 10",
  "customeripaddress": "sample string 11",
  "customeruseragent": "sample string 12",
  "authuser": {
    "userid": "sample string 1",
    "password": "sample string 2"
  }
}

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'TC_HotelPreBookRQContract'.

Response Information

Resource Description

预book

ReturnResultOfTC_HotelPreBookRSContract
NameDescriptionTypeAdditional information
data

TC_HotelPreBookRSContract

None.

code

状态码:100成功,其他自定义

integer

None.

message

提示消息

string

None.

Response Formats

application/json, text/json

Sample:
{
  "data": {
    "prebookingtoken": "sample string 1",
    "roomid": "sample string 2",
    "roomname": "sample string 3",
    "bedtypes": [
      {
        "bedtypeid": "sample string 1",
        "bedtype": "sample string 2"
      },
      {
        "bedtypeid": "sample string 1",
        "bedtype": "sample string 2"
      }
    ],
    "ispackage": true,
    "hotelinfo": {
      "hotelcode": "sample string 1",
      "hotelname": "sample string 2",
      "hotelengname": "sample string 3",
      "longitude": "sample string 4",
      "latitude": "sample string 5",
      "rating": "sample string 6",
      "citycode": "sample string 7",
      "city": "sample string 8",
      "country": "sample string 9",
      "countrycode": "sample string 10",
      "regions": [
        {
          "regionid": "sample string 1",
          "region": "sample string 2"
        },
        {
          "regionid": "sample string 1",
          "region": "sample string 2"
        }
      ],
      "resort": "sample string 11",
      "address": "sample string 12",
      "streetnumber": "sample string 13",
      "postalcode": "sample string 14",
      "phone": [
        "sample string 1",
        "sample string 2"
      ],
      "fax": "sample string 15",
      "email": [
        "sample string 1",
        "sample string 2"
      ],
      "url": "sample string 16",
      "descript": "sample string 17",
      "location": "sample string 18",
      "catedescripts": [
        {
          "cateid": "sample string 1",
          "catename": "sample string 2",
          "content": "sample string 3"
        },
        {
          "cateid": "sample string 1",
          "catename": "sample string 2",
          "content": "sample string 3"
        }
      ],
      "classimages": [
        {
          "classid": "sample string 1",
          "classname": "sample string 2",
          "classimages": [
            {
              "title": "sample string 1",
              "url": "sample string 2",
              "descript": "sample string 3"
            },
            {
              "title": "sample string 1",
              "url": "sample string 2",
              "descript": "sample string 3"
            }
          ]
        },
        {
          "classid": "sample string 1",
          "classname": "sample string 2",
          "classimages": [
            {
              "title": "sample string 1",
              "url": "sample string 2",
              "descript": "sample string 3"
            },
            {
              "title": "sample string 1",
              "url": "sample string 2",
              "descript": "sample string 3"
            }
          ]
        }
      ],
      "roomtypes": [
        {
          "roomtypeid": "sample string 1",
          "roomtype": "sample string 2",
          "roomfacilitys": [
            {
              "facilityid": "sample string 1",
              "facility": "sample string 2",
              "notes": "sample string 3",
              "costinfo": "sample string 4"
            },
            {
              "facilityid": "sample string 1",
              "facility": "sample string 2",
              "notes": "sample string 3",
              "costinfo": "sample string 4"
            }
          ]
        },
        {
          "roomtypeid": "sample string 1",
          "roomtype": "sample string 2",
          "roomfacilitys": [
            {
              "facilityid": "sample string 1",
              "facility": "sample string 2",
              "notes": "sample string 3",
              "costinfo": "sample string 4"
            },
            {
              "facilityid": "sample string 1",
              "facility": "sample string 2",
              "notes": "sample string 3",
              "costinfo": "sample string 4"
            }
          ]
        }
      ],
      "hotelfacilitys": [
        {
          "facilityid": "sample string 1",
          "facility": "sample string 2",
          "notes": "sample string 3",
          "costinfo": "sample string 4"
        },
        {
          "facilityid": "sample string 1",
          "facility": "sample string 2",
          "notes": "sample string 3",
          "costinfo": "sample string 4"
        }
      ],
      "tripadvisorinfo": {
        "rating": 1.1,
        "ratingimgurl": "https://www.tripadvisor.com/img/cdsi/img2/ratings/traveler/1.1-52242-5.svg",
        "reviewcount": 2,
        "reviewurl": "sample string 3",
        "nearbyrestaurants": "sample string 4",
        "nearbyattractions": "sample string 5",
        "ranking": {
          "rankingno": "sample string 1",
          "rankingnumber": "sample string 2",
          "rankinglocation": "sample string 3",
          "rankingdescript": "sample string 4"
        },
        "awards": [
          {
            "awardtype": "sample string 1",
            "displayname": "sample string 2",
            "year": "sample string 3",
            "tinyimgurl": "sample string 4",
            "smallimgurl": "sample string 5",
            "largeimgurl": "sample string 6"
          },
          {
            "awardtype": "sample string 1",
            "displayname": "sample string 2",
            "year": "sample string 3",
            "tinyimgurl": "sample string 4",
            "smallimgurl": "sample string 5",
            "largeimgurl": "sample string 6"
          }
        ]
      }
    },
    "total": 5.0,
    "surchargetotal": 6.0,
    "hotelfees": [
      {
        "description": "sample string 1",
        "amount": 2.0,
        "currencty": "sample string 3"
      },
      {
        "description": "sample string 1",
        "amount": 2.0,
        "currencty": "sample string 3"
      }
    ],
    "surcharges": [
      {
        "type": "sample string 1",
        "amount": 2.0,
        "currencty": "sample string 3"
      },
      {
        "type": "sample string 1",
        "amount": 2.0,
        "currencty": "sample string 3"
      }
    ],
    "currency": "sample string 7",
    "canceldeadline": "2024-12-23T20:06:04.1663791+08:00",
    "includebreakfast": "sample string 13",
    "mealtype": "sample string 14",
    "iswifi": "sample string 15",
    "roompernights": [
      {
        "date": "sample string 1",
        "rate": 2.0,
        "currency": "sample string 3"
      },
      {
        "date": "sample string 1",
        "rate": 2.0,
        "currency": "sample string 3"
      }
    ],
    "additionals": [
      {
        "AdditionalId": "sample string 1",
        "Additional": "sample string 2"
      },
      {
        "AdditionalId": "sample string 1",
        "Additional": "sample string 2"
      }
    ],
    "cancellationpolicy": "sample string 16",
    "checkininstructions": "sample string 17",
    "specialcheckininstructions": "sample string 18",
    "acceptpaymentCard": [
      "sample string 1",
      "sample string 2"
    ]
  },
  "code": 1,
  "message": "sample string 2"
}