curl --request POST \
--url https://api.aihubmax.com/v1/images/generations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "patina-material",
"prompt": "Weathered red brick wall with moss",
"image_size": 1024,
"maps": [
"basecolor",
"normal",
"roughness",
"height"
]
}
'{
"created": 1757165031,
"id": "task-unified-1757165031-uyujaw3d",
"model": "<string>",
"object": "image.generation.task",
"progress": 0,
"status": "pending",
"task_info": {
"can_cancel": true,
"estimated_time": 45
},
"type": "image"
}{
"error": {
"message": "Invalid request parameters",
"type": "invalid_request_error"
}
}{
"error": {
"message": "Invalid API key",
"type": "authentication_error"
}
}{
"error": {
"message": "Insufficient balance",
"type": "insufficient_quota"
}
}{
"error": {
"message": "Parameter validation failed",
"type": "validation_error"
}
}{
"error": {
"message": "Rate limit exceeded",
"type": "rate_limit_error"
}
}{
"error": {
"message": "Internal server error",
"type": "server_error"
}
}{
"error": {
"message": "Service temporarily unavailable, please try again later",
"type": "service_unavailable"
}
}Patina Material Generation
- PATINA Material model, generates tileable textures and PBR maps
- Supports text-to-material and image-to-material, configurable tiling mode and upscale factor
- Asynchronous processing mode, use the returned task ID to query task status
- Generated image links are valid for 24 hours, please save them promptly
curl --request POST \
--url https://api.aihubmax.com/v1/images/generations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "patina-material",
"prompt": "Weathered red brick wall with moss",
"image_size": 1024,
"maps": [
"basecolor",
"normal",
"roughness",
"height"
]
}
'{
"created": 1757165031,
"id": "task-unified-1757165031-uyujaw3d",
"model": "<string>",
"object": "image.generation.task",
"progress": 0,
"status": "pending",
"task_info": {
"can_cancel": true,
"estimated_time": 45
},
"type": "image"
}{
"error": {
"message": "Invalid request parameters",
"type": "invalid_request_error"
}
}{
"error": {
"message": "Invalid API key",
"type": "authentication_error"
}
}{
"error": {
"message": "Insufficient balance",
"type": "insufficient_quota"
}
}{
"error": {
"message": "Parameter validation failed",
"type": "validation_error"
}
}{
"error": {
"message": "Rate limit exceeded",
"type": "rate_limit_error"
}
}{
"error": {
"message": "Internal server error",
"type": "server_error"
}
}{
"error": {
"message": "Service temporarily unavailable, please try again later",
"type": "service_unavailable"
}
}Authorizations
All APIs require Bearer Token authentication
Add to request header:
Authorization: Bearer YOUR_API_KEY
Body
patina-material: Generates tileable textures and PBR maps
"patina-material"
Material description prompt
Notes:
- Describe the desired material appearance
- Supports English and Chinese
"Weathered red brick wall with moss"
PBR map types to generate
Options:
basecolor— Base color mapnormal— Normal maproughness— Roughness mapmetalness— Metalness mapheight— Height map
[
"basecolor",
"normal",
"roughness",
"height"
]
Reference image public URL
Notes:
- Optional, used as reference for material generation
- When omitted, pure text-to-material mode
"https://example.com/brick-photo.jpg"
Mask image public URL
Notes:
- Used with
image_urlto specify local area for material generation
"https://example.com/mask.png"
Output image size (pixels)
Notes:
- Controls the size of generated textures and PBR maps
512
Tiling mode
Options:
none— No tilingx— Horizontal tilingy— Vertical tilingxy— Bidirectional tiling
Do not pass this parameter unless necessary.
"xy"
Upscale factor
Notes:
- Upscales the output material
- Enabling increases billing
Do not pass this parameter unless necessary.
2
Response
Task created successfully
Task creation timestamp
1757165031
Task ID
"task-unified-1757165031-uyujaw3d"
Actual model name used
Specific task type
image.generation.task Task progress percentage (0-100)
0 <= x <= 1000
Task status
pending, processing, completed, failed "pending"
Async task information
Show child attributes
Show child attributes
Task output type
image "image"