文档中心 > API类目 > 飞猪-菲住联盟

alitrip.futurehotel.hotel.querybyname (根据酒店名称查询酒店列表)

根据酒店名称查询酒店列表

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
param_query_hotel_by_name_r_q QueryHotelByNameRq 可选 request
  • └ brand_id
  • Number
  • 可选
  • 1
  • 品牌id
  • └ city_id
  • Number
  • 可选
  • 330100
  • 城市id
  • └ city_name
  • String
  • 可选
  • 杭州市
  • 城市名称
  • └ group_id
  • Number
  • 可选
  • 222
  • 品牌id
  • └ name
  • String
  • 可选
  • 测试酒店
  • 酒店名称
  • └ trace_id
  • String
  • 可选
  • 123
  • tracerId

响应参数

名称 类型 示例值 描述
result QueryHotelByNameRs {} result
  • └ fh_code
  • String
  • 100000
  • 错误码
  • └ fh_msg
  • String
  • 系统异常
  • 错误信息
  • └ fh_success
  • Boolean
  • true
  • success
  • hotel_list
  • Hotel []
  • []
  • 酒店集合
  • └ addr_e
  • String
  • addr_e
  • 酒店英文地址
  • └ address
  • String
  • address
  • 酒店地址
  • └ ahid
  • Number
  • ahid
  • ahid
  • └ alias
  • String
  • alias
  • alias
  • amusement_facilities
  • Facility []
  • []
  • 酒店设施
  • └ name
  • String
  • 前台
  • 设施名称
  • └ option_list
  • String []
  • []
  • 设施服务
  • booking_notices
  • BookingNotice []
  • []
  • 预定须知
  • └ desc
  • String
  • 12:00入住
  • 描述
  • └ name
  • String
  • 入住时间
  • 名称
  • └ brand
  • String
  • 仟那
  • 品牌
  • └ brand_id
  • Number
  • 1
  • 品牌id
  • └ business_id_list
  • Number []
  • 1222
  • 商圈id
  • └ city_id
  • Number
  • 330100
  • 城市id
  • └ city_name
  • String
  • 杭州市
  • 城市名称
  • └ contact_man
  • String
  • 测试
  • 联系人名称
  • └ contact_phone
  • String
  • 12333
  • 联系电话
  • └ cooperation_status
  • Number
  • 1
  • 合作状态
  • └ decorate_time
  • String
  • 2018
  • 装修年份
  • └ desc_e
  • String
  • 12222
  • 英文描述
  • └ description
  • String
  • 33333
  • 描述
  • └ district_id
  • Number
  • 330101
  • └ district_name
  • String
  • 上城区
  • 行政区名称
  • └ extend
  • String
  • extend
  • extend
  • └ gmt_create
  • String
  • 2019-08-06 15:43:41
  • 创建时间
  • └ gmt_modified
  • String
  • 2019-08-06 15:43:41
  • 更新时间
  • └ group_id
  • Number
  • 1111
  • 集团id
  • hotel_facilities
  • Facility []
  • []
  • 酒店设施服务
  • └ name
  • String
  • 前台
  • 名称
  • └ option_list
  • String []
  • 24H
  • 服务
  • └ hotel_tags
  • Number []
  • 免佣
  • 酒店标签
  • └ id
  • Number
  • 111
  • 酒店id
  • └ latitude
  • String
  • 120.000000
  • 经度
  • └ level
  • String
  • 3
  • 酒店等级
  • └ longitude
  • String
  • 82.000000
  • 经度
  • └ name
  • String
  • 测试酒店
  • 酒店名称
  • └ name_e
  • String
  • name_e
  • 酒店英文名
  • └ opening_time
  • String
  • 2018
  • 开业年份
  • └ outer_hotel_id
  • String
  • 3333222
  • outer_hotel_id
  • pics
  • Pic []
  • []
  • 图片
  • └ head_image
  • Number
  • 1
  • 是否酒店头图
  • └ image_id
  • Number
  • 2222
  • 图片id
  • └ room_id
  • Number
  • 1234
  • 房型id
  • └ room_name
  • String
  • 特价房
  • 房型名称
  • └ status
  • Number
  • 1
  • 状态
  • └ tag
  • Number
  • 免佣
  • 酒店标签
  • └ upload_time
  • String
  • 2021-6-8 21:12:15
  • 上传时间
  • └ url
  • String
  • 1111
  • 图片url
  • └ poi_id_list
  • Number []
  • 123
  • poi热点信息
  • └ postal_code
  • String
  • 330100
  • 邮编
  • └ province_id
  • Number
  • 330000
  • 省id
  • └ reviews
  • Number
  • 好评
  • 评论
  • room_facilities
  • Facility []
  • []
  • 房间设施
  • └ name
  • String
  • 室内WiFi
  • 设施服务名称
  • └ option_list
  • String []
  • []
  • 是否提供服务
  • └ rooms
  • Number
  • 5
  • 房间数
  • └ sales
  • Number
  • 1000
  • 销量
  • └ score
  • String
  • 5.0
  • 酒店评分
  • service_facilities
  • Facility []
  • []
  • 酒店服务
  • └ name
  • String
  • 免费停车
  • 设施服务名称
  • └ option_list
  • String []
  • []
  • 是否提供服务
  • └ shid
  • Number
  • 12222
  • 标准酒店id
  • └ status
  • Number
  • 1
  • 状态
  • └ storeys
  • String
  • 5-10
  • 楼层信息
  • └ tags
  • String
  • 商务
  • 标签
  • └ taobao_outer_id
  • String
  • taobaoOuterId
  • taobaoOuterId
  • └ tel
  • String
  • 110000110
  • 电话
  • └ type
  • String
  • 商务
  • 类型

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AlitripFuturehotelHotelQuerybynameRequest req = new AlitripFuturehotelHotelQuerybynameRequest();
AlitripFuturehotelHotelQuerybynameRequest.QueryHotelByNameRq obj1 = new AlitripFuturehotelHotelQuerybynameRequest.QueryHotelByNameRq();
obj1.setBrandId(1L);
obj1.setCityId(330100L);
obj1.setCityName("杭州市");
obj1.setGroupId(222L);
obj1.setName("测试酒店");
obj1.setTraceId("123");
req.setParamQueryHotelByNameRQ(obj1);
AlitripFuturehotelHotelQuerybynameResponse rsp = client.execute(req);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<alitrip_futurehotel_hotel_querybyname_response>
    <result>
        <fh_code>100000</fh_code>
        <fh_msg>系统异常</fh_msg>
        <fh_success>true</fh_success>
        <hotel_list>
            <hotel>
                <addr_e>addr_e</addr_e>
                <address>address</address>
                <ahid>ahid</ahid>
                <alias>alias</alias>
                <amusement_facilities>
                    <facility>
                        <name>前台</name>
                        <option_list>
                            <string>[]</string>
                        </option_list>
                    </facility>
                </amusement_facilities>
                <booking_notices>
                    <booking_notice>
                        <desc>12:00入住</desc>
                        <name>入住时间</name>
                    </booking_notice>
                </booking_notices>
                <brand>仟那</brand>
                <brand_id>1</brand_id>
                <business_id_list>
                    <number>1222</number>
                </business_id_list>
                <city_id>330100</city_id>
                <city_name>杭州市</city_name>
                <contact_man>测试</contact_man>
                <contact_phone>12333</contact_phone>
                <cooperation_status>1</cooperation_status>
                <decorate_time>2018</decorate_time>
                <desc_e>12222</desc_e>
                <description>33333</description>
                <district_id>330101</district_id>
                <district_name>上城区</district_name>
                <extend>extend</extend>
                <gmt_create>2019-08-06 15:43:41</gmt_create>
                <gmt_modified>2019-08-06 15:43:41</gmt_modified>
                <group_id>1111</group_id>
                <hotel_facilities>
                    <facility>
                        <name>前台</name>
                        <option_list>
                            <string>24H</string>
                        </option_list>
                    </facility>
                </hotel_facilities>
                <hotel_tags>
                    <number>免佣</number>
                </hotel_tags>
                <id>111</id>
                <latitude>120.000000</latitude>
                <level>3</level>
                <longitude>82.000000</longitude>
                <name>测试酒店</name>
                <name_e>name_e</name_e>
                <opening_time>2018</opening_time>
                <outer_hotel_id>3333222</outer_hotel_id>
                <pics>
                    <pic>
                        <head_image>1</head_image>
                        <image_id>2222</image_id>
                        <room_id>1234</room_id>
                        <room_name>特价房</room_name>
                        <status>1</status>
                        <tag>免佣</tag>
                        <upload_time>2021-6-8 21:12:15</upload_time>
                        <url>1111</url>
                    </pic>
                </pics>
                <poi_id_list>
                    <number>123</number>
                </poi_id_list>
                <postal_code>330100</postal_code>
                <province_id>330000</province_id>
                <reviews>好评</reviews>
                <room_facilities>
                    <facility>
                        <name>室内WiFi</name>
                        <option_list>
                            <string>[]</string>
                        </option_list>
                    </facility>
                </room_facilities>
                <rooms>5</rooms>
                <sales>1000</sales>
                <score>5.0</score>
                <service_facilities>
                    <facility>
                        <name>免费停车</name>
                        <option_list>
                            <string>[]</string>
                        </option_list>
                    </facility>
                </service_facilities>
                <shid>12222</shid>
                <status>1</status>
                <storeys>5-10</storeys>
                <tags>商务</tags>
                <taobao_outer_id>taobaoOuterId</taobao_outer_id>
                <tel>110000110</tel>
                <type>商务</type>
            </hotel>
        </hotel_list>
    </result>
</alitrip_futurehotel_hotel_querybyname_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

返回
顶部