POST
/
v1
/
ai
/
image-relight
curl --request POST \
--url https://api.freepik.com/v1/ai/image-relight \
--header 'Content-Type: application/json' \
--header 'x-freepik-api-key: <api-key>' \
--data '{
"image": "iVBORw0KGgoAAAANSUhEUgAAASwAAAEsAQAAAABRBrPYAAABrElEQVR4nO3BMQEAAADCoPVPbQ0Po...",
"prompt": "A sunlit forest clearing at golden hour",
"transfer_light_from_reference_image": "iVBORw0KGgoAAAANSUhEUgAAASwAAAEsAQAAAABRBrPYAAABrElEQVR4nO3BMQEAAADCoPVPbQ0Po...",
"light_transfer_strength": 100,
"interpolate_from_original": false,
"change_background": true,
"style": "smooth",
"advanced_settings": {
"whites": 60,
"blacks": 60,
"brightness": 30,
"contrast": 40,
"saturation": 50,
"engine": "illusio",
"transfer_light_a": "low",
"transfer_light_b": "soft_in",
"fixed_generation": true
}
}'
{
"data": {
"generated": [
"https://openapi-generator.tech",
"https://openapi-generator.tech"
],
"task_id": "046b6c7f-0b8a-43b9-b35d-6489e6daee91",
"status": "IN_PROGRESS"
}
}

Important

Upscaler endpoints are only available for premium API users. You can upgrade your account here.

Request

Authorizations

x-freepik-api-key
string
header
required

Your Freepik API key. Required for authentication. Learn how to obtain an API key

Body

application/json

Response

200
application/json

OK - The request has succeeded and the relight process has started.

The response is of type object.