> ## Documentation Index
> Fetch the complete documentation index at: https://docs.maska.co.in/llms.txt
> Use this file to discover all available pages before exploring further.

# Glossary

> Definitions of the terms used across Maska procurement & inventory — locations, catalog, documents, stock, costing, and access.

A shared vocabulary for the Back of House (procurement & inventory) module. Terms
are grouped by area; document lifecycles are shown as state tables.

## Organisation & locations

<ResponseField name="Tenant">
  A single business (restaurant group) on Maska. All data — items, vendors,
  stock, documents — is scoped to one tenant and never visible across tenants.
</ResponseField>

<ResponseField name="Location">
  Any physical place that holds stock. One of three **types**:
  `warehouse`, `central_kitchen`, or `outlet`.
</ResponseField>

<ResponseField name="Outlet">
  A customer-facing branch (a restaurant or store). Outlets requisition stock,
  receive transfers, and run stock takes. Staff are scoped to their outlet.
</ResponseField>

<ResponseField name="Warehouse">
  A central stock-holding location that receives purchase orders from vendors
  and supplies outlets via transfers.
</ResponseField>

<ResponseField name="Central Kitchen (CK)">
  A prep location that produces stock and dispatches it to the **warehouse** (a
  `ck_dispatch`). Outlets never receive directly from the kitchen — the warehouse
  receives the kitchen's goods and then forwards them to the requesting outlet via
  a transfer.
</ResponseField>

<ResponseField name="Department">
  A section within the business (e.g. Bar, Kitchen, Housekeeping) used to scope
  which **items** and **staff** belong together. Enabling a department on an
  outlet seeds that department's items there at zero stock so staff can count them.
</ResponseField>

## Catalog

<ResponseField name="Item">
  A stock-keeping product. Each item has a **type** — `raw_material`,
  `consumable`, or `finished_good` — a base unit (UOM), and an auto-minted SKU.
</ResponseField>

<ResponseField name="SKU">
  The item's stock-keeping code, auto-minted as `ITM-00001`. Unique per tenant.
</ResponseField>

<ResponseField name="UOM (Unit of Measure)">
  The base unit an item is counted and valued in (kg, g, L, ml, pcs, …). All
  stock quantities are stored in the base unit.
</ResponseField>

<ResponseField name="Pack / Pack size / Purchase unit">
  Items may be purchased in **packs** — `packSize` base units per pack, labelled
  by a `purchaseUnit` (BOX, TRAY, PACK…). Ordering happens in whole packs, but
  quantities are always stored in base units (a pack of 1 is just the base unit).
</ResponseField>

<ResponseField name="Par level / Reorder point">
  The per-location stock threshold below which an item is considered
  **low stock** and should be reordered. Set per item per location.
</ResponseField>

<ResponseField name="Vendor (Supplier)">
  A business you buy from. Carries contact details and **payment terms**
  (`net_7`, `net_15`, `net_30`, `advance`, `cod`).
</ResponseField>

<ResponseField name="Vendor catalog">
  A vendor's price list: per item, a `unitPrice`, optional minimum order
  quantity, and a **preferred-vendor** flag (one preferred vendor per item).
</ResponseField>

<ResponseField name="GST rate">
  The statutory Indian tax slab on an item — one of `0`, `5`, `12`, `18`, `28`
  percent. Input is constrained to these five.
</ResponseField>

## Procurement documents

Every document gets an auto-minted **doc number** and moves through a
defined **state** lifecycle.

<ResponseField name="Purchase Request (PR) / Requisition">
  A request to procure items, typically raised by an outlet or department. An
  approved PR is converted into a Purchase Order.
</ResponseField>

| PR state    | Meaning                                 |
| ----------- | --------------------------------------- |
| `draft`     | Being prepared, not yet submitted.      |
| `submitted` | Sent for manager approval.              |
| `approved`  | Approved, ready to convert to a PO.     |
| `rejected`  | Declined by the approver.               |
| `converted` | Turned into a Purchase Order.           |
| `fulfilled` | The resulting goods have been received. |

<ResponseField name="Purchase Order (PO)">
  An order placed with a vendor for items at agreed prices. Receiving against a
  PO is done with a GRN.
</ResponseField>

