Create document
POST /api/documents
Publishes a new markdown document to a shareable URL. Free tier users get nanoid-based URLs with 7-day expiry. Pro+ users can set custom filenames for user-scoped URLs (/@username/slug). Returns 403 if the user’s plan document limit is reached.
Request Body
Section titled “Request Body ”Body
Request body for creating a new document
object
Markdown content (max 1MB)
Optional title (max 200 chars)
Custom filename (Pro+ only, e.g., meeting-notes)
Whether the document is publicly accessible
Responses
Section titled “ Responses ”Full document with content and metadata
Full document with content and metadata
object
Unique document ID
URL-friendly identifier
Full markdown content
R2 object storage key
URL scheme: nanoid (free), user_scoped (/@username/slug), subdomain
Owner user ID
Current status of the document
Whether the document is publicly accessible
Number of times the document was viewed
Creation timestamp
Last update timestamp
Standard error response
Standard error response
object
Error code or short description
Human-readable error details
Standard error response
Standard error response
object
Error code or short description
Human-readable error details
Standard error response
Standard error response
object
Error code or short description
Human-readable error details