---
title: "Update a document you own"
method: POST
path: "/{slug}"
---

# Update a document you own

`POST /{slug}`

## Request

- Base URL: `https://lucid.page`
- URL: `https://lucid.page/{slug}`
- Auth: one of:
  - HTTP bearer
  - API key in query parameter `apiKey`
  - none

Replaces the Markdown source; the URL is stable and every update is stored as a revision. Requires an lp_ API key or session.

## Path parameters

- `slug` string, required

## Request body

- object
  - `markdown` string, required
  - `title` string, nullable

## Response `200`

Updated

- UpdateResponse
  - `slug` string, required
  - `revision_hash` string, required
  - `visibility` string, required
  - `url` string, required

## Other responses

- `401`: Authentication required
- `404`: Not found (or owned by someone else)

---

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