Customer · Settings

Integration API

Get prices, create orders and track their status from your own software; the API docs, first requests, bulk orders, safe retries, webhook signatures and limits.

The Integration API lets your ordering, ERP or warehouse software connect to Courino directly. Your software can do every order task you do by hand in the portal: get a price, create, edit and cancel orders, and track the status and live location. This article is a starting guide for your software developer.

The price comes from the price list your courier company set for you, with the same calculation as in the portal. An order created through the API lands on the company's screen just like one entered by hand.

What do you need?

Your first order step by step

  1. Create a key on the Integration (API keys) card on the My details page.
  2. Click the API docs button at the top right of the same card. The docs open in a new tab, in the language you use the portal in (English or Turkish).
  3. In the docs, click Authorize, paste the key and confirm. You can now try every endpoint from the browser with Try it out, using your real account.
  4. Get the districts and delivery types with GET /me/order-options. Every address in an order needs a district ID (districtId) and the order needs a delivery type (deliveryTypeId).
  5. See the price with POST /pricing/quote. This request saves nothing.
  6. Create the order with POST /orders. The response returns the order's ID (id) and number (number).
  7. Read the status with GET /me/orders/{id} or listen for it with a webhook.
The sender is always the customer account the key belongs to. You can leave the sender empty ({}) in the request.

Commonly used endpoints

All paths are under /api/v1 (e.g. https://client.courino.com/api/v1/orders).

EndpointWhat it does
GET /me/order-optionsDistricts, delivery types and business hours
POST /pricing/quotePrice quote (saves nothing)
POST /ordersCreates an order
POST /me/orders/batchBulk orders (up to 1000 rows)
GET /me/ordersMy orders; filter by reference, barcode, status and date, free-text search with q, amount range with minAmount/maxAmount, sorting with sort (e.g. sort=-total)
GET /me/orders/{id}Order details
PUT /me/orders/{id}Edits an order that is still in the pool
POST /me/orders/{id}/cancelCancels the order
GET /me/orders/{id}/trackingLive location while the courier is on the way
POST /me/orders/{id}/tracking-linkTracking link to send to the recipient
POST /me/orders/importsPreviews an Excel/CSV shipment file; .../confirm creates the orders
GET /me/ecommerce/ordersOrders from your connected stores; fix, retry or skip the ones awaiting a match
GET /me/customer/statementAccount statement for a period (PDF)
GET /me/customer/paymentsYour online payments (read only)
GET /me/customer/messagesSMS and e-mails sent to you and your contacts

This table only lists the most used endpoints; every billing, cash on delivery, contact and special date endpoint is in the documentation.

Safe retries

When the connection drops you can't tell whether the request arrived. When creating and cancelling orders, put a value unique to that job (e.g. your own order number) in the Idempotency-Key header. If you send it again with the same value, no second order is created and the first response is returned. Sending different content with the same value returns a 409 error. The value is kept for 24 hours.

In bulk orders each row's reference number (reference) does the same job: an order with the same reference isn't created twice. You can send the bulk request with dryRun: true first to only validate it. See Bulk shipments for details.

Verifying the webhook signature

Every webhook request comes with these headers:

To verify the signature, join the t value, a dot and the raw request body, and compute HMAC-SHA256 with the signing secret (all of it, including whsec_); compare the result with v1. Reject requests whose time is more than 5 minutes old. Reply quickly with 2xx; if you return 410, retries stop for that message. A code sample is in the docs and on the courino.com/en/developers page.

Rules and limits

Having trouble?