Ghalalytics Documentation
Ghalalytics is a warehouse management system built for teams that operate in low-connectivity or offline environments. It works fully offline, syncs automatically when a connection is restored, and maintains a complete, immutable audit trail.
This documentation covers everything from initial setup to advanced API integration. If you're new, start with the Quickstart guide to have your first warehouse running in under 5 minutes.
Quickstart
Get your first warehouse live in under 5 minutes. No credit card or configuration required.
1. Create an account
Visit ghalalytics.app/auth/signupand sign up with your email or GitHub. Confirm your email, and you'll be taken directly to your workspace.
2. Create a warehouse
From the dashboard, click New Warehouse. Enter a name, timezone, and optional address. Your warehouse is created instantly — you can add locations (rows, aisles, bins) later.
3. Add your first SKUs
Navigate to Products and click Add SKU. Fill in the product name, unit, barcode (optional), and reorder threshold. You can also bulk-import from a CSV file.
4. Record a receipt
Go to Receipts, click New Receipt, scan or enter the SKU barcode, and confirm the quantity. Your stock level updates immediately — even offline.
Offline First
Ghalalytics is designed to work without internet. Every action (receipt, dispatch, adjustment) is written to a local append-only log immediately. When connectivity is restored, logs from all devices are merged automatically using deterministic rules.
How it works
Each mutation is an immutable log entry with a unique ID, a timestamp, the acting user, and the delta (e.g. +50 units of SKU-001). The sync engine merges these logs by time-ordering them across devices and replaying them to reconstruct the canonical state.
Conflict resolution
Because all mutations are append-only and non-destructive (there are no UPDATE or DELETE operations — only ADD, REMOVE, and ADJUST), there are no write conflicts. Two devices recording a receipt for the same SKU at the same time simply result in two log entries, both applied in order.
// Example: merge result for two simultaneous receipts LOG ENTRY 001 | 2026-06-11T14:01:33Z | user:alice | RECEIVE +50 SKU-001 LOG ENTRY 002 | 2026-06-11T14:01:35Z | user:bob | RECEIVE +30 SKU-001 // Canonical state after merge: SKU-001 stock = 80 units
REST API
The Ghalalytics API allows you to programmatically read inventory levels, create receipts and dispatches, manage SKUs, and trigger report generation from any system.
Base URL
https://api.ghalalytics.app/v1
Authentication
All API requests require a Bearer token in the Authorization header. Generate a token from Settings → API Keys.
curl https://api.ghalalytics.app/v1/warehouses \ -H "Authorization: Bearer YOUR_API_KEY"
Get stock levels
GET /v1/warehouses/:id/stock
// Response
{
"warehouse_id": "wh_01ABCD",
"as_of": "2026-06-11T14:00:00Z",
"items": [
{ "sku": "SKU-001", "name": "Paracetamol 500mg", "qty": 840, "unit": "boxes" },
{ "sku": "SKU-002", "name": "Ibuprofen 200mg", "qty": 320, "unit": "boxes" }
]
}Record a receipt
POST /v1/warehouses/:id/receipts
{
"reference": "PO-2026-1042",
"supplier": "East Africa Pharma",
"received_at": "2026-06-11T14:00:00Z",
"lines": [
{ "sku": "SKU-001", "qty": 200 },
{ "sku": "SKU-003", "qty": 50 }
]
}