Get location
const url = 'https://safe-api.safetyradar.com/v2/locations/123e4567-e89b-12d3-a456-426614174000';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://safe-api.safetyradar.com/v2/locations/123e4567-e89b-12d3-a456-426614174000 \ --header 'Authorization: Bearer <token>'Get a single location by UUID or external ID. The resolver accepts both formats.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Location ID (UUID) or external ID
Example
123e4567-e89b-12d3-a456-426614174000Location ID (UUID) or external ID
Responses
Section titled “Responses”Location found
object
object
Names of the resource tags on the location, sorted. Single-location responses (GET by id, POST) also carry tags as { id, name } objects; tagNames is the same set as plain names.
Example
{ "data": { "status": "active", "type": "equipment", "tagNames": [ "Region North" ] }}Invalid request: a parameter or the body failed validation (validation_error), or the body is not valid JSON (invalid_json)
object
Machine-readable error code
Human-readable error message
Additional error details. For validation_error: issues, a list of { location, path, message } (location is query, param, header or json).
object
Example
{ "code": "validation_error", "message": "Request validation failed"}Unauthorized
object
Machine-readable error code
Human-readable error message
Additional error details. For validation_error: issues, a list of { location, path, message } (location is query, param, header or json).
object
Example
{ "code": "validation_error", "message": "Request validation failed"}Location not found
object
Machine-readable error code
Human-readable error message
Additional error details. For validation_error: issues, a list of { location, path, message } (location is query, param, header or json).
object
Example
{ "code": "validation_error", "message": "Request validation failed"}Rate limit exceeded (rate_limit_exceeded)
object
Machine-readable error code
Human-readable error message
Additional error details. For validation_error: issues, a list of { location, path, message } (location is query, param, header or json).
object
Example
{ "code": "validation_error", "message": "Request validation failed"}Unexpected server error (internal_error)
object
Machine-readable error code
Human-readable error message
Additional error details. For validation_error: issues, a list of { location, path, message } (location is query, param, header or json).
object
Example
{ "code": "validation_error", "message": "Request validation failed"}
