REST API · Live

Open Source Banner Generator API

A production REST API that generates product banner images on demand — no open source infrastructure to host, no template slots to fill, no GPU servers to maintain. POST your product photo and a scene prompt; the API handles background removal, AI compositing, and returns a banner-ready image in under 10 seconds. $0.026 per banner image — roughly half the cost of Bannerbear's Automate plan. 5,000 free credits (24-hour trial), no credit card.

$0.026 / banner < 10s typical 5,000 free credits (24-hour trial) No credit card Any resolution SOC2-aligned infra
Get an API key (free) Quick start See pricing API docs

Quick start — generate a banner in one API call

Sign up, copy your key from the dashboard, and POST your product image with a scene description. The endpoint queues the job and returns a generation_id. Poll GET /v1/image/{id} until status=completed, then download the banner from output_url.

# Generate banner — product on AI-composed background scene
curl -X POST https://api.pixelapi.dev/v1/image/replace-background \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -F "[email protected]" \
  -F "prompt=luxury gradient studio, soft light, e-commerce banner"
# Response: {"generation_id": "uuid", "status": "queued", ...}

# Poll until completed
curl https://api.pixelapi.dev/v1/image/UUID \
  -H "Authorization: Bearer YOUR_API_KEY"
# Response: {"status": "completed", "output_url": "https://...banner.jpg"}
pip install pixelapi
---
from pixelapi import PixelAPI

client = PixelAPI(api_key="YOUR_API_KEY")
result = client.replace_background(
    image="product.jpg",
    prompt="luxury gradient studio, soft light, e-commerce banner"
)
result.save("banner.jpg")  # banner-ready JPEG
npm install pixelapi
---
import { PixelAPI } from "pixelapi";

const client = new PixelAPI({ apiKey: process.env.PIXELAPI_KEY });
const result = await client.replaceBackground({
  image: "./product.jpg",
  prompt: "luxury gradient studio, soft light, e-commerce banner",
});
await result.save("banner.jpg");  // banner-ready JPEG
composer require pixelapi/pixelapi
---
<?php
use PixelAPI\Client;

$client = new Client(getenv("PIXELAPI_KEY"));
$result = $client->replaceBackground([
  "image"  => "product.jpg",
  "prompt" => "luxury gradient studio, soft light, e-commerce banner",
]);
file_put_contents("banner.jpg", $result->getBody());
gem install pixelapi
---
require "pixelapi"

client = PixelAPI::Client.new(api_key: ENV["PIXELAPI_KEY"])
result = client.replace_background(
  image: "product.jpg",
  prompt: "luxury gradient studio, soft light, e-commerce banner"
)
File.binwrite("banner.jpg", result.body)
go get github.com/pixelapi/pixelapi-go
---
import "github.com/pixelapi/pixelapi-go"

client := pixelapi.New("YOUR_API_KEY")
result, err := client.ReplaceBackground("product.jpg",
  pixelapi.Prompt("luxury gradient studio, soft light, e-commerce banner"))
if err != nil { panic(err) }
result.Save("banner.jpg")

Full banner pipeline — cut, compose, shadow

For maximum banner quality, combine three endpoints: remove the product background first, replace it with an AI-generated scene, then add a realistic drop shadow. Each step is a separate POST and independently pollable.

  1. Remove background — POST /v1/image/remove-background — returns a transparent PNG cutout ($0.012)
  2. Replace background — POST /v1/image/replace-background — composes product into an AI-generated scene ($0.026)
  3. Add shadow — POST /v1/image/shadow — attaches a natural drop shadow matched to light direction ($0.026)

Total three-step pipeline: $0.064 per finished banner. Skip steps you don't need — replace-background alone ($0.026) handles most e-commerce banner use cases.

Pricing — lower than Bannerbear, no subscription lock-in

ProviderFree tierPer-banner API costModel
PixelAPI 5,000 credits (24-hour trial), no card $0.026 (AI background scene) Pay-per-image
Bannerbear 30 renders (one-time) $0.049/render (Automate, 1,000 renders for $49/mo) Monthly subscription
Creatify 10 credits/mo $0.39/creative (Starter, 100 credits for $39/mo) Monthly subscription
adcreative.ai — see adcreative.ai/pricing Monthly subscription
pencil.ai — see pencil.ai/pricing Monthly subscription

Bannerbear and Creatify pricing verified from each provider's public pricing page, October 2026. PixelAPI's per-image price is set at approximately half the cheapest commercial API rival per our pricing principle. adcreative.ai and pencil.ai pricing pages were unavailable at time of publication — check their sites for current rates.

