Owner and repository name, description, stars, forks and language — a repository social card.
This is a real render from the API with the example values below, at 1200×630.
For open-source projects, package pages and developer blogs. Flat and white like the repository cards developers already recognise, with the language colour as a bar along the bottom — set accent to your language's colour.
Every field is optional. Long text shrinks to fit instead of overflowing; an image field takes a public URL that we fetch on our side.
| Field | Type | Description | Example |
|---|---|---|---|
repo |
text | Repository name. default: repository | og-kit |
owner |
text | Repository owner (user or organisation). | northwind |
description |
text | Repository description. | Typed helpers for generating Open Graph images at build time and on the edge. |
stars |
text | Star count, e.g. 12.4k. | 12.4k |
forks |
text | Fork count, e.g. 1.1k. | 1.1k |
language |
text |
Main programming language. Set accent to its colour.
|
TypeScript |
site |
text | Host shown in the corner, e.g. github.com. | github.com |
avatar |
image URL | Owner avatar or project logo. | https://example.com/images/logo-northwind.png |
accent |
colour | Brand colour as hex, e.g. #6366f1. Drives buttons, highlights and the background glow. default: #3178c6 | #3178c6 |
theme |
dark | light | Colour scheme: dark or light. default: light | — |
Use the slug as template. The response holds the URL of the finished PNG; ?wait=true keeps the connection open until it is ready.
curl -X POST "https://imageapi.benchkithq.com/v1/images?wait=true" \
-H "Authorization: Bearer sk_live_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{
"template": "github-repo",
"modifications": {
"repo": "og-kit",
"owner": "northwind",
"description": "Typed helpers for generating Open Graph images at build time and on the edge.",
"stars": "12.4k",
"forks": "1.1k",
"language": "TypeScript",
"site": "github.com",
"avatar": "https://example.com/images/logo-northwind.png"
}
}'
For static sites, Webflow, Shopify and no-code tools: put the fields in the query string and sign it with your signing secret. The first request renders the image, every later one is a redirect to the cached file. How to compute the signature.
<meta property="og:image" content="https://imageapi.benchkithq.com/i/acc_YOUR_ACCOUNT_ID/github-repo.png?description=Typed%20helpers%20for%20generating%20Open%20Graph%20images%20at%20build%20time%20and%20on%20the%20edge.&forks=1.1k&language=TypeScript&owner=northwind&repo=og-kit&site=github.com&stars=12.4k&s=YOUR_SIGNATURE">
accent and theme change per request. For anything more, copy the template into your account: you get an ordinary HTML template with the same fields that you can edit in the dashboard or through the API. If the slug is free on your account, the copy takes it — your integrations switch to your version without changing a line.
curl -X POST "https://imageapi.benchkithq.com/v1/templates/library/github-repo/copy" \
-H "Authorization: Bearer sk_live_YOUR_KEY"