---
title: "Create or update an article"
method: POST
path: "/api/articles"
tags: ["Articles"]
---

# Create or update an article

`POST /api/articles`

## Request

- Base URL: `https://www.polyblog.io`
- URL: `https://www.polyblog.io/api/articles`
- Auth: one of:
  - HTTP basic
  - API key in header `Authorization`

Creates an article (or updates one when the body carries an existing `_id`). Requires the `articles:write` scope. Fires the `article.created` webhook.

## Request body

- object
  - `blogId` string
  - `title` string
  - `content` string
  - `slug` string
  - `locale` string
  - `published` boolean

## Response `200`

The created or updated article

## Other responses

- `401`: Missing or invalid credentials
- `403`: API key is missing the `articles:write` scope
- `429`: API key rate limit exceeded

---

[API](https://skmtc.dev/polyblog/apis/polyblog-api.md) · [All operations](https://skmtc.dev/polyblog/apis/polyblog-api/llms.txt) · [OpenAPI document](https://skmtc.dev/polyblog/apis/polyblog-api/revisions/b0d2db9337ab?raw)
