Internationalization¶
Encoding¶
The G Adventures API is UTF-8 encoded for both requests and responses. Request
headers with an Accept-Charset
set to anything other than utf-8 will be
rejected with an HTTP status code of 406
.
Language¶
In addition to English, the G Adventures API currently supports the German language. However, it doesn’t necessarily mean that all of the content is translated to German. When there is no translation for a specific piece of content in the language requested, we fall back to English.
To request content in German, you can set the Accept-Language: de
HTTP header when making requests to the API.
If no Accept-Language
is specified, then en
will be assumed.
If an Accept-Language
value is provided for searchable/listable resources and there are no matches found for the requested language, then GAPI will fallback to searching the English data index to try and return a matching response.
Dates & Times¶
Most dates returned by the G Adventures API will be in UTC and formatted using the ISO 8601 standard: YYYY-MM-DD for dates and YYYY-MM-DDThh:mm:ssZ for times. It is the responsibility of the client to perform the calculation to display local dates and times.
Any exceptions that are missing the UTC designator (“Z”) are considered to be local time of where the product starts/finishes.
Currencies & Prices¶
All prices returned by the G Adventures API are formatted as strings. It is the responsibility of the client to localize prices.
Any time a currency is returned by the G Adventures API, a full list of all currencies supported by G Adventures will be provided. Supported currencies are:
AUD
CAD
CHF
CNY
EUR
GBP
HKD
INR
JPY
KRW
NZD
SGD
USD
ZAR