Agent API
Call the hosting API with an API key: plan limits, curl examples, and error codes.
Who it's for
Agents and owners who host HTML with a key from Account.
Steps
- New here? — Create an account and host your first page.
- Create a key — Click Create on Account. The full
hp_live_…key shows once; later you only see a prefix. Revoke, then Create, to replace it. - Authorize —
Authorization: Bearer hp_live_…onhttps://www.htmlput.com. No Turnstile. Quota, size, and review still apply. About 30 requests a minute. Spec at/openapi.json. - Plan — Bearer only; cookies stay as they are. Pricing. Free: paste, list, read. Plus: edit and delete pasted pages. Pro/Ultra: zip/folder upload, re-upload, and delete uploaded sites. Ultra has larger limits and zip video. Low plan →
403API_PLAN_REQUIREDwithrequiredPlanplusorpro. - Hosting endpoints —
GET/POST /api/v1/hosting/pages,GET/PUT/DELETE …/pages/PAGE_ID,POST …/bundle,PUT …/PAGE_ID/bundle. Paste returnsdata.shareUrlanddata.pageId(fileKeyfor page data). See Upload a zip or folder. - Page data (owner, same key) — On a page you own:
PUT/GET /api/v1/pages/{fileKey}/kv/settings(enable with{ "enabled": true }; optional schema /requireReview; may return a one-timewriteToken),POST …/kv/rotate-token,GET …/kv(list),POST …/kv/{key}/reviewwith{ "status": "approved" | "rejected" }. Full shapes in/openapi.json. - Tool types — List/read and page-data list/settings GET are Read. Paste, edit, delete, bundle, settings PUT, rotate, and review are Write. None is a sensitive write. Each call touches only your pages.
Gotchas
The key cannot call billing, account deletion, or admin.
Guest page-data writes use a page write-token, not this API key. Never put hp_live_… in front-end HTML. Prefer Page data, or wire the token: Wire page data into your own HTML. Overview: What page data is.
| HTTP | code | Meaning |
|---|---|---|
| 401 | API_KEY_INVALID | Bad or revoked key |
| 403 | API_PLAN_REQUIRED | Plan too low |
| 403 | API_ROUTE_NOT_AVAILABLE | Not this API |
| 429 | API_RATE_LIMITED | Over the minute cap |
| 400 | HOST_PASTE_TOO_LARGE | Paste too big |
| 400 | HOST_QUOTA_EXCEEDED | Storage full |