Image API
Compare image generation and image editing models, including their supported adapters. Start with hosted samsar-js and use the deployment guide when configuring your own providers.
- Base URL
https://api.samsar.one/v1- Authentication
- Bearer API key
- Execution
- Generation and edits are async; title assignment is synchronous
- Billing
- Route-specific; credit headers report usage
- Content type
application/json
Poll /image/status?request_id=... (or /v1/status) for asynchronous work, or use /image/list to fetch history.
Pricing
| Endpoint | Credits | Notes |
|---|---|---|
POST /image/text_to_image | Selected model rates | Charged on completion; defaults to NANOBANANA2. |
POST /image/assign_title | Usage-based credits | Image title generation. Returns synchronously. |
POST /image/enhance | Selected model rates | Configuration includes resolution (defaults to 1k). |
POST /image/remove_branding | Selected model rates | Charged on completion of the image edit. |
POST /image/add_image_set | Selected model rates | Final charge covers completed image-model calls. |
POST /image/receipt_templates/create | Free | Builds and saves a receipt template + normalized schema from one sample image. |
GET /image/template_json | Free | Returns the saved structured template JSON for a template_id owned by your API key. |
POST /image/receipt_templates/query | 50 | Validates receipt against template and returns standardized JSON fields. |
POST /image/create_rollup_banner | 30 | Flat per request. |
POST /image/enhance_and_generate_rollup_banner | Variable | Enhance credits for low-res images + 30 credits per rollup request. |
See the final image token and output prices for the listed model and adapter routes. Text, image, output, and cached-input token prices are shown separately where supported. Final charges depend on the actual adapter, model configuration, and usage.
Final image token prices
Credits per one million tokens for the named native adapter and token category. The listed generation and edit keys use the same rates. A dash means the token category does not apply; text output includes reasoning tokens when reported.
| Model | Adapter | Token category | Input | Cached input | Output |
|---|---|---|---|---|---|
GPTIMAGE2.5 / GPTIMAGE2.5EDIT | OpenAI | Text tokens | 600 | — | — |
GPTIMAGE2.5 / GPTIMAGE2.5EDIT | OpenAI | Image tokens | 960 | — | 3,600 |
NANOBANANA2 / NANOBANANA2EDIT | Google global | Text tokens | 60 | 6 | 360 |
NANOBANANA2 / NANOBANANA2EDIT | Google global | Image tokens | 60 | 6 | 7,200 |
NANOBANANA2 / NANOBANANA2EDIT | Google regional | Text tokens | 66 | 6.6 | 396 |
NANOBANANA2 / NANOBANANA2EDIT | Google regional | Image tokens | 66 | 6.6 | 7,920 |
NANOBANANAPRO / NANOBANANAPROEDIT | Google global | Text tokens | 240 | 24 | 1,440 |
NANOBANANAPRO / NANOBANANAPROEDIT | Google global | Image tokens | 240 | 24 | 14,400 |
NANOBANANAPRO / NANOBANANAPROEDIT | Google regional | Text tokens | 264 | 26.4 | 1,584 |
NANOBANANAPRO / NANOBANANAPROEDIT | Google regional | Image tokens | 264 | 26.4 | 15,840 |
Final output image prices
Credits per generated image for the listed native adapter and configuration.
| Model | Adapter | Configuration | Credits / output image |
|---|---|---|---|
DALLE3 | OpenAI | Standard · 1024×1024 | 4.8 |
DALLE3 | OpenAI | Standard · 1792×1024 or 1024×1792 | 9.6 |
IMAGEN3 | Standard generation | 4.8 | |
IMAGEN3FLASH | Fast generation | 2.4 | |
WAN2.7PRO | Alibaba international | 1K | 9 |
QWENIMAGE3PRO | Alibaba international | 1K | 4.8 |
QWENIMAGE3PRO | Alibaba international | 2K | 9 |
WAN2.7PRO | Alibaba China / global | 1K | 8.25132 |
QWENIMAGE3PRO | Alibaba China / global | 1K | 4.1256 |
QWENIMAGE3PRO | Alibaba China / global | 2K | 8.25132 |
Fal-backed hosted image calls use these checked-in final rates:
| Model key | Configuration | Final hosted charge |
|---|---|---|
KLINGIMAGE4 | Studio / agent: 16:9 or 9:16 at 720p, resized from minimum 2K generation; API also supports native 2K / 4K / 8K; one output per request | 7.56 credits / output image |
FLUX1DEV | Flux Dev | 3 credits / billed MP |
FLUX1PRO | Flux Pro | 6 credits / billed MP |
FLUX1.1PRO | Flux 1.1 Pro | 4.8 credits / billed MP |
FLUX1.1ULTRA | Flux 1.1 Ultra | 7.2 credits / output image |
RECRAFTV3 | Recraft V3, normal / vector illustration | 4.8 / 9.6 credits per image |
RECRAFT20B | Recraft 20B, normal / vector illustration | 2.628 / 5.256 credits per image |
IDEOGRAMV3 | Ideogram V3, BALANCED default | 7.2 credits / output image |
WAN2.7PRO | Wan 2.7 Pro text to image | 9 credits / output image |
NANOBANANA2 / NANOBANANAPRO | Both keys currently route to Nano Banana 2, 1K default | 9.6 credits / output image |
NANOBANANA2EDIT / NANOBANANAPROEDIT / NANOBANANAEDIT | Nano Banana 2 edit; enhance supports resolution tiers, other edits use 1K; image sets allow up to four outputs | 7.2 / 9.6 / 14.4 / 19.2 credits per image at 0.5K / 1K / 2K / 4K |
FLUX1.1PROREDUX | Flux 1.1 Pro Redux, submitted image size | 6 credits / billed MP |
BRIA_ERASER | Bria erase | 4.8 credits / generation |
BRIA_GENFILL | Bria fill | 4.8 credits / generation |
BRIA_BACKGROUNDREMOVE | Bria background removal | 2.16 credits / generation |
Each output is charged using the listed configuration. Supported Flux routes use one billable 1024×1024 megapixel unit at their constrained submitted sizes. The worker saves the tariff before submission; a model or option without a verified tariff stops before a new paid Fal call. The table identifies edit resolutions and configuration-dependent prices.
Hosted direct Fal routes for SDV3.5, SANA, SANA4.5B, SANASPRINT, PHOTON, PHOTONFLASH, LUMINAV2, REVE, HIDREAMI1, HUNYUAN, FLUX1PROFILL and FLUX1.1PROULTRAREDUX are unavailable under this billing policy until their megapixel billing rule or output sizing is verified. Fal routes for IMAGEN4, FLITE, SEEDREAM and GPTIMAGE2.5 lack a verified tariff. Other adapters for these model keys may still be available.
Other adapter routes report configuration-specific final charges in their completion receipts. Their prices should not be inferred from another adapter's table.
Completion billing
Studio generation, edits, enhancements, and reroll image calls use the same completion billing as these endpoints. Production agent pipelines retain their flat stage pricing. Standalone Docker does not debit local image credits; calls through the Samsar.js adapter are charged by the hosted image endpoint.
Image submissions return creditsCharged: 0 and billingStatus: "PENDING". Poll /image/status for the final creditsCharged, remainingCredits, and matching credit headers. Billing confirmation can keep a request pending after generation finishes.
Use the same Idempotency-Key header when retrying a logical image submission. In Samsar.js request options, pass { idempotencyKey: 'stable-image-request' }. The same key and payload reuse the queued job and original charge; a changed payload returns 409. Polling does not create another model call or charge.
POST /image/text_to_image
Generate one or more images from a text prompt. This route is also available as /image/generate and /image/generations.
Use the stable request key GPTIMAGE2.5 for GPTImage 2.6 Sunburst (High).
The key is retained for compatibility; native OpenAI and fal generation now target 2.6 Sunburst. The retired key GPTIMAGE2 is not an alias:
new requests return HTTP 400 with Invalid model: GPTIMAGE2. Use GPTIMAGE2.5.
This validation also applies to the mode field and the v2 image-generation routes.
{
"prompt": "A minimal product still life on warm stone, soft daylight.",
"model": "NANOBANANA2",
"aspect_ratio": "1:1",
"num_images": 1
}
| Field | Required | Notes |
|---|---|---|
prompt | Yes | Non-empty generation prompt. |
model or mode | No | GPTIMAGE2.5, NANOBANANA2 (default), NANOBANANAPRO, SEEDREAM, WAN2.7PRO, or KLINGIMAGE4. |
aspect_ratio or aspectRatio | No | Defaults to 1:1; Wan 2.7 Pro accepts 1:1, 16:9, or 9:16. Kling Image 4 accepts those ratios plus 4:3, 3:4, 3:2, 2:3, 21:9, and auto. |
resolution | No | Wan 2.7 Pro accepts 1K; Kling Image 4 accepts 2K (API default), 4K, or 8K. Use 720p with 16:9 or 9:16 for 720p output; other models ignore this field. |
num_images or numImages | No | Positive output count; defaults to 1. Kling Image 4 requires 1 per request. See the final model prices and completion receipt. |
KLINGIMAGE4 uses fal's kling/v4/text-to-image endpoint. Agent, Vidgenie, and Studio image generation use 16:9 at 1280×720 or 9:16 at 720×1280. Fal starts at 2K, so these flows generate at its lowest native resolution and resize the result to 720p. Studio calls cost 7.56 credits ($0.0756) per completed image, applying a 20% markup to the $0.063 provider rate; resizing does not reduce that rate. Agent and Vidgenie workflows retain their existing stage pricing and can combine this image model with their supported inference and video models. Direct API requests can still select the native image resolutions and other documented ratios. Configure FAL_API_KEY for direct fal routing, or use the Samsar adapter in standalone deployments.
Success response (200)
{
"status": "queued",
"request_id": "img_gen_123",
"session_id": "img_gen_123",
"case_type": "text_to_image",
"model": "NANOBANANA2",
"aspect_ratio": "1:1",
"num_images": 1,
"creditsCharged": 0,
"remainingCredits": null,
"billingStatus": "PENDING"
}
Poll GET /image/status?request_id=img_gen_123 until the request is complete.
POST /image/assign_title
Assign a short SEO-friendly title to an image. The title is suitable for an image title or for client-side filename generation after camel-casing.
This endpoint uses two generation steps:
- Analyze the image in low-detail vision mode for naming-relevant visual cues.
- Combine that description with optional metadata JSON to create one short title.
JSON request body
{
"image_url": "https://cdn.example.com/product-photo.png",
"metadata": {
"product": "linen travel shirt",
"collection": "spring essentials"
}
}
You can also send image_data as a base64 image data URL.
Multipart request
curl -X POST "https://api.samsar.one/v1/image/assign_title" \
-H "Authorization: Bearer $SAMSAR_API_KEY" \
-F "image=@./product-photo.png" \
-F 'metadata={"product":"linen travel shirt","collection":"spring essentials"}'
Supported image file types are PNG, JPEG, WEBP, and non-animated GIF.
Success response (200)
{
"content": "Linen Travel Shirt"
}
Response headers include:
x-credits-charged: <credits>x-credits-remaining: <remaining>
POST /image/enhance
Upscale and denoise an image.
Request body
{
"image_url": "https://cdn.example.com/photo.png",
"resolution": "0.5k | 1k | 2k | 4k"
}
image_urlrequired, non-empty URL.resolutionoptional; defaults to1k.
Success response (200)
{
"status": "queued",
"request_id": "img_enh_123",
"session_id": "img_enh_123",
"global_status_id": "img_enh_123",
"case_type": "image_enhance",
"image_url": "https://cdn.example.com/photo.png",
"resolution": "1K",
"aspect_ratio": "16:9",
"creditsCharged": 0,
"remainingCredits": null,
"billingStatus": "PENDING"
}
POST /image/remove_branding
Remove visible text from an image.
Request body
{
"image_url": "https://cdn.example.com/watermarked.png"
}
Success response (200)
{
"status": "queued",
"request_id": "img_rm_123",
"session_id": "img_rm_123",
"global_status_id": "img_rm_123",
"case_type": "logo_remove",
"image_url": "https://cdn.example.com/watermarked.png",
"creditsCharged": 0,
"remainingCredits": null,
"billingStatus": "PENDING"
}
POST /image/add_image_set
Extend or save a set of images for downstream generation.
Request body
{
"image_urls": [
"https://cdn.example.com/look1.png",
"https://cdn.example.com/look2.png"
],
"metadata": { "campaign": "spring" },
"prompt": "Optional creative direction",
"num_images": 4
}
image_urlsrequired, non-empty array of strings.num_imagesoptional positive number; defaults toimage_urls.lengthwhen omitted.promptoptional string;metadataoptional object.
Success response (200)
{
"status": "queued",
"request_id": "img_set_123",
"session_id": "img_set_123",
"global_status_id": "img_set_123",
"case_type": "image_list_to_image_set",
"image_urls": [
"https://cdn.example.com/look1.png",
"https://cdn.example.com/look2.png"
],
"metadata": { "campaign": "spring" },
"prompt": "Optional creative direction",
"num_images": 4,
"creditsCharged": 0,
"remainingCredits": null,
"billingStatus": "PENDING"
}
POST /image/receipt_templates/create
Create and persist a reusable receipt extraction template from a sample receipt image.
This endpoint is free (no credits deducted).
Request body
{
"image_url": "https://cdn.example.com/receipt-template.png",
"template_name": "kbank-transfer-template"
}
image_urlrequired, public image URL.template_nameoptional.
Success response (200)
{
"template_id": "receipt_tpl_0e4f9f1dca744ec9b3a3f8df",
"template_hash": "f8b8f4e6e7d9b66d3f4a9e6f35b17c4d7ac4dce2f0d63f15e2d55b9872e3be35",
"template_name": "kbank-transfer-template",
"normalized_template": {
"schema_version": "1.0",
"merchant_hint": "Kasikornbank",
"currency_hint": "THB",
"rois": [
{ "id": "meta_header", "label": "Header and Meta", "left": 0, "top": 0, "width": 1, "height": 0.35 },
{ "id": "line_items", "label": "Line Items/Table", "left": 0, "top": 0.28, "width": 1, "height": 0.5 },
{ "id": "totals", "label": "Totals", "left": 0.45, "top": 0.7, "width": 0.55, "height": 0.3 }
],
"fields": [
{ "key": "merchant_name", "type": "string", "required": true },
{ "key": "transaction_date", "type": "date", "required": true },
{ "key": "total", "type": "currency", "required": true }
],
"validation_rules": {
"arithmetic": true,
"amount_tolerance": 0.05
}
},
"sample_receipt": {
"merchant_name": "Kasikornbank",
"transaction_date": "2026-01-14",
"total": 786
}
}
POST /image/receipt_templates/query
Extract receipt fields by validating an input receipt image against an existing template.
This endpoint charges 50 credits per request.
Request body
{
"template_id": "receipt_tpl_0e4f9f1dca744ec9b3a3f8df",
"image_url": "https://cdn.example.com/receipt-instance.png"
}
template_idrequired.image_urlrequired.- The template must belong to the same API key. Cross-account template access returns
404.
Success response (200)
{
"template_id": "receipt_tpl_0e4f9f1dca744ec9b3a3f8df",
"template_hash": "f8b8f4e6e7d9b66d3f4a9e6f35b17c4d7ac4dce2f0d63f15e2d55b9872e3be35",
"template_name": "kbank-transfer-template",
"receipt_json": {
"merchant_name": "Kasikornbank",
"transaction_date": "2026-01-14",
"transaction_id": "TRBS260114764844309",
"currency": "THB",
"fee": 0,
"total": 786
},
"standardized_receipt": {
"merchant_name": "Kasikornbank",
"transaction_date": "2026-01-14",
"transaction_time": "17:25",
"transaction_id": "TRBS260114764844309",
"currency": "THB",
"subtotal": 786,
"tax": null,
"fee": 0,
"discount": null,
"total": 786,
"payment_method": "transfer",
"from_account": "xxx-x-xxxx-x",
"to_account": "xxx-x-xxxx-x"
},
"items": [],
"unreadable_fields": [],
"confidence": 0.93,
"validation": {
"is_valid": true,
"issues": []
},
"attempts": 1
}
Response headers include:
x-credits-charged: 50x-credits-remaining: <remaining>
GET /image/template_json
Fetch a saved structured receipt template by template_id.
This endpoint validates ownership against your API key and returns the template JSON only when the template belongs to that user.
Primary route: GET /image/template_json
Alias route: GET /image/receipt_templates/template_json
Query params
template_idrequired.
Sample request
curl "https://api.samsar.one/v1/image/template_json?template_id=receipt_tpl_0e4f9f1dca744ec9b3a3f8df" \
-H "Authorization: Bearer $SAMSAR_API_KEY"
Success response (200)
{
"template_id": "receipt_tpl_0e4f9f1dca744ec9b3a3f8df",
"template_hash": "f8b8f4e6e7d9b66d3f4a9e6f35b17c4d7ac4dce2f0d63f15e2d55b9872e3be35",
"template_name": "kbank-transfer-template",
"source_image_url": "https://cdn.example.com/receipt-template.png",
"normalized_template": {
"schema_version": "1.0",
"merchant_hint": "Kasikornbank",
"currency_hint": "THB",
"rois": [
{ "id": "meta_header", "label": "Header and Meta", "left": 0, "top": 0, "width": 1, "height": 0.35 },
{ "id": "line_items", "label": "Line Items/Table", "left": 0, "top": 0.28, "width": 1, "height": 0.5 },
{ "id": "totals", "label": "Totals", "left": 0.45, "top": 0.7, "width": 0.55, "height": 0.3 }
],
"fields": [
{ "key": "merchant_name", "type": "string", "required": true },
{ "key": "transaction_date", "type": "date", "required": true },
{ "key": "total", "type": "currency", "required": true }
],
"validation_rules": {
"arithmetic": true,
"amount_tolerance": 0.05
}
},
"template_json": {
"schema_version": "1.0"
},
"sample_receipt": {
"merchant_name": "Kasikornbank",
"transaction_date": "2026-01-14",
"total": 786
},
"created_at": "2026-03-01T00:26:29.478Z",
"updated_at": "2026-03-01T00:26:29.478Z"
}
template_jsonmirrorsnormalized_templateand is returned as a compatibility alias.
Error responses
400missingtemplate_id.401invalid API key.404template does not exist or does not belong to this API key.
JavaScript SDK (samsar-js)
import SamsarClient from 'samsar-js';
const samsar = new SamsarClient({ apiKey: process.env.SAMSAR_API_KEY! });
const templateJson = await samsar.getReceiptTemplateJson(
'receipt_tpl_0e4f9f1dca744ec9b3a3f8df',
);
console.log(templateJson.data.template_json);
GET /image/status
Check the latest state for a single image request (accepts request_id or session_id).
curl "https://api.samsar.one/v1/image/status?request_id=img_enh_123" \
-H "Authorization: Bearer $SAMSAR_API_KEY"
Queued / processing
{
"session_id": "img_enh_123",
"request_id": "img_enh_123",
"status": "PENDING",
"type": "image",
"case_type": "image_enhance"
}
Completed
{
"session_id": "img_enh_123",
"request_id": "img_enh_123",
"status": "COMPLETED",
"type": "image",
"case_type": "image_enhance",
"result_url": "https://cdn.samsar.one/images/img_enh_123.png"
}
result_urlsis present when multiple assets are produced.thumbnail_urlis included for rollup banner completions and points to a downscaled preview.- A
404is returned if the request does not belong to your API key or is unknown.
GET /image/list
Fetch a list of your recent image API sessions, including their current status and any available results. Use limit (max 500) to trim the response.
curl "https://api.samsar.one/v1/image/list?limit=50" \
-H "Authorization: Bearer $SAMSAR_API_KEY"
Response (200)
{
"sessions": [
{
"session_id": "img_rm_123",
"request_id": "img_rm_123",
"status": "COMPLETED",
"type": "image",
"case_type": "logo_remove",
"request_type": "API",
"result_url": "https://cdn.samsar.one/images/img_rm_123.png",
"created_at": "2024-08-20T08:10:11.000Z",
"updated_at": "2024-08-20T08:12:42.000Z"
},
{
"session_id": "img_set_987",
"request_id": "img_set_987",
"status": "PENDING",
"type": "image",
"case_type": "image_list_to_image_set",
"request_type": "API",
"created_at": "2024-08-20T08:15:55.000Z",
"updated_at": "2024-08-20T08:15:55.000Z"
}
]
}
Common errors
400invalid or missing fields (empty URLs, bad resolution, non-numericnum_images).401invalid API key.402insufficient credits.404unknownrequest_id(or a request that does not belong to the API key on/image/status).
Utils
POST /image/enhance_and_generate_rollup_banner
Enhance low-resolution tiles (if needed) and generate a rollup banner. Images below the rollup minimum (2020x2526) are auto-upscaled using 1k/2k/4k, then the list is expanded to 28 tiles before rendering.
Request body
{
"images": [
{
"image_url": "https://cdn.example.com/tile-1.png",
"image_text": "Rooftop Bar",
"image_category": "Social",
"overlay": { "top_left": "2 hours", "top_right": "City", "footer": "Rooftop Bar" }
}
],
"header_image_url": "https://cdn.example.com/header.png",
"footer_image_url": "https://cdn.example.com/footer.png",
"columns": 4,
"max_tiles": 28,
"image_tiling_position": {
"font_key": "en",
"font_family": "Poppins, Helvetica, Arial, sans-serif",
"top_left": {
"margin_min": 28,
"margin_ratio": 0.02,
"diameter_min": 220,
"diameter_max": 320,
"diameter_ratio": 0.215,
"inner_padding_min": 12,
"inner_padding_ratio": 0.08
},
"top_right": {
"margin_min": 28,
"margin_ratio": 0.02,
"max_width_floor": 260,
"min_width": 220,
"padding_left": 36,
"padding_right": 48,
"padding_top": 30,
"padding_bottom": 24,
"overlay_height_min": 140
},
"bottom": {
"inset_min": 32,
"inset_ratio": 0.03,
"offset_min": 12,
"offset_ratio": 0.02,
"container_margin_min": 40,
"container_margin_ratio": 0.08,
"text_inset_min": 18,
"text_inset_ratio": 0.04,
"overlay_height_min": 280
}
}
}
images(orimage_list/image_urls) required, non-empty array.- Items accept
image_url(orenhanced_url) plus optionalimage_text,image_category,image_duration,overlay. columnsoptional integer 1-6; defaults to 4.max_tilesoptional integer; defaults to 28.header_image_urlandfooter_image_urloptional.image_tiling_positionoptional object for tile overlay layout and font overrides. Omit to use defaults.
image_tiling_position (optional)
Overrides for per-tile overlay placement and font selection. You can send only the fields you want to change.
font_keyrequired if provided; must match a supported subtitle language key (e.g.,en,fr,es,ja,ko,zh-cn,zh-tw,hi,ar).font_familyoptional; comma-separated stack. The first font must be supported for the chosenfont_key.top_leftoptional object for the circular badge.margin_min,margin_ratiodiameter_min,diameter_max,diameter_ratioinner_padding_min,inner_padding_ratio
top_rightoptional object for the top-right label.margin_min,margin_ratiomax_width_floor,min_widthpadding_left,padding_right,padding_top,padding_bottomoverlay_height_min
bottomoptional object for the footer label.inset_min,inset_ratiooffset_min,offset_ratiocontainer_margin_min,container_margin_ratiotext_inset_min,text_inset_ratiooverlay_height_min
All *_ratio values are fractions between 0 and 1. Values are validated; invalid ranges return 400.
Success response (200)
{
"status": "completed",
"session_id": "rollup_enh_123",
"request_id": "rollup_enh_123",
"rollup_session_id": "rollup_456",
"rollup_request_id": "rollup_456",
"case_type": "rollup_banner_enhance",
"result_url": "https://cdn.samsar.one/rollups/rollup_456.png",
"thumbnail_url": "https://cdn.samsar.one/rollups/rollup_456-thumb.png",
"result_urls": ["https://cdn.samsar.one/rollups/rollup_456.png"],
"input_image_urls": [
"https://cdn.example.com/tile-1-enhanced.png"
],
"creditsCharged": 59,
"remainingCredits": 4941
}
Poll /image/status?request_id=rollup_enh_123 for completion. The status payload includes case_type: rollup_banner_enhance.
input_image_urls returns the enhanced URLs used for the rollup request (falls back to original URLs when no enhancement was needed), before any duplication to 28 tiles.
POST /image/create_rollup_banner
Generate a rollup banner image from a list of tiles, with optional header/footer imagery.
Request body
{
"image_list": [
{
"image_url": "https://cdn.example.com/tile-1.png",
"title": "Rooftop Bar",
"image_category": "Social",
"image_duration": "2 hours"
},
{
"enhanced_url": "https://cdn.example.com/tile-2.png",
"overlay": { "top_left": "Half day", "top_right": "Pool", "footer": "Cabana" }
}
],
"header_image_url": "https://cdn.example.com/header.png",
"footer_image_url": "https://cdn.example.com/footer.png",
"columns": 4,
"max_tiles": 28,
"image_tiling_position": {
"font_key": "en",
"font_family": "Poppins, Helvetica, Arial, sans-serif",
"top_left": {
"margin_min": 28,
"margin_ratio": 0.02,
"diameter_min": 220,
"diameter_max": 320,
"diameter_ratio": 0.215,
"inner_padding_min": 12,
"inner_padding_ratio": 0.08
},
"top_right": {
"margin_min": 28,
"margin_ratio": 0.02,
"max_width_floor": 260,
"min_width": 220,
"padding_left": 36,
"padding_right": 48,
"padding_top": 30,
"padding_bottom": 24,
"overlay_height_min": 140
},
"bottom": {
"inset_min": 32,
"inset_ratio": 0.03,
"offset_min": 12,
"offset_ratio": 0.02,
"container_margin_min": 40,
"container_margin_ratio": 0.08,
"text_inset_min": 18,
"text_inset_ratio": 0.04,
"overlay_height_min": 280
}
}
}
image_list(orimages) required, non-empty array. Each item must includeimage_urlorenhanced_url.overlayoptional; supportstop_left,top_right,footer(fallbacks:title,image_text,image_category,image_duration).columnsoptional integer 1-6; defaults to 4.max_tilesoptional integer; defaults to 28.header_image_urlandfooter_image_urloptional.image_tiling_positionoptional object for tile overlay layout and font overrides. Omit to use defaults.
image_tiling_position (optional)
Same schema and validation as /image/enhance_and_generate_rollup_banner. See details above.
Success response (200)
{
"status": "completed",
"session_id": "rollup_123",
"request_id": "rollup_123",
"result_url": "https://cdn.samsar.one/rollups/rollup_123.png",
"thumbnail_url": "https://cdn.samsar.one/rollups/rollup_123-thumb.png",
"result_urls": ["https://cdn.samsar.one/rollups/rollup_123.png"],
"creditsCharged": 30,
"remainingCredits": 4970
}