Master REST API Endpoint Reference
lynx-anchor
lynx-anchor
This document is the complete, exhaustive HTTP REST API referencefor all 41 Express route modules (53 documented API subsystem sections) in the backend server.
Table of Contents
- Base URL, Headers & Authentication
- Public & System Recovery APIs (
/api/public) - Authentication APIs (
/api/auth) - Enterprise Sales & POS APIs (
/api/sales) - Inventory, Items & Transfers (
/api/inventory) - Purchase Orders (
/api/purchase-orders) - Goods Receiving / GRN (
/api/receiving) - Suppliers & Vendors (
/api/suppliers) - Restaurant, Tables, KOTs & KDS (
/api/restaurant) - Accounting, COA, Vouchers & Loans (
/api/accounting) - Finance & Ledgers (
/api/finance) - HRMS & Staff Payroll (
/api/hrms) - Customer App & Rider Delivery (
/api/delivery) - Lucky Draw & Raffle Campaigns (
/api/lucky-draw) - Night Audit & EOD Reconciliation (
/api/night-audit) - B2B Marketplace & Trade Chat (
/api/community) - Famalth Lynx AI Assistant (
/api/v1/ai) - Autonomous Background Agents (
/api/v1/agent) - AI Cart Intelligence & Recommendations (
/api/v1/intelligence) - Plugin Marketplace & Sandbox (
/api/v1/plugins) - Workflow Automation Engine (
/api/v1/workflows) - Developer API Keys & Webhooks (
/api/v1/developer) - WhatsApp Cloud API & Queue (
/api/whatsapp) - WhatsApp Webhooks (
/webhooks/whatsapp) - Sticky Notes System (
/api/notes) - Multi-Tax Groups (
/api/settings/tax-groups,/api/inventory/tax-groups) - User & Role Management (
/api/users) - Reports & Analytics (
/api/reports,/api/analytics) - Operations & Audit Trail (
/api/v1/operations,/api/audit) - Notifications (
/api/notifications) - System Server Time (
/api/system) - 1-Click Cloud Migration Gateway (
/api/public/migration) - Quick Users & PIN Authentication (
/api/auth) - Multi-Country Tax Seeding & Integrity (
/api/settings/tax-groups) - Contactless QR Table Dining & Multi-Seat Portal (
/api/public/dining) - M-Pesa & Mobile Money Gateway (
/api/payments/mpesa) - Multi-Gateway Payment Configuration (
/api/payments/gateways) - Plugin Developer Studio & Sandbox Engine (
/api/v1/plugins) - Public Outlet Onboarding & OTP Verification (
/api/public/outlet) - Operations Document Modification & Differential Revisions
- Enterprise SaaS Control Plane & IAM (
/api/v1/control-plane) - Sandboxed Data Doctor & Schema Studio (
/api/v1/control-plane/support) - Clinic Management & OPD Healthcare Suite (
/api/clinic) - Public Patient Portal & Appointments (
/api/public/clinic) - System Maintenance & Lockout Engine (
/api/system/maintenance) - Transport Logistics & Fleet Management (
/api/transport) - Delivery Challan Subsystem (
/api/restaurant/challan) - Multi-Tiered Storage & Enterprise Backups (
/api/backup) - Model Context Protocol (MCP) & AI Gateway (
/api/v1/developer/mcp) - Statutory Tax Compliance (GST & ITR) (
/api/accounting/tax) - Employee Mobile Self-Service & Office HRMS (
/api/hrms/employee,/api/hrms/employee-auth) - Open REST API Gateway (
/api/v1/open) - B2B Marketplace Vendors (
/api/marketplace)
1. Base URL, Headers & Authentication
- Default Local Base URL:
http://127.0.0.1:3000 - Health Check:
GET /health - Protected Request Headers:
Authorization: Bearer <JWT_TOKEN>
Content-Type: application/json
Idempotency-Key: <UUID> (Optional for safe retries)
2. Public & System Recovery APIs (/api/public)
No JWT required.
POST /api/public/outlet/check- Check outlet registration status.POST /api/public/outlet- Register new outlet terminal.GET /api/public/property-info- Retrieve public store branding.POST /api/public/recovery/verify-pin- Verify owner master recovery PIN.POST /api/public/recovery/execute- Execute automated database recovery.POST /api/public/emergency-reset/request-otp- Send SMS/Email password reset OTP.POST /api/public/emergency-reset/verify-and-reset- Set new admin password with OTP.POST /api/public/system/check-update- Check for new software version binaries.
3. Authentication APIs (/api/auth)
POST /api/auth/login- Authenticate store user (email/password) and issue JWT token.POST /api/auth/pin-login- High-speed PIN login for waiters/cashiers with outlet & username resolution.GET /api/auth/quick-users- List quick-login staff enabled for dropdown PIN selection.POST /api/auth/refresh- Refresh expired JWT token.POST /api/auth/change-password- Change current user password.POST /api/auth/logout- Invalidate user session.
4. Enterprise Sales & POS APIs (/api/sales)
Requires: JWT + INVENTORY License Module.
GET /api/sales- List sales invoices with date range, cashier, and customer filters.POST /api/sales- Commit new POS sale transaction (atomic stock deduction & loyalty credit).GET /api/sales/:id- Retrieve full sale details, tax split, and payment records.PUT /api/sales/:id- Update sale bill details (Admin only).POST /api/sales/:id/void- Void/cancel sales invoice and restore stock.POST /api/sales/:id/reprint- Generate audited receipt reprint payload.GET /api/sales/customer/:phone- Retrieve sales history for customer.
5. Inventory, Items, Modifiers & Stock Taking (/api/inventory)
GET /api/inventory/items- List items with search, category, Veg/Non-Veg, and low stock filters.POST /api/inventory/items- Create new item master record.PUT /api/inventory/items/:id- Update item details, pricing, dietary flags, and barcode.DELETE /api/inventory/items/:id- Deactivate item.GET /api/inventory/categories- List item categories.POST /api/inventory/categories- Create item category.GET /api/inventory/modifiers- List item modifiers and add-on groups (e.g. Extra Cheese).POST /api/inventory/modifiers- Create modifier with price and optional raw material recipe link.PUT /api/inventory/modifiers/:id- Edit modifier properties and pricing.DELETE /api/inventory/modifiers/:id- Remove modifier.GET /api/stock-taking- Retrieve stock audit sheet with current balances and variances.POST /api/stock-taking/reconcile- Commit physical count and post adjustment variance journal.GET /api/inventory/stock-locations- List warehouse locations & racks.POST /api/inventory/transfers/request- Create multi-branch stock transfer request.POST /api/inventory/transfers/dispatch- Dispatch stock to target branch.POST /api/inventory/transfers/receive- Accept inward transfer at target outlet.POST /api/inventory/damages- Record damaged inventory write-off.POST /api/inventory/assembly/produce- Run BOM assembly production batch.
6. Purchase Orders (/api/purchase-orders)
Requires: JWT + PURCHASE License Module.
GET /api/purchase-orders- List purchase orders with status filter.POST /api/purchase-orders- Create new purchase order (supports integer net rounding for VAT-inclusive).GET /api/purchase-orders/:id- Retrieve purchase order details.PUT /api/purchase-orders/:id- Update pending purchase order.POST /api/purchase-orders/:id/approve- Manager approval of PO.POST /api/purchase-orders/:id/cancel- Cancel purchase order.
7. Goods Receiving / GRN (/api/receiving)
DOCTRINE: GRNs are NEVER auto-generated. They require manual operator physical counting and inward verification.
GET /api/receiving- List Goods Receiving Notes (GRNs).POST /api/receiving- Commit manual operator-verified GRN and credit stock into inventory.GET /api/receiving/:id- Retrieve GRN details and linked PO.PUT /api/receiving/:id- Modify receiving entry (Admin audit).
8. Suppliers & Vendors (/api/suppliers, /api/payment-methods)
GET /api/suppliers- List suppliers with outstanding balances.POST /api/suppliers- Create supplier master profile (state is optional; opening balance auto-syncs to COA).PUT /api/suppliers/:id- Update supplier details & credit limit.POST /api/suppliers/:id/payments- Settle supplier invoice using custom payment methods.POST /api/suppliers/return- Process return to supplier (Debit Note).POST /api/suppliers/return-refund- Settle supplier refund/adjustment.GET /api/payment-methods- List payment methods with linkedcoa_account_id.POST /api/payment-methods- Create custom payment method linked to COA Asset account.PUT /api/payment-methods/:id- Update payment method and COA binding.
9. Restaurant, Tables, KOTs & KDS (/api/restaurant)
GET /api/restaurant/floors- List floors and dining areas.POST /api/restaurant/floors- Create dining floor.GET /api/restaurant/tables- List tables with live availability status and assigned staff.POST /api/restaurant/tables- Create new dining table.POST /api/restaurant/tables/bulk-import- Bulk import dining tables from Excel/CSV template.POST /api/restaurant/tables/:id/assign- Assign table or section to specific waiter/captain.PUT /api/restaurant/tables/:id/status- Update table status (OCCUPIED,AVAILABLE).POST /api/restaurant/tables/transfer- Transfer active order to another table.POST /api/restaurant/tables/merge- Merge multiple tables for group dining.GET /api/restaurant/kots/active- Live active KOTs stream for KDS.POST /api/restaurant/kots- Create & fire new KOT to kitchen (supports multi-client tickets per table).PUT /api/restaurant/kots/:id/items/:itemId/status- Bump-bar update (COOKING->DONE).POST /api/restaurant/kots/:id/settle- Settle table and generate POS invoice.POST /api/restaurant/reservations- Create table reservation.POST /api/v1/qr-order- Public customer QR code table self-ordering submission.
10. Accounting, COA, Vouchers & Loans (/api/accounting)
GET /api/accounting/coa- Retrieve hierarchical Chart of Accounts tree.POST /api/accounting/coa- Create ledger account.POST /api/accounting/coa/seed- Seed default retail/restaurant accounts.GET /api/accounting/vouchers- Search accounting vouchers (JV, PV, RV, CV).POST /api/accounting/vouchers- Post balanced double-entry voucher.GET /api/accounting/banks- List company bank accounts.POST /api/accounting/banks- Register bank account.GET /api/accounting/loans-assets- List loans and amortized asset schedules.POST /api/accounting/loans- Register business loan.POST /api/accounting/loans/pay-emi- Post monthly EMI installment.
11. Finance & Ledgers (/api/finance)
GET /api/finance/cash-ledger- Retrieve daily cashbook transactions.POST /api/finance/expenses- Record expense entry.GET /api/finance/recurring-expenses- List recurring expense templates.
12. HRMS & Staff Payroll (/api/hrms)
GET /api/hrms/employees- List employee directory.POST /api/hrms/employees- Onboard new employee.GET /api/hrms/shifts- List work shifts.POST /api/hrms/shifts- Create work shift.POST /api/hrms/attendance/punch- Record employee punch-in / punch-out.GET /api/hrms/attendance/daily-grid- Daily employee attendance grid.POST /api/hrms/payroll/calculate- Run monthly gross-to-net payroll engine.POST /api/hrms/payroll/finalize- Finalize payroll and generate payslips.
13. Customer App & Rider Delivery (/api/delivery)
GET /api/delivery/catalog- Public customer shopping catalog.POST /api/delivery/orders- Place online delivery order.GET /api/delivery/orders/:id/track- Real-time order delivery tracking.POST /api/delivery/rider/login- Rider mobile authentication.PUT /api/delivery/rider/orders/:id/status- Rider updates delivery status (PICKED_UP,DELIVERED).
14. Lucky Draw & Raffle Campaigns (/api/lucky-draw)
GET /api/lucky-draw/campaigns- List lucky draw campaigns.POST /api/lucky-draw/campaigns- Create new raffle campaign.GET /api/lucky-draw/campaigns/:id/stats- Retrieve participant counts and ticket stats.POST /api/lucky-draw/campaigns/:id/draw- Execute certified random winner draw.
15. Night Audit & EOD Reconciliation (/api/night-audit)
GET /api/night-audit/status- Check day-end closing status.POST /api/night-audit/validate- Validate open registers, unbilled KOTs, and cash.POST /api/night-audit/execute- Finalize day-end closing and lock daily ledger.
16. B2B Marketplace & Trade Chat (/api/community)
GET /api/community/conversations- Fetch 1-on-1 chats and trade channels.POST /api/community/conversations- Initiate new supplier conversation.GET /api/community/messages- Retrieve chat history.POST /api/community/messages- Send direct message or PO reference.GET /api/community/merchants- List verified marketplace suppliers.
17. Famalth Lynx AI Assistant (/api/v1/ai)
POST /api/v1/ai/chat- Conversational natural language query and actions.POST /api/v1/ai/voice-command- Handle transcribed voice shortcuts.
18. Autonomous Background Agents (/api/v1/agent)
GET /api/v1/agent/proposals- List pending autonomous agent proposals.POST /api/v1/agent/proposals/:id/approve- Approve and execute proposal.POST /api/v1/agent/proposals/:id/reject- Reject proposal.GET /api/v1/agent/audit-logs- Audit log of autonomous agent activities.
19. AI Cart Intelligence & Recommendations (/api/v1/intelligence)
GET /api/v1/intelligence/recommendations- Fetch live basket cross-sell suggestions.GET /api/v1/intelligence/customer-insights/:id- RFM customer lifetime analytics.
20. Plugin Marketplace & Sandbox (/api/v1/plugins)
GET /api/v1/plugins/marketplace- Discover available plugins.GET /api/v1/plugins/installed- List installed plugins.POST /api/v1/plugins/install- Install plugin.POST /api/v1/plugins/:id/toggle- Enable or disable plugin.
21. Workflow Automation Engine (/api/v1/workflows)
GET /api/v1/workflows/rules- List workflow trigger rules.POST /api/v1/workflows/rules/:id/toggle- Toggle workflow active state.POST /api/v1/workflows/trigger- Emit manual event into workflow engine.
22. Developer API Keys & Webhooks (/api/v1/developer)
GET /api/v1/developer/ecosystem/info- Ecosystem telemetry & version.GET /api/v1/developer/api-keys- List integration API keys.POST /api/v1/developer/api-keys- Generate new developer API key.GET /api/v1/developer/webhooks- List registered webhook URLs.POST /api/v1/developer/webhooks- Register new outbound webhook.
23. WhatsApp Cloud API & Queue (/api/whatsapp)
GET /api/whatsapp/config- Retrieve WhatsApp API credentials.POST /api/whatsapp/config- Configure Meta Cloud API token and phone number ID.POST /api/whatsapp/config/test- Test WhatsApp connectivity.GET /api/whatsapp/templates- List approved WhatsApp message templates.POST /api/whatsapp/send-invoice- Enqueue digital invoice PDF message.
24. WhatsApp Webhooks (/webhooks/whatsapp)
GET /webhooks/whatsapp- Meta webhook verification challenge.POST /webhooks/whatsapp- Ingest inbound customer message events.
25. Sticky Notes System (/api/notes)
GET /api/notes- List user notes & pinned memos.POST /api/notes- Create new sticky note.PUT /api/notes/:id- Update note content, color, or pin status.PUT /api/notes/:id/trash- Move note to trash.PUT /api/notes/:id/restore- Restore note from trash.DELETE /api/notes/:id/permanent- Permanently delete note.
26. Multi-Tax Groups (/api/settings/tax-groups, /api/inventory/tax-groups)
GET /api/settings/tax-groups- List tax groups (GST, VAT, Sales Tax, CESS).POST /api/settings/tax-groups- Create new flat or compound tax group.PUT /api/settings/tax-groups/:id- Update tax group components.DELETE /api/settings/tax-groups/:id- Deactivate tax group.
27. User & Role Management (/api/users)
GET /api/users- List store users and assigned roles.POST /api/users- Create new cashier/staff user.PUT /api/users/:id- Update user details or permissions.POST /api/users/:id/reset-password- Reset staff password.
28. Reports & Analytics (/api/reports, /api/analytics)
GET /api/reports/sales- Comprehensive sales report with tax splits.GET /api/reports/stock-balance- Current inventory balance & valuation.GET /api/reports/stock-ledger- Historical transaction stock ledger.GET /api/reports/monthly-stock-closing- Retrieve monthly closing stock snapshot valuation (Opening, Inward, Outward, Closing).POST /api/reports/monthly-stock-closing/run- Manually execute month-end stock closing snapshot calculation.GET /api/reports/trial-balance- Real-time Trial Balance statement.GET /api/reports/profit-loss- Period Profit & Loss statement.GET /api/reports/balance-sheet- Certified Balance Sheet.GET /api/reports/cashier-handover- Cashier shift handover audit.GET /api/analytics/dashboard-summary- Real-time sales, gross profit, and visitor metrics.
29. Operations & Audit Trail (/api/v1/operations, /api/audit)
GET /api/audit/logs- Immutable audit trail of all system mutations.GET /api/v1/operations/summary- Operations intelligence overview.
30. Notifications (/api/notifications)
GET /api/notifications- Retrieve user notifications.PUT /api/notifications/:id/read- Mark notification as read.
31. System Server Time (/api/system)
GET /api/system/server-time- Synchronize client clock with database server time.
32. 1-Click Cloud Migration Gateway (/api/public/migration)
GET /api/public/migration/ping- Verify cloud migration gateway reachability.POST /api/public/migration/export-bundle- Export complete local store database snapshot.POST /api/public/migration/import-bundle- Ingest snapshot onto cloud server with ID translation.POST /api/public/migration/sync-online-to-offline- Pull down cloud database to local offline node.
33. Quick Users & PIN Authentication (/api/auth)
GET /api/auth/quick-users?outlet_code=...&role=...- Pre-login active staff members configured for fast dropdown selection.POST /api/auth/pin-login- Scoped authentication usingoutlet_code,username,pin, androle.
34. Multi-Country Tax Seeding & Integrity (/api/settings/tax-groups)
POST /api/settings/tax-groups/seed-country- Auto-seed legal fiscal tax slabs for detected country (IN, DE, US, KE, BR, GB).POST /api/settings/tax-groups/replace-and-delete- Atomic reassignment of linked items to target tax group before deleting old group.DELETE /api/settings/tax-groups/:id- Safe delete tax group with linked item count protection.
35. Contactless QR Table Dining & Multi-Seat Portal (/api/public/dining)
GET /api/public/dining/table-info?outlet_id=...&table_id=...&seat=...&client_tag=...- Retrieve public menu, categories, per-seat bills, and combined table bills.POST /api/public/dining/place-order- Place dining order withseat,client_tag,sub_table, andpayment_method. Generates kitchen KOT tickets, records revision snapshots, and notifies floor captain.POST /api/public/dining/pay-bill- Settle per-seat or combined table bills with transaction ID and payment mode (UPI, Cash, Online Gateway).GET /api/public/dining/tables?outlet_id=...- List active dining tables and floor areas for digital self-service.POST /api/public/dining/book-table- Online guest table booking for restaurant reservations.POST /api/public/dining/ai-assistant- Conversational Dining AI Chat & Voice Waiter endpoint.POST /api/public/dining/call-waiter- Guest table assistance call button.
36. M-Pesa & Mobile Money Gateway (/api/payments/mpesa)
POST /api/payments/mpesa/callback- Public asynchronous webhook callback for Safaricom Daraja STK push results.GET /api/payments/mpesa/config- Retrieve outlet M-Pesa Till / Paybill credentials.POST /api/payments/mpesa/config- Save encrypted M-Pesa shortcode, passkey, and Daraja API keys (Admin only).POST /api/payments/mpesa/stk-push- Trigger instant M-Pesa STK push prompt on customer mobile device.POST /api/payments/mpesa/stk-query- Poll real-time status of initiated STK push transaction.
37. Multi-Gateway Payment Configuration (/api/payments/gateways)
GET /api/payments/gateways/config- Retrieve omnichannel payment configuration (Razorpay, Stripe, Square, PayPal, M-Pesa, UPI) with masked credentials.POST /api/payments/gateways/config- Save and encrypt multi-gateway API credentials and settlement modes (Admin only).
38. Plugin Developer Studio & Sandbox Engine (/api/v1/plugins)
POST /api/v1/plugins/developer/test-hook- Execute in-sandbox test hook (onInit,onPaymentCreate,onSaleComplete,onKotCreated) with live benchmark timer and console logs.POST /api/v1/plugins/developer/deploy- Compile TypeScript/JavaScript plugin manifest and publish to outlet or global marketplace.GET /api/v1/plugins/reports/third-party-orders- Comprehensive audit report for third-party food aggregators (Zomato, Swiggy, UberEats) and B2B marketplace orders with commission breakdowns.GET /api/v1/plugins/marketplace- Paginated marketplace listings with category filters and verified developer badges.
39. Public Outlet Onboarding & OTP Verification (/api/public/outlet)
POST /api/public/outlet/send-otp- Request 6-digit SMS and email verification code before branch provisioning.POST /api/public/outlet/verify-otp- Cryptographically verify OTP and obtain authorization token for branch registration.POST /api/public/outlet- Provision branch database schema and trigger automated welcome email with admin credentials.
40. Operations Document Modification & Differential Revisions
PUT /api/purchase-orders/:id- Modify approved or draft Purchase Order with recalculation of tax groups and line item revisions.PUT /api/receiving/:id- Amend Goods Receiving Note (GRN) with differential stock ledger adjustments (delta_in,delta_out) and accounts payable sync.PUT /api/inventory/request/:id- Update internal departmental material requisition quantities and priority.PUT /api/inventory/issue/:id- Revise stock issue/dispatch quantities with automated inventory restoration or deduction.
41. Enterprise SaaS Control Plane & IAM (/api/v1/control-plane)
GET /api/v1/control-plane/auth/setup-status- Check air-gapped system initialization status and admin account count.POST /api/v1/control-plane/auth/initialize-master- First-time master owner bootstrap creation.POST /api/v1/control-plane/auth/login- Dedicated JWT login for master staff members (SuperAdmin, Reseller, Developer, Support).GET /api/v1/control-plane/auth/me- Fetch current staff profile, role, and active permissions.GET /api/v1/control-plane/staff- List staff accounts with role filters.POST /api/v1/control-plane/staff- Create staff account with assigned role and reseller scoping.GET /api/v1/control-plane/fleet/overview- Aggregated KPI metrics: active tenants, connected outlets, grace periods, open tickets, MRR/ARR.GET /api/v1/control-plane/tenants- Paginated tenant directory with active licenses and assigned Relationship Managers.PATCH /api/v1/control-plane/tenants/:id/status- Kill-switch or activate tenant organization.POST /api/v1/control-plane/tenants/:tenantId/assign-rm- Assign personal Relationship Manager to tenant.POST /api/v1/control-plane/tenants/:tenantId/modify-license- Modify license tiers, expiry dates, and terminal quotas.POST /api/v1/control-plane/licenses/approve-payment/:tenantId- Approve subscription payment, extend validity, and trigger vector PDF invoice.GET /api/v1/control-plane/license-and-rm-status- Heartbeat called by client POS terminals for 30-day quota guard and RM profile card.GET /api/v1/control-plane/invoices/download/:tenantId- Stream crisp vector PDF subscription invoice (subscriptionInvoicePdf.service.ts).GET /api/v1/control-plane/renewals/export- Export upcoming tenant renewals CSV.POST /api/v1/control-plane/support/tickets- Outlet cashier ticket submission.GET /api/v1/control-plane/support/tickets- Support queue with status and priority filters.POST /api/v1/control-plane/support/tickets/:id/messages- Post real-time chat message on ticket thread.POST /api/v1/control-plane/support/tickets/:id/resolve- Mark support ticket resolved with diagnostic notes.
42. Sandboxed Data Doctor & Schema Studio (/api/v1/control-plane/support)
POST /api/v1/control-plane/support/data-doctor/execute- Execute sandboxed diagnostic SQL query strictly scoped to tenant database with audit logging.GET /api/v1/control-plane/support/data-doctor/schema- Retrieve dynamic database schema dictionary and table definitions.POST /api/v1/control-plane/support/analyze-error- Automatic regex diagnostic analysis of client POS exception traces.
43. Clinic Management & OPD Healthcare Suite (/api/clinic)
GET /api/clinic/appointments- List appointments filtered by date, doctor, status, and patient search query.POST /api/clinic/appointments- Register patient and issue sequential OPD token number.PATCH /api/clinic/appointments/:id/status- Update appointment state (WAITING,IN_CONSULTATION,COMPLETED,CANCELLED,NO_SHOW).POST /api/clinic/appointments/:id/prescription- Save doctor consultation vitals, complaints, diagnosis, prescribed medicines, and lab investigations.POST /api/clinic/appointments/:id/send-to-billing- Convert prescribed medicines and consultation fees into draft sales invoice for pharmacy checkout.POST /api/clinic/appointments/:id/accept-and-pay- Settle consultation fee with Cash, UPI, or Card, generating an official invoice.PATCH /api/clinic/appointments/:id/billing-complete- Mark appointment billing status as completed.GET /api/clinic/doctors- Retrieve doctor directory with specialties, degrees, room numbers, and consultation fees.POST /api/clinic/doctors- Create doctor profile and consulting schedule.PUT /api/clinic/doctors/:id- Update doctor profile, consultation fee, or cabin allocation.DELETE /api/clinic/doctors/:id- Archive or remove doctor profile.GET /api/clinic/medicines- Search clinic pharmacy inventory with real-time stock balances and expiry dates.GET /api/clinic/patient-history- Retrieve patient historical consultations, past vitals, and previous prescriptions.GET /api/clinic/patient-credit- Check outstanding credit balance for patient ledger.POST /api/clinic/patient-credit/settle- Post payment against patient outstanding credit.GET /api/clinic/clinical-tests- Retrieve master catalog of diagnostic laboratory investigations.POST /api/clinic/clinical-tests- Add or modify diagnostic laboratory test definitions.GET /api/clinic/analytics- Clinic revenue analytics, doctor-wise patient counts, and OPD fee totals.GET /api/clinic/operating-status- Check whether clinic is open today and public online booking enabled.POST /api/clinic/toggle-closed-today- Emergency holiday closure toggle.GET /api/clinic/subscriptions- List multi-session therapy packages (Physiotherapy, Dental, Dialysis).POST /api/clinic/subscriptions- Enroll patient in therapy package.POST /api/clinic/subscriptions/:id/consume- Punch and deduct completed therapy session.GET /api/clinic/subscriptions/:id/ledger- View session punch history and remaining balance.
44. Public Patient Portal & Appointments (/api/public/clinic)
GET /api/public/clinic/cities- Retrieve cities where clinic doctors operate.GET /api/public/clinic/specialities- Retrieve medical specialties for search filtering.GET /api/public/clinic/doctors- Search public doctor directory by city and specialty.POST /api/public/clinic/request-email-otp- Request 6-digit email OTP for patient identity verification.POST /api/public/clinic/verify-email-otp- Cryptographically verify email OTP.POST /api/public/clinic/appointment- Book self-service appointment slot.GET /api/public/clinic/patient-history- Patient self-service portal to view past visits and download digital prescriptions.POST /api/public/clinic/cancel-appointment- Patient self-service appointment cancellation.GET /api/public/clinic/operating-status- Real-time clinic open/closed notification banner.GET /api/public/clinic/my-subscriptions- View active therapy session packages and balances.
45. System Maintenance & Lockout Engine (/api/system/maintenance)
GET /api/system/maintenance-status- Public endpoint returning active maintenance mode status, countdown, and advance notice info.POST /api/system/maintenance- Activate or deactivate system maintenance mode, set estimated duration, and customize lockout message (SuperAdmin / Owner only).POST /api/system/maintenance/advance-notice- Broadcast or clear scheduled maintenance advance notice banner across all store dashboards.
46. Transport Logistics & Fleet Management (/api/transport)
POST /api/transport/driver/login- Public Driver authentication with mobile number and PIN.POST /api/transport/driver/forgot-password- Request driver password reset OTP.POST /api/transport/driver/reset-password- Cryptographically verify OTP and set new driver password.GET /api/transport/driver/me- Authenticated driver self-service profile and vehicle assignment.GET /api/transport/driver/assigned-trips- Retrieve active trip manifest and delivery stops.POST /api/transport/driver/verify-delivery- Verify doorstep recipient drop-off with customer OTP or touchscreen signature.POST /api/transport/driver/update-location- Real-time background driver GPS beacon update.GET /api/transport/fleet-tracking- Live fleet map tracking for dispatchers.GET /api/transport/vehicles- List fleet vehicles with model, ownership type, and operational status.POST /api/transport/vehicles- Register new commercial delivery vehicle.PUT /api/transport/vehicles/:id- Update fleet vehicle details and maintenance status.DELETE /api/transport/vehicles/:id- Deactivate / archive delivery vehicle.GET /api/transport/drivers- List active commercial transport drivers.POST /api/transport/drivers- Register driver profile with license number and contact.PUT /api/transport/drivers/:id- Update driver details and duty availability.DELETE /api/transport/drivers/:id- Deactivate driver profile.POST /api/transport/assign-trip- Group delivery challans into a truck run and assign vehicle + driver.POST /api/transport/release-trip- Release vehicle and driver back to available fleet upon route completion.GET /api/transport/active-trips- Monitor real-time transit status of all dispatched logistics routes.
47. Delivery Challan Subsystem (/api/restaurant/challan)
GET /api/restaurant/challan- Search and filter delivery challans by status, customer, and date range.POST /api/restaurant/challan- Create and issue official transport Delivery Challan under GST Rule 55.GET /api/restaurant/challan/:id- Retrieve full delivery challan with itemized quantities and vehicle dispatch info.PUT /api/restaurant/challan/:id- Amend draft delivery challan before dispatch.PATCH /api/restaurant/challan/:id/status- Update challan workflow status (ISSUED,DISPATCHED,DELIVERED,BILLED,CANCELLED).POST /api/restaurant/challan/:id/convert-to-sale- Convert delivered goods challan into an official POS sales invoice.
48. Multi-Tiered Storage & Enterprise Backups (/api/backup)
GET /api/backup/storage-stats- Retrieve outlet-scoped storage usage breakdown (backups, uploads, database size).GET /api/backup/enterprise-storage- Retrieve global cross-outlet storage usage analytics (Admin Console).GET /api/backup/storage-quota- Check metered storage plan, quota limit, and warning threshold states.POST /api/backup/tenant-backup- Generate fast.posbakoperational snapshot for active outlet.POST /api/backup/create-fambak- Generate comprehensive.fambakarchive with schema manifest (Outlet or Enterprise scope).GET /api/backup/download/:filename- Secure streaming download supporting JWT header, signed query token, or loopback.POST /api/backup/inspect-backup- Pre-inspect archive manifest without executing writes.POST /api/backup/restore-fambak- Execute selective outlet restore or complete enterprise restoration from.fambakpackage.POST /api/backup/restore-tenant-backup- Restore.posbaktransactional state.DELETE /api/backup/:filename- Purge backup archive from outlet storage.POST /api/backup/system-backup- Full bare-metal backup stored inbackend/storage/enterprise/backups/.POST /api/backup/restore-system-backup- Restore full bare-metal system backup.GET /api/backup/cloud-backups- List historical encrypted.encsnapshots.POST /api/backup/restore-cloud-backup- 1-click cloud snapshot restoration.POST /api/backup/email-backup-link- Dispatch off-server signed download link via email.GET /api/backup/email-download- Public token-authenticated download endpoint.POST /api/backup/provider/retention-preview- Preview expired backup records eligible for cloud retention pruning.POST /api/backup/provider/retention-purge- Execute automated retention pruning of expired backups.POST /api/backup/storage-quota/upgrade- Upgrade monthly storage capacity quota.GET /api/backup/admin/storage-overview- Enterprise Admin Console overview of all outlet storage quotas and utilization.POST /api/backup/admin/modify-storage- Admin manual quota adjustment for client outlets.POST /api/backup/storage-quota/payment-success- Automated recurring storage capacity provisioning on payment confirmation.
49. Model Context Protocol (MCP) & AI Gateway (/api/v1/developer/mcp)
Authentication: X-API-Key header, query parameter ?api_key=, Bearer JWT from OAuth 2.0 PKCE, or loopback exemption for local kiosks. Strictly scoped to developer key's tenant outlet and linked branch clusters.
OAuth 2.0 Authorization Server & Discovery
GET /api/v1/developer/.well-known/oauth-authorization-server- RFC 8414 Authorization Server Metadata discovery endpoint for OpenAI ChatGPT Actions and external MCP hosts.GET /api/v1/developer/.well-known/openid-configuration- OpenID Connect compatibility discovery document.GET /api/v1/developer/mcp/.well-known/oauth-authorization-server- Discovery alias under MCP namespace.GET /api/v1/developer/oauth/authorize- Interactive browser consent dialog for OAuth 2.0 Authorization Code flow with PKCE (code_challenge/code_challenge_method=S256).POST /api/v1/developer/oauth/authorize- Process user sign-in and authorization grant generation.POST /api/v1/developer/oauth/token- Exchange authorization code or API key credentials for scoped access token (grant_type=authorization_codeorclient_credentials).
Protocol Transports & Metadata
GET /api/v1/developer/mcp/config- Retrieve active MCP server version, protocol capabilities, transport status, and connected outlet cluster info.GET /api/v1/developer/mcp/tools- Enumerate all 38 active AI & ERP tools with JSON Schema parameters, output schemas, and security scopes.POST /api/v1/developer/mcp- Standard JSON-RPC 2.0 transport over HTTP (supportsinitialize,tools/list,tools/call,prompts/list,prompts/get,ping).GET /api/v1/developer/mcp/sse- Remote MCP Server-Sent Events (SSE) streaming transport for Claude Desktop, Cursor AI, and continuous LLM streaming sessions. Emitsevent: endpoint.POST /api/v1/developer/mcp/messages- Endpoint for client message exchange over SSE transport session.ALL /api/v1/developer/mcp/chat- Universal compatibility alias supporting SSE (GET) and JSON-RPC 2.0 (POST).
Dynamic LLM Specification Generators
GET /api/v1/developer/mcp/chatgpt-openapi.json- Dynamic OpenAPI 3.0 specification tailored for ChatGPT Custom GPT Actions, reflecting real-time outlet server URL, OAuth authorization endpoints, and tool actions.GET /api/v1/developer/mcp/gemini-tools.json- Native Google Gemini Function Calling declaration schema for Vertex AI / Google AI Studio integration.
Direct AI Tool Execution Endpoints (OpenAPI Actions)
POST /api/v1/developer/mcp/tools/execute- Universal direct tool execution dispatcher bytool_nameandarguments.POST /api/v1/developer/mcp/tools/analyze-sales- AI tool analyzing sales revenue, order volumes, tax summaries, payment methods, and hourly velocity trends over customizable date ranges.POST /api/v1/developer/mcp/tools/create-order-bill- AI tool creating draft or finalized POS sales orders/bills with customer info, item lines, and automated stock deductions.POST /api/v1/developer/mcp/tools/inventory-status- AI tool inspecting real-time stock levels, low-stock reorder thresholds, and active warehouse batch counts.POST /api/v1/developer/mcp/tools/search-products- AI tool searching product catalogs across names, barcodes, SKUs, and categories with live pricing.
50. Statutory Tax Compliance (GST & ITR) (/api/accounting/tax)
Requires: JWT + REPORTS License Module.
GET /api/accounting/tax/gst-summary- Returns aggregated GSTR-1 outward supplies, B2B/B2C classification, and GSTR-3B Input Tax Credit (ITC) reconciliation tables.GET /api/accounting/tax/gstr1-export- Generates and streams government-compliant GSTR-1 JSON schema payload for direct upload to the GST portal.POST /api/accounting/tax/gsp-file-gstr1- Direct GSP API submission with mutual TLS authentication, returning filing ARN reference tokens.GET /api/accounting/tax/itr-summary- Computes statutory schedules for ITR-4 (Presumptive Sec 44AD/44ADA) and ITR-5 (Trading/Manufacturing P&L and Balance Sheet).GET /api/accounting/tax/itr4-export- Exports statutory tax schedule dataset formatted for Income Tax utility software.GET /api/accounting/tax/config- Fetches store legal business name, GSTIN, PAN, filing frequency, and turnover brackets.POST /api/accounting/tax/config- Updates legal fiscal profile and GSTIN credentials.GET /api/accounting/tax/filings- Retrieves permanent audit history of past returns and government ARN timestamps.
51. Employee Mobile Self-Service & Office HRMS (/api/hrms/employee, /api/hrms/employee-auth)
Public Employee Auth
POST /api/hrms/employee-auth/login- Public staff mobile authentication using Email, Mobile Phone, or Employee Code with device hardware locking.POST /api/hrms/employee-auth/forgot-password/request-otp- Dispatches 6-digit cryptographic verification OTP to employee email.POST /api/hrms/employee-auth/forgot-password/reset- Verifies email OTP and updates employee account password.
Authenticated Employee Portal
GET /api/hrms/employee/my-profile- Retrieves logged-in staff profile, assigned shift schedule, office geofence center, and leave balances.POST /api/hrms/employee/punch- Submits geotagged attendance punch with Haversine mathematical distance validation and optional selfie photo.POST /api/hrms/employee/change-password- Updates employee login credentials from mobile settings.POST /api/hrms/employee/request-loan- Submits formal staff salary advance or loan application with requested EMI deduction.POST /api/hrms/employee/request-salary-raise- Submits formal salary increment and appraisal request.POST /api/hrms/employees/:id/reset-device- Admin endpoint to unbind staff hardware device ID upon smartphone replacement.
52. Open REST API Gateway (/api/v1/open)
Authentication: Supports both X-API-Key header/query parameter and OAuth 2.0 Authorization: Bearer <token> with granular scope enforcement.
GET /api/v1/open/orders(orders:read) - Paginated order list scoped to authorized outlet.GET /api/v1/open/orders/:id(orders:read) - Retrieve itemized order details by ID.POST /api/v1/open/orders(orders:write) - Inject external e-commerce or delivery order directly into POS.GET /api/v1/open/billing/invoices(billing:read) - Retrieve invoice summaries, taxes, and payment records.GET /api/v1/open/reports/sales-summary(reports:read) - Fetch period sales analytics and revenue totals.GET /api/v1/open/inventory/items(inventory:read) - Retrieve catalog items, SKU codes, pricing, and stock levels.
53. B2B Marketplace Vendors (/api/marketplace)
GET /api/marketplace/vendors- Discover verified wholesale distributors and suppliers on the B2B network.POST /api/marketplace/distributor-status- Toggle or update current outlet's B2B wholesale distributor visibility status.GET /api/marketplace/vendors/:id/catalog- Browse a wholesale vendor's published product catalog and bulk pricing tiers.
Last Updated: November 2026 | Covers 100% of all 41 Express Route Modules across 53 Documented API Subsystem Sections