YOUR_ID and YOUR_PASSWORD with your partner credential. Every call uses HTTP Basic authentication, except the file upload in step 1.
Your credential needs the
assets_write scope to upload art and the orders_write scope to preview and place orders. See Scopes.Before you start
- Garment ids. An order line names its garment either by catalog ids (
styleIdandcolorId) or bybrand,styleNumberandcolorName. There is no catalog endpoint yet, so ask your decorator for the ids or the exact names of the styles you may order. - What’s supported. Only screen print (
SP) decorations and garments you supply yourself (suppliedBy: "customer") are taken today. Fields the API doesn’t take yet, such asrush, are refused withnot_supported_yet. - Art. PNG, JPG, GIF, WebP, TIFF, SVG, PDF, AI, EPS or PSD, up to 100 MB.
1
Upload your art
Start the upload with the file name and size in bytes:The answer holds an Then finalize the upload so DEKHQ checks and stores the file:The
upload.uploadId and a signed uploadUrl:PUT the file’s bytes to uploadUrl with exactly the uploadHeaders. The URL is on a different host from the API and is already signed, so send no Basic authentication with this request. It expires after a few minutes.upload.status is now finalized. You can use the same uploadId on later orders.2
Preview the price
Send the order you plan to place to For a pickup order, send
POST /api/partners/v1/order-submissions/preview. Nothing is created."shippingMethod": "pickup" and leave out shipTo.A priced preview can still be refused when you place the order. Some checks, such as an unrecognized size or a print location that doesn’t fit the garment, run only at placement.
3
Place the order
Send the same body to The answer is always HTTP Keep the
POST /api/partners/v1/order-submissions, with two additions: expectedTotal set to the preview’s total, and an Idempotency-Key header you make up (a unique string per order).202 with a submission. Usually it is already decided:submissionId and the orderId. If you send the same key and body again you get this first answer, never a second order, so it is safe to retry after a timeout. The same key with a different body returns 409 idempotency_conflict.4
Poll for the outcome
The submission
status is one of:accepted: the order exists. The answer includesorder.refused: the order wasn’t created. See If an order is refused.received: still processing. CallGET /api/partners/v1/order-submissions/{submissionId}again after a moment until it changes.
GET /api/partners/v1/orders/{orderId}; see Order Status.What pending_approval means
A new order is accepted with status pending_approval. DEKHQ has the order and its price, but it is not in production yet: it waits for approval on the DEKHQ side. Once approved it moves on to approved, in_production, shipped and delivered; cancelled is final. Check GET /api/partners/v1/orders/{orderId} to see where it is.
If an order is refused
A refused submission or preview returns a problem withcode order_refused and an errors[] list naming each field. Fix the fields and submit again with a new Idempotency-Key. These are the refusals seen while testing the sandbox:
An upload that can’t be taken returns HTTP
422 upload_refused when you start it or finalize it, for example for an unsupported file type, a file over 100 MB, or a finalize before the bytes arrived. Every error lists its requestId; quote it if you contact your decorator. See Rate limits and errors for the full list.
Verified against DEKHQ cbe1264 on 2026-11-12