Buy prepaid credits, or use a Luxe included allowance.
3
Create a key
The secret is shown once. Store it in a secret manager.
4
Start a job
POST /images/stage with the key and an Idempotency-Key.
5
Poll
GET /jobs/{job_id} every 2 to 5 seconds until the job is completed, failed, or canceled. First-stage generation typically takes about 30 seconds.
Authentication
Every request uses a bearer API key.
Authorization: Bearer hs_live_...
Keys are scoped to one account. Revocation takes effect on the next request.
Scopes: images:write, images:read, usage:read. New keys receive all three.
Never put a key in browser code, a mobile app, or a public repository.
Base URL and versioning
https://homeartist.ai/api/public/v1
v1 is the current contract. Additive fields may appear. Existing fields and error codes keep their meaning.
Billing
1 API unit = $0.05. Web photo credits are a separate product and are not charged here.
Action
Units
Retail
Home Staging
16
$0.80
Home Design Automatic
16
$0.80
Home Design Custom
16
$0.80
Transforms
16
$0.80
Declutter
14
$0.70
Floor Plan
21
$1.05
Luxe includes 1,000 API units per billing cycle. Unused included units do not roll over. Purchased PAYG units do not expire. Included units are consumed first, then PAYG. Failed or canceled jobs refund the original buckets.
Exceeding rate or concurrency returns 429 with Retry-After. An empty wallet returns 402 payment_required and does not call the provider.
Idempotency
Send an Idempotency-Key on every generation request. Max 255 characters.
Idempotency-Key: listing-8842-photo-3
Same key, same payload: original job, no second charge.
Same key, different payload: 409 idempotency_conflict.
Missing header: a retry starts a second billed job.
Endpoints
Image jobs return 202 and a job id. Poll GET /jobs/{id} until the job is terminal. Floor plan completes inside the request (HTTP 200) with the same envelope, so a client that always polls still works.
POST/images/stageimages:write16 unitsHTTP 202
Virtually stage a room photograph. Furniture and decor only. Architecture stays put.
{
"object": "error",
"error": {
"code": "payment_required",
"message": "API balance exhausted. Buy API credits to continue.",
"request_id": "req_2f4c…"
}
}
Code
HTTP
Meaning
invalid_api_key
401
Malformed or unknown key
api_key_revoked
401
Key was revoked
insufficient_scope
403
Key lacks the required scope
payment_required
402
Included + PAYG balance is exhausted. No provider call.
rate_limit_exceeded
429
Too many requests
concurrency_limit_exceeded
429
Too many jobs in flight
invalid_request
400
Payload failed validation
unsupported_operation
400
Unknown transform operation
invalid_source_image
400
image_url is not a public https URL
idempotency_conflict
409
Key reused with a different payload
job_not_found
404
No such job for this account
job_not_cancelable
409
Job already terminal
provider_unavailable
503
Generator temporarily unavailable
generation_failed
500
Generation failed; units refunded
Image requirements
image_url must be a publicly reachable https URL. Private hosts, link-local addresses, http, and data URIs are rejected. Host the photo on a CDN or signed object URL we can fetch.