Through postman, I'm trying to send a post request to create a post, but I get an error that is described in the question itself (error code - 405).
On top of all that, I've issued ALL permissions. What is the problem?
and schema.json from grade -
{
"kind": "collectionType",
"collectionName": "grades",
"info": {
"singularName": "grade",
"pluralName": "grades",
"displayName": "grade"
},
"options": {
"draftAndPublish": true
},
"pluginOptions": {},
"attributes": {
"id_post": {
"type": "biginteger"
},
"grade": {
"type": "integer"
}
}
}
CodePudding user response:
from comments, it seems the problem is two extra invisible characters after the url:
this line makes them visible:
[2022-12-21 14:38:39.382] http: POST /api/grades/
(4 ms) 40
notice the
remove them or copy paste clean url:
http://localhost:1337/api/grades