Run a template
POST /v1/orgs/:orgId/template/:templateId/runContent-Type: application/jsonx-license-key: <server-secret>Example:
curl -X POST "$AABHAS_CORE_BASE_URL/v1/orgs/$AABHAS_ORG_ID/template/$AABHAS_TEMPLATE_ID/run" \ -H "content-type: application/json" \ -H "x-license-key: $AABHAS_LICENSE_KEY" \ --data-raw '{ "entityId": "customer-or-product-reference", "traceId": "client-generated-trace-id", "aspectRatioKey": "2:3", "variables": {}, "options": {}, "inputs": { "<PERSON_INPUT_KEY>": "https://example.com/person.jpg", "<GARMENT_INPUT_KEY>": "https://example.com/garment.jpg" } }'Input keys and aspect ratios come from the assigned template. Do not copy keys from another organization or template.
Request identities
Section titled “Request identities”traceIdconnects the client request to outputs and diagnostics. Generate a unique, non-secret value.entityIdgroups outputs for an application entity such as a customer session or catalog item. Do not place email addresses or sensitive personal data in it.
Use the same idempotency or request identity only for the same logical execution. A deliberate new generation should receive a new identity.
Reuse image preparation
Section titled “Reuse image preparation”Templates configured for prepared-image caching can reuse eligible intermediate images automatically. Send the original inputs as usual; customer or garment identifiers are not required for cache matching. Read Prepared-image caching for prerequisites, response statuses, a verification sequence, and optional caller-provided prepared inputs.