1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
const axios = require('axios');
const api_key = "YOUR API-KEY";
const url = "https://api.segmind.com/v1/gpt-image-1-mini";
const data = {
"prompt": "Design a pop-art urban street-inspired cover. Bright yellow, red, cyan with black/white contrast. Include graffiti textures, comic-style murals, playful stickers, and hand-drawn typography. Bold, energetic, and vibrant style, ideal for street festivals, concerts, or city cultural events.",
"size": "1024x1024",
"quality": "high",
"moderation": "auto",
"background": "opaque",
"output_compression": 100,
"output_format": "png"
};
(async function() {
try {
const response = await axios.post(url, data, { headers: { 'x-api-key': api_key } });
console.log(response.data);
} catch (error) {
console.error('Error:', error.response.data);
}
})();
Describe the image you want to generate. Try using descriptive keywords and context for creative imagery or straight-forward terms for clear visuals.
Choose how big the image should be. Use square for fast results and larger sizes for detailed or wide visuals.
Allowed values:
Set the image's visual quality. Use high for intricate details or medium for efficiency without much compromise.
Allowed values:
Choose moderation level for content. Use low for creative freedom, auto for balanced safety.
Allowed values:
Decide if background should be see-through or solid. Transparent is best for overlays; opaque suits standalone images.
Allowed values:
Select how compressed the output image is. A higher number preserves quality; lower numbers shrink file size.
Choose the file type for saving. PNG is great for quality; jpeg for smaller files.
Allowed values:
To keep track of your credit usage, you can inspect the response headers of each API call. The x-remaining-credits property will indicate the number of remaining credits in your account. Ensure you monitor this value to avoid any disruptions in your API usage.
Edited by Segmind Team on October 12, 2025.
GPT Image 1 Mini is a dynamic text-to-image AI model that works through a sophisticated API interface. Its ability to create sharp images from descriptive text prompts makes it a go-to tool for developers and businesses who need high-quality images in quick succession. GPT Image 1 Mini is also packed with crucial editing options, including inpainting and style reference, empowering users with greater control over the image quality. It renders premium images while maintaining resource efficiency, making it optimal for applications and automated workflow integration.
How does GPT Image 1 Mini compare to other image models? GPT Image 1 Mini focuses on efficiency by rendering production-ready images with robust API integration capabilities, making it ideal for business applications and automated workflows.
What's the recommended image size for best results? Go with 1024x1024 for the most balanced output. Use 1536x1024 or 1024x1536 for specialized aspect ratios that need more detail.
Can I use the model for commercial projects? Yes, GPT Image 1 Mini is designed for commercial projects; it can also be integrated into various business applications through its API.
How can I optimize image quality vs. generation speed? Balance the quality parameter (high/ medium/ low) with your desired image output. Use 'medium' for rapid prototyping and 'high' for final assets. The output compression setting can further improve the results.
Does the model support image editing features? Yes, it supports inpainting and style reference features, for image modification and style-guided generation.