Country codes

GET https://app.ecwid.com/api/v3/{storeId}/countries?lang=en&withStates=true

Required access scopes

Your app doesn't need any specific access scopes to make this request.

Path params

All path params are required.

Param
Type
Description

storeId

number

Ecwid store ID.

Query params

All query params are optional.

Name
Type
Description

withStates

boolean

If true, adds states field for each country in the response.

lang

string

Language ISO code for translations in JSON response, e.g. en, fr. If not specified, response will be in English.

Headers

The Authorization header is optional. Request works the same way with or without access token.

Header
Format
Description

Authorization

Bearer secret_ab***cd

Access token of the application.

Response JSON

A JSON array of objects with the following fields:

Field
Type
Description

code

string

Two-digit country code in ISO 639-1.

name

string

Country name in the specified language.

states

object states

Details about states that beong to the country.

states

Field
Type
Description

code

string

Two-digit state code in ISO 639-1.

name

string

State name in the specified language.

Last updated

Was this helpful?