First of all, is the Record topic of the docs missing an Attributes section? The other topics all seem to start with Attributes, but nothing for records.
I am sending an HTTP POST to https://site-api.datocms.com/items to create a new record but regardless of what I try, the only result ever returned is a 406. I issued a GET request against the same model, copied and pasted the attributes back, minus the created one and still receive a 406. Here is my request with the apikey obfuscated.
POST https://site-api.datocms.com/items HTTP/1.1
X-Api-Version: 3
Authorization: Bearer xxx
Accept: application/json
Content-Type: application/json
{
"data": {
"type": "item",
"attributes": {
"first_name": "Troy",
"last_name": "Forster",
"email_address": "troy.forster@gmail.com",
"phone_number": "4166174921",
"salesforce": "",
"results": [
]
},
"meta": {},
"relationships": {
"item_type": {
"data": {
"id": "199010",
"type": "item_type"
}
}
}
}
}