region
Requires at least one of the permissions settings:regional:read or settings:tenant:read.
Returns one region. Requires permission to read regional or tenant settings.
Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.
Example:
- GraphQL
- cURL
query Region($id: String!) {
region(id: $id) {
id
code
countryCode
stateCode
name
cityName
}
}
curl -X POST "https://<api-host>/graphql" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
--data @- <<'EOF'
{
"query": "query Region($id: String!) {\n region(id: $id) {\n id\n code\n countryCode\n stateCode\n name\n cityName\n }\n}",
"variables": {
"id": "string"
}
}
EOF
Variables:
{
"id": "string"
}
Response:
{
"data": {
"region": {
"id": "id",
"code": "string",
"countryCode": "string",
"stateCode": "string",
"name": "string",
"cityName": "string"
}
}
}
region(
id: String!
): Region!
Arguments
region.id ● String! non-null scalar
The ID of the region.
Type
Region object
A region such as a country, state or city.