I am attempting to create a very simple article in the KB by posting the following body, but I receive a validation error that I can’t figure out. I have confirmed that article.meta.categories.name is correct, as well as the id. I also tried the slug instead of the name with the same result.
Body:
{
"propertyId": "xxx9f7c37xxx12e96xxxxx",
"article": {
"content": {
"siteId": "primary",
"title": "Toolbox Test Article Title 4.5",
"status": "draft",
"subtitle": "Toolbox Test Article Subtitle",
"contents": [
{
"content": {
"text": "<p>This is an example paragraph.</p>",
"size": 18,
"color": "#000000",
"backgroundColor": "#FFFFFF"
},
"type": "paragraph"
}
],
"author": "xxxc554cb2xxxe1daxxx",
"slug": "toolbox-test-article"
},
"meta": {
"visibility": "public",
"categories": [
{
"id": "xxxb241c8e8cxxxe41xxxx",
"name": "Developers",
"primary": true
}
],
"relatedArticles": []
}
}
}
Error:
{
"ok": false,
"error": "validation_error",
"message": "article.meta.categories[0].name"
}
Can anyone tell me what I’m missing or doing wrong?