Screenshot API Webhook
Receive screenshots asynchronously via POST requests to your own endpoint. Perfect for background processing, custom pipelines, and event-driven architectures.
How Webhooks Work
Instead of waiting for the screenshot response, you can provide a webhook URL. GetScreenshot will capture the screenshot and POST the results to your endpoint when ready.
This is ideal for long-running captures, batch processing, or when you don't want to keep connections open waiting for screenshots to complete.
API Parameter
webhook=https://your-server.com/webhook
Provide any URL that can receive POST requests. The screenshot data will be sent as JSON when the capture completes.
Process Flow
-
1
You make an API request with webhook parameter
Request returns immediately with confirmation
-
2
GetScreenshot captures the webpage
Processing happens in the background
-
3
Results POSTed to your webhook URL
JSON payload with screenshot URL and metadata
Example Request
https://api.rasterwise.com/v1/get-screenshot
?apikey=YOUR_API_KEY
&url=https://example.com
&webhook=https://your-app.com/webhook
Webhook Payload (POST)
// POST to your webhook URL
{
"screenshot": "https://cdn.rasterwise.com/...",
"url": "https://example.com",
"width": 1280,
"height": 800,
"format": "png",
"timestamp": "2026-01-18T12:00:00Z"
}
When to Use Webhooks
Async screenshot delivery for advanced workflows
Batch Processing
Queue hundreds of screenshot requests and process results as they complete. No need to manage open connections or timeouts.
Background Jobs
Trigger screenshots from background workers and let your job queue handle the webhook responses when they arrive.
Serverless Functions
Perfect for AWS Lambda, Cloudflare Workers, or Vercel Edge Functions where you can't hold long connections.
Website Monitoring
Schedule periodic screenshots and receive webhooks when captures complete for visual regression testing or uptime monitoring.
Learn moreEvent Pipelines
Integrate screenshots into event-driven architectures. Trigger downstream processes when screenshots are ready.
Long Captures
For complex pages that take time to render, webhooks let you avoid timeout issues while still getting results.
Implementation Examples
Receive webhooks in your favorite language
Node.js / Express
// Webhook endpoint to receive screenshots
app.post('/webhook/screenshot', (req, res) => {
const { screenshot, url, width, height } = req.body;
// Process the screenshot
console.log(`Screenshot ready: ${screenshot}`);
// Save to database, send notification, etc.
saveScreenshot({ screenshot, url, width, height });
res.status(200).send('OK');
});
Python / Flask
# Webhook endpoint to receive screenshots
@app.route('/webhook/screenshot', methods=['POST'])
def handle_screenshot():
data = request.get_json()
screenshot_url = data['screenshot']
original_url = data['url']
# Process the screenshot
save_to_storage(screenshot_url)
return 'OK', 200
Related Features
Combine webhooks with other capabilities
Ready to Use Screenshot Webhooks?
Get started with GetScreenshot's affordable plans. Webhook delivery included in all tiers.