Locations
in package
A namespaced client for the "/v1/reference-data/locations" endpoints.
Access via the Amadeus client object.
$amadeus = Amadeus::builder("clientId", "secret")->build(); $amadeus->getReferenceData()->getLocations();
Table of Contents
- $airports : Airports
- A namespaced client for the "/v1/reference-data/locations/airports" endpoints.
- $amadeus : Amadeus
- $hotel : Hotel
- A namespaced client for the "/v1/reference-data/locations/hotel" endpoints.
- $hotels : Hotels
- A namespaced client for the "/v1/reference-data/locations/hotels" endpoints.
- __construct() : mixed
- get() : array<string|int, Location>
- Airport and City Search API
- getAirports() : Airports
- Get a namespaced client for the "/v1/reference-data/locations/airports" endpoints.
- getHotel() : Hotel
- Get a namespaced client for the "/v1/reference-data/locations/hotel" endpoints.
- getHotels() : Hotels
- Get a namespaced client for the "/v1/reference-data/locations/hotels" endpoints.
Properties
$airports
A namespaced client for the "/v1/reference-data/locations/airports" endpoints.
private
Airports
$airports
$amadeus
private
Amadeus
$amadeus
$hotel
A namespaced client for the "/v1/reference-data/locations/hotel" endpoints.
private
Hotel
$hotel
$hotels
A namespaced client for the "/v1/reference-data/locations/hotels" endpoints.
private
Hotels
$hotels
Methods
__construct()
public
__construct(Amadeus $amadeus) : mixed
Parameters
- $amadeus : Amadeus
Return values
mixed —get()
Airport and City Search API
public
get(array<string|int, mixed> $query) : array<string|int, Location>
Returns a list of airports and cities matching a given keyword.
$amadeus->getReferenceData()->getLocations()->get( ["keyword" => "PAR", "subType" => "CITY"] );
Parameters
- $query : array<string|int, mixed>
-
the parameters to send to the API
Tags
Return values
array<string|int, Location> —an API resource
getAirports()
Get a namespaced client for the "/v1/reference-data/locations/airports" endpoints.
public
getAirports() : Airports
Return values
Airports —getHotel()
Get a namespaced client for the "/v1/reference-data/locations/hotel" endpoints.
public
getHotel() : Hotel
Return values
Hotel —getHotels()
Get a namespaced client for the "/v1/reference-data/locations/hotels" endpoints.
public
getHotels() : Hotels