DatoCMS client v0.2.3 DatoCMS.Client.Item
Summary
Functions
Calls POST /items
Calls DELETE /items/{(%2Fschemata%2Fitem%23%2Fdefinitions%2Fitem%2Fdefinitions%2Fidentity)}
Calls GET /items/{(%2Fschemata%2Fitem%23%2Fdefinitions%2Fitem%2Fdefinitions%2Fidentity)}
Calls GET /items
Calls PUT /items/{(%2Fschemata%2Fitem%23%2Fdefinitions%2Fitem%2Fdefinitions%2Fidentity)}
Calls POST /items/{(%2Fschemata%2Fitem%23%2Fdefinitions%2Fitem%2Fdefinitions%2Fidentity)}/validate
Calls POST /items/validate
Functions
Calls POST /items
params
is JSON encoded and passed as the request body.
params Schema
{
"additionalProperties": false,
"properties": {
"data": {
"additionalProperties": false,
"properties": {
"attributes": {
"description": "The JSON data associated to the item",
"example": {
"title": "This is a item!"
},
"type": "object"
},
"relationships": {
"additionalProperties": false,
"properties": {
"item_type": {
"additionalProperties": false,
"description": "The record model",
"properties": {
"data": {
"additionalProperties": false,
"description": "JSON API data",
"properties": {
"id": {
"description": "ID of item type",
"example": "44",
"type": "string"
},
"type": {
"description": "JSON API type field",
"example": "item_type",
"pattern": "^item_type$",
"type": [
"string"
]
}
},
"required": [
"type",
"id"
],
"type": "object"
}
},
"required": [
"data"
],
"type": "object"
}
},
"required": [
"item_type"
],
"type": "object"
},
"type": {
"description": "JSON API type field",
"example": "item",
"pattern": "^item$",
"type": [
"string"
]
}
},
"required": [
"type",
"attributes",
"relationships"
],
"type": "object"
}
},
"required": [
"data"
],
"type": "object"
}
Calls DELETE /items/{(%2Fschemata%2Fitem%23%2Fdefinitions%2Fitem%2Fdefinitions%2Fidentity)}
Calls GET /items
params
is added to the URL as query parameters.
params Schema
{
"properties": {
"filter[ids]": {
"description": "IDs to fetch, comma separated",
"example": "12,31",
"type": [
"string"
]
},
"filter[query]": {
"description": "textual query to match",
"example": "foo",
"type": [
"string"
]
},
"filter[type]": {
"description": "model ID to filter",
"example": "44",
"type": [
"string"
]
},
"page[limit]": {
"default": 30,
"description": "number of records to fetch",
"example": 15,
"type": [
"integer"
]
},
"page[offset]": {
"default": 1,
"description": "index of first record to fetch",
"example": 2,
"type": [
"integer"
]
}
},
"type": [
"object"
]
}
Calls PUT /items/{(%2Fschemata%2Fitem%23%2Fdefinitions%2Fitem%2Fdefinitions%2Fidentity)}
params
is JSON encoded and passed as the request body.
params Schema
{
"additionalProperties": false,
"properties": {
"data": {
"additionalProperties": false,
"properties": {
"attributes": {
"description": "The JSON data associated to the item",
"example": {
"title": "This is a item!"
},
"type": "object"
},
"id": {
"description": "ID of item",
"example": "4235",
"type": "string"
},
"type": {
"description": "JSON API type field",
"example": "item",
"pattern": "^item$",
"type": [
"string"
]
}
},
"required": [
"type",
"id",
"attributes"
],
"type": "object"
}
},
"required": [
"data"
],
"type": "object"
}
Calls POST /items/{(%2Fschemata%2Fitem%23%2Fdefinitions%2Fitem%2Fdefinitions%2Fidentity)}/validate
params
is JSON encoded and passed as the request body.
params Schema
{
"additionalProperties": false,
"properties": {
"data": {
"additionalProperties": false,
"properties": {
"attributes": {
"description": "The JSON data associated to the item",
"example": {
"title": "This is a item!"
},
"type": "object"
},
"id": {
"description": "ID of item",
"example": "4235",
"type": "string"
},
"relationships": {
"additionalProperties": false,
"properties": {
"item_type": {
"additionalProperties": false,
"properties": {
"data": {
"additionalProperties": false,
"description": "JSON API data",
"properties": {
"id": {
"description": "ID of item type",
"example": "44",
"type": "string"
},
"type": {
"description": "JSON API type field",
"example": "item_type",
"pattern": "^item_type$",
"type": [
"string"
]
}
},
"required": [
"type",
"id"
],
"type": "object"
}
},
"required": [
"data"
],
"type": "object"
}
},
"required": [
"item_type"
],
"type": "object"
},
"type": {
"description": "JSON API type field",
"example": "item",
"pattern": "^item$",
"type": [
"string"
]
}
},
"required": [
"id",
"type",
"attributes",
"relationships"
],
"type": "object"
}
},
"required": [
"data"
],
"type": "object"
}
Calls POST /items/validate
params
is JSON encoded and passed as the request body.
params Schema
{
"additionalProperties": false,
"properties": {
"data": {
"additionalProperties": false,
"properties": {
"attributes": {
"description": "The JSON data associated to the item",
"example": {
"title": "This is a item!"
},
"type": "object"
},
"relationships": {
"additionalProperties": false,
"properties": {
"item_type": {
"additionalProperties": false,
"properties": {
"data": {
"additionalProperties": false,
"description": "JSON API data",
"properties": {
"id": {
"description": "ID of item type",
"example": "44",
"type": "string"
},
"type": {
"description": "JSON API type field",
"example": "item_type",
"pattern": "^item_type$",
"type": [
"string"
]
}
},
"required": [
"type",
"id"
],
"type": "object"
}
},
"required": [
"data"
],
"type": "object"
}
},
"required": [
"item_type"
],
"type": "object"
},
"type": {
"description": "JSON API type field",
"example": "item",
"pattern": "^item$",
"type": [
"string"
]
}
},
"required": [
"type",
"attributes",
"relationships"
],
"type": "object"
}
},
"required": [
"data"
],
"type": "object"
}