| PO state                 | Meaning                                                           |
| ------------------------ | ----------------------------------------------------------------- |
| `draft`                  | Being prepared.                                                   |
| `pending_owner_approval` | Awaiting owner sign-off (when no auto-approval threshold is set). |
| `sent`                   | Issued to the vendor (in transit).                                |
| `partially_received`     | Some — not all — lines received.                                  |
| `received`               | Every line fully received.                                        |
| `closed`                 | Settled / archived.                                               |

<ResponseField name="Goods Received Note (GRN)">
  Records the receipt of goods. **Posting** a GRN writes the stock ledger,
  updates balances (via **WMA**), and advances the
  source PO/transfer. A GRN's **source** is a `purchase_order` or a `transfer`
  (central-kitchen dispatches are received through a separate dispatch-receive
  flow, not as a GRN). States: `draft` → `posted` (or `cancelled`).
</ResponseField>

<ResponseField name="Transfer">
  A stock movement between locations (e.g. warehouse → outlet, or outlet →
  outlet). States: `draft` → `dispatched` → `received` (or `cancelled`). The
  receiving side records it as a transfer-sourced GRN.
</ResponseField>

<ResponseField name="Adjustment">
  A manual change to stock outside the normal purchase/transfer flow. **Types**:
  `opening_balance`, `variance`. A write-off (wastage/spoilage) posts as a
  `variance` adjustment carrying a **reason** (`wastage`, `spoilage`,
  `count_variance`, `damage`, `expiry`, `other`). States: `draft` → `posted`
  (or `cancelled`).
</ResponseField>

<ResponseField name="Opening balance">
  The initial stock seeded at a location when it is first set up — an adjustment
  of type `opening_balance`. Priced from the vendor catalog when available.
</ResponseField>

## Stock & costing

<ResponseField name="Stock balance">
  The current on-hand quantity **and** average cost of one item at one location.
  This is the live "how much do we have, and what is it worth" record.
</ResponseField>

<ResponseField name="Stock ledger">
  The append-only history of every stock movement (GRN, adjustment, transfer,
  wastage, …), each row carrying the running quantity and running average cost
  after the movement. The ledger is the source of truth; the balance is its tip.
</ResponseField>

<ResponseField name="WMA (Weighted Moving Average)">
  The costing method. On a receipt, the existing on-hand value is blended with
  the incoming value to recompute a new **average cost**:
  `newAvg = (qtyOnHand × avgCost + qtyIn × unitCost) / (qtyOnHand + qtyIn)`.
</ResponseField>

<ResponseField name="Average cost (avgCost)">
  The per-unit cost used to value stock, maintained by **WMA**.
</ResponseField>

<ResponseField name="Stock value">
  `quantity × average cost` — the monetary value of on-hand stock.
</ResponseField>

<ResponseField name="Low stock">
  An item whose on-hand quantity is at or below its
  **par level / reorder point** (when that point is > 0).
</ResponseField>

<ResponseField name="Stock take">
  A physical count to reconcile recorded stock against reality. Differences
  surface as **variances** and post correcting adjustments.
</ResponseField>

<ResponseField name="Variance">
  A difference between two quantities — counted vs recorded (stock take), or
  received vs ordered (GRN). Small differences within tolerance are treated as
  exact matches, not variances.
</ResponseField>

<ResponseField name="Wastage">
  Stock written off as a loss. It posts as a `variance` **Adjustment** (above)
  whose **reason** is one of `wastage`, `spoilage`, `count_variance`, `damage`,
  `expiry`, `other`. Logged against an item, quantity, and reason.
</ResponseField>

## People & access

<ResponseField name="Role">
  An authorization role on the procurement module: `admin`, `manager`,
  `procurement_manager`, `warehouse_manager`, `outlet_staff`, `kitchen_staff`
  (central-kitchen head chef), and `viewer` (read-only). A user may hold more
  than one.
</ResponseField>

<ResponseField name="Permission">
  A specific capability a role grants, e.g. `items:write`, `prs:approve`,
  `grns:manage`, `stock:read`. Effective permissions are the union of the user's
  roles. Managers/owners are unscoped; outlet staff are department-scoped.
</ResponseField>

## System

<ResponseField name="Doc number">
  An auto-minted, per-tenant document identifier, e.g. `PO-2026-000001`,
  `GRN-2026-000001`, `ADJ-2026-000001`, `ITM-00001`. Minted transactionally so
  numbers never collide or skip.
</ResponseField>

<ResponseField name="Audit log">
  A field-level change history (old value → new value, who, when) recorded for
  items and other entities, surfaced as **History** in the UI.
</ResponseField>
