TCS Innovations Logo

TCS-i API

Everything the console does, from any system or AI agent. REST, JSON.

Introduction

Everything in TCS-i works through this API, with or without a warehouse system (WMS). The console, AI agents and our WMS integrations use the same endpoints you do: anything you can do on a console page, you can do with a call.

  • Your data (/v1, free): boxes, products and orders. Send an order, get its box, record what it was packed in.
  • How it packs (free): packing preferences, box rules and cost parameters.
  • What happened (free): every recommendation and what was packed, reports, the assistant's fixes, and webhooks so your system hears about changes.
  • The engine (POST /pack, billed): pure 3D packing. Send items, boxes and requirements; get the plan. It never reads your data. POST /v1/pack-input builds its input from your data in TCS-i.
  • AI agents: the same actions as MCP tools at /mcp. An agent can set your account up from a key.
Quickstart, about 10 minutes:
  1. Start free, then in the console open Integrations > Link your own system and press Make a test key (free, never billed).
  2. Run the one-line command it shows. Our example syncs boxes and products, sends an order, gets the box and reports it packed, and every step turns green in the console.
  3. Add each call to your system where the guide says, with our one-file client (Python or Node). Boxes and products can start as a CSV upload.
  4. Swap in a live key to go live. Prefer Postman? Download the collection.
The whole loop
# 1. Whose key is this, and what is left to set up?
curl https://api.tcs-i.com/v1/setup -H "x-api-key: $TCSI_KEY"

# 2. Your boxes and products, once (then whenever they change)
curl -X PUT https://api.tcs-i.com/v1/boxes/CARTON-M -H "x-api-key: $TCSI_KEY" \
  -H "Content-Type: application/json" -d '{ "length": 40, "width": 30, "height": 20 }'
curl -X PUT https://api.tcs-i.com/v1/products/TEE-M -H "x-api-key: $TCSI_KEY" \
  -H "Content-Type: application/json" -d '{ "length": 30, "width": 20, "height": 3, "is_flexible": true }'

# 3. For each order: send it, get its box, say what it was packed in
curl -X PUT https://api.tcs-i.com/v1/orders/SO-1 -H "x-api-key: $TCSI_KEY" \
  -H "Content-Type: application/json" -d '{ "lines": [ { "sku": "TEE-M", "quantity": 2 } ] }'
curl -X POST https://api.tcs-i.com/v1/orders/SO-1/recommend -H "x-api-key: $TCSI_KEY"
curl -X POST https://api.tcs-i.com/v1/orders/SO-1/packed -H "x-api-key: $TCSI_KEY"

All requests go to https://api.tcs-i.com over HTTPS, with JSON bodies and JSON answers. Not sure what's left to do on your account? GET /v1/setup lists it.

Keys, scopes and test keys

Send your API key as the x-api-key header, or as Authorization: Bearer <key>. Make keys in the console (Developers); no account yet? Start free, no credit card needed.GET /v1/me says which account a key belongs to and what it may do.

curl https://api.tcs-i.com/v1/me -H "x-api-key: $TCSI_KEY"
curl https://api.tcs-i.com/v1/me -H "Authorization: Bearer $TCSI_KEY"     # the same

{ "account": "5555…", "name": "Acme Fulfilment", "scopes": ["pack", "read", "write"],
  "key_kind": "test", "plan": "free", "region": "UK", "units": "metric" }

Scopes

You choose what a key may do when you make it. A key made without choosing has read, write and pack.

ScopeAllows
readEvery GET: boxes, products, orders, results, reports, events, webhooks, the assistant, preferences, rules and settings.
writeEvery change to your data and settings: boxes, products, orders and what they were packed in, webhooks, preferences, box rules, cost parameters, the assistant's findings.
packBox recommendations: POST /pack and recommending an order (billed with a live key; free with a test key).
adminThe account itself: API keys, team invites, the plan, WMS logins and partner links. Only on a key made with it: give it to your own tooling or an agent setting the account up, not to a key that only syncs data.

Test keys

Build and test before you go live: in Console > Developers, choose Test key when you create a key. It works on any plan, the free one too. POST /pack and recommending an order answer exactly as for a live key (the answer says "mode": "test"), but they're never billed, and they're kept out of your orders, reports and alarms. Everything under /v1 works; shipped and packed orders reported with a test key are checked and answered ("stored": "test") but not stored for monitoring. A test key makes up to 500 recommendations a day (UTC), then answers 429. Other billed endpoints (/pack.png, batching, shipping) need a live key.

Postman

Every public endpoint as a Postman collection, with example bodies: download tcs-i.postman_collection.json, import it, and set the api_key variable to a test key. It's made from the same document as GET /v1/openapi.json, so it's always up to date.

Conventions, units and errors

The same rules hold on every /v1 endpoint. Only box recommendations are billed; everything else under /v1 is free on every plan, including the free one.

How it works
brandA 3PL names the brand (client account) on each call, in the body or as ?brand=. A single brand leaves it out; its data comes back as brand null.
dimension_unit, weight_unitSizes you send may be in cm, mm or in, and kg, g or lb. A write answers in the units it was sent in; a read answers in cm and kg unless you ask with ?dimension_unit= or ?weight_unit=.
limit, cursorLists return { data, next_cursor }. Pass next_cursor back as ?cursor= for the next page; up to 500 a page (default 100).
PUTCreates the thing, or changes it to what you send: safe to repeat, so retries never make duplicates. Sending something again as it is changes nothing: nothing is written or sent to your WMS, no webhook goes out, and the bulk calls answer result: unchanged. So a nightly sync of everything is fine.
Assistant fixesWhen the assistant fixes a size or tag from what packers shipped, you hear it as product.updated (changed_by: assistant). Copy it into your system. If your next sync still sends the old value, the fix stays (the bulk result says kept_assistant_fix); a different value is a new measurement and wins.
FieldsA field the API doesn't know is a 422 that names it and lists the fields, so a typo never passes as done. Fields a read returns (status, updated_at…) may be sent back as they are.
Your WMSIf a brand is connected to a WMS TCS-i keeps in step with, a change goes to that WMS first. If the WMS refuses it, nothing is saved (wms_refused, 502).

Errors

Every error has the same shape, with a message written for the person who has to fix it.

HTTP/1.1 409 Conflict
{ "error": { "code": "conflict",
             "message": "Several brands have a box 'STD' (Acme, Voxy): send ?brand=." },
  "detail": "Several brands have a box 'STD' (Acme, Voxy): send ?brand=." }
StatuscodeMeans
400, 422invalid_requestSomething in the request is wrong: the message names the field.
401unauthorizedNo API key.
402payment_requiredA live key asking for a recommendation on the free plan. Use a test key, or upgrade.
403forbiddenThe key isn't valid, or lacks the scope the call needs (the message says which).
404not_foundNo such box, product, order…
409conflictIt can't be done as things stand (already exists, already packed, several brands match).
429rate_limitedA test key's 500 recommendations a day.
502wms_refusedYour WMS refused the change; nothing was saved.
503unavailableTry again shortly.

Cookies & Preferences

We use essential cookies to secure your session and analytics to optimise performance. Read our Privacy Policy.