How do I create a screenshot via API?

Creating the Screenshot

You can create a screenshot by sending a POST request to /screenshots with a website URL, and a height and width.

Retrieving the Screenshot

You can poll the GET request to the /screenshots/:uid endpoint for status updates and retrieve the Screenshot object referenced by its uid.

Using a Webhook

By using a webhook, you can be notified when the screenshot is rendered. Use the webhook_url parameter to tell Bannerbear where to POST the full Screenshot object, once the rendering is completed. The screenshot object will be posted to your webhook as JSON.

Using a synchronous request

As an alternative to polling the GET endpoint or using webhooks, you can generate screenshots synchronously. This is where your API request is held open until the media file has finished generating. The API will then respond with the completed screenshot object. To make a synchronous request, use the synchronous base URL ( ). The API required attributes / parameters function the same as normal.

Check the API Reference ↗ page for more information on this.

Have a question?

Contact our customer support team anytime via chat or email