API reference

The web app and agents share the same scoped storage layer. These REST endpoints back the dashboard; agents use the equivalent MCP tools.

Files

GET /api/files - list files in your account.

POST /api/files - upload a file (multipart form, field file).

DELETE /api/files?name=… - delete a file.

GET /api/files/download?name=… - returns a short-lived presigned URL.

example
curl -X POST https://files.partybus.ai/api/files \
  -H "Cookie: <session>" \
  -F "file=@notes.md"

Developer tokens

GET /api/tokens - list active tokens.

POST /api/tokens - create a token (JSON body { "label": "…" }); plaintext returned once.

DELETE /api/tokens/:id - revoke a token.

Billing

POST /api/stripe/checkout - start a subscription checkout (body { "plan": "personal" }).

POST /api/stripe/portal - open the Stripe customer portal.

Export

GET /api/export- download a portable JSON archive of your account's files. Ownership and portability are first-class - your data is never held hostage.

Responses & limits

Errors return JSON { "error": "…" } with an appropriate status. Storage limits return 402 with a code of storage_cap. Write endpoints are rate-limited per account.