Publish posts with the blog API

Create, edit, and publish blog posts from your server, automation tools, or AI agents. Covers keys, permissions, limits, and errors.

With the blog API, your own server, automation tools (n8n, Zapier, Make), or AI agents can create, edit, and publish posts on your Weekerp blog. You can upload images too.

 

What you can do

Task Method · path Permission
Issue an API key In the dashboard —
Edit or revoke an API key In the dashboard —
Create an empty post (draft) POST /posts write
List posts GET /posts read
Get a post GET /posts/{id} read
Update a post PUT /posts/{id} write · publish for published posts
Delete a post DELETE /posts/{id} write · publish for published posts
Get a post by externalId GET /posts/external/{externalId} read
Sync a post by externalId PUT /posts/external/{externalId} write · publish for published posts
Publish a post POST /posts/{id}/publish publish
Schedule a post POST /posts/{id}/publish publish
Unpublish a post POST /posts/{id}/unpublish publish
Upload an image POST /uploads write
List categories GET /categories read
List authors GET /authors read
Example code (full flow) — —

 

Basics

Item Value
Base URL https://api-open.weekerp.com/blog/v1
Authentication Authorization: Bearer <API key>
Format JSON (UTF-8). Uploads use multipart/form-data
Time ISO-8601, UTC (e.g. 2026-12-01T09:00:00Z)
  • Only https:// is accepted. Requests sent over http:// return 403.
  • A key works only for the blog it was issued for.

To check that your key works, read the category list first.

curl https://api-open.weekerp.com/blog/v1/categories \
  -H "Authorization: Bearer wk_live_xxxxxxxx"

 

Permissions

Each key has one permission level. A higher level can do everything a lower level can.

What you can do Read only (read) Write only (write) Full access (publish)
Read posts, categories, authors ✅ ✅ ✅
Create, edit, delete drafts ✅ ✅
Upload files ✅ ✅
Publish, schedule, unpublish ✅
Edit or delete published posts ✅

Changes to a published post go live on your blog as soon as you save them. That is why only full-access keys can edit or delete published posts.

For AI agents and outside automation, we recommend a Write only key. The AI uploads drafts, and someone on your team reviews and publishes them.

 

Limits

Each key has its own limits. When you issue or edit a key, you can change them under Advanced options, up to the maximum.

Limit Default Maximum
Requests per minute 60 120
New posts per day 50 200
Uploads per day 200 1,000
  • Daily counts reset at midnight UTC.
  • New posts per day counts only newly created posts. Editing, publishing, or upserting an existing post does not count.
  • When you go over a limit, you get 429 with a Retry-After header (in seconds). Wait that long, then send the same request again.

 

Error format

Every error has the same shape.

{ "error": { "code": "post_not_found", "message": "Post not found.", "status": 404 } }
  • Branch on code. message is a human-readable English description and its wording may change.
  • You can safely retry 429, 500, and 503. For other 4xx responses, fix the request before sending it again.
  • If you need to retry creating a post (POST /posts), use the externalId upsert instead. It never creates the same post twice.
HTTP code Meaning
400 invalid_value · invalid_request · invalid_type A value or the request shape is wrong. message names the field
400 lang_invalid The language code is not two lowercase letters
400 post_slug_invalid · post_slug_reserved The slug format is wrong, or the slug can't be used
400 post_external_id_invalid The externalId format is wrong
400 post_author_required No author could be set. Add author
400 post_category_invalid One of the category codes doesn't exist
400 post_content_unsafe The content contains executable HTML
400 post_duplicated_toc_id Two headings in the content are the same
400 post_not_publishable The post can't be published without a title, content, and author
400 upload_empty_file · upload_invalid_extension · upload_file_too_large Empty file, unsupported format, or over 50 MB
401 api_key_missing · api_key_invalid The key is missing, wrong, or revoked
403 api_key_scope_insufficient The key's permission is not enough. message names the permission you need
404 post_not_found · author_not_found · not_exist_api The post, author, or path doesn't exist
409 post_slug_duplicated · post_external_id_duplicated The same slug or externalId already exists in that language
409 post_slug_immutable A published post's slug can't be changed
429 rate_limited · daily_post_limit_exceeded · daily_image_limit_exceeded You went over a limit
500 · 503 internal_server_error · image_service_unavailable Try again in a moment

 

Versioning

  • While the URL stays at v1, response fields are only ever added. Make your code ignore fields it doesn't know.
  • New error codes may appear. Handle unknown codes by their HTTP status.

If you get stuck while using the API, let us know through a technical inquiry.