Ideogram 3 Reframe Serverless API
Ideogram 3.0's Reframe effortlessly adapts images to diverse formats, enhancing visual content creation for any platform.
1import requests
2import json
3
4url = "https://api.segmind.com/v1/ideogram-3-reframe"
5headers = {
6 "x-api-key": "YOUR_API_KEY",
7 "Content-Type": "application/json"
8}
9
10data = {
11 "image": "https://segmind-resources.s3.amazonaws.com/output/1a759c90-ef73-43dc-b4c0-58c1ae13d2e4-01961465-ffee-4df5-a1cc-4f4fe232f434.png",
12 "resolution": "1024x1024",
13 "rendering_speed": "DEFAULT",
14 "style_codes": [],
15 "style_reference_images": []
16}
17
18response = requests.post(url, headers=headers, json=data)
19
20if response.status_code == 200:
21 result = response.json()
22 print(json.dumps(result, indent=2))
23else:
24 print(f"Error: {response.status_code}")
25 print(response.text) 1import requests
2import json
3
4url = "https://api.segmind.com/v1/ideogram-3-reframe"
5headers = {
6 "x-api-key": "YOUR_API_KEY",
7 "Content-Type": "application/json"
8}
9
10data = {
11 "image": "https://segmind-resources.s3.amazonaws.com/output/1a759c90-ef73-43dc-b4c0-58c1ae13d2e4-01961465-ffee-4df5-a1cc-4f4fe232f434.png",
12 "resolution": "1024x1024",
13 "rendering_speed": "DEFAULT",
14 "style_codes": [],
15 "style_reference_images": []
16}
17
18response = requests.post(url, headers=headers, json=data)
19
20if response.status_code == 200:
21 result = response.json()
22 print(json.dumps(result, indent=2))
23else:
24 print(f"Error: {response.status_code}")
25 print(response.text)API Endpoint
https://api.segmind.com/v1/ideogram-3-reframeParameters
imagerequiredstring (uri)Image Url used as base input. Use high-resolution links for optimal results.
color_paletteoptionalany | anyA color palette for generation
Preset Color PaletteoptionalanynamerequiredstringCustom Color Paletteoptionalanymembersrequiredobject[]rendering_speedoptionalstringSets rendering speed. 'DEFAULT' works well for most tasks.
"DEFAULT""TURBO""DEFAULT""QUALITY"resolutionoptionalstringChoose output resolution. '1024x1024' for balance of quality and efficiency.
"1024x1024""512x1536""576x1408""576x1472""576x1536""640x1344""640x1408""640x1472""640x1536""704x1152""704x1216"+59 moreseedoptionalintegerSeed for random operations. Use '42' for reproducibility in testing.
style_codesoptionalstring[]Apply style codes here. Try ['Modern','Aesthetic'] for artistic results.
style_reference_imagesoptionalstring[]Upload style reference images. Use your favorite artworks for personalization.
Response Type
Returns: Image
Common Error Codes
The API returns standard HTTP status codes. Detailed error messages are provided in the response body.
Bad Request
Invalid parameters or request format
Unauthorized
Missing or invalid API key
Forbidden
Insufficient permissions
Not Found
Model or endpoint not found
Insufficient Credits
Not enough credits to process request
Rate Limited
Too many requests
Server Error
Internal server error
Bad Gateway
Service temporarily unavailable
Timeout
Request timed out