Quick Start — Generate Your First OG Image
Step 1 — Get Your API Key
Section titled “Step 1 — Get Your API Key”Sign up with your email. No credit card required.
Prefer the terminal? Use curl instead.
curl -X POST https://og-engine.com/auth/register \ -H "Content-Type: application/json" \ -d '{"email": "you@example.com"}'{ "apiKey": "oge_sk_a1b2c3...", "plan": "free", "limit": 500, "message": "API key also sent to you@example.com" }The API key is returned in the response and also emailed as a backup.
Step 2 — Generate Your First Image
Section titled “Step 2 — Generate Your First Image”curl -X POST https://og-engine.com/render \ -H "Authorization: Bearer oge_sk_a1b2c3..." \ -H "Content-Type: application/json" \ -d '{"format": "og", "title": "Hello, OG Engine"}' \ --output hello.pngStep 3 — Customize It
Section titled “Step 3 — Customize It”{ "format": "og", "title": "My First OG Image", "description": "Generated in ~22ms, no browser needed.", "tag": "Tutorial", "style": { "accent": "#38ef7d", "font": "Outfit", "layout": "left" }, "variables": { "author_name": "Jane Smith", "read_time": "5 min read" }, "images": { "avatar": "https://example.com/avatar.png" }}variables and images let you inject dynamic content into templates that support them — useful for author names, custom labels, or per-post artwork.
Try editing the title below — the image updates instantly:
0.0ms|1300× vs Puppeteer
Step 4 — Check If Text Fits (Free, Unlimited)
Section titled “Step 4 — Check If Text Fits (Free, Unlimited)”curl -X POST https://og-engine.com/validate \ -H "Content-Type: application/json" \ -d '{"format": "og", "title": "Some very long headline that might not fit..."}'{ "fits": true, "title": { "lines": 2, "maxLines": 3, "overflow": false }, "computeTimeMs": 0.12}Step 5 — Use the SDK (Optional)
Section titled “Step 5 — Use the SDK (Optional)”npm install @atypical-consulting/og-engine-sdkimport { OGEngine } from '@atypical-consulting/og-engine-sdk'
const og = new OGEngine('oge_sk_a1b2c3...')
const image = await og.render({ format: 'og', title: 'Hello from the SDK',})
await Bun.write('hello.png', image)Step 6 — Zero-Config: Render From a URL (Optional)
Section titled “Step 6 — Zero-Config: Render From a URL (Optional)”Skip the JSON entirely — point OG Engine at any URL and it scrapes the page’s OG tags automatically:
curl -X POST https://og-engine.com/render/from-url \ -H "Authorization: Bearer oge_sk_a1b2c3..." \ -H "Content-Type: application/json" \ -d '{"url": "https://myblog.com/posts/my-article", "format": "og"}' \ --output article-card.pngOr with the SDK:
const image = await og.renderFromUrl({ url: 'https://myblog.com/posts/my-article', format: 'og', style: { gradient: 'deep-sea' },})Next Steps
Section titled “Next Steps”- Explore the Templates Gallery to see all 12 available designs
- Learn about Formats & Templates for different platforms
- Dive into the API Reference for full endpoint details