Locations API

Locations API Reference

get  /archivist/v2/locations

List locations

Description: Returns a paginated list of locations

null
Response Parameter Type Description
locations array Describes a location for asset resources
next_page_token string Token to retrieve the next page of results or empty if there are none.
Responses Description
200A successful response.
401Returned when the user is not authenticated to the system.
403Returned when the user is not authorized to read the location.
defaultAn unexpected error response.

post  /archivist/v2/locations

Create a location

Description: This request creates a new location. A name and a latitude and longitude must be provided. The display_name is the friendly name. The latitude and longitude must be entered in Degrees Decimal format See Change of units and format. The attributes field is a flat map of { "key": "value" }. The keys and values must be strings.

{
  "attributes": {
    "Facility Type": "Manufacture",
    "address": "Bridgewater, Somerset",
    "director": "John Smith",
    "support_email": "support@macclesfield.com",
    "support_phone": "123 456 789"
  },
  "description": "Manufacturing site, North West England, Macclesfield, Cheshire",
  "display_name": "Macclesfield, Cheshire",
  "latitude": "53.2546799",
  "longitude": "-2.1213956,14.54"
}
Parameter Type Description
attributes object key value mapping of location properties
description string Free text description of the location
display_name string Customer friendly name for the asset.
latitude number Latitude in decimal degrees format.
longitude number longitude in decimal degrees format.

{
  "attributes": {
    "Facility Type": "Manufacture",
    "address": "Bridgewater, Somerset",
    "director": "John Smith",
    "support_email": "support@macclesfield.com",
    "support_phone": "123 456 789"
  },
  "description": "Manufacturing site, North West England, Macclesfield, Cheshire",
  "display_name": "Macclesfield, Cheshire",
  "identity": "locations/08838336-c357-460d-902a-3aba9528dd22",
  "latitude": "53.2546799",
  "longitude": "-2.1213956,14.54"
}
Response Parameter Type Description
attributes object key value mapping of asset properties
description string Free text description of the location
display_name string Customer friendly name for the location.
identity string Unique identification for the location, Relative Resource Name
latitude number Latitude in decimal degrees
longitude number Longitude in decimal degrees
tenant string Tenent id
Responses Description
200A successful response.
401Returned when the user is not authenticated to the system.
403Returned when the user is not authorized to create a location.
defaultAn unexpected error response.

delete  /archivist/v2/{identity}

Delete a location

Description: Delete the identified location

Responses Description
200A successful response.
401Returned when the user is not authenticated to the system.
403Returned when the user is not authorized to delete the location.
404Returned when the identified location does not exist.
defaultAn unexpected error response.

get  /archivist/v2/{identity}

Get a location

Description: Returns the identified location

{
  "attributes": {
    "Facility Type": "Manufacture",
    "address": "Bridgewater, Somerset",
    "director": "John Smith",
    "support_email": "support@macclesfield.com",
    "support_phone": "123 456 789"
  },
  "description": "Manufacturing site, North West England, Macclesfield, Cheshire",
  "display_name": "Macclesfield, Cheshire",
  "identity": "locations/08838336-c357-460d-902a-3aba9528dd22",
  "latitude": "53.2546799",
  "longitude": "-2.1213956,14.54"
}
Response Parameter Type Description
attributes object key value mapping of asset properties
description string Free text description of the location
display_name string Customer friendly name for the location.
identity string Unique identification for the location, Relative Resource Name
latitude number Latitude in decimal degrees
longitude number Longitude in decimal degrees
tenant string Tenent id
Responses Description
200A successful response.
401Returned when the user is not authenticated to the system.
403Returned when the user is not authorized to read the location.
404Returned when the identified location does not exist.
defaultAn unexpected error response.

patch  /archivist/v2/{identity}

Update a location's details

Description: Perform a full or partial update of the identified location

{
  "attributes": {
    "Facility Type": "Manufacture",
    "address": "Bridgewater, Somerset",
    "director": "John Smith",
    "support_email": "support@macclesfield.com",
    "support_phone": "123 456 789"
  },
  "description": "Manufacturing site, North West England, Macclesfield, Cheshire",
  "display_name": "Macclesfield, Cheshire",
  "identity": "locations/08838336-c357-460d-902a-3aba9528dd22",
  "latitude": "53.2546799",
  "longitude": "-2.1213956,14.54"
}
Parameter Type Description
attributes object key value mapping of asset properties
description string Free text description of the location
display_name string Customer friendly name for the location.
identity string Unique identification for the location, Relative Resource Name
latitude number Latitude in decimal degrees
longitude number Longitude in decimal degrees
tenant string Tenent id

{
  "attributes": {
    "Facility Type": "Manufacture",
    "address": "Bridgewater, Somerset",
    "director": "John Smith",
    "support_email": "support@macclesfield.com",
    "support_phone": "123 456 789"
  },
  "description": "Manufacturing site, North West England, Macclesfield, Cheshire",
  "display_name": "Macclesfield, Cheshire",
  "identity": "locations/08838336-c357-460d-902a-3aba9528dd22",
  "latitude": "53.2546799",
  "longitude": "-2.1213956,14.54"
}
Response Parameter Type Description
attributes object key value mapping of asset properties
description string Free text description of the location
display_name string Customer friendly name for the location.
identity string Unique identification for the location, Relative Resource Name
latitude number Latitude in decimal degrees
longitude number Longitude in decimal degrees
tenant string Tenent id
Responses Description
200A successful response.
401Returned when the user is not authenticated to the system.
403Returned when the user is not authorized to update the location.
404Returned when the identified location does not exist.
defaultAn unexpected error response.

get  /archivist/v2/{location_identity}/permissions

Get location permissions

Description: Get location permissions for identified location

null
Response Parameter Type Description
location_identity string
permissions
Responses Description
200A successful response.
401Returned when the user is not authenticated to the system.
403Returned when the user is not authorized to list permissions for the location.
404Returned when the identified location does not exist.
defaultAn unexpected error response.

patch  /archivist/v2/{location_identity}/permissions

Patch location permissions

Description: Patch location permissions for identified location

null
Parameter Type Description
subject_identities array list of subject identities this location is shared with

null
Response Parameter Type Description
location_identity string
permissions
Responses Description
200A successful response.
401Returned when the user is not authenticated to the system.
403Returned when the user is not authorized to access permissions for the location.
404Returned when the identified location does not exist.
defaultAn unexpected error response.

Edit this page on GitHub