Generate Images
How to generate several images at once - Abyssale REST API
Last updated
How to generate several images at once - Abyssale REST API
Last updated
Multiple images can be created at once by sending data and customisation parameters to the POST /async/banner-builder/{template_id}/generate
endpoint, which will respond synchronously with only a generation_request_id
property.
Supported template type: Static
Generation response type: Asynchronous (Webhooks or Polling)
The elements
property is the same as Generate Image.
callback_url
request parameter and the asynchronous mechanismAs this method is asynchronous you should provide a callback_url
. The NewBannerBatch
event will be POSTed to this URL when the generation batch finishes.
To discover globally how this system works, check out the following Webhooks guide:
WebhooksDo not forget to replace {YOUR-API-KEY}
and {templateId}
All formats of a template can be generated by removing the template_format_names
property.
Generate multiple formats of an image at once from a template designed in Abyssale.
This method is asynchronous and allows to generate several images with one API call. Of course, it can also be used for single image generation (because of time-constraints for instance).
You can find available formats & elements of a template by calling the GET /templates/{templateId} route.
Unique identifier (UUID) of the template
A dictionary
containing all elements with properties you would like to override form the default template (keys correspond to layer names)
Format IDs you would like to generate.
The array can be empty or not provided if you want to generate all formats of this template.
The url that will be called once generation of your images is done.
We will do a POST
request of the NewBannerBatch event on this URL with a JSON payload.
Ok
Unique identifier (UUID) of the batch generation