256 ร 256 px
Hex Character Pack
Color: Hair
API GET Endpoint
/api/portrait?size=256...
cURL Command
curl ...
OpenAPI 3.0 Documentation
Interactive reference and specification for the Hex Character Pack avatar and asset generator.
GET
/api/portrait
Generate avatar image at arbitrary resolution
Generates and streams a pixel-perfect character portrait. Supports PNG and SVG formats.
| Parameter | Type | Default | Description |
|---|---|---|---|
size |
integer | 256 |
Output dimension in px: 16, 64, 128, 256, 512, 1024 (or any value from 16 to 4096). |
format |
string | png |
png for binary PNG, svg for vector with crisp pixel rendering. |
skin |
integer | random | Skin tone index (0 to 11). |
hair_style |
integer | string | random | Hairstyle index (0 to 31), or none for bald. |
hair_color |
string | random | Color: dark, blonde, blue, red, green, orange, pink, lilac, magent, white, etc. |
clothes_style |
integer | string | random | Outfit style index (0 to 11), or none. |
clothes_color |
string | random | Palette color name. |
eyes_style |
integer | random | Eyes expression (0 to 11). |
eyes_color |
string | random | Iris color name. |
eyebrows_style |
integer | random | Eyebrows expression (0 to 11). |
mouth_style |
integer | random | Mouth expression (0 to 11). Automatically skin-toned. |
bg_pattern |
integer | string | random | Background pattern (0 to 11), or none for transparent. |
bg_color |
string | random | Palette color name or 6-digit hex code without # (e.g. 3b82f6). |
seed |
string | - | Deterministic seed for repeatable avatar generation. |
download |
boolean | false |
Force browser attachment download. |
curl -o avatar.png "http://localhost:8080/api/portrait?size=256&skin=1&hair_style=8&hair_color=blonde&clothes_style=4&clothes_color=red"
GET
/api/part
Get isolated transparent part sprite
Extracts and returns a single isolated component (hair, clothes, eyes, mouth, etc.) with transparency at any resolution.
| Parameter | Type | Required | Description |
|---|---|---|---|
category |
string | Yes | hair, clothes, eyes, eyebrows, mouth, skin, bg. |
style |
integer | Yes | Component index (0..31 for hair, 0..11 for others). |
color |
string | No | Palette color (default: dark). |
skin |
integer | No | Skin tone index (used for mouth lip shading). |
size |
integer | No | Output resolution in px (default: 60, or 16, 128, 256, 512, 1024). |
curl -o hair.png "http://localhost:8080/api/part?category=hair&style=4&color=blonde&size=256"
GET
/api/parts
List all parts, palette colors, and direct URLs
Returns the full JSON inventory of available skin tones, colors, component categories, and direct asset download URLs.
curl -s http://localhost:8080/api/parts | jq .