---
title: "Draft a page from notes"
description: "Turns rough notes into a page in Markdown."
canonical_url: https://docs.markdrop.in/api/page-ai/draft-a-page-from-notes
last_updated: 2026-11-04
site: "Markdrop Docs"
index: https://docs.markdrop.in/llms.txt
---

# Draft a page from notes

`POST https://api.markdrop.in/api/v1/ai/pages/notes`

Turns rough notes into a page in Markdown. Streams the result as server-sent events: `delta` events with text as it's written, then `done` (or `limit` when a limit stops it). Nothing is saved: create the page with [Create a page](https://docs.markdrop.in/api/pages/create-a-page).

- **Authentication:** API token required: `Authorization: Bearer mdk_…`.
- **Rate limit:** 30 per minute per IP address.
- **Guide:** [AI in pages](https://docs.markdrop.in/pages/ai)

## Request body

`application/json`, required.

- `notes` (string, required): The rough notes. Up to 42,000 characters.
- `template` (string): A built-in template's id to shape the page, or `auto` to let AI choose. Up to 64 characters.
- `title` (string): A title for the page. Up to 200 characters.
- `workspace` (string): The workspace the page will go in (members and up). Its AI setting and limits apply. Up to 64 characters.

## Responses

- `200`: OK.
- `401`: No token, or the token is revoked or mistyped.
- `422`: The request didn't validate. `detail` lists each problem, with where it is (`loc`) and why (`msg`).
- `429`: Too many requests from your IP address. Wait the seconds in `Retry-After`.

## Examples

**curl**

```bash
curl -X POST https://api.markdrop.in/api/v1/ai/pages/notes \
  -H "Authorization: Bearer $MARKDROP_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"notes":"kickoff thurs, sam owns api, ship by 20th","template":"auto"}'
```

**JavaScript**

```javascript
const res = await fetch("https://api.markdrop.in/api/v1/ai/pages/notes", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.MARKDROP_TOKEN}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    "notes": "kickoff thurs, sam owns api, ship by 20th",
    "template": "auto"
  }),
});
const data = await res.text();
```

**Python**

```python
import os

import requests

r = requests.post(
    "https://api.markdrop.in/api/v1/ai/pages/notes",
    headers={"Authorization": f"Bearer {os.environ['MARKDROP_TOKEN']}"},
    json={
        "notes": "kickoff thurs, sam owns api, ship by 20th",
        "template": "auto",
    },
)
r.raise_for_status()
print(r.text)
```