Open source banner generator API — hosted vs self-hosted

Open source banner generators — Puppeteer HTML-to-image pipelines, PIL compositing scripts, ImageMagick templates — all work, but they come with real ongoing costs that rarely show up in the initial estimate:

No server to maintain

Self-hosted pipelines need a server that stays alive, gets security patches, and is sized for peak traffic. PixelAPI handles all of that. Your app makes an HTTP call; the infra is our problem.

AI scenes, not fixed templates

Template-based banner generators put your product into a fixed slot. PixelAPI's replace-background generates an AI scene around your product's actual shape, colour, and texture — no template to update per SKU.

No burst-scaling problem

A product launch or sale event can spike banner requests 100×. PixelAPI's infrastructure scales to concurrent requests automatically. A self-hosted queue requires you to pre-provision capacity.

Pay-per-image, not per server

At 10,000 banners/month, PixelAPI costs $260. Running an equivalent server 24/7 — plus DevOps time — exceeds that easily. Scale down to zero with no fixed cost.

What you get back

JPEG banner (default)

Web-optimised JPEG served via CDN. Direct drop-in for Facebook, Instagram, Google Display, Flipkart, Shopify product pages. Pass output_format=jpeg (default).

PNG with transparency

Need the cutout on a transparent layer to composite in your own design tool? Pass output_format=png. Full alpha channel — works in Figma, Photoshop, Canva.

WebP for the web

~30% smaller file than JPEG at the same visual quality. Pass output_format=webp. Supported by all modern browsers and CDNs.

Transparent cutout only

Just want the clean product cutout without a generated background? Use POST /v1/image/remove-background instead — $0.012/image, transparent PNG output.

Banner sizes and common formats

PixelAPI's image editing endpoints accept any resolution input. Pass width and height on the request to specify your canvas. Common banner formats:

FormatDimensionsUse case
Meta square1080 × 1080 pxInstagram feed, Facebook post
Meta story1080 × 1920 pxInstagram/Facebook Stories, Reels thumbnail
Google Display1200 × 628 pxGoogle Display Network, Open Graph preview
Google leaderboard728 × 90 pxWeb display banner
Square product800 × 800 pxFlipkart, Amazon, Meesho listing image
Wide product1600 × 900 pxShopify hero, e-commerce category banner

Common banner generation workflows

PixelAPI's image editing API is the foundation for these production workflows. Each links to a setup guide:

E-commerce

Automated product banner generation for Shopify, WooCommerce, Flipkart — triggered on SKU upload.

Fashion

Catalog banners at scale — new arrivals, sale events, seasonal lookbooks.

Cosmetics & beauty

Bottle and palette banners with matched backgrounds — one API call per SKU.

Automotive

Parts and accessories banners for marketplace listings.

Art & print

Gallery and framing mockups generated automatically for each print SKU.

Books & media

Cover art banners for promotional emails and social ads.

Integrations & SDKs

Shopify

Auto-generate product banners on new inventory sync via webhook.

Make.com

Drag-and-drop banner generation in Make scenarios — no code.

Webflow

CMS-driven banner images auto-generated for each product page.

BigCommerce

Catalog automation with the BigCommerce product API.

Next.js

Server-side banner generation for Next.js storefronts and ISR pages.

Magento

Adobe Commerce / Magento 2 plugin pattern for bulk banners.

Comparison vs alternatives

vs adcreative.ai

adcreative.ai is a subscription platform. PixelAPI is pay-per-image with no monthly minimum — better for variable or burst workloads.

vs Creatify

Creatify focuses on video ads. PixelAPI specialises in product image banners — faster, cheaper per image.

vs Bannerflow

Bannerflow is a rich-media DCO platform. PixelAPI is a lightweight API — integrate into your existing stack without a new platform.

vs Canva Ads

Canva Ads requires a designer workflow. PixelAPI is fully programmatic — pipe product photos in, get banners out, no manual steps.

vs Smartly.io

Smartly.io is an enterprise ad platform. PixelAPI is a lean REST API that any developer can integrate in an afternoon.

vs Creatopy

Creatopy requires a visual editor. PixelAPI generates banners via API call — fully automatable in CI/CD pipelines.

Related image editing APIs

Banner generation is one part of a larger product image pipeline. These live PixelAPI endpoints work together:

Remove Background API

Clean product cutout as the first step in any banner pipeline. $0.012/image.

Replace Background API

Swap the background with a custom AI-generated scene. $0.026/image.

Product Photo API

Full AI product photography — lifestyle shot, studio white, or marketplace-ready. $0.050/image.

Rate limits & error handling

20 requests/minute on the free trial, 60 on Starter, 120 on Pro, and 300 on Scale, with 3/10/20/50 concurrent jobs respectively. Exceeding the limit returns HTTP 429 with a Retry-After header. The recommended strategy is exponential backoff starting at 2s, doubling on each retry up to 30s. The Python and Node SDKs handle this automatically.

# Python SDK auto-retries 429 with backoff
from pixelapi import PixelAPI
client = PixelAPI(api_key="...", max_retries=4)
result = client.replace_background(image="bulk_product.jpg",
    prompt="clean white studio, soft shadow")  # auto-retries on 429

Common error codes: 400 invalid input (check image format or size), 402 insufficient credits, 429 rate limit exceeded, 503 temporary overload (retry after Retry-After). Failed jobs are auto-detected and credits are automatically refunded — you never pay for a broken banner.

Frequently asked questions

What is an open source banner generator API?

An open source banner generator API is a self-hosted service that produces marketing banner images programmatically from templates or prompts. Common open-source approaches include Puppeteer/Playwright HTML-to-image pipelines, PIL/Pillow compositing scripts, and ImageMagick wrappers. PixelAPI is a hosted commercial alternative — you POST your product image, the API handles everything, and you get a finished banner back. No servers to manage.

How does the PixelAPI banner generator work?

POST your product image to POST /v1/image/replace-background with a background scene prompt (e.g. "luxury studio gradient"). The API removes the product background, generates a matching AI scene around it, and returns a banner-ready JPEG. The whole pipeline completes in under 10 seconds. Poll GET /v1/image/{id} until status=completed, then download from output_url.

What does banner generation via API cost?

$0.026 per banner image (replace-background). A two-step pipeline — background removal ($0.012) plus scene replacement ($0.026) — costs $0.038 total. New accounts get 5,000 free credits (24-hour trial) with no credit card required, enough to generate over 130 real product banners before paying anything.

How does PixelAPI compare to Bannerbear?

Bannerbear's Automate plan charges $0.049 per API render and requires a monthly subscription. PixelAPI's replace-background endpoint produces an AI-composed product banner for $0.026 per image with no monthly minimum. Unlike template-based tools, PixelAPI uses AI compositing so the scene adapts to your product's shape, colour, and lighting — no template to update per SKU.

What output image formats are returned?

JPEG by default (web-ready, small file). You can request PNG for transparency or WebP for better compression. All outputs are served via a CDN-backed URL returned in output_url once generation completes.

What banner sizes and aspect ratios are supported?

Any size you need — pass width and height on the request. Common banner formats: 1080×1080 (Instagram square), 1080×1920 (Stories), 1200×628 (Google Display), 800×800 (Flipkart/Amazon), 1600×900 (Shopify hero). No size restrictions.

Is there a Python SDK for banner generation?

Yes — pip install pixelapi. SDKs are available for Python, Node.js (npm install pixelapi), PHP (Composer), Ruby (Gem), and Go. All SDKs handle authentication, async polling, retry-on-429, and binary file saving automatically.

Why use a hosted API instead of an open source banner generator?

Self-hosted open-source pipelines require server maintenance, scaling under burst traffic, and library updates. A hosted API like PixelAPI is serverless from your side: pay per image, not per server. No cold starts, no capacity planning, no maintenance windows. For most teams under 50,000 banners/month, the hosted API cost is lower than the total cost of running infrastructure.

Can I add a drop shadow to my product banners?

Yes. Use POST /v1/image/shadow after the background replacement step. Shadow generation costs $0.026 per image and produces a soft, natural shadow matched to the product's footprint and the simulated light direction in the generated scene.

What are the rate limits?

20 requests/minute on the free trial, 60 on Starter, 120 on Pro, and 300 on Scale, with 3/10/20/50 concurrent jobs respectively. Exceeding the limit returns HTTP 429 with a Retry-After header. Higher limits for batch workflows — email support@pixelapi.dev with your expected volume.

Can I get an invoice / GST?

Yes. PixelAPI is a registered Indian business. We issue GST invoices — 18% IGST for international clients, CGST/SGST for domestic. Invoice download is available in the dashboard.

Start free — 5,000 credits, no card Read full API docs Compare all plans