⌘Developer API
Generate images & videos programmatically, then fetch results by polling or signed webhooks. Available on the Studio plan.
Get an API key
API access is included on the Studio plan. Open Billing → API access → Generate key. The raw key (gr_live_…) is shown once — store it securely. Usage draws from your monthly credits. Building a higher-volume / B2B integration? Contact us.
Base URL & authentication
Send your key in the X-API-Key header on every request.
Base URL: https://api.genreach.app Header: X-API-Key: gr_live_…
Generate an image
/v1/images→ 202 { id, status, type }curl -X POST https://api.genreach.app/v1/images \
-H "X-API-Key: gr_live_…" -H "Content-Type: application/json" \
-d '{
"prompt": "a serene mountain lake at dawn",
"platform": "tiktok", // youtube | tiktok | instagram_reel | instagram_post
"resolution": "ultra", // standard 1K · hd 2K · ultra 4K
"locale": "en",
"metadata": { "my_ref": "post-123" } // echoed back on the webhook
}'Generate a video
/v1/videos→ 202 { id, status, type }curl -X POST https://api.genreach.app/v1/videos \
-H "X-API-Key: gr_live_…" -H "Content-Type: application/json" \
-d '{
"prompt": "3 quick sleep tips",
"platform": "tiktok",
"scene_count": 5, // 2–12
"hd": false,
"caption_style": "word", // word | clean | bold-pop | none
"locale": "en"
}'Fetch the result
/v1/jobs/{id}status + result_url when done (tenant-scoped)/v1/usageyour job counts by status (metering)Either poll /v1/jobs/{id} until status is completed (then read result_url), or — better — register a webhook and we'll push the result.
Webhooks (recommended)
Set a webhook URL when your key is provisioned. On a job's terminal state we POST a signed event to it:
{ "id": "<event_id>", "type": "job.completed", // or job.failed
"created": 1718000000,
"data": { "job_id": "…", "status": "completed", "type": "image",
"result_url": "https://cdn…/x.webp", "error": null,
"metadata": { "my_ref": "post-123" } } }Verify the X-Genreach-Signature: t=<ts>,v1=<hmac> header — HMAC-SHA256 of "{t}.{raw_body}" with your webhook secret. Reject if the timestamp is stale or the HMAC mismatches:
import hmac, hashlib, time
def verify(secret: str, raw_body: bytes, header: str, tol: int = 300) -> bool:
p = dict(kv.split("=", 1) for kv in header.split(","))
if abs(time.time() - int(p["t"])) > tol:
return False
mac = hmac.new(secret.encode(), f'{p["t"]}.'.encode() + raw_body, hashlib.sha256).hexdigest()
return hmac.compare_digest(mac, p["v1"])Delivery is at-least-once with exponential-backoff retries (1m → 6h), so dedupe on event.id and respond 2xx quickly.
Notes
- Rate limits: 120/min (images), 60/min (videos) — back off on
429. - Idempotency: include an
idempotency_keyinmetadataand dedupe on your side. - Generate-only: the API returns assets; you publish to your own connected accounts (managed-publish is on the roadmap).
- Billing: usage draws from your plan's monthly credits (same costs as the app).
Questions? [email protected]