SDK
SDK Javascript v5.x
1

deleteSpecifications #

Delete specifications linked to the collection object.


deleteSpecifications([options], [callback]) #

Arguments Type Description
options JSON object Optional parameters
callback function Optional callback

Options #

Option Type Description Default
queuable boolean Make this request queuable or not true
refresh string If set to wait_for, Kuzzle will wait for the persistence layer indexation to return (available with Elasticsearch 5.x and above) undefined

Return Value #

Returns the Collection object to allow chaining.

Usage #

Copied to clipboard!
// Deleting specifications using callbacks (NodeJS or Web Browser)
kuzzle
  .collection('collection', 'index')
  .deleteSpecifications(function (err, res) {
    // callback called once the delete action has been completed
  });
// Deleting specifications using promises (NodeJS)
kuzzle
  .collection('collection', 'index')
  .deleteSpecificationsPromise()
  .then(res => {
    // promises resolved once the delete action has been completed
  });

Callback response:

Copied to clipboard!
{
  "acknowledged": true
}