LMMA Backend API Docs

Current NestJS API surface from backend controllers
Public Docs Wallet docs

Overview

Base URL: http://localhost:3000
AuthJWT is required unless marked Public.
AdminAdmin-only routes use @AdminOnly.
UploadsStored under /public/uploads.

Auth

POST/auth/register Public
POST/auth/login Public
POST/auth/otp/verify Public

Users

GET/users/me
PATCH/users/me
GET/users/admin
GET/users/admin/<USER_UUID>
PATCH/users/admin/<USER_UUID>
DELETE/users/admin/<USER_UUID>

Addresses

GET/addresses
GET/addresses/<ADDRESS_UUID>
POST/addresses
PATCH/addresses/<ADDRESS_UUID>
PATCH/addresses/<ADDRESS_UUID>/default
DELETE/addresses/<ADDRESS_UUID>

Categories

GET/categories Public
GET/categories/slug/<SLUG> Public
GET/categories/<CATEGORY_UUID> Public
POST/categories
PATCH/categories/<CATEGORY_UUID>
DELETE/categories/<CATEGORY_UUID>
GET/categories/<CATEGORY_UUID>/subcategories Public
GET/categories/subcategories/list Public
GET/categories/subcategories/slug/<SLUG> Public
GET/categories/subcategories/<SUBCATEGORY_UUID> Public
POST/categories/subcategories
PATCH/categories/subcategories/<SUBCATEGORY_UUID>
DELETE/categories/subcategories/<SUBCATEGORY_UUID>

Localizations

GET/localizations/translate?key=...&language=...
POST/localizations
PATCH/localizations/<LOCALIZATION_UUID>
DELETE/localizations/<LOCALIZATION_UUID>

Vendors

GET/vendors Public
POST/vendors/signup Public
GET/vendors/me
PATCH/vendors/me
POST/vendors/me/setup
GET/vendors/me/products
GET/vendors/me/deals
GET/vendors/me/deals/<DEAL_UUID>
GET/vendors/me/documents
POST/vendors/me/documents
DELETE/vendors/me/documents/<DOCUMENT_UUID>
GET/vendors/<VENDOR_UUID> Public
GET/vendors/admin/<VENDOR_UUID>
POST/vendors/convert-user-to-vendor
POST/vendors Public
POST/vendors/<VENDOR_UUID>/accept
POST/vendors/<VENDOR_UUID>/reject
POST/vendors/<VENDOR_UUID>/block
POST/vendors/<VENDOR_UUID>/unblock
POST/vendors/<VENDOR_UUID>/profile-image Public
PATCH/vendors/<VENDOR_UUID>
DELETE/vendors/<VENDOR_UUID>

Products

POST/products/with-deal
PATCH/products/<PRODUCT_UUID>
DELETE/products/<PRODUCT_UUID>

Deals

Statuses: open, pending_approval, rejected, wait_for_fulfillment, fulfilled, completed, closed, expired.

POST/deals
GET/deals Public
GET/deals/admin/pending
GET/deals/admin/all
GET/deals/<DEAL_UUID> Public
PATCH/deals/<DEAL_UUID>
PATCH/deals/<DEAL_UUID>/owner
POST/deals/<DEAL_UUID>/approve
POST/deals/<DEAL_UUID>/reject
POST/deals/<DEAL_UUID>/refund-close Admin
DELETE/deals/<DEAL_UUID>
POST/deals/<DEAL_UUID>/join

Wallet-only two-step flow. First call reserves quantity for 15 minutes and returns a pending order. Second call completes payment (escrow for open deals, direct purchase for active deals). If the wallet is insufficient, the response contains a gateway URL for top-up; the linked order is auto-completed when the gateway callback succeeds.

GET/deals/<DEAL_UUID>/fulfillments
POST/deals/<DEAL_UUID>/ship Multipart

Comments

GET/products/<PRODUCT_UUID>/comments Public
POST/products/<PRODUCT_UUID>/comments
DELETE/products/comments/<COMMENT_UUID>
GET/deals/<DEAL_UUID>/comments Public
POST/deals/<DEAL_UUID>/comments
DELETE/deals/comments/<COMMENT_UUID>

Ratings

GET/vendors/<VENDOR_UUID>/ratings Public
POST/vendors/ratings
DELETE/vendors/<VENDOR_UUID>/ratings/me

Orders

GET/orders?scope=all
GET/orders/<ORDER_UUID>
GET/orders/<ORDER_UUID>/activities
POST/orders
PATCH/orders/<ORDER_UUID>
DELETE/orders/<ORDER_UUID>
POST/orders/<ORDER_UUID>/ship
POST/orders/<ORDER_UUID>/cancel
GET/orders/public/ping Public

Shipments

GET/orders/<ORDER_UUID>/shipment

Conflicts

Buyer complaint resolution. Types: item_not_received, item_not_found_at_seller, item_differs_from_images, item_received_damaged, seller_scam_fake_invoice, other. Statuses: pending_review, buyer_refunded, rejected, seller_blocked, seller_blocked_and_deal_cancelled. Resolution actions: refund_buyer, reject, block_seller, block_seller_refund_all.

POST/conflicts
GET/conflicts?scope=all
GET/conflicts/<CONFLICT_UUID>
POST/conflicts/<CONFLICT_UUID>/resolve Admin

Bank Accounts

POST/bank-accounts
GET/bank-accounts
GET/bank-accounts/<BANK_ACCOUNT_UUID>
PATCH/bank-accounts/<BANK_ACCOUNT_UUID>
DELETE/bank-accounts/<BANK_ACCOUNT_UUID>
POST/bank-accounts/<BANK_ACCOUNT_UUID>/set-default

Uploads

GET/uploads/images Public
POST/uploads/image Public
DELETE/uploads/images/<IMAGE_UUID> Public

Notifications

In-app notifications + Firebase push tokens. Types include deal, vendor, order, shipment, wallet, conflict and system events.

GET/notifications?page=&limit=&unreadOnly=
GET/notifications/unread-count
PATCH/notifications/<NOTIFICATION_UUID>/read
POST/notifications/read-all
DELETE/notifications/<NOTIFICATION_UUID>
POST/notifications/device-token
DELETE/notifications/device-token

Platform

GET/platform/config
PATCH/platform/config
GET/platform/profits
GET/platform/profits/summary

Admin

GET/admin/stats
GET/admin/reports/dashboard
GET/admin/reports/profits
GET/admin/reports/commissions
GET/admin/reports/orders-summary
GET/admin/reports/sales-analysis
GET/admin/reports/transactions

Wallet

GET/wallet/balance
GET/wallet/balance/<USER_UUID>
GET/wallet/transactions
GET/wallet/transactions/<USER_UUID>
POST/wallet/topup
GET/wallet/topups
POST/wallet/transfer
POST/wallet/donate
POST/wallet/donate/slug
GET/wallet/charities
GET/wallet/charities/slug/<SLUG> Public
GET/wallet/charities/<CHARITY_UUID>
GET/wallet/charities/<CHARITY_UUID>/donations
POST/wallet/charities
POST/wallet/charities/<CHARITY_UUID>/update
POST/wallet/mint-request
GET/wallet/trades/marketplace
GET/wallet/trades/my
POST/wallet/trades
POST/wallet/trades/<TRADE_UUID>/request
POST/wallet/trades/<TRADE_UUID>/approve
POST/wallet/trades/<TRADE_UUID>/complete
POST/wallet/trades/<TRADE_UUID>/cancel
POST/wallet/withdrawals

Requires: vendor account active, no pending conflicts, all vendor deals COMPLETED, and 10 days since the last completed deal.

GET/wallet/withdrawals
GET/wallet/withdrawals/<WITHDRAWAL_UUID>
POST/wallet/withdrawals/<WITHDRAWAL_UUID>/cancel
GET/wallet/admin/stats
GET/wallet/admin/mint-requests
POST/wallet/admin/mint-requests/<REQUEST_UUID>/approve
POST/wallet/admin/mint-requests/<REQUEST_UUID>/reject
GET/wallet/admin/charities
POST/wallet/admin/charities/<CHARITY_UUID>/verify
GET/wallet/admin/withdrawals
GET/wallet/admin/withdrawals/pending-count
POST/wallet/admin/withdrawals/<WITHDRAWAL_UUID>/resolve
POST/wallet/admin/withdrawals/<WITHDRAWAL_UUID>/reject
GET/wallet/admin/dashboard
GET/wallet/admin/dashboard/detailed
GET/wallet/admin/users/<USER_UUID>/wallet
POST/wallet/admin/users/freeze
POST/wallet/admin/users/unfreeze
POST/wallet/admin/users/adjust
POST/wallet/admin/users/mint
GET/wallet/admin/audit
POST/wallet/admin/audit/search
GET/wallet/admin/audit/critical
GET/wallet/admin/audit/user/<USER_UUID>
GET/wallet/admin/audit/stats
GET/wallet/admin/monitor/high-value
GET/wallet/admin/monitor/unusual-activity

Webhooks

Wallet top-up callbacks credit the buyer wallet. If the top-up was linked to a deal order (orderId), the corresponding reserved order is automatically completed when the callback succeeds.

POST/webhooks/wallet/edfapay Public
POST/webhooks/wallet/thawani Public
POST/webhooks/wallet/edfapay/3ds-return Public