API and AI assistants
Give your assistant a key, describe your idea, and open the result in ALTEGO. Your AI uses the same pages, blocks and effects as the editor.
Connect your assistant
ALTEGO_API_KEY in its secret store.Use https://altego.club/api/v1/guide and its OpenAPI schema to build my ALTEGO page. My API key is configured in your secret store as ALTEGO_API_KEY. Read https://altego.club/api/v1/catalog for block defaults and effects. Create a draft from my brief and return its editor link. Ask me before publishing. For edits, fetch the current document and revision first. Preserve fields I did not ask to change.
Keys and permissions
Each key accesses only its owner’s pages. Keys cannot access other accounts or admin controls. Keep the key in the assistant’s secret settings, outside public prompts, page content and source control.
Authorization: Bearer YOUR_KEY Content-Type: application/json User-Agent: ALTEGO-Agent/1.0
| Permission | What it allows |
|---|---|
pages:read | Read your pages and assets. Always included. |
pages:write | Create and edit drafts. |
assets:write | Upload images and fonts. |
pages:publish | Publish, unpublish and modify live pages. |
Publishing is off by default. Editing a live page needs both write and publish permissions. Keys expire in 1–365 days and can be revoked at any time in Settings → API.
Endpoints
Base URL: https://altego.club/api/v1. Private endpoints require your Bearer key. The guide, schema and catalog are public.
| Request | Action |
|---|---|
GET /me | Check the account and key permissions. |
GET /catalog | Read block defaults and effect presets. |
GET /pages | List your pages and revisions. |
POST /pages | Create a draft from a name, handle and blocks. |
GET /pages/{id} | Read a complete page document. |
PUT /pages/{id} | Replace the document with its expected revision. |
PUT /assets/{id} | Upload an image or font as raw bytes. |
GET /assets/{id} | Download your stored asset. |
POST /pages/{id}/publish | Publish a page. |
POST /pages/{id}/unpublish | Return a page to draft. |
Your first API page
Set ALTEGO_API_KEY in your environment, then run this Python example. It creates one draft and prints its editor link.
import json, os, uuid, urllib.request
body = {"operationId": str(uuid.uuid4()), "page": {
"handle": "ai-" + uuid.uuid4().hex[:12],
"name": "Built with AI",
"blocks": [{"type": "heading", "text": "Hello, world"}]}}
request = urllib.request.Request(
"https://altego.club/api/v1/pages",
data=json.dumps(body).encode(), method="POST",
headers={"Authorization": "Bearer " + os.environ["ALTEGO_API_KEY"],
"Content-Type": "application/json",
"User-Agent": "ALTEGO-Agent/1.0"})
with urllib.request.urlopen(request) as response:
page = json.load(response)
print("https://altego.club/#/edit/" + page["document"]["handle"])Effects and layers
Use the block and effect catalog for complete defaults and the available preset IDs. Place blocks with frame: {x, y, w, h} on the 1280 px desktop canvas; phone and tablet layouts adapt automatically.
The block array controls layer order: first at the back, last in front. Effects accept custom colors, transparent alpha and opacity from 0 to 100. Use #RRGGBBAA for effect colors with transparency.
Upload images or fonts before saving the page. Images use {kind: "upload", key: "asset UUID"}; an effect’s photo field takes the asset UUID directly. Upload IDs are immutable.
Publishing and retries
To update a page, fetch its complete document and revision. Send the modified document with expectedRevision and a fresh operationId. Preserve fields you did not intend to change.
After a timeout, retry the exact same body and operation ID. A revision conflict returns 409: fetch the current page, reconcile your changes, then use a new operation ID. There is no page deletion endpoint in v1.
| Status | Meaning |
|---|---|
| 401 | Invalid, expired or revoked key. |
| 403 | Missing permission. An edge rejection may also occur before the API; use the client identity shown above. |
| 404 | Page or asset missing, or belongs to another account. |
| 409 | Revision, handle or operation ID conflict. |
| 413 / 415 | Size limit or unsupported upload. |
| 429 | Rate limit; wait before retrying. |
Read the full API guide for all limits, error codes and upload formats.