Core
API v2.x
2

exists #

Checks if the specified keys exist in the database.

[Redis documentation]


Query Syntax #

HTTP #

Copied to clipboard!
URL: http://kuzzle:7512/ms/_exists?keys=key1,key2,...
Method: GET

Other protocols #

Copied to clipboard!
{
  "controller": "ms",
  "action": "exists",
  "keys": ["key1", "key2", "..."]
}

Arguments #

  • keys: list of keys to verify

Response #

Returns the number of existing keys.

Copied to clipboard!
{
  "requestId": "<unique request identifier>",
  "status": 200,
  "error": null,
  "controller": "ms",
  "action": "exists",
  "collection": null,
  "index": null,
  "result": 1
}