问题是我无法使用 Postman 应用程序执行 PUT 或 POST。但删除是可能的。是的,我为公共用户启用了所有操作。
这是 GET 请求结果:
{
"data": [
{
"id": 2,
"attributes": {
"title": "23123",
"game": "1231",
"players": "2312313",
"createdAt": "2022-02-19T16:36:34.221Z",
"updatedAt": "2022-02-19T16:36:34.971Z"
}
}
],
"meta": {
"pagination": {
"page": 1,
"pageSize": 25,
"pageCount": 1,
"total": 1
}
}
}
Run Code Online (Sandbox Code Playgroud)
最后请求 POST 后结果如下:
{
"data": null,
"error": {
"status": 400,
"name": "ValidationError",
"message": "Missing \"data\" payload in the request body",
"details": {}
}
}
Run Code Online (Sandbox Code Playgroud)
问题是什么?