Studio API
Everything the AI Studio does, over HTTP. Create a key on the studio page (it acts as the wallet that made it) and send it as Authorization: Bearer riu_sk_…. Generations spend that wallet's credits. CORS is open.
KEY=riu_sk_…
curl -s https://v2.regwatchhq.org/api/studio/images \
-H "Authorization: Bearer $KEY" -H "content-type: application/json" \
-d '{"prompt":"my frog watching the chart go up, caption \"we are so back\"","kind":"meme"}'
# → 202 {"image":{"id":"…","status":"pending"},"balance":…}
curl -s https://v2.regwatchhq.org/api/studio/images/<id> -H "Authorization: Bearer $KEY"
# → {"image":{"status":"done","url":"/api/studio/images/<id>/file",…}}Credit price, per-image cost, and the StudioCredits contract per chain.
Credit a purchase. The contract event names the wallet credited; each purchase counts once.
{ "chainId": 4663000, "txHash": "0x…" }Wallet, balance and recent credit movements.
Start a generation. Answers 202 with a pending image; credits are taken now and refunded if it fails. kind: pfp | meme | free. size: 1K | 2K. token makes it a meme of that token and always includes the creator's pinned meme kit. postToX posts the finished image to the wallet's connected X account with that text.
{ "prompt": "my frog in a gold chain", "kind": "pfp", "size": "1K", "characterId": "…", "referenceIds": ["…"], "token": { "chainId": 4663, "address": "0x…" }, "postToX": "$TICKER gm" }A token's meme kit (the creator's pinned references and style notes) and its latest memes.
Token creator only: create or edit the meme kit. Pin references with /api/studio/characters/:kitId/pins.
{ "name": "$FROG", "notes": "green frog, gold chain, comic outlines" }Post a finished image to the wallet's connected X account. Connecting X is done on the site.
{ "text": "$FROG gm" }Poll one image until status is done or failed.
Your images, newest first. ?limit=&before=&kind=
The image bytes. Public by id; add ?download for an attachment.
Hide an image from your gallery and unpin it.
Upload a reference image.
multipart field "file" (or a raw image body), up to 8 MBYour characters with their pinned references.
Create a character.
{ "name": "Frog", "notes": "green, gold chain" }Pin a reference (max 10). Pinned references go with every generation for that character.
{ "imageId": "…" }Unpin a reference.
Errors are JSON { "error": "code" }: 401 no_pass, 402 insufficient_credits (with need and balance), 429 rate_limited (30 generations per 10 minutes per wallet), 503 studio_disabled.
