Update Organisation Location

Enables users to update the details of a specific organization’s location by referencing its unique identifier (ID). With this endpoint, users can modify a range of location attributes to keep information current and accurate, supporting better user experience and operational efficiency.

Syntax: see 'CCall Structure

Type = 'PATCH'

'https://connect.cambrionix.com/api/locations/v1/locations/location_id' \

Output Description
location-id This is the unique id of the location

Next, in the data section of the request, enter the location fields you want to update, following the format provided below. For detailed information on each variable, please see the variable table located in the section immediately following the return values.

{ "id": "location-id", "name": "location-name", "description": "location-description", "organization": { "id": "organisation-id" }, "address": { "components": [ { "name": { "long": "long-name", "short": "short-name" }, "types": [ "component-type" ] } ], "location": { "latitude": "latitude", "longitude": "longitude" }, "formatted": "formatted-address" }, "viewport": { "northeast": { "latitude": "latitude", "longitude": "longitude" }, "southwest": { "latitude": "latitude", "longitude": "longitude" } } }, "type": "address-type", ], }

Returns:

{ "result": [ { "created": { "time": "time", "user": { "id": "user-id", "detail": { "givenName": "given-name", "surname": "surname", "displayName": "display-name", "email": "account-email" } } }, "updated": { "time": "time", "user": { "id": "user-id", "detail": { "givenName": "given-name", "surname": "surname", "displayName": "display-name", "email": "account-email" } } }, "id": "location-id", "name": "location-name", "description": "location-description", "organization": { "id": "organisation-id" }, "address": { "components": [ { "name": { "long": "long-name", "short": "short-name" }, "types": [ "component-type" ] } ], "location": { "latitude": "latitude", "longitude": "longitude" }, "formatted": "formatted-address" }, "viewport": { "northeast": { "latitude": "latitude", "longitude": "longitude" }, "southwest": { "latitude": "latitude", "longitude": "longitude" } } }, "type": "address-type", ], }

Output Description
time The hub time, shown as an integer in ms
user-id This is the id of the user as a unique 128-bit number
given-name The first name of the user
surname The surname of the user
display-name The account name of the user
account-email The email of the user
location-id This is the unique id of the location
location-name This is the user defined name of the location
organisation-id This is the unique id of the organisation
long-name The full name of the component
short-name The shorthand version of the name of the component
component-type The address component type see Address Component Types
latitude

The latititude of the location

longitude The longitude of the location
formatted-address The full address formatted as a string
address-type The type of address, see Address Types
Example
{
  "result": {
      "id": "337a0e54-2699-4bca-9357-bb87092ecd92",
      "name": "Office",
      "description": "Office",
      "organization": {
        "id": "dafc70d5-a4c8-42a3-ad8d-a8ccb5fa313f"
      },
      "address": {
        "components": [
          {
            "name": {
              "long": "The Maurice Wilkes Building",
              "short": "The Maurice Wilkes Building"
            },
            "types": [
              "premise"
            ]
          },
          {
            "name": {
              "long": "Cowley Road",
              "short": "Cowley Rd"
            },
            "types": [
              "route"
            ]
          },
          {
            "name": {
              "long": "Cambridgeshire",
              "short": "Cambridgeshire"
            },
            "types": [
              "administrative_area_level_2",
              "political"
            ]
          },
          {
            "name": {
              "long": "England",
              "short": "England"
            },
            "types": [
              "administrative_area_level_1",
              "political"
            ]
          },
          {
            "name": {
              "long": "CB4 0DS",
              "short": "CB4 0DS"
            },
            "types": [
              "postal_code"
            ]
          },
          {
            "name": {
              "long": "United Kingdom",
              "short": "GB"
            },
            "types": [
              "country",
              "political"
            ]
          }
        ],
        "location": {
          "latitude": 52.23316289999999,
          "longitude": 0.1513396
        },
        "formatted": "The Maurice Wilkes Building, Cowley Rd, Cambridge CB4 0DS, UK"
      },
      "type": "office"
    }
  }
}
Errors

If there is an error in the API method then JSON-RPC Error Object a will be returned