Hub API
Catalog, orders, inventory, and authentication. All paths are under /api/v1.
Authentication
Brand endpoints require X-API-Key. Sandbox keys return fixture catalog data and cannot place live orders. Never expose live keys in browser-side code — call Hub from your server or Brand Kit backend.
| Type | Prefix | Catalog | Rate limit |
|---|---|---|---|
| Live | nx_live_ | Production SKUs | 120/min (default) |
| Sandbox | nx_sandbox_ | Fixture SKUs only | 30/min (default) |
Request headers
X-API-KeyBrand API key — nx_live_* or nx_sandbox_*Idempotency-KeyUUID required on POST /orders — replays same response for 24hX-API-VersionOptional — must match URI version (1)X-Correlation-IDOptional client trace id — echoed in error responsesContent-Typeapplication/json on all POST/PUT bodies
Pagination & filters
Catalog list and sync endpoints accept standard pagination. Responses include data and pagination.total.
limitPage size — 1–200, default 50offsetZero-based row offset for paginationqSearch product name or sku_code (catalog only)currencyFilter price context — USD, EUR, GBP, CHF, AEDupdated_fromISO date — return products updated after this timestamp (sync)
Endpoints
All paths are relative to /api/v1.
| Method | Path |
|---|---|
GET | /products |
GET | /products/sync |
GET | /products/:id |
GET | /products/:id/price |
POST | /orders |
GET | /orders |
GET | /orders/:id |
GET | /inventory/:id |
POST | /inventory/bulk |
GET | /onboarding/applications/:id |
Code examples
Switch language tabs to copy examples in cURL, JavaScript, TypeScript, or Python.
List catalog (paginated)
Returns brand-scoped SKUs. Use limit/offset for pagination; optional q filters by name or sku_code.
curl -s "https://api.nerionx.dev/api/v1/products?limit=20&offset=0" \
-H "X-API-Key: nx_live_your_key"Cold-start catalog sync
Use GET /products/sync during Brand Kit onboarding to page through the full master catalog.
curl -s "https://api.nerionx.dev/api/v1/products/sync?limit=100&offset=0" \
-H "X-API-Key: nx_live_your_key"Create order (idempotent)
Pass Idempotency-Key on every POST. Hub validates price floor and locks inventory before confirming.
curl -s -X POST "https://api.nerionx.dev/api/v1/orders" \
-H "Content-Type: application/json" \
-H "X-API-Key: nx_live_your_key" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"brand_id": "your-brand-uuid",
"customer": { "email": "buyer@example.com", "phone": "+14155550100" },
"shipping_address": {
"line1": "1 Main St", "city": "Zurich",
"postal_code": "8001", "country": "CH"
},
"items": [{
"sku_id": "SKU-001", "quantity": 1,
"local_price_cents": 1500, "local_currency": "USD"
}]
}'Handle API errors
All Hub errors return a consistent envelope with code, message, and correlation_id.
{
"error": {
"code": "PRICE_FLOOR_VIOLATION",
"message": "local_price_cents is below the Hub price floor",
"details": { "sku_id": "SKU-001", "floor_cents": 1800 },
"correlation_id": "req_01HX9K2M4QZ8"
}
}