Screenshot
Capture a homepage screenshot of any website as a base64-encoded PNG. Returned inline in the response — no CDN URL.
Endpoint: GET /v1/brand/screenshot
Credits: 5 per request
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
domain | string | Yes | Domain to screenshot (e.g., stripe.com) |
Response Schema
{
"data": {
"domain": "stripe.com",
"url": "https://stripe.com/",
"format": "png",
"width": 1440,
"height": 900,
"image_base64": "iVBORw0KGgoAAAANSUhEUgAA..."
},
"_meta": {
"timing": { "fetch_ms": 6210, "total_ms": 6350 },
"cache": { "hit": false }
}
}Code Examples
cURL
curl -X GET "https://api.orsa.dev/v1/brand/screenshot?domain=stripe.com" \
-H "Authorization: Bearer YOUR_API_KEY"TypeScript
const { data: shot } = await client.brand.screenshot({
domain: 'stripe.com',
});
// Save the inline PNG to disk
import { writeFileSync } from 'node:fs';
writeFileSync('stripe.png', Buffer.from(shot.image_base64, 'base64'));Python
import base64
res = client.brand.screenshot(domain="stripe.com")
shot = res["data"]
with open("stripe.png", "wb") as f:
f.write(base64.b64decode(shot["image_base64"]))Error Codes
| Code | Status | Description |
|---|---|---|
INPUT_VALIDATION_ERROR | 400 | Missing or invalid domain |
UNAUTHORIZED | 401 | Missing or invalid API key |
SERVICE_UNAVAILABLE | 503 | Browser pool unavailable |
RATE_LIMITED | 429 | Rate limit exceeded |
USAGE_EXCEEDED | 402 | Insufficient credits |
Notes
- Captures the homepage (
https://<domain>/) at desktop viewport (1440x900), PNG format, above-the-fold only. - The image is returned inline as base64 — decode it client-side and write to disk or upload to your own storage.
- Custom viewport sizes, full-page captures, dark mode, JPEG output, and CDN-hosted URLs are not currently supported.