Changelog

OpenAPI specification: http://localhost:3040/openapi.yaml

Posts

Create a post

Create a new post. The response echoes your body with a new id.

POSThttps://jsonplaceholder.typicode.com/posts

Servers

https://jsonplaceholder.typicode.com

Live public API

Request body

application/jsonRequired
userIdbodyintegerrequired
titlebodystringrequired
bodybodystringrequired

Responses

The created post.

idintegerrequired
userIdintegerrequired
The author's user ID.
titlestringrequired
bodystringrequired
RequestcURL
curl --request POST \
  --url 'https://jsonplaceholder.typicode.com/posts'
  --data '{
  "userId": 1,
  "title": "My first post",
  "body": "Hello from the Try It console."
}'
Response

Send a request to preview the response.

Was this page helpful?