Reference · Resources
Photta API resource endpoints the ids every generation needs
In one sentence
Resource endpoints return the ids a generation call takes: mannequins, poses, backgrounds, footwear, garment attributes and brand labels, plus your account balance and usage. Listing costs nothing.
- Resource endpoints: 13 resource endpoints
- Authentication: Bearer key
- Limits: 600 requests/min
Every figure on this page comes from the Photta API docs · checked
Every resource endpoint, with the call that reads it
Each section links the capability that consumes those ids.
Mannequins
Lists the models available for apparel try-on: Photta’s system mannequins, your own uploads, and the ones you built with the mannequin generation API. POST to the same path to upload a custom mannequin, which stays private to your account. The id goes into `mannequin_id` on a try-on call.
curl https://api.photta.app/api/v1/mannequins \
-H "Authorization: Bearer $PHOTTA_API_KEY"const res = await fetch("https://api.photta.app/api/v1/mannequins", {
headers: { Authorization: `Bearer ${process.env.PHOTTA_API_KEY}` },
});
const { data } = await res.json();import os, requests
res = requests.get(
"https://api.photta.app/api/v1/mannequins",
headers={"Authorization": f"Bearer {os.environ['PHOTTA_API_KEY']}"},
)
data = res.json()["data"]Jewelry mannequins
Uploads a close-up model photo for jewelry try-on. Jewelry work is framed on a neckline, an ear, a wrist or a hand, so it takes its own mannequin set rather than the full-body apparel one.
RESPONSE=$(curl -s -X POST https://api.photta.app/api/v1/mannequins/jewelry \
-H "Authorization: Bearer $PHOTTA_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"image": "https://cdn.yourstore.com/models/emma-neck.jpg",
"jewelry_type": "necklace",
"gender": "female",
"name": "Emma"
}')
ID=$(echo "$RESPONSE" | jq -r '.data.id')const res = await fetch("https://api.photta.app/api/v1/mannequins/jewelry", {
method: "POST",
headers: { Authorization: `Bearer ${process.env.PHOTTA_API_KEY}`, "Content-Type": "application/json" },
body: JSON.stringify({
"image": "https://cdn.yourstore.com/models/emma-neck.jpg",
"jewelry_type": "necklace",
"gender": "female",
"name": "Emma"
}),
});
const { data } = await res.json(); // data.id, data.statusimport os, requests
res = requests.post(
"https://api.photta.app/api/v1/mannequins/jewelry",
headers={"Authorization": f"Bearer {os.environ['PHOTTA_API_KEY']}"},
json={
"image": "https://cdn.yourstore.com/models/emma-neck.jpg",
"jewelry_type": "necklace",
"gender": "female",
"name": "Emma"
},
)
data = res.json()["data"] # data["id"], data["status"]Poses
Lists the poses a try-on can request, filterable by category and by the product type they suit. Pass the id as `pose_id`; leave it out and the API picks a pose that fits the garment.
curl https://api.photta.app/api/v1/poses \
-H "Authorization: Bearer $PHOTTA_API_KEY"const res = await fetch("https://api.photta.app/api/v1/poses", {
headers: { Authorization: `Bearer ${process.env.PHOTTA_API_KEY}` },
});
const { data } = await res.json();import os, requests
res = requests.get(
"https://api.photta.app/api/v1/poses",
headers={"Authorization": f"Bearer {os.environ['PHOTTA_API_KEY']}"},
)
data = res.json()["data"]Garment length and fit
Returns the length and fit keys apparel try-on accepts. Send the key, not a free-text description, so the same shirt renders the same way across a catalogue.
curl https://api.photta.app/api/v1/garment-attributes \
-H "Authorization: Bearer $PHOTTA_API_KEY"const res = await fetch("https://api.photta.app/api/v1/garment-attributes", {
headers: { Authorization: `Bearer ${process.env.PHOTTA_API_KEY}` },
});
const { data } = await res.json();import os, requests
res = requests.get(
"https://api.photta.app/api/v1/garment-attributes",
headers={"Authorization": f"Bearer {os.environ['PHOTTA_API_KEY']}"},
)
data = res.json()["data"]Backgrounds
Lists system backgrounds and your own uploads for apparel try-on, with cursor pagination. POST to the same path to upload a custom background; it stays private to your account.
curl https://api.photta.app/api/v1/backgrounds \
-H "Authorization: Bearer $PHOTTA_API_KEY"const res = await fetch("https://api.photta.app/api/v1/backgrounds", {
headers: { Authorization: `Bearer ${process.env.PHOTTA_API_KEY}` },
});
const { data } = await res.json();import os, requests
res = requests.get(
"https://api.photta.app/api/v1/backgrounds",
headers={"Authorization": f"Bearer {os.environ['PHOTTA_API_KEY']}"},
)
data = res.json()["data"]Brand labels
Uploads a reusable label image for ghost mannequin work and returns an id you pass as `brand_label_id`, on single jobs and batches alike. GET lists what you have saved; DELETE removes one when you reach the account limit.
RESPONSE=$(curl -s -X POST https://api.photta.app/api/v1/brand-labels \
-H "Authorization: Bearer $PHOTTA_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"file": "@/path/to/pribrand-label.png",
"name": "Pribrand Collar Label"
}')
ID=$(echo "$RESPONSE" | jq -r '.data.id')const res = await fetch("https://api.photta.app/api/v1/brand-labels", {
method: "POST",
headers: { Authorization: `Bearer ${process.env.PHOTTA_API_KEY}`, "Content-Type": "application/json" },
body: JSON.stringify({
"file": "@/path/to/pribrand-label.png",
"name": "Pribrand Collar Label"
}),
});
const { data } = await res.json(); // data.id, data.statusimport os, requests
res = requests.post(
"https://api.photta.app/api/v1/brand-labels",
headers={"Authorization": f"Bearer {os.environ['PHOTTA_API_KEY']}"},
json={
"file": "@/path/to/pribrand-label.png",
"name": "Pribrand Collar Label"
},
)
data = res.json()["data"] # data["id"], data["status"]Footwear
Lists footwear options for apparel try-on, filterable by type and gender, with cursor pagination. Use it to put shoes on the same model that wears the garment.
curl https://api.photta.app/api/v1/footwear \
-H "Authorization: Bearer $PHOTTA_API_KEY"const res = await fetch("https://api.photta.app/api/v1/footwear", {
headers: { Authorization: `Bearer ${process.env.PHOTTA_API_KEY}` },
});
const { data } = await res.json();import os, requests
res = requests.get(
"https://api.photta.app/api/v1/footwear",
headers={"Authorization": f"Bearer {os.environ['PHOTTA_API_KEY']}"},
)
data = res.json()["data"]Account
Returns your credit balance broken down by source, your current plan and the next credit renewal. Read it before a large batch rather than discovering the shortfall in a 402.
curl https://api.photta.app/api/v1/account \
-H "Authorization: Bearer $PHOTTA_API_KEY"const res = await fetch("https://api.photta.app/api/v1/account", {
headers: { Authorization: `Bearer ${process.env.PHOTTA_API_KEY}` },
});
const { data } = await res.json();import os, requests
res = requests.get(
"https://api.photta.app/api/v1/account",
headers={"Authorization": f"Bearer {os.environ['PHOTTA_API_KEY']}"},
)
data = res.json()["data"]Usage
Generation counts and credit spend for the current calendar-month billing window, split into successful and failed jobs. This is the endpoint to graph, not your own tally of requests.
curl https://api.photta.app/api/v1/account/usage \
-H "Authorization: Bearer $PHOTTA_API_KEY"const res = await fetch("https://api.photta.app/api/v1/account/usage", {
headers: { Authorization: `Bearer ${process.env.PHOTTA_API_KEY}` },
});
const { data } = await res.json();import os, requests
res = requests.get(
"https://api.photta.app/api/v1/account/usage",
headers={"Authorization": f"Bearer {os.environ['PHOTTA_API_KEY']}"},
)
data = res.json()["data"]Questions about the resource endpoints
What are the resource endpoints for?
They return the ids that generation calls take — a mannequin, a pose, a background, a brand label — plus your account state. Nothing in this group creates an image.
Do resource calls cost credits?
No. Listing is free, and the uploads in this group — a custom mannequin, a background, a brand label — are free as well. You pay only for generations.
How do I page through a long list?
The list endpoints take a limit and a cursor: pass the last id you saw as `starting_after` and read the next page. Cache what you get rather than re-listing on every request.
Can I upload my own mannequins and backgrounds?
Yes. POST `/api/v1/mannequins`, POST `/api/v1/mannequins/jewelry`, POST `/api/v1/backgrounds` and POST `/api/v1/brand-labels` all accept your own images, and everything you upload is private to your account.
Where these ids are used
Capabilities
Virtual try-on API for apparel
REST API that places apparel on AI mannequins. Asynchronous, 1.5–4 minute generation, 5 credits at 2K, 6 at 4K. cURL, Node.js and Python examples.
ReadCapabilities
Jewelry try-on API for necklaces, rings, bracelets and earrings
Place necklaces, rings, bracelets and earrings on AI models via REST. 5 credits at 2K, close-up mannequins built-in, reflection-aware rendering from the Photta docs.
ReadCapabilities
Ghost mannequin API for hollow-man product photos
AI ghost mannequin endpoint. Remove the mannequin from a garment photo and preserve interior detail. 3D or flat-lay, batch processing, 4 credits at 2K.
ReadReference
First Photta image in under five minutes.
Sign up, generate an API key, run your first cURL call, poll until it completes, persist the result. Five steps, documented end-to-end.
ReadReference
Photta API authentication
How to authenticate against the Photta API: the Authorization header, the key prefix, where keys are created, and how to rotate one safely.
ReadReference
Photta API pricing
What each Photta API endpoint costs in credits at 2K and 4K, how charging and refunds work, and which endpoints are free. No per-image money price.
ReadReference
Photta API rate limits
The Photta API rate limit, its window, the Retry-After header, the polling interval and the per-plan concurrency caps, all read from the API documentation.
ReadReference
Photta API errors
The full list of Photta API error types with their status codes, the shape of an error body, and which failures are worth retrying.
Read
Every figure on this page comes from the Photta API docs · checked
Try the API in five minutes
Generate a Photta API key, paste the cURL snippet above, and you'll have your first on-model image before the coffee finishes brewing.
- 13 resource endpoints
- Bearer key
- 600 requests/min