RoofRender API
Render photorealistic roof previews from your own app or website. Send a photo of a house plus a material and color; get back a rendered image in about 20 seconds.
Base URL: https://roofrender.app
Quickstart
Your first render in one command. Replace the key with yours and point at any photo of a house; about 20 seconds later the JSON response contains your rendered image URL.
curl -X POST https://roofrender.app/api/v1/render \
-H "Authorization: Bearer YOUR_API_KEY" \
-F "image=@house.jpg" \
-F "material=Standing Seam Metal" \
-F "color=Onyx Black"Or send a link to the photo as JSON:
curl -X POST https://roofrender.app/api/v1/render \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: 6f1c2e0a-3d4b-4a77-9e1f-2b8c5d7a9e10" \
-d '{"image_url":"https://example.com/house.jpg","material":"Architectural Shingle","color":"Timberline HDZ Charcoal","contractor_id":"acme-roofing"}'Authentication
Every request needs an API key, available on Growth and Professional plans. Send it as a header, either way works:
Authorization: Bearer YOUR_API_KEY
X-API-Key: YOUR_API_KEYRenders draw from your plan's monthly renders. Call the API from your server, never from a browser: the key would be public, and the render endpoint does not allow browser (CORS) requests. Platforms get a server-only API key that the website widget refuses; contact us to get one, rotate a key or revoke it.
Render a roof
POST /api/v1/render with multipart/form-data or application/json. Send the photo one way only.
| Field | Type | Description |
|---|---|---|
| image | file | The photo, multipart only. JPEG, PNG, WebP or HEIC (iPhone). Requests over 4.5 MB are refused before they reach us, so send large photos as image_url. |
| image_url | string | A public https link to the photo, up to 10 MB. Best for full-size phone photos. |
| image_base64 | string | The photo as base64, JSON only. Counts towards the 4.5 MB request limit. |
| material | string | Required. A material name from GET /api/v1/materials. |
| color | string | Required. A colour listed for that material. |
| quality | string | "hd" (default): the render at your photo's proportions. "ultra_hd": drawn at 2K, slower; Growth and Professional. |
| contractor_id | string | Optional. Your id for the contractor this render is for (1-100 of A-Z a-z 0-9 _ - . : @). Returned with the render and counted in /api/v1/usage. |
| logo / logo_url | file / string | Optional. A logo placed on the render (PNG recommended; JPEG, WebP, or SVG with text converted to outlines; up to 1 MB), about 18% of the image width. |
| logo_position | string | bottom-right (default), bottom-left, top-right or top-left. |
Header Idempotency-Key (optional, a UUID per render): if a request times out and you retry with the same key, you get the first render back instead of a second charge. While the first is still rendering, the retry answers 409 in_progress.
Before rendering we straighten phone photos saved sideways, convert HEIC, WebP and PNG to JPEG, and scale photos over 2,560 pixels down to that. The roof is found automatically: no mask needed. Only the roof changes; walls, windows and landscaping stay as they are.
Example response
{
"render_id": "8d3f6a2e-1b4c-4f0e-9a7d-2c5b8e1f4a60",
"render_url": "https://...signed image URL...",
"expires_in": 7200,
"material": "Architectural Shingle",
"color": "Timberline HDZ Charcoal",
"quality": "hd",
"contractor_id": "acme-roofing",
"width": 2048,
"height": 1536,
"renders_remaining": 942
}The link is valid for 2 hours: save the image on your side, or get a fresh link with the render_id. A render takes about 20 seconds (Ultra HD longer); use a client timeout of 300 seconds. Small photos add a warnings list.
Get or delete a render
GET /api/v1/renders/{render_id} returns a fresh 2-hour link and the render's details. DELETE /api/v1/renders/{render_id} deletes the render and the homeowner's photo for good, for example when a homeowner asks for their data to be deleted. Both need a server API key: a website widget key sits in your public page, so it can render but not read or delete.
curl -X DELETE https://roofrender.app/api/v1/renders/RENDER_ID \
-H "Authorization: Bearer YOUR_API_KEY"Usage
GET /api/v1/usage?from=2026-11-01&to=2026-11-30 returns the renders left this month, banked renders, credits, when the month refills, and how many API renders each contractor_id had in those dates (default: the last 30 days). Server API key only.
{
"plan": "pro",
"monthly_limit": 1000,
"used_this_month": 58,
"remaining_this_month": 942,
"banked": 0,
"credits": 0,
"remaining_total": 942,
"resets_at": "2026-12-14T00:00:00Z",
"period": { "from": "2026-11-01", "to": "2026-11-30" },
"api_renders": 58,
"by_contractor": [{ "contractor_id": "acme-roofing", "renders": 41 }, { "contractor_id": "bay-roofs", "renders": 17 }]
}List materials and colors
GET /api/v1/materials: no auth required. Returns every material with its category, description, and available colors (with hex values and the manufacturers' product lines, such as GAF Timberline HDZ), so your app can build pickers that stay in sync with our catalog.
curl https://roofrender.app/api/v1/materialsErrors
Errors return JSON { "error": "...", "code": "..." }. Branch on code; error is for people. A failed render is never charged.
| Status | code | What to do |
|---|---|---|
| 400 | invalid_request, missing_image, invalid_image, image_url_invalid, image_url_failed, image_url_not_image, invalid_material, invalid_color, color_not_for_material, invalid_quality, invalid_contractor_id, invalid_idempotency_key, invalid_logo | Fix the request; the message says what. Values come from /api/v1/materials. |
| 401 | missing_key, invalid_key | Send your key in the Authorization header exactly as shown above. |
| 402 | out_of_renders | The account has no renders left this month. Renders refill with the billing month; we can add more on request. |
| 403 | plan_required, subscription_inactive, quality_not_in_plan, server_key_required | The API needs an active Growth or Professional plan; Ultra HD too. Renders and usage need a server API key. |
| 404 | not_found | No render with that render_id on your account. |
| 409 | in_progress | A render with this Idempotency-Key is still running. Retry after the Retry-After seconds. |
| 413 | image_too_large | Over 10 MB. Request bodies over 4.5 MB are refused before reaching us, as plain text (FUNCTION_PAYLOAD_TOO_LARGE): send image_url instead. |
| 415 | invalid_request | Use multipart/form-data or application/json. |
| 422 | photo_rejected, idempotency_key_reused | The photo could not be rendered: try another photo. Or the Idempotency-Key was already used for a different request: use a new key. |
| 429 | rate_limited | Too many renders a minute for this key. Wait the Retry-After seconds. |
| 500 | storage_failed, internal_error | Retry after a few seconds. |
| 502 | render_failed | Busy or failed. Retry after the Retry-After seconds; use the same Idempotency-Key. |
| 504 | timeout | Took too long and was stopped (not charged). Retry with the same Idempotency-Key. |
Each key may start 10 renders a minute by default; we raise it to match your volume.
Website widget
Prefer a no-code option? The same renders are available as a drop-in widget for your website: one iframe line, no programming. Your key is in your dashboard under Website widget and API, with this line already filled in.
<iframe src="https://roofrender.app/embed/YOUR_EMBED_KEY" width="100%" height="900" style="border:0;max-width:720px;" allow="camera"></iframe>
<script src="https://roofrender.app/embed.js" async></script>MCP server (AI assistants)
RoofRender is also available as an MCP server, so AI assistants like Claude can render roofs as a tool: ask for a house photo in a material and color, get the rendered image back in the conversation. Uses your regular API key and the same plan quota.
Endpoint
https://roofrender.app/api/mcpFour tools are exposed: list_roof_materials, render_roof (returns the image inline), get_account_usage, and list_recent_renders.
render_roof takes an optional quality: "hd" (default, returned at the photo's own dimensions) or "ultra_hd" (2K, Growth and Pro plans, slower). Send the original full-size photo, ideally 1500+ pixels on the long side.
ChatGPT
Enable Developer mode in ChatGPT's settings (its location in the settings menu varies by plan), then create a new connector/plugin with the endpoint URL above and OAuth as the authentication method. You'll be sent to RoofRender to log in and approve. No key handling needed.
Claude (claude.ai)
Settings → Customize → Connectors → "Add custom connector". Enter any name and the endpoint URL above, leave the advanced OAuth fields blank, click Add, then log in and approve when prompted.
Claude Code / other dev tools (API key)
claude mcp add --transport http roofrender https://roofrender.app/api/mcp \
--header "Authorization: Bearer YOUR_API_KEY"Codex (config file)
[mcp_servers.roofrender]
url = "https://roofrender.app/api/mcp"
http_headers = { "Authorization" = "Bearer YOUR_API_KEY" }AI apps reorganize these menus often. If a step doesn't match what you see, search your AI app's help for "add custom MCP connector". The endpoint and OAuth flow above stay the same regardless of client.
Get an API key
API access is included with Growth and Professional plans. Your key is in the dashboard under Website widget and API. Anything off, email us.