Kuzzle
Documentation
2

delete #

Deletes a device.

See also the document:delete API action.


Query Syntax #

HTTP #

Copied to clipboard!
URL: http://kuzzle:7512/_/device-manager/:index/devices/:_id[?refresh=wait_for][&source]
Method: DELETE

Other protocols #

Copied to clipboard!
{
  "index": "<index>",
  "controller": "device-manager/device",
  "action": "delete",
  "_id": "<deviceId>"
}

Kourou #

Copied to clipboard!
kourou device-manager/device:delete <index> --id <deviceId>

Arguments #

  • index: Tenant index name

Optional: #

  • refresh: if set to wait_for, Kuzzle will not respond until the document is removed from the search indexes
  • source: if set to true Kuzzle will return the entire deleted document body in the response.

Response #

Returns information about the deleted device:

  • _id: device unique identifier
  • _source: deleted device source, only if option source is set to true
Copied to clipboard!
{
  "status": 200,
  "error": null,
  "index": "<index>",
  "controller": "device-manager/device",
  "action": "delete",
  "requestId": "<unique request identifier>",
  "result": {
    "_id": "<deviceId>",
    "_source": "<deleted document>" // If `source` option is set to true
  }
}