The location column stores a location with longitude and latitude precision (but displayed with text). Our API fully supports the location column, so you can read, update, and clear it via the API. Filtering by the location column is not yet available.

Reading the location column

You can query the location column using the column_values object. The object has different fields based on which API version you are using. Column values v2 fields will be available in API versions 2023-10 and later, while column values v1 fields are only supported in versions 2023-07 and 2023-04.

Column values v2

The column_values object enables you to return column-specific subfields by sending a fragment in your query. Values for the location column are of the LocationValue type.

👍

Pro tip

column_values v2 fields are only available in API version 2023-10.

query {
  items (ids:[1234567890, 9876543210]) {
    column_values {
      ... on LocationValue {
        country
        street
        street_number
      }
    }
  }
}

Fields

FieldDescription
address StringThe column's address value.
city StringThe column's city value.
city_short StringThe column's shortened city value.
column Column!The column the value belongs to.
country StringThe column's country value.
country_short StringThe column's shortened country value.
id ID!The column's unique identifier.
lat FloatThe column's latitude value.
lng FloatThe column's longitude value.
place_id StringThe unique place identifier of the location.
street StringThe column's street value.
street_number StringThe column's street building number value.
street_number_short StringThe column's shortened street building number value.
street_short StringThe column's shortened street value.
text StringThe column's value as text.
type ColumnType!The column's type.
updated_at DateThe column's last updated date.
value JSONThe column's JSON-formatted raw value.

Column values v1

You can return the data in a location column in two different formats when you query by column values. The text field will return the location as a simple string. The value field will return metadata about the column as a JSON string.

🚧

Removing column values v1 support

column_values v1 fields will no longer be supported in API versions 2023-10 and later.

{
  "text": "Taj Mahal",
  "value": "{\"lat\":\"27.1751448\",\"lng\":\"78.0421422\",\"city\":{\"long_name\":\"Agra\",\"short_name\":\"Agra\"},\"street\":null,\"address\":\"Taj Mahal\",\"country\":{\"long_name\":\"India\",\"short_name\":\"IN\"},\"placeId\":\"ChIJbf8C1yFxdDkR3n12P4DkKt0\",\"changed_at\":\"2022-07-21T12:00:00.000Z\",\"streetNumber\":null}"
}

Updating the location column

You can update a location column using the change_simple_column_value mutation and sending a simple string in the value argument. You can also use the change_multiple_column_values mutation and pass a JSON string in the column_values argument.

📘

Note

The address is not verified to match the latitude/longitude and is just used as the text displayed in the cell. In case no address is provided, the address will be displayed as unknown.

The legal values for latitude are between -90.0 and 90.0 exclusive and between -180.0 and 180.0 inclusive for longitude. If the updated values exceed those ranges, you will get an error.

Simple strings

To update a location column, send the latitude, longitude, and address of the location separated by spaces (optional).

mutation {
  change_simple_column_value (item_id:9876543210, board_id:1234567890, column_id:"location", value:"29.9772962 31.1324955 Giza Pyramid Complex") {
    id
  }
}
fetch ("https://api.monday.com/v2", {
  method: 'post',
  headers: {
    'Content-Type': 'application/json',
    'Authorization' : 'YOUR_API_KEY_HERE'
  },
  body: JSON.stringify({
    query : "mutation ($myBoardId:Int!, $myItemId:Int!, $myColumnValue: String!, $columnId: String!) { change_simple_column_value (item_id:$myItemId, board_id:$myBoardId, column_id: $columnId, value: $myColumnValue) { id } }",
    variables : JSON.stringify({
      myBoardId: 1234567890,
      myItemId: 9876543210,
      columnId: "location",
      myColumnValue: "29.9772962 31.1324955 Giza Pyramid Complex"
      })
    })
  })

JSON

To update a location column using JSON, send the latitude, longitude, and address of the location (optional). Check out this mutation in action in our Postman library or follow along with these code samples!

mutation {
  change_multiple_column_values(item_id:9876543210, board_id:1234567890, column_values: "{\"location\" : {\"lat\":\"29.9772962\",\"lng\":\"31.1324955\",\"address\":\"Giza Pyramid Complex\"}}") {
    id
  }
}
fetch ("https://api.monday.com/v2", {
  method: 'post',
  headers: {
    'Content-Type': 'application/json',
    'Authorization' : 'YOUR_API_KEY'
  },
  body: JSON.stringify({
    query : "mutation ($myBoardId:Int!, $myItemId:Int!, $myColumnValues:JSON!) { change_multiple_column_values(item_id:$myItemId, board_id:$myBoardId, column_values: $myColumnValues) { id } }",
    variables : JSON.stringify({
      myBoardId: 1234567890,
      myItemId: 9876543210,
      myColumnValues: "{\"location\" : {\"lat\" : \"29.9772962\", \"lng\": \"31.1324955\", \"address\": \"Giza Pyramid Complex\"}}"
    })
  })
})

Clearing the location column

You can also clear a location column using the change_multiple_column_values mutation and passing null or an empty object in the column_values argument.

mutation {
  change_multiple_column_values(item_id:9876543210, board_id:1234567890, column_values: "{\"location\" : null}") {
    id
  }
}
fetch ("https://api.monday.com/v2", {
  method: 'post',
  headers: {
    'Content-Type': 'application/json',
    'Authorization' : 'YOUR_API_KEY_HERE'
  },
  body: JSON.stringify({
    query : "mutation ($myBoardId:Int!, $myItemId:Int!, $myColumnValues:JSON!) { change_multiple_column_values(item_id:$myItemId, board_id:$myBoardId, column_values: $myColumnValues) { id } }",
    variables : JSON.stringify({
      myBoardId: 1234567890,
      myItemId: 9876543210,
      myColumnValues: "{\"location\" : null}"
    })
  })
})

📘

Join our developer community!

We've created a community specifically for our devs where you can search through previous topics to find solutions, ask new questions, hear about new features and updates, and learn tips and tricks from other devs. Come join in on the fun! 😎