文档中心 > API类目 > 酒店商品API

taobao.xhotel.distribution.feed.hotel.query (飞猪酒店分销-静态信息-酒店-查询)

飞猪酒店分销-静态信息-酒店-查询

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
feed_hotel_query FeedHotelQuery 必须 查询条件
  • └ after_modified_time
  • String
  • 可选
  • 2013-12-01 00:00:00
  • 最后更新时间
  • └ language
  • String
  • 必须
  • cn
  • 标准语言ISO_639-1 二字码;例如:cn,en
page_request PageRequest 必须 分页配置
  • └ size
  • Number
  • 可选
  • 100
  • 分页_size
  • └ page
  • Number
  • 可选
  • 1
  • 分页_页数

响应参数

名称 类型 示例值 描述
trace_id String 2127f0c417024824014503859e2dd2 traceId
data PageableContent 分页结果
  • data
  • Hotel []
  • 酒店列表
  • └ rooms
  • Number
  • 10
  • 酒店房间数
  • └ position_type
  • String
  • GaoDe
  • 经纬度来源,Google:谷歌地图;GaoDe:高德
  • └ minimum_guest_age
  • String
  • 1
  • 最小入住年龄
  • └ latitude
  • String
  • 30.269311
  • 酒店经纬度-纬度
  • └ description
  • String
  • 这是一个美丽的酒店,距离机场xxx公里
  • 酒店描述
  • └ remark
  • String
  • 酒店不提供一次性洗漱用品
  • 酒店提醒
  • └ city_id
  • String
  • 654300
  • 城市ID
  • └ country_id
  • String
  • 1
  • 国家ID
  • pictures
  • FeedPicture []
  • 图片列表
  • └ id
  • String
  • 391391725
  • 图片id
  • └ url
  • String
  • //img.alicdn.com/imgextra/i1/6000000005240/O1CN01N8k0Ud1oZyBSnB3UV_!!6000000005240-0-hotel.jpg
  • 图片地址
  • └ desc
  • String
  • xxx
  • 图片描述
  • └ city_name
  • String
  • 阿勒泰地区
  • 城市名称
  • └ tel
  • String
  • ##17374899426,0086#0906#2888889
  • 酒店联系电话
  • └ longitude
  • String
  • 119.950899
  • 酒店经纬度-经度
  • └ address
  • String
  • 地址
  • 酒店地址
  • └ star
  • String
  • 4
  • 星级
  • └ check_in_time
  • String
  • 12:00
  • checkIn时间
  • └ hotel_id
  • String
  • 55104001
  • 酒店ID
  • └ hotel_name
  • String
  • xxx酒店
  • 酒店名称
  • └ check_out_time
  • String
  • 12:00
  • checkout 时间
  • └ country_name
  • String
  • China
  • 国际名称
  • facilities
  • FeedFacility []
  • 酒店设施
  • └ name
  • String
  • 1
  • 设施名称
  • └ description
  • String
  • xxxx
  • 设施描述
  • └ id
  • String
  • 333519399
  • 设施id
  • └ status
  • Number
  • 0
  • 酒店状态0:下线 ,1:上线
  • └ page_index
  • Number
  • 2
  • pageIndex
  • └ page_size
  • Number
  • 10
  • pageSize

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
XhotelDistributionFeedHotelQueryRequest req = new XhotelDistributionFeedHotelQueryRequest();
XhotelDistributionFeedHotelQueryRequest.FeedHotelQuery obj1 = new XhotelDistributionFeedHotelQueryRequest.FeedHotelQuery();
obj1.setAfterModifiedTime("2013-12-01 00:00:00");
obj1.setLanguage("cn");
req.setFeedHotelQuery(obj1);
XhotelDistributionFeedHotelQueryRequest.PageRequest obj2 = new XhotelDistributionFeedHotelQueryRequest.PageRequest();
obj2.setSize(100L);
obj2.setPage(1L);
req.setPageRequest(obj2);
XhotelDistributionFeedHotelQueryResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<xhotel_distribution_feed_hotel_query_response>
    <trace_id>2127f0c417024824014503859e2dd2</trace_id>
    <data>
        <data>
            <hotel>
                <rooms>10</rooms>
                <position_type>GaoDe</position_type>
                <minimum_guest_age>1</minimum_guest_age>
                <latitude>30.269311</latitude>
                <description>这是一个美丽的酒店,距离机场xxx公里</description>
                <remark>酒店不提供一次性洗漱用品</remark>
                <city_id>654300</city_id>
                <country_id>1</country_id>
                <pictures>
                    <feed_picture>
                        <id>391391725</id>
                        <url>//img.alicdn.com/imgextra/i1/6000000005240/O1CN01N8k0Ud1oZyBSnB3UV_!!6000000005240-0-hotel.jpg</url>
                        <desc>xxx</desc>
                    </feed_picture>
                </pictures>
                <city_name>阿勒泰地区</city_name>
                <tel>##17374899426,0086#0906#2888889</tel>
                <longitude>119.950899</longitude>
                <address>地址</address>
                <star>4</star>
                <check_in_time>12:00</check_in_time>
                <hotel_id>55104001</hotel_id>
                <hotel_name>xxx酒店</hotel_name>
                <check_out_time>12:00</check_out_time>
                <country_name>China</country_name>
                <facilities>
                    <feed_facility>
                        <name>1</name>
                        <description>xxxx</description>
                        <id>333519399</id>
                    </feed_facility>
                </facilities>
                <status>0</status>
            </hotel>
        </data>
        <page_index>2</page_index>
        <page_size>10</page_size>
    </data>
</xhotel_distribution_feed_hotel_query_response>

异常示例

  • XML示例
  • JSON示例
<error_response>
    <code>50</code>
    <msg>Remote service error</msg>
    <sub_code>isv.invalid-parameter</sub_code>
    <sub_msg>非法参数</sub_msg>
</error_response>

错误码解释

错误码 错误描述 解决方案

API工具

如何获得此API

FAQ

返回
顶部