POST https://api.sila.sh/v1/scrape
Request
{
"url": "https://example.com",
"formats": ["markdown"],
"render": "auto",
"screenshot": { "width": 1920, "height": 1080, "waitMs": 2000 }
}
| Field | Description |
|---|---|
url | Page to fetch. Required. |
formats | Any of markdown, html, signals, siteInfo, screenshot. Default ["markdown"]. |
render | auto (falls back to a headless browser when blocked), never (static only), always (headless). Default auto. |
screenshot | Size and wait time. Used with the screenshot format. |
robots.txt.
Response 200
Only the requested formats are present.{
"url": "https://example.com",
"finalUrl": "https://example.com/",
"statusCode": 200,
"renderedViaHeadless": false,
"creditsUsed": 1,
"markdown": "# Example",
"html": "<html>…</html>",
"screenshot": { "base64": "…", "mimeType": "image/png", "width": 1920, "height": 1080 },
"signals": {
"title": "Example", "description": null, "language": "en", "category": "content",
"ogImage": null, "imageUrls": [], "jsonLd": [], "forms": [], "integrations": []
},
"siteInfo": { "logoUrl": null, "siteName": "Example", "title": "Example" }
}
Errors
| Status | Code | Meaning |
|---|---|---|
| 400 | invalid_url | The URL is malformed or not safe to fetch. |
| 400 | invalid_request | The body is invalid. |
| 401 | unauthorized | Invalid API key. |
| 402 | credits_exhausted | No credits left. |
| 422 | target_http_error | The target returned a non-2xx status. |
| 429 | rate_limited | Too many requests. |
| 500 | fetch_failed | Sila could not fetch the page. |
{ "error": { "code": "target_http_error", "message": "HTTP 404: Not Found", "targetStatus": 404 } }