ClarityAI Creative Upscaler
Clarity AI intelligently enhances image resolution, preserving fine details for stunning visual clarity.
1import requests
2import json
3
4url = "https://api.segmind.com/v1/clarityai-creative-upscaler"
5headers = {
6 "x-api-key": "YOUR_API_KEY",
7 "Content-Type": "application/json"
8}
9
10data = {
11 "image": "https://segmind-resources.s3.amazonaws.com/input/3890b175-3f64-40e5-9d3c-248b5168c774-output-1762260857540.png",
12 "scale_factor": 4,
13 "creativity": 2,
14 "resemblance": 3,
15 "dynamic": 0,
16 "fractality": 1,
17 "style": "portrait",
18 "prompt": "Maximize detail with vibrant color enhancement."
19}
20
21response = requests.post(url, headers=headers, json=data)
22
23if response.status_code == 200:
24 result = response.json()
25 print(json.dumps(result, indent=2))
26else:
27 print(f"Error: {response.status_code}")
28 print(response.text) 1import requests
2import json
3
4url = "https://api.segmind.com/v1/clarityai-creative-upscaler"
5headers = {
6 "x-api-key": "YOUR_API_KEY",
7 "Content-Type": "application/json"
8}
9
10data = {
11 "image": "https://segmind-resources.s3.amazonaws.com/input/3890b175-3f64-40e5-9d3c-248b5168c774-output-1762260857540.png",
12 "scale_factor": 4,
13 "creativity": 2,
14 "resemblance": 3,
15 "dynamic": 0,
16 "fractality": 1,
17 "style": "portrait",
18 "prompt": "Maximize detail with vibrant color enhancement."
19}
20
21response = requests.post(url, headers=headers, json=data)
22
23if response.status_code == 200:
24 result = response.json()
25 print(json.dumps(result, indent=2))
26else:
27 print(f"Error: {response.status_code}")
28 print(response.text)API Endpoint
https://api.segmind.com/v1/clarityai-creative-upscalerParameters
creativityoptionalintegerAdjusts the creativity effect; higher values for unique transformations, 2 for balance.
2Range: -10 - 10dynamicoptionalintegerModifies dynamic range; 0 retains original, higher for more contrast.
0Range: -10 - 10fractalityoptionalintegerAdds fractal texture; 1 for subtlety, 5 for pronounced detail.
1Range: -10 - 10imageoptionalstring (uri)Provides a reference image for styling. Use unique images for specific effects.
"https://segmind-resources.s3.amazonaws.com/input/3890b175-3f64-40e5-9d3c-248b5168c774-output-1762260857540.png"promptoptionalstringGuides the upscaling process with text; use 'vibrant color' for vivid results.
"Maximize detail with vibrant color enhancement."resemblanceoptionalintegerControls how much the result resembles the original; use 3 for moderate similarity.
3Range: -10 - 10scale_factoroptionalintegerDetermines upscaling quality. Use 4x for high detail, and 8x for larger projects.
4Range: 2 - 16styleoptionalstringSelects final image style; 'portrait' for faces, 'anime' for stylized art.
"portrait""default""portrait""anime"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