API Reference
Complete reference documentation for the ProductAI REST API.
Base URL
https://api.productai.photo/v1Authentication
All API requests require authentication using a Bearer token in the Authorization header.
curl -X POST "https://api.productai.photo/v1/generate" \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json"
Quick Example
Generate an image using the Nano Banana 2 model:
curl -X POST "https://api.productai.photo/v1/generate" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "nanobanana2",
"image_url": "https://example.com/product.jpg",
"prompt": "Place the product on a marble table with soft lighting"
}'Available Models
nanobanana2(5 credits)nanobananapro(8 credits)nanobanana(3 credits)kontext-pro(3 credits)kontext-max(3 credits)seedream(3 credits)gpt-high(8 credits)Endpoints
Rate Limits
API requests are rate limited based on your subscription plan. If you exceed the rate limit, you'll receive a 429 Too Many Requests response.
| Plan | Rate Limit |
|---|---|
| Free | 10 requests/minute |
| Pro | 60 requests/minute |
| Enterprise | Custom |
Error Handling
The API uses standard HTTP status codes to indicate success or failure.
200Success400Bad Request - Invalid parameters401Unauthorized - Invalid or missing API key403Forbidden - Insufficient permissions404Not Found - Resource doesn't exist429Too Many Requests - Rate limit exceeded500Internal Server Error