deleteMetadata #

Deletes a metadata of the metadata referential.

The request is rejected if a model still uses the metadata.

Its mappings stay in the engines collections, Elasticsearch cannot remove them: a metadata with the same name and different mappings cannot be created afterwards.

A metadata registered with deviceManager.models.registerMetadata is written again at the next startup.

See Metadata Referential.


Query Syntax #

HTTP #

URL: http://kuzzle:7512/_/device-manager/models/metadata/:name
Method: DELETE

Other protocols #

{
  "controller": "device-manager/models",
  "action": "deleteMetadata",
  "name": "<metadata name>"
}

Arguments #

  • name: metadata name

Response #

Returns the updated metadata referential.

{
  "status": 200,
  "error": null,
  "controller": "device-manager/models",
  "action": "deleteMetadata",
  "requestId": "<unique request identifier>",
  "result": {
    // Remaining metadata
  }
}

Errors #

  • A BadRequestError (400) is thrown if a model still uses the metadata, or if the metadata is registered from code (managed)
  • A NotFoundError (404) is thrown if the metadata does not exist