提供给商家,查询汽车票班次余票
名称 | 类型 | 是否必须 | 示例值 | 更多限制 | 描述 |
---|---|---|---|---|---|
top_query_seat_rq | TopQuerySeatRq | 必须 | 查询参数 | ||
|
名称 | 类型 | 示例值 | 描述 |
---|---|---|---|
service_price | Number | 200 | 服务费 |
price | Number | 8000 | 票价单位分 |
dep_time | String | 08:00 | 出发时间 HH:mm |
stock | Number | 30 | 库存 |
dep_date | String | 2025-03-19 | 出发日期 yyyy-MM-dd |
status | Number | 1 | 状态 |
bus_number_id | String | 129841026905121 | 班次id-短-仅作展示使用 |
half_price | Number | 2000 | 半价票,单位分 |
bus_type | String | 大巴车 | 车型 |
dep_std_station_name | String | 南京火车站 | 出发车站名称 |
arr_std_station_name | String | 杭州火车站 | 到达车站名称 |
item_unique_key | String | ITEM_UNIQUE_KEY_001 | 班次唯一键 |
route_key | String | ROUTE_KEY_001 | routeKey |
shift_type | Number | 0 | 是否流水班(固定班次=0,流水班次=1) |
last_dep_time | String | 09:00 | 最晚发车时间,HH:mm |
extra_schedule | Boolean | false | 是否加班车 |
refund_rule | String | 退票规则 | jsong格式数据 |
refund_time | Number | 30 | 开车前多少分钟可以退票-实际场景中可能值为负数 |
is_refund | Boolean | true | 是否可退票 |
refund_mode | Number | 1 | 退票模式 1:按单退 2 按票退 |
support_child | Boolean | true | 是否支持儿童票 |
support_with_child | Boolean | false | 是否支持携童票 |
with_child_stock | Number | 12 | 携童票库存 |
support_ele_ticket | Boolean | true | 是否支持携童票 |
max_sell_num | Number | 5 | 一单最大售票数量 |
spend_time | String | 50 | 耗时(单位分钟) |
distance | Number | 10 | 里程(单位:km) |
result_code | String | SYS_ERROR | 错误码 |
result_msg | String | 系统异常 | 错误信息 |
is_success | Boolean | true | 是否成功 |
1 2 3 4 5 6 7 | TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret); BusSeatpriceGetRequest req = new BusSeatpriceGetRequest(); BusSeatpriceGetRequest.TopQuerySeatRq obj1 = new BusSeatpriceGetRequest.TopQuerySeatRq(); obj1.setItemUniqueKey( "827817551201061" ); req.setTopQuerySeatRq(obj1); BusSeatpriceGetResponse rsp = client.execute(req, sessionKey); System.out.println(rsp.getBody()); |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | < bus_seatprice_get_response > < service_price >200</ service_price > < price >8000</ price > < dep_time >08:00</ dep_time > < stock >30</ stock > < dep_date >2025-03-19</ dep_date > < status >1</ status > < bus_number_id >129841026905121</ bus_number_id > < half_price >2000</ half_price > < bus_type >大巴车</ bus_type > < dep_std_station_name >南京火车站</ dep_std_station_name > < arr_std_station_name >杭州火车站</ arr_std_station_name > < item_unique_key >ITEM_UNIQUE_KEY_001</ item_unique_key > < route_key >ROUTE_KEY_001</ route_key > < shift_type >0</ shift_type > < last_dep_time >09:00</ last_dep_time > < extra_schedule >false</ extra_schedule > < refund_rule >退票规则</ refund_rule > < refund_time >30</ refund_time > < is_refund >true</ is_refund > < refund_mode >1</ refund_mode > < support_child >true</ support_child > < support_with_child >false</ support_with_child > < with_child_stock >12</ with_child_stock > < support_ele_ticket >true</ support_ele_ticket > < max_sell_num >5</ max_sell_num > < spend_time >50</ spend_time > < distance >10</ distance > < result_code >SYS_ERROR</ result_code > < result_msg >系统异常</ result_msg > < is_success >true</ is_success > </ bus_seatprice_get_response > |
1 2 3 4 5 6 | < error_response > < code >50</ code > < msg >Remote service error</ msg > < sub_code >isv.invalid-parameter</ sub_code > < sub_msg >非法参数</ sub_msg > </ error_response > |
错误码 | 错误描述 | 解决方案 |
---|