Asset Generator
FreshPurpose
Generate images and visual assets using 30+ AI models through the Creatify Asset Generator API.
Prerequisites
- Authenticated API access (Authentication SOP)
- A text prompt describing the desired asset
- Sufficient credits
Procedure
Step 1: Get Available Models and Schema
List all available AI models and their supported parameters.
bash
curl --request GET \
--url https://api.creatify.ai/api/ai_generation/schema/ \
--header "X-API-ID: $CREATIFY_API_ID" \
--header "X-API-KEY: $CREATIFY_API_KEY"Response (partial):
json
{
"models": [
{
"id": "model-001",
"name": "Realistic Photo",
"description": "Generate photorealistic images",
"parameters": {
"prompt": { "type": "string", "required": true },
"negative_prompt": { "type": "string", "required": false },
"width": { "type": "integer", "default": 1024 },
"height": { "type": "integer", "default": 1024 }
}
},
{
"id": "model-002",
"name": "Illustration",
"description": "Generate digital illustrations",
"parameters": { "..." : "..." }
}
]
}Step 2: Create a Generation Task
bash
curl --request POST \
--url https://api.creatify.ai/api/ai_generation/ \
--header "Content-Type: application/json" \
--header "X-API-ID: $CREATIFY_API_ID" \
--header "X-API-KEY: $CREATIFY_API_KEY" \
--data '{
"model": "model-001",
"prompt": "A professional product photo of a sleek smartphone on a marble surface with soft studio lighting",
"negative_prompt": "blurry, low quality, watermark",
"width": 1024,
"height": 1024
}'Response:
json
{
"id": "gen-task-uuid",
"status": "pending"
}Step 3: Poll for Completion
bash
curl --request GET \
--url https://api.creatify.ai/api/ai_generation/gen-task-uuid/ \
--header "X-API-ID: $CREATIFY_API_ID" \
--header "X-API-KEY: $CREATIFY_API_KEY"Completed response:
json
{
"id": "gen-task-uuid",
"status": "done",
"output": "https://cdn.creatify.ai/images/generated-asset.png"
}Step 4: Download Asset
Download the generated image from the output URL.
Credit Cost
| Operation | Credits |
|---|---|
| Get model schema | 0 |
| List generated items | 0 |
| Create generation task | Varies by model |
Verification Checklist
- [ ] Model ID exists in the schema
- [ ] Parameters match the model's expected schema
- [ ] Task creation returns
pendingstatus - [ ] Final status is
donewith valid output URL - [ ] Generated image matches the prompt description
- [ ] Image resolution matches requested dimensions
See Also
- IAB Images SOP -- Generate ad-compliant banners
- Product Video SOP -- Use generated images in product videos
- AI Avatar v1 SOP -- Combine with avatar videos