Agnes Image 2.1 Flash is an upgraded image generation model from Sapiens AI. It supports text-to-image and image-to-image workflows. Compared with version 2.0, it is better suited for high-information-density images, complex compositions, and detail-rich visual scenes.
Model
agnes-image-2.1-flashAPI Endpoint
POST /v1/images/generationsCore Optimization
High-information-density images, complex visual details, and semantic alignment.
Current Price
Image generation is currently
$0 / image.Overview
Agnes Image 2.1 Flash can generate images from text prompts and transform, redraw, or stylize input images. Results can be returned as image URLs or Base64 data.High-density Visuals
Better suited for complex scenes, rich compositions, and multi-layer visual elements.
Composition Preservation
Preserves the original composition and subject layout as much as possible during image-to-image editing.
Core Capabilities
Text-to-image
Generate high-quality images from natural language prompts.
Image-to-image
Transform or improve existing images based on prompt instructions.
High-information-density Images
Optimized for detail-rich images with complex layouts and dense visual elements.
Composition Preservation
Preserve the original composition and subject layout when editing input images.
Flexible Size Control
Use resolution tiers such as
1K, 2K, 3K, or 4K with a supported aspect ratio.URL / Base64 Output
Return generated images as URLs or Base64 data.
Use Cases
Creative Design
Concept art, visual exploration, and poster drafts.
Marketing Content
Campaign images, product visuals, and social media creatives.
High-density Visual Generation
Detailed scenes, complex environments, and rich compositions.
Image Transformation
Style transfer, scene relighting, and background transformation.
Product Visualization
Product photos, mockups, and commercial visuals.
Social Media Assets
Covers, banners, thumbnails, and post images.
API Reference
Endpoint
Headers
Request Parameters
Size and Ratio
For predictable output dimensions, usesize together with ratio.
- Recommended
sizevalues:1K,2K,3K,4K - Supported
ratiovalues:1:1,3:4,4:3,16:9,9:16,2:3,3:2,21:9 - If you request an unsupported exact size such as
1920x1080or2560x1440, the service may map it to the nearest supported tier and aspect ratio. - For common 16:9 display assets such as
1920x1080or2560x1440, requestsize: "2K"withratio: "16:9"and then crop or resize downstream if you need an exact final canvas.
Output Dimension Reference
Example: 16:9 2K Output
2K tier output size, 2624x1472.
Important Notes
Text-to-image
Required parameters are
model, prompt, and size.Size + Ratio
Use tier-based
size values such as 2K with ratio, for example 16:9.Image-to-image
Provide an input image URL or Data URI Base64 value in
extra_body.image.Base64 Output
For text-to-image, use top-level
return_base64: true.No tags Required
Image-to-image requests do not require
tags: ["img2img"].Request Examples
- Text-to-image: URL Output
- Text-to-image: Base64 Output
- Image-to-image: URL Input + URL Output
- Image-to-image: Base64 Output
- Data URI Base64 Input
Response Format
- URL Output
- Base64 Output
Response Fields
Prompting Guide
Text-to-image Prompt Structure
Text-to-image Prompt Structure
Image-to-image Prompt Structure
Image-to-image Prompt Structure
Clearly describe what should change and what should remain unchanged.
High-information-density Images
High-information-density Images
Agnes Image 2.1 Flash is optimized for complex and detail-rich visuals. For best results, describe the visual hierarchy clearly.Recommended elements:
- Main subject
- Background environment
- Important secondary details
- Style and lighting
- Composition constraints
- Elements to preserve for image-to-image tasks
Common Errors and Troubleshooting
Top-level response_format causes errors
Top-level response_format causes errors
Do not place Correct:
response_format at the top level.Incorrect:Input image URL cannot be accessed
Input image URL cannot be accessed
Use public HTTPS image URLs that do not require login, cookies, or private request headers. If the image cannot be made public, use Data URI Base64 input.
Request timeout
Request timeout
Image generation may take several seconds to tens of seconds depending on prompt complexity, image size, and server load. A client timeout of
60s - 360s is recommended.Missing image parameter for image-to-image
Missing image parameter for image-to-image
Image-to-image generation requires an input image array in
extra_body.image.Pricing
Integration Checklist
Use
agnes-image-2.1-flash as the model name.Use
https://apihub.agnes-ai.com/v1/images/generations as the API endpoint.For text-to-image, include
model, prompt, and size.For predictable dimensions, use
size tiers such as 1K or 2K together with ratio.For image-to-image, provide input images through
extra_body.image.Do not expose temporary or real API keys in public documentation.