curl -X PUT "https://api.dyeink.com/api/posts/507f1f77bcf86cd799439011" \ -H "Content-Type: application/json" \ -H "Cookie: session=your_session_token" \ -d '{ "title": "Updated Blog Post Title", "published": true }'
{ "id": "507f1f77bcf86cd799439011", "userId": "507f191e810c19729de860ea", "title": "Updated Blog Post Title", "slug": "my-blog-post", "content": "# Welcome\n\nThis is my blog post content.", "excerpt": "An introduction to my blog", "coverImage": "https://example.com/cover.jpg", "published": true, "publishedAt": "2026-03-04T11:00:00.000Z", "views": 42, "shares": 5, "createdAt": "2026-03-04T10:00:00.000Z", "updatedAt": "2026-03-04T11:00:00.000Z"}
Posts
Update Post
Update an existing post
PUT
/
api
/
posts
/
:id
curl -X PUT "https://api.dyeink.com/api/posts/507f1f77bcf86cd799439011" \ -H "Content-Type: application/json" \ -H "Cookie: session=your_session_token" \ -d '{ "title": "Updated Blog Post Title", "published": true }'
{ "id": "507f1f77bcf86cd799439011", "userId": "507f191e810c19729de860ea", "title": "Updated Blog Post Title", "slug": "my-blog-post", "content": "# Welcome\n\nThis is my blog post content.", "excerpt": "An introduction to my blog", "coverImage": "https://example.com/cover.jpg", "published": true, "publishedAt": "2026-03-04T11:00:00.000Z", "views": 42, "shares": 5, "createdAt": "2026-03-04T10:00:00.000Z", "updatedAt": "2026-03-04T11:00:00.000Z"}
Whether the post should be published. Setting to true will set publishedAt to the current timestamp if not already published. Setting to false will set publishedAt to null.
ISO 8601 timestamp of when the post was last updated
curl -X PUT "https://api.dyeink.com/api/posts/507f1f77bcf86cd799439011" \ -H "Content-Type: application/json" \ -H "Cookie: session=your_session_token" \ -d '{ "title": "Updated Blog Post Title", "published": true }'
{ "id": "507f1f77bcf86cd799439011", "userId": "507f191e810c19729de860ea", "title": "Updated Blog Post Title", "slug": "my-blog-post", "content": "# Welcome\n\nThis is my blog post content.", "excerpt": "An introduction to my blog", "coverImage": "https://example.com/cover.jpg", "published": true, "publishedAt": "2026-03-04T11:00:00.000Z", "views": 42, "shares": 5, "createdAt": "2026-03-04T10:00:00.000Z", "updatedAt": "2026-03-04T11:00:00.000Z"}