The VMS API provides flexible language localization for returned data, allowing you to tailor the language of responses according to your needs.
To control the language used for displayed information – including error messages and other localized resources – the API supports a special hl (host language) parameter, which should be specified individually for each request.
Use one of the following ways to specify a relevant output language:
-
Use the
hlHTTP Header
Include the relevant locale in thehlheader of your request.
Example:Hl: en -
Use the
hlparameter in query string or request body
You can also pass thehlparameter either in the query stringquery paramsor in the request body. You can pass thehlparameters directly in the URL-request.
Example:GEThttps://your.domain/api/v1/items?hl=en.
Priority. If you provide the hl parameter in both the request body (or query parameters) and the HTTP header, the value specified in the HTTP header will take priority.
-
If you don't use the methods mentioned above, the localization will be set to the default language.To find out which languages are supported, you can get a list of available locales from the API response, which is often provided in a field like
available_locales.