Skip to main content

updateRegion

Requires permission platform:region:manage.

Edits a region. Regions are shared by every organization, so this needs the platform permission to manage regions, which only platform administrators hold.

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:

mutation UpdateRegion($id: String!, $input: UpdateRegionInput!) {
updateRegion(id: $id, input: $input) {
id
code
countryCode
stateCode
name
cityName
}
}

Variables:

{
"id": "string",
"input": {}
}

Response:

{
"data": {
"updateRegion": {
"id": "id",
"code": "string",
"countryCode": "string",
"stateCode": "string",
"name": "string",
"cityName": "string"
}
}
}
updateRegion(
id: String!
input: UpdateRegionInput!
): Region!

Arguments​

updateRegion.id ● String! non-null scalar​

The ID of the region.

updateRegion.input ● UpdateRegionInput! non-null input​

The fields to change.

Type​

Region object​

A region such as a country, state or city.