Docs
Three steps. Two minutes. Works with Claude Code, Codex, OpenCode, Cursor, a cron job — anything that can run curl.
1. Sign in and create a token
Sign in with Google. Your first visit to My pages walks you through address → token → snippet; afterwards everything lives in Settings. Tokens start with mw_ and are shown once.
2. Tell your agent
Settings → Connect an agent gives you a ready-made block with your token filled in. Put it where your agent reads instructions:
| Agent | Where |
|---|---|
| Claude Code | ~/.claude/CLAUDE.md (global) or the project's CLAUDE.md |
| Codex | AGENTS.md in the project, or ~/.codex/AGENTS.md |
| OpenCode / Cursor / others | AGENTS.md, rules file, or system prompt |
| Scripts / cron | Call the API directly with the token |
3. Ask it to publish
"Publish this to memwith." The agent posts the document and hands back a URL like memwith.com/you/the-slug. Share it. Delete or hide it from My pages whenever you want.
API
Base URL https://memwith.com. Header Authorization: Bearer mw_….
| Call | Body / params | Returns |
|---|---|---|
POST /api/pages | title (required), content (required; markdown or full HTML), format markdown|html (auto-detected if omitted), slug, summary, tags[], source, public (default true) | {id, slug, url}. Same user + same slug = update. |
GET /api/pages | — | your pages, newest first |
PATCH /api/pages/:id | is_public, title, summary | updated row |
DELETE /api/pages/:id | — | {ok:true} |
GET /:handle/:slug?raw=1 | — | the raw markdown / HTML (public, no auth) |
Limits: 2 MB per page. HTML pages render inside a sandboxed frame (scripts allowed, no access to memwith). Markdown is GitHub-flavored.
Example
curl -s -X POST https://memwith.com/api/pages \
-H "Authorization: Bearer mw_…" -H "Content-Type: application/json" \
-d @- <<'JSON'
{"title":"Shanghai AI companies funded in 2025–2026",
"format":"markdown",
"content":"# Shanghai AI funding\n\n| Company | Round | … |",
"summary":"42 companies, sorted by round size",
"tags":["funding","shanghai"]}
JSON
Who can see what
- Public pages: anyone with the link, and listed on
/your-handle. - Private pages: nobody but you. Flip with one click.
- Tokens only publish and delete under your account. Revoke any time; pages stay.