ImmoPhoto API
Upload, enhance, stage, declutter, and transform real estate photos programmatically. Available to Pro and Enterprise accounts.
How It Works
Upload your image
Call upload to get a signed upload URL and a picture_id
PUT the image binary
Upload the raw file directly to the signed URL. Supports any size up to 50MB.
Process with any action
Use the picture_id with enhance, stage, declutter, etc. Each action creates a new picture — the original is never modified.
Download the result
Each action returns a new picture_id and a download_url (signed, valid for 1 hour). Use get to generate a fresh URL anytime.
Quick Start
1. Generate your API key from the Dashboard
2. Upload an image:
# Step 1: Request an upload slot
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "action": "upload", "name": "front.jpg" }'
# Response: { "picture_id": "abc-123", "upload_url": "https://..." }
# Step 2: Upload the raw image
curl -X PUT "UPLOAD_URL_FROM_STEP_1" \
-H "Content-Type: image/jpeg" \
--data-binary @front.jpg
# Step 3: Enhance the photo
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "action": "enhance", "picture_id": "abc-123" }'
# Response: { "picture_id": "def-456", "download_url": "https://..." }Authentication
All API requests require a valid API key passed as a Bearer token in the Authorization header.
Authorization: Bearer imph_live_sk_your_key_hereKeep your API key secret
API keys are for server-to-server use only. Never expose them in client-side code, browser applications, or public repositories.
Base URL
https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gatewayAll requests are POST to this endpoint with an action field in the JSON body.
Pricing
| Resolution | Cost per call | Notes |
|---|---|---|
| 2K (up to 2048px) | €0.28 | Default resolution |
| 4K (up to 4096px) | €0.48 | Available for enhance, empty-room, garden, sky-replace, stage |
Upload, list, get, and delete actions are free. Only enhancement actions are billed. Failed calls are not billed. Magic Eraser is always billed at 2K rate.
Rate Limits
| Plan | Requests / minute |
|---|---|
| Pro | 30 |
| Enterprise | 120 |
Rate limit info is returned in response headers:
X-RateLimit-Limit: 30
X-RateLimit-Remaining: 28
X-RateLimit-Reset: 1713024000Endpoints
/v1/uploadRequest an upload slot. Returns a picture_id and a signed upload URL. PUT your image binary to the URL.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "upload" |
name | string | Optional | A label for the image (e.g. "front.jpg"). Defaults to a generated name. |
Example
# Step 1: Get upload URL
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "action": "upload", "name": "living-room.jpg" }'
# Step 2: Upload the file
curl -X PUT "UPLOAD_URL" \
-H "Content-Type: image/jpeg" \
--data-binary @living-room.jpgResponse
{
"success": true,
"picture_id": "a1b2c3d4-...",
"upload_url": "https://...signed-url...",
"storage_path": "api/user-id/uuid.jpg",
"message": "PUT your image binary to upload_url with Content-Type: image/jpeg"
}Supported formats
- JPEG, PNG, WebP, HEIC, TIFF
- Maximum file size: 50 MB
- The upload URL is valid for 1 hour
- SVG and vector formats are not supported
/v1/listList all pictures in your API Bucket, including originals and processed results.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "list" |
Response
{
"pictures": [
{
"id": "a1b2c3d4-...",
"name": "living-room.jpg",
"created_at": "2026-04-13T14:30:00Z",
"type": "original",
"parent_id": null,
"action": null
},
{
"id": "e5f6g7h8-...",
"name": "living-room.jpg (enhance)",
"created_at": "2026-04-13T14:31:00Z",
"type": "result",
"parent_id": "a1b2c3d4-...",
"action": "enhance"
}
]
}/v1/getGet a signed download URL for any picture (original or processed result).
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "get" |
picture_id | string | Required | The ID of the picture to download |
Response
{
"success": true,
"picture_id": "a1b2c3d4-...",
"name": "living-room.jpg",
"download_url": "https://...signed-url...",
"expires_in": 3600
}/v1/deleteDelete a picture from your API Bucket (removes from storage and database).
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "delete" |
picture_id | string | Required | The ID of the picture to delete |
Response
{ "success": true, "message": "Picture deleted" }Enhancement Actions
All enhancement actions require a picture_id from a previous upload. Each action creates a new picture — the original is never modified. The response includes the new picture_id and a download_url (valid for 1 hour).
/v1/enhanceEnhance a property photo with professional lighting, sharpness, and color correction.
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "enhance" |
picture_id | string | Required | ID of the picture to enhance |
Example
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "action": "enhance", "picture_id": "a1b2c3d4-..." }'Response
{
"success": true,
"picture_id": "e5f6g7h8-...",
"parent_picture_id": "a1b2c3d4-...",
"action": "enhance",
"download_url": "https://...signed-url...",
"expires_in": 3600
}/v1/sky-replaceReplace the sky in an exterior property photo.
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "sky-replace" |
picture_id | string | Required | ID of the picture |
sky_type | string | Required | "BLUE", "SUNNY", "CLOUDY", or "GOLDENHOUR" |
Example
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "action": "sky-replace", "picture_id": "a1b2c3d4-...", "sky_type": "BLUE" }'/v1/stageVirtually stage a room with a specific interior design style.
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "stage" |
picture_id | string | Required | ID of the picture |
style | string | Optional | "MODERN", "INDUSTRIAL", "ZEN", "SCANDINAVIAN", "BOHEMIAN", "MINIMALIST", "CLASSIC", or "CONTEMPORARY". Required if custom_prompt is not set. |
custom_prompt | string | Optional | Custom staging description (max 500 chars). Use instead of style. |
Example (preset)
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "action": "stage", "picture_id": "a1b2c3d4-...", "style": "SCANDINAVIAN" }'Example (custom)
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"action": "stage",
"picture_id": "a1b2c3d4-...",
"custom_prompt": "Add a large sectional sofa, warm lighting, and a bookshelf"
}'/v1/declutterRemove clutter and mess from a room while preserving furniture and decor.
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "declutter" |
picture_id | string | Required | ID of the picture |
Example
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "action": "declutter", "picture_id": "a1b2c3d4-..." }'/v1/empty-roomRemove all movable furniture and personal items, revealing the empty space.
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "empty-room" |
picture_id | string | Required | ID of the picture |
resolution | string | Optional | "1K", "2K" (default), or "4K" |
Example
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "action": "empty-room", "picture_id": "a1b2c3d4-...", "resolution": "4K" }'/v1/gardenEnhance garden and lawn appearance — revive dry grass, tidy hedges, clean up landscaping.
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "garden" |
picture_id | string | Required | ID of the picture |
Example
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "action": "garden", "picture_id": "a1b2c3d4-..." }'/v1/magic-eraserRemove specific objects from a photo using a mask. Always 2K resolution.
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | Required | "magic-eraser" |
picture_id | string | Required | ID of the picture |
mask_base64 | string | Required | Base64-encoded mask image. White (#FFFFFF) = remove, Black (#000000) = keep. Must match input image dimensions. |
Mask requirements
- Must be the exact same dimensions as the input image
- Format: JPEG or PNG, base64-encoded
- White pixels = areas to remove, Black pixels = areas to keep
- Always billed at 2K rate (€0.28)
Example
curl -X POST https://wqtgjlivrlknthecdqcb.supabase.co/functions/v1/api-gateway \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"action": "magic-eraser",
"picture_id": "a1b2c3d4-...",
"mask_base64": "/9j/4AAQSkZJRg..."
}'Response Format
All enhancement actions return the same structure:
{
"success": true,
"picture_id": "new-uuid-...",
"parent_picture_id": "original-uuid-...",
"action": "enhance",
"download_url": "https://...signed-url...",
"expires_in": 3600
}The download_url expires after 1 hour. Call get with the picture_id to generate a fresh URL at any time.
Error Handling
{
"error": {
"type": "INVALID_PARAM",
"message": "sky_type must be one of: BLUE, SUNNY, CLOUDY, GOLDENHOUR",
"code": "INVALID_PARAM"
}
}| Status | Code | Description |
|---|---|---|
| 400 | INVALID_ACTION | Unknown action |
| 400 | INVALID_PARAM | Missing or invalid parameter |
| 400 | MISSING_PARAM | Required parameter not provided |
| 401 | UNAUTHORIZED | Invalid or revoked API key |
| 403 | FORBIDDEN | Account lacks API access (requires Pro or Enterprise) |
| 404 | NOT_FOUND | Picture not found or not owned by your account |
| 413 | IMAGE_TOO_LARGE | Image exceeds 20MB processing limit |
| 429 | RATE_LIMITED | Too many requests |
| 500 | PROCESSING_ERROR | Enhancement failed. Not billed. |
| 504 | TIMEOUT | Processing timed out. Not billed. |
Billing
- Upload, list, get, delete are free — no charge
- You are only billed for successful enhancement calls
- Failed calls, timeouts, and validation errors are not billed
- Usage is tracked per API key and visible in your dashboard
- Invoicing is monthly based on actual usage
Support
For API support, billing questions, or Enterprise onboarding, contact us at contact@immophoto.app