POST /posts

POST /posts

Body Required

  • id string Required

    The post id.

  • userId string Required

    The post userId.

  • title string Required

    The title of the post

  • body string Required

    The body content of the post

Responses

  • 201

    The request has succeeded and a new resource has been created as a result.

POST /posts
curl \
 -X POST https://api.example.com/v1/posts \
 -H "Content-Type: application/json" \
 -d '{"userId":1,"id":1,"title":"The First Post","body":"we are building a blog post API using OpenAPI Specification."}'
Request example
{
  "userId": 1,
  "id": 1,
  "title": "The First Post",
  "body": "we are building a blog post API using OpenAPI Specification."
}
Request examples
{
  "id": 1,
  "body": "we are building a blog post API using OpenAPI Specification.",
  "title": "The First Post",
  "userId": 1
}