Post’s schema.json looks fine.
{
"kind": "collectionType",
"collectionName": "posts",
"info": {
"singularName": "post",
"pluralName": "posts",
"displayName": "Post",
"description": ""
},
"options": {
"draftAndPublish": true
},
"pluginOptions": {},
"attributes": {
"title": {
"type": "string",
"required": true
},
"body": {
"type": "text",
"required": true
},
"tags": {
"type": "relation",
"relation": "oneToMany",
"target": "api::tag.tag"
}
}
}
but I don’t see posts as relation against tag, when accessing http://localhost:1337/api/tags?populate[0]=posts
In this case, posts and tags supposed to be in many-to-many relations.
As Post has all 3 tags, in the screenshot below, eash tag should contain 1 post as nested element.
