Webhooks

Last modified: October 20, 2021Author: Jakub Pomykała

Bannerly is a reliable, scalable, and easy to use API for customizing your own banners. We support webhooks that can trigger updates from any third-party system. Webhooks allow external services to be notified when certain events happen. When the specified events happen, we’ll send a POST request to each of the URLs you provide. To use webhooks with Bannerly, you can simply add a webhookUrl to your image or screenshot request.

Create Image Webhook

curl 
    --location 
    --request POST 'https://api.bannerly.io/api/v1/images' \
    --header 'X-API-KEY: <API_KEY>' \
    --header 'Content-Type: application/json' \
    --data-raw '{
        "template": "<TEMPLATE_ID>",
        "webhookUrl": "https://my-service.com/webhook-receiver"
        "changes": [
            {
              "id": "text_1f",
              "text": "Hello There!",
            }
            ...
        ],
    }'

Take a screenshot Webhook

curl 
    --location 
    --request POST 'https://api.bannerly.io/api/v1/screenshots' \
    --header 'X-API-KEY: <API_KEY>' \
    --header 'Content-Type: application/json' \
    --data-raw '{
        "url": "https://bannerly.io"
        "width": 1366,
        "height": 768,
        "webhookUrl": "https://my-service.com/webhook-receiver"
    }'

Resources