API quickstart: your first 3D model in three requests
Three calls: check your key, submit a generation, poll it. Everything below runs in a terminal with cURL.
1. Create a key
Open Settings → API keys and create a key with the read and generate scopes. The full value (sk-…) is shown once; store it as API_KEY in your environment. API access is included with every paid plan and credit pack — see pricing.
2. Check the key and your balance
cURL
curl -H "Authorization: Bearer $API_KEY" https://ai3d.studio/v1/meA 200 with data.credits means the key works. A 401 or 403 names the problem in data.code — see error codes.
3. Submit a text-to-3D request and poll it
cURL
# 1. Start the generation. Reuse the same Idempotency-Key only when retrying this request.
curl -X POST https://ai3d.studio/v1/generate \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{"mediaType":"3d","model":"tripo-h3-1","scene":"text-to-3d","prompt":"a wooden rocking chair with a woven seat, game asset"}'
# 2. Poll every 5 seconds with the id from data.id until data.workflow.isTerminal is true.
curl -H "Authorization: Bearer $API_KEY" \
https://ai3d.studio/v1/workflows/WORKFLOW_IDThe submit answers with data.id (the workflow id) and data.totalCredits (what was charged). When data.workflow.isTerminal is true and data.workflow.status is success, data.assets[].storedUrl holds the model files. Full scripts in Python and JavaScript are on the code samples page.