POST
/
v1
/
ai-clothes-changer
Python
from magic_hour import Client
from os import getenv

client = Client(token=getenv("API_TOKEN"))
res = client.v1.ai_clothes_changer.create(
    assets={
        "garment_file_path": "api-assets/id/outfit.png",
        "garment_type": "dresses",
        "person_file_path": "api-assets/id/model.png",
    },
    name="Clothes Changer image",
)
{
  "id": "cuid-example",
  "frame_cost": 25,
  "credits_charged": 25
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <api_key>, where <api_key> is your API key. To get your API key, go to Developer Hub and click "Create new API Key".

Body

application/json

Body

The body is of type object.

Response

200
application/json

Success