Abyssale Developer Hub
  • Getting Started
  • Rest API
    • Overview - Rest API
    • Authentication
    • Designs
      • Design Details
    • Generation
      • Design information
      • Synchronous generation
        • Generate single image
      • Asynchronous generation
        • Generate Multi-Format images
        • Generate Multi-Format PDFs for Printing
        • Generate Multi-Page PDF for Printing
        • Generate Multi-Format Videos
        • Generate Multi-Format Animated GIFs
        • Generate HTML5 Banner Ads
          • ad network
      • Element properties
        • Root
        • Text
        • Button
        • Image
        • Logo
        • Shape
        • Rating
        • Illustration
        • QR Code
        • Video
        • Audio
      • Errors
    • Image Export
    • Fonts
    • Annexes
    • API Reference
  • Dynamic Images
    • Overview - Dynamic Images
    • Dynamic Image generation with URL
  • Webhooks
    • Overview - Webhooks
    • Events
      • Design
      • Banner
      • Global events
Powered by GitBook
On this page
  • Asynchronous Asset Generation Endpoint
  • Generation Characteristics
  • Output File Types
  • Additional information
  • Sample request
  • Sample response
  1. Rest API
  2. Generation
  3. Asynchronous generation

Generate Multi-Format Animated GIFs

PreviousGenerate Multi-Format VideosNextGenerate HTML5 Banner Ads

Last updated 6 months ago

This feature is available from the plan.

Asynchronous Asset Generation Endpoint

POST /async/banner-builder/{design_id}/generate

Generation Characteristics

  • Supported Design Type: Animated

  • Response: Asynchronous

  • Enables batch generation of multiple assets

  • Required Parameter: image_file_type=gif

  • Retrieval methods:

    • Webhooks

    • Polling

Output File Types

Supported formats:

  • Gif images

Additional information

Output customisation

In addition to the supported image properties, a gif property can be set to customise the output gif. Here is the available option:

Frame Rate Configuration FPS (Frames Per Second)

  • Property name : fps

  • Default: 9 fps

  • Range: 2-9 fps

Repeat

Duplicate frame removal generates a lighter file without compromising visual quality. This optimization technique reduces file size by eliminating redundant image data while preserving the GIF visual integrity.

  • Property name : repeat

  • Default: -1 The GIF will repeat indefinitely.

  • Value 0: Play only once.

  • Value of 1: Play twice. And so on.

Configuration Example:

"gif": {
 "fps": 8,
 "repeat": 3
}

Sample request

​Do not forget to replace {YOUR-API-KEY} and {design_id}

curl -X POST -H "x-api-key:{YOUR-API-KEY}" -H "Content-Type: application/json"  \
-d '{
  "callback_url": "https://webhook.mycompany.com/images",
  "image_file_type": "gif",
  "gif": {
    "max_fps": 9,
    "repeat": -1
  },
  "template_format_names": ["facebook-feed", "instagram-post", "iab-medium"],
  "elements": {
    "primary_text": {
        "payload": "New branding available.",
        "color": "#FF0000"
    }
  }
}' \
https://api.abyssale.com/async/banner-builder/{design_id}/generate
const axios = require('axios');

const payload = {
  "callback_url": "https://webhook.mycompany.com/images",
  "image_file_type": "gif",
  "gif": {
    "max_fps": 9,
    "repeat": -1
  },
  "template_format_names": ["facebook-feed", "instagram-post", "iab-medium"],
  "elements": {
    "primary_text": {
        "payload": "New branding available.",
        "color": "#FF0000"
    }
  }
}

// Replace {id} by your template ID
axios.post("https://api.abyssale.com/async/banner-builder/{design_id}/generate", payload, {
    headers: {"x-api-key": "{YOUR-API-KEY}", "Content-Type": "application/json", "timeout": 30000}
  }).then(response => {
    console.log(response.data)
}j
import json
import requests

image_generation_payload = {
  "callback_url": "https://webhook.mycompany.com/images",
  "image_file_type": "gif",
  "gif": {
    "max_fps": 9,
    "repeat": -1
  },
  "template_format_names": ["facebook-feed", "instagram-post", "iab-medium"],
  "elements": {
    "primary_text": {
        "payload": "New branding available.",
        "color": "#FF0000"
    }
  }
}

# Do not forget to replace {YOUR-API-KEY} and {template_id}
r = requests.post("https://api.abyssale.com/async/banner-builder/{design_id}/generate",
  headers={"x-api-key": "YOUR-API-KEY", "Content-Type": "application/json"},
  data=json.dumps(image_generation_payload),
  timeout=30
)
r.json()

Sample response

{
  "generation_request_id": "df75afa8-5a77-4e03-aeef-6d1b6dd0580a"
}
Business