πŸ”„Conversions

View available conversions for the File

GET https://uc.alxgsv.com/api/v1/projects/:project_id/files/:file_id/conversions.json

curl -X GET -H "Authorization: Bearer ${SECRET_KEY}" https://uc.alxgsv.com/api/v1/projects/${PROJECT_ID}/files/${FILE_ID}/conversions.json

Path Parameters

Name
Type
Description

project_id*

String

file_id*

String

Headers

Name
Type
Description

Authorization

String

Bearer SECRET_KEY

{
    "data": {
        "type": "conversions",
        "attributes": {
            "format_current": "png",
            "formats_available": [
                "avif",
                "bmp",
                "gif",
                "ico",
                "jpg",
                "pcx",
                "pdf",
                "ps",
                "svg",
                "tga",
                "thumbnail",
                "tiff",
                "wbmp",
                "webp"
            ],
            "methods_available": [
                "image",
                "remove_bg"
            ]
        }
    }
}

Image conversion

POST https://uc.alxgsv.com/api/v1/projects/:project_id/files/:file_id/conversions/image.json

curl -X POST -H "Authorization: Bearer ${SECRET_KEY}" -d "recipe=/format/webp/" https://uc.alxgsv.com/api/v1/projects/${PROJECT_ID}/files/${FILE_ID}/conversions/image.json

Path Parameters

Name
Type
Description

project_id*

String

file_id*

String

Headers

Name
Type
Description

Authorization*

String

Bearer SECRET_KEY

Request Body

Name
Type
Description

recipe*

String

Conversion recipe

Video conversion

POST https://uc.alxgsv.com/api/v1/projects/:project_id/files/:file_id/conversions/video.json

curl -X POST -H "Authorization: Bearer ${SECRET_KEY}" -d "recipe=/format/ogg/-/quality/best/" https://uc.alxgsv.com/api/v1/projects/${PROJECT_ID}/files/${FILE_ID}/conversions/video.json

Path Parameters

Name
Type
Description

project_id*

String

file_id*

String

Headers

Name
Type
Description

Authorization*

String

Bearer SECRET_KEY

Request Body

Name
Type
Description

recipe*

String

Conversion recipe

Document conversion

POST https://uc.alxgsv.com/api/v1/projects/:project_id/files/:file_id/conversions/document.json

curl -X POST -H "Authorization: Bearer ${SECRET_KEY}" -d "recipe=/format/png/" https://uc.alxgsv.com/api/v1/projects/${PROJECT_ID}/files/${FILE_ID}/conversions/document.json

Path Parameters

Name
Type
Description

project_id*

String

file_id*

String

Headers

Name
Type
Description

Authorization*

String

Bearer SECRET_KEY

Request Body

Name
Type
Description

recipe*

String

Conversion recipe

Background removal conversion

POST https://uc.alxgsv.com/api/v1/projects/:project_id/files/:file_id/conversions/remove_bg.json

curl -X POST -H "Authorization: Bearer ${SECRET_KEY}" -d "recipe=/position/original/" https://uc.alxgsv.com/api/v1/projects/${PROJECT_ID}/files/${FILE_ID}/conversions/remove_bg.json

Path Parameters

Name
Type
Description

project_id*

String

file_id*

String

Headers

Name
Type
Description

Authorization*

String

Bearer SECRET_KEY

Request Body

Name
Type
Description

recipe*

String

Conversion recipe

Last updated