This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
ors-soap-api:public:trips [2015/12/23 08:32] admin [Return parameters] |
ors-soap-api:public:trips [2019/07/15 10:01] (current) admin [Examples] |
||
|---|---|---|---|
| Line 15: | Line 15: | ||
| <code php> | <code php> | ||
| - | public array trips( array $searchData, array $headerData, boolean $cleanUrl = true, $topOffersFilter = array()) | + | public array trips( array $searchData, array $headerData, $topOffersFilter = array(), boolean $cleanUrl = true) |
| </code> | </code> | ||
| Line 183: | Line 183: | ||
| ( | ( | ||
| [AI] => all inclusive | [AI] => all inclusive | ||
| - | ) | ||
| - | |||
| - | ) | ||
| - | |||
| - | [ppc] => Array | ||
| - | ( | ||
| - | [selected] => 0 | ||
| - | [val] => Array | ||
| - | ( | ||
| - | [192] => 192 | ||
| - | [1015] => 1015 | ||
| ) | ) | ||
| Line 210: | Line 199: | ||
| ) | ) | ||
| + | [rfilters] => Array | ||
| + | ( | ||
| + | [ppc] => "192-1015" | ||
| + | ) | ||
| + | | ||
| [sorts] => Array | [sorts] => Array | ||
| ( | ( | ||
| Line 287: | Line 281: | ||
| * ''cppc'' : catalog price (if cppc is grater then zero, then this is information about catalog price -- without discounts) | * ''cppc'' : catalog price (if cppc is grater then zero, then this is information about catalog price -- without discounts) | ||
| * ''ahc'' : departure airport (IATA code) | * ''ahc'' : departure airport (IATA code) | ||
| + | * ''zhc'' : arrival airport (IATA code) | ||
| * ''sid'' : entry point ID (only for ''trips'' content type) | * ''sid'' : entry point ID (only for ''trips'' content type) | ||
| * ''sin'' : entry point name (only for ''trips'' content type) | * ''sin'' : entry point name (only for ''trips'' content type) | ||
| Line 293: | Line 288: | ||
| * **0** : trip is cancelled | * **0** : trip is cancelled | ||
| * **3** : trip is almost guaranteed | * **3** : trip is almost guaranteed | ||
| + | * **4** : trip is finished | ||
| * else : trip has no status | * else : trip has no status | ||
| * ''url'' : a suggested URL with search parameters for [[check|check method]] | * ''url'' : a suggested URL with search parameters for [[check|check method]] | ||
| Line 305: | Line 301: | ||
| * ''ahc'' : filters by departure airport (only for ''pauschall'', ''charter'', and ''oneway'' content types | * ''ahc'' : filters by departure airport (only for ''pauschall'', ''charter'', and ''oneway'' content types | ||
| * ''alt'' : filters alternative trips | * ''alt'' : filters alternative trips | ||
| + | * ''rfilters (array)'' : range filters | ||
| * ''ppc'' : filters by price per person | * ''ppc'' : filters by price per person | ||
| * ''sorts (array)'' : possible sorting | * ''sorts (array)'' : possible sorting | ||
| Line 355: | Line 352: | ||
| 'tdc' => '2', // filter by duration (display only trips with duration 2 nigths) | 'tdc' => '2', // filter by duration (display only trips with duration 2 nigths) | ||
| 'vnd' => '20140903' // filter by checkin date (display only trips that starts on 3rd Sep. 2014) | 'vnd' => '20140903' // filter by checkin date (display only trips that starts on 3rd Sep. 2014) | ||
| + | ), | ||
| + | 'rfilter' => array( | ||
| + | 'ppc' => '50-100' // filter by price range | ||
| ) | ) | ||
| ); | ); | ||
| Line 401: | Line 401: | ||
| $trips = $soapClient->orsxml_hotel_api_call( 'trips', $searchParams, $header ); | $trips = $soapClient->orsxml_hotel_api_call( 'trips', $searchParams, $header ); | ||
| + | </code> | ||
| + | |||
| + | ===== JSON Examples ===== | ||
| + | |||
| + | @see [[ors-soap-api:public:json_api]] how to post request. | ||
| + | |||
| + | <code php> | ||
| + | { | ||
| + | "requestType" : "search", | ||
| + | "action": "trips", | ||
| + | "search": { | ||
| + | "typ": "hotel", | ||
| + | "vnd": "2018-01-10", | ||
| + | "bsd": "2018-03-10", | ||
| + | "tdc": "1-5", | ||
| + | "gid": "15257", | ||
| + | "epc": "2" | ||
| + | }, | ||
| + | "top" : { | ||
| + | "toc" : "FTI" | ||
| + | }, | ||
| + | "header": { | ||
| + | "lang": "[lang]", | ||
| + | "usr" : "[usr]", | ||
| + | "pass": "[pass]", | ||
| + | "agid": "[agid]" | ||
| + | } | ||
| + | } | ||
| </code> | </code> | ||