Class: countries

countries(domainOrOptionsopt)

new countries(domainOrOptionsopt)

Parameters:
Name Type Attributes Description
domainOrOptions string | object <optional>
The project domain or options object. If object, see the object's optional properties.
Properties
Name Type Attributes Description
domain string <optional>
The project domain
token object <optional>
auth token - object with value property and optional headerOrQueryName and isQuery properties
Source:

Methods

getCountries(marketId, regionTypeId, regionName, sort, order)

Retrieves summary country information for the provided marketId and filters
Parameters:
Name Type Description
marketId string MarketId in which the request is being made, and for which responses should be localized
regionTypeId integer Restrict countries to this region type; required if regionName is supplied
regionName string Restrict countries to this region name; required if regionTypeId is supplied
sort string The term to sort the result countries by.
order string The direction to sort the result countries by.
Source:

getCountry(countryKey, marketId, sort, order)

Retrieves country and summary state information for provided countryKey
Parameters:
Name Type Description
countryKey string The country key
marketId string MarketId in which the request is being made, and for which responses should be localized
sort string The term to sort the result country states by.
order string The direction to sort the result country states by.
Source:

setToken(value, headerOrQueryName, isQuery)

Set Token
Parameters:
Name Type Description
value string token's value
headerOrQueryName string the header or query name to send the token at
isQuery boolean true if send the token as query param, otherwise, send as header param
Source: