Skip to content

Create Avatar

POST
/api/v1/generation-avatar

Create new avatar images based on your prompt. This generates AI-generated people/characters that you can later save as persistent avatars.

num_images - How many avatar images to generate (1-5).

prompt - Describe the avatar you want to create (e.g., 'young woman with long brown hair', 'athletic man in casual clothes').

Authorizations

HTTPBearer
TypeHTTP (bearer)

Request Body

JSON
{
"num_images": 0,
"prompt": ""
}

Responses

Successful Response
application/json
JSON
{
"generation_id": 0,
"clothing_item_id": 0,
"num_images": 0,
"payload": "string",
"status": "string",
"feature_name": "string",
"created_at": "string",
"updated_at": "string",
"avatar_id": 0
}

Samples

cURL
curl -X POST \
'https://api.uwear.ai/api/v1/generation-avatar' \
 -H "Content-Type: application/json"
JavaScript
fetch('https://api.uwear.ai/api/v1/generation-avatar', {method:'POST',headers:{'Content-Type':'application/json'}})
  .then(response => response.json())
  .then(data => console.log(data));
PHP
<?php
$url = 'https://api.uwear.ai/api/v1/generation-avatar';
$method = 'POST';
$headers = [
    'Content-Type' => 'application/json',
];

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, $method);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);

$response = curl_exec($ch);
curl_close($ch);

echo $response;
?>
Python
import requests

url = 'https://api.uwear.ai/api/v1/generation-avatar'

headers = {
    'Content-Type': 'application/json'
}

response = requests.post(url, headers=headers)
print(response.json())
Powered by VitePress OpenAPI