PUT api/v1/devices/{id}/Purge

Purge device data before the specified date (if date not specified, now is used).

Request Information

URI Parameters

NameDescriptionTypeAdditional information
id

globally unique identifier

Required

Body Parameters

PurgeDeviceDto
NameDescriptionTypeAdditional information
BeforeDate

date

None.

Measurements

Purge all measurments (including hourly/daily summaries) upto "BeforeDate"

boolean

None.

StatusPosts

Purge all status posts upto "BeforeDate" NB: Not Implemented at present!

boolean

None.

Media

Purge all media upto "BeforeDate" NB: Not Implemented at present!

boolean

None.

Request Formats

application/json, text/json, application/senml+json

Sample:
{
  "BeforeDate": "2024-11-21T04:19:41.8804069+00:00",
  "Measurements": true,
  "StatusPosts": true,
  "Media": true
}

application/xml, text/xml

Sample:
<PurgeDeviceDto xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AnalysisUK.Tinamous.www.ApiControllers.Models.Devices">
  <BeforeDate>2024-11-21T04:19:41.8804069+00:00</BeforeDate>
  <Measurements>true</Measurements>
  <Media>true</Media>
  <StatusPosts>true</StatusPosts>
</PurgeDeviceDto>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

Status code only. Does not include updated object.

IHttpActionResult

None.

Response Formats

application/json, text/json, application/xml, text/xml, application/senml+json

Sample:

Sample not available.