POST api/v1/devices/{deviceId}/location
Set the devices current location. Use this in preference to setting the location object of the device when updating.
Request Information
URI Parameters
| Name | Description | Type | Additional information | 
|---|---|---|---|
| deviceId | globally unique identifier | Required | 
Body Parameters
SetLocationDto| Name | Description | Type | Additional information | 
|---|---|---|---|
| Latitude | decimal number | None. | |
| Longitude | decimal number | None. | |
| Elevation | decimal number | None. | 
Request Formats
application/json, text/json, application/senml+json
            Sample:
        
{
  "Latitude": 1.1,
  "Longitude": 2.1,
  "Elevation": 3.1
}
        application/xml, text/xml
            Sample:
        <SetLocationDto xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AnalysisUK.Tinamous.www.ApiControllers.Models.DeviceLocation"> <Elevation>3.1</Elevation> <Latitude>1.1</Latitude> <Longitude>2.1</Longitude> </SetLocationDto>
application/x-www-form-urlencoded
            Sample:
    
Sample not available.
Response Information
Resource Description
Collection of LocationDto| Name | Description | Type | Additional information | 
|---|---|---|---|
| Name | Friendly name for the location | string | None. | 
| Latitude | decimal number | None. | |
| Longitude | decimal number | None. | |
| Elevation | decimal number | None. | |
| WellKnownLocationId | globally unique identifier | None. | |
| LastUpdated | date | None. | 
Response Formats
application/json, text/json, application/senml+json
            Sample:
        
[
  {
    "Name": "sample string 1",
    "Latitude": 2.1,
    "Longitude": 3.1,
    "Elevation": 4.1,
    "WellKnownLocationId": "8bb33895-f964-4e2e-b71a-369c670622a5",
    "LastUpdated": "2025-10-31T22:44:42.5093769+00:00"
  },
  {
    "Name": "sample string 1",
    "Latitude": 2.1,
    "Longitude": 3.1,
    "Elevation": 4.1,
    "WellKnownLocationId": "8bb33895-f964-4e2e-b71a-369c670622a5",
    "LastUpdated": "2025-10-31T22:44:42.5093769+00:00"
  }
]
        application/xml, text/xml
            Sample:
<ArrayOfLocationDto xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AnalysisUK.Tinamous.www.ApiControllers.Models.Shared">
  <LocationDto>
    <Elevation>4.1</Elevation>
    <LastUpdated>2025-10-31T22:44:42.5093769+00:00</LastUpdated>
    <Latitude>2.1</Latitude>
    <Longitude>3.1</Longitude>
    <Name>sample string 1</Name>
    <WellKnownLocationId>8bb33895-f964-4e2e-b71a-369c670622a5</WellKnownLocationId>
  </LocationDto>
  <LocationDto>
    <Elevation>4.1</Elevation>
    <LastUpdated>2025-10-31T22:44:42.5093769+00:00</LastUpdated>
    <Latitude>2.1</Latitude>
    <Longitude>3.1</Longitude>
    <Name>sample string 1</Name>
    <WellKnownLocationId>8bb33895-f964-4e2e-b71a-369c670622a5</WellKnownLocationId>
  </LocationDto>
</ArrayOfLocationDto>