Skip to content

Latest commit

 

History

History
82 lines (61 loc) · 1.27 KB

File metadata and controls

82 lines (61 loc) · 1.27 KB
code type title
true
page
getSpecifications

getSpecifications

Returns the validation specifications associated to the given index and collection.


Query Syntax

HTTP

URL: http://kuzzle:7512/<index>/<collection>/_specifications
Method: GET

Other protocols

{
  "index": "<index>",
  "collection": "<collection>",
  "controller": "collection",
  "action": "getSpecifications"
}

Arguments

  • collection: collection name
  • index: index name

Response

Returns a specifications object with the following properties:

  • collection: specified collection
  • index: specified index
  • validation: specifications description
{
  "status": 200,
  "error": null,
  "action": "getSpecifications",
  "controller": "collection",
  "collection": "<collection>",
  "index": "<index>",
  "result": {
    "collection": "<collection>",
    "index": "<index>",
    "validation": {
      "fields": {
        "myField": {
          "defaultValue": 42,
          "mandatory": true,
          "type": "integer"
        }
      },
      "strict": true
    }
  }
}

Possible errors