The API

Every call carries an X-Api-Key header. A key is read only, write only, or both, and is shown once when it is made. Answers are JSON.

CallWhat it doesNeeds
GET /api/integration/productsThe catalogue with stock on hand, packs and GTINs.Read
GET /api/integration/stock?groupBy=product|location|lotStock on hand, grouped.Read
GET /api/integration/lots?expiringDays=30Lots and their expiry.Read
GET /api/integration/movementsThe movement ledger, newest first.Read
GET /api/integration/scan?barcode=…What a GS1 or HIBC barcode says and which product it is.Read
POST /api/integration/consumeRecords use: lines of GTIN or SKU, quantity, lot, location code and a reference. Picked soonest-expiry first.Write
POST /api/integration/receiveBooks a delivery in: lines of GTIN or SKU, lot, expiry, quantity and location code.Write
POST /api/integration/temperatureA sensor reading for a location code; outside the range raises an alert.Write

Recording use from a clinical system

POST /api/integration/consume
X-Api-Key: arm_…

{
  "lines": [
    { "gtin": "09312345678907", "quantity": 2, "locationCode": "TH2-CART", "reference": "Case 4471" }
  ]
}

Webhooks

An https address you name is sent a JSON message when something you subscribe to happens. Each message carries X-Armaria-Event and X-Armaria-Signature: sha256=…, an HMAC of the body with the secret shown when the webhook was made. A delivery that is not answered 2xx is retried with growing waits.

EventWhen
stock.lowA product reached its reorder point.
stock.movedStock was received, moved, used or adjusted.
lot.expiringA lot is inside its expiry warning window.
lot.expiredA lot expired.
purchaseorder.sentA purchase order was sent to the vendor.
purchaseorder.receivedA purchase order was fully received.
goodsreceipt.postedA delivery was booked in.
recall.matchedA recall matched stock on hand.
temperature.breachA location read outside its temperature range.

Barcodes it reads

GS1

DataMatrix and GS1-128 with the application identifiers for GTIN (01), expiry (17), production date (11), lot (10) and serial (21). A day of 00 is the end of the month.

HIBC

Primary and secondary HIBC codes, as printed on many surgical products.

Plain GTIN and your own codes

EAN-13, UPC and any GTIN padded to 14 digits; a product's SKU or a pack's own barcode; a shelf's label.

Connecting a system?

We will walk your integrator through the keys, the calls and the webhook signature.

Talk to us