Ops Portal
Operations Command Center. 98% built, 51 of 52 documented modules live in production. The internal staff workspace for moderation, dispute resolution, support, and growth.
Module tree
The 6 module groups
1. Mission Control (4 modules)
Real-time platform overview, the homepage of ops.
| Module | Purpose |
|---|---|
| Overview | Live KPIs, total users, active listings, verification queue, total orders |
| GMV Trend | Gross Merchandise Value over 7d, 1m, 6m, 1y |
| Categories | Category mix breakdown |
| Heatmap | Shipping hub heatmap by Indonesian city |
2. Operations (10 modules)
Day-to-day platform health and customer service.
| Module | What ops staff does here |
|---|---|
| Support Inbox | Manage user-submitted support tickets |
| Listing Moderation | Approve, reject, or flag new listings |
| Brand Authentication | Verify luxury brand listings |
| Dispute Resolution | Decide buyer vs seller disputes |
| ID Verification | Review KTP submissions, approve or reject |
| Content Reports | Process user-reported content, backed by content_reports table. Was non-functional from 2026-04-16 until PS-122 fix (2026-05-02): table never created despite migration being marked applied, and GET /admin/reports was reading old KV store. |
| Duplicate Detection | Review auto-flagged duplicate listings |
| Returns and Refunds | Process return requests, release refunds 🟡 partial |
| Review Moderation | Manage flagged or suspicious reviews |
| Live Monitor | Real-time activity stream |
3. Commerce (7 modules)
Transaction-side tooling.
| Module | Purpose | Status |
|---|---|---|
| Escrow Manager | View escrow KPIs, 7-day trend chart, BPF revenue, manual timer check | ✅ Fully wired (PS-359→PS-361, 2026-05-12) |
| Logistics Hub | Shipment list with enriched order context, late-order tracking | ✅ Fully wired (PS-362, 2026-05-12) |
| Logistics Heatmap | Region delivery speed map, courier health, waybill management | ✅ Fully wired (PS-363→PS-365, 2026-05-12) |
| Voucher Engine | Create and manage promo codes (flat, %, free shipping, BPF waiver) | ✅ Fully wired (PS-366→PS-367, 2026-05-12) |
4. Growth & Analytics (11 modules)
Marketing operations and analytics.
| Module | Purpose | Status |
|---|---|---|
| Conversion Funnel | View → like → checkout → purchase analytics; daily/weekly/monthly period selector | ✅ Fully wired (PS-396, 2026-05-13) |
| Seller Analytics | Per-seller performance dashboards | ✅ Fully wired (PS-400, 2026-05-13) |
| Seller Quality | Seller score tracking and tier override | ✅ Fully wired |
| Paid Promotions | Boost product management | ✅ Fully wired |
| Growth Tools | Boost grant/revoke and fee waiver grant/revoke | ✅ Fully wired |
| Campaign Manager | Marketing campaign creation and tracking | ✅ Fully wired (PS-398, 2026-05-13, administrator role added) |
| A/B Tests | Active experiment monitoring and creation | ✅ Fully wired (PS-394, 2026-05-13, New Test form + backend route) |
| Broadcast Center | Create and send push/email broadcasts | ✅ Auth wired (PS-399, 2026-05-13, administrator role added); actual dispatch is a separate backlog item |
| Email Templates | Edit and persist Resend email templates | ✅ Fully wired (PS-393, 2026-05-13, save/delete persist to backend) |
| Push Notifications | Targeted push management with delete | ✅ Fully wired (PS-397, 2026-05-13, send awaits API; DELETE endpoint added) |
| SekenPulse Engine | Recommendation engine, not yet active | 🟡 Disabled (PULSE_ENABLED=false); tab shows coming-soon placeholder (PS-395, 2026-05-13) |
5. People (4 modules)
User and team management.
| Module | Purpose | Status |
|---|---|---|
| User Directory | Search, filter, verify, suspend, and ban users | ✅ Fully wired (PS-376→PS-378, 2026-05-13) |
| Account Manager | Edit profiles with full side-effect chain | ✅ Fully wired (PS-379, 2026-05-13) |
| Hiring Panel | Review job applications submitted via careers | ✅ Fully wired (PS-380, 2026-05-13) |
| Pre-Launch Waitlist | Manage waitlist signups; admin-gated delete | ✅ Fully wired (PS-402, 2026-05-13) |
6. System (9 modules)
Platform configuration and observability.
| Module | Purpose | Status |
|---|---|---|
| User Guide and SOPs | Internal documentation for ops staff | ✅ |
| Platform Settings | Global feature flags and config | ✅ Fully wired (PS-406, 2026-05-14, security tab routes to PUT /admin/settings/security; SECURITY_KEYS no longer silently dropped; PS-404 BRAND-01 fix: Dark Purple theme swatch → Dark Teal #006D77) |
| Marketing & Analytics | GTM, Meta Pixel, TikTok Pixel IDs + tracking toggle | ✅ Fully wired (PS-401, 2026-05-13, administrator role added) |
| Prototype Flow Map | UX flow visualization | ✅ |
| Audit Log | Complete record of all ops actions | ✅ Fully wired (PS-403, 2026-05-14, CSV export fixed: POST /admin/audit-log/export with { from, to, reason } body; date-range + reason modal; PS-404 BRAND-01 fix: dispute_resolved badge → #3B82F6) |
| Webhook Monitor | Xendit and Biteship webhook delivery status | ✅ Fully wired (PS-405, 2026-05-14, retry awaits API; error toast on failure; per-webhook loading state; list refreshes from backend on success) |
| Inventory Health | Stale listing detection | ✅ (PS-404, 2026-05-14, BRAND-01 fix: no_photos → #6B7280, Pricing Issues KPI → #3B82F6) |
| Infra Tools | Cron jobs, data purges, system maintenance | ✅ (PS-404, 2026-05-14, BRAND-01 fix: Order Index icon, Run Backfill button, Passport ID info icon → #3B82F6) |
| Fraud Monitor | Real-time fraud cases, 5-state machine (open → investigating → confirmed / rejected → resolved), inline transition UI, role-gated to administrator / fraud_ops, see page 18 | ✅ Fully wired (PS-373→PS-375, 2026-05-12) |
Ops AI bot
Built into the platform sidebar. Available to all logged-in ops staff.
Capabilities:
- Answer SOP questions
- Help navigate to specific modules
- Explain platform policies
- Draft response templates for support tickets
Safety:
- PII redaction layer scrubs user data before sending to OpenAI
- Rate limiting per staff member
- All conversations logged to audit_log
Cost monitoring: OpenAI token usage tracked per staff member.
Common ops workflows
Workflow 1, KTP review
- Pending KTP appears in ID Verification queue
- Staff reviews OCR-extracted data vs uploaded photo
- Click approve, reject (with reason), or request resubmit
- User notified via Resend
- Audit logged to
moderation_override_log
Workflow 2, Dispute resolution
DISPUTE_OPENorder surfaces in Dispute Resolution queue- Staff reviews:
- Listing photos vs delivered item photos
- Chat history
- Buyer purchase + dispute history
- Seller reputation + dispute history
- Decide: buyer wins, seller wins, or split
- Refund or release as appropriate
- Both parties notified
- Audit logged
Workflow 3, Listing moderation
- New listing enters moderation queue
- Auto-flags for review (luxury brand, suspicious pricing, banned keywords)
- Staff approves, rejects, or requests edits
- Seller notified
- Listing goes live or stays hidden
Workflow 4, Content report moderation
- User submits a report via the app (
POST /reports), targets a listing, seller, or user - Report row created in
content_reports(status:open) - Report surfaces in Content Reports queue (
GET /admin/reports) - Staff reviews: reporter identity, target listing/seller, reason + details
- Staff action via
PUT /admin/reports/:idwith action:investigate,resolve, ordismiss - Status updated to
investigating/resolved/dismissed; admin note andresolved_byrecorded
Workflow 5, Duplicate Detection review
- Ops staff opens Duplicate Detection panel in ops.pasarseken.id → Operations
- Click Scan:
POST /admin/duplicates/scanfires:- Clears all
status = "pending"groups (idempotent rescan, PS-301) - Groups active listings into per-brand buckets (O(M²) within bucket, not O(N²): PS-305)
- Scoring:
titleSim × 0.5 + brandMatch (+30pts) + priceSim × 0.2, threshold ≥ 70 - Image similarity is not implemented: title, brand, and price only (PS-300)
- Saves groups to
duplicate_groupstable withreference_title,reference_brand,reference_price,reference_imageas dedicated columns (PS-306)
- Clears all
- Staff reviews each group, filter tabs: Pending (red badge), Reviewed (cyan badge, PS-303), Resolved
- Per-group actions, all persisted to backend immediately (PS-298):
- Merge: sets all duplicates to
draft, marks groupstatus = "resolved",action_taken = "merged" - Undo Merge: appears only on merged groups; reverts to
status = "pending"(PS-304) - Remove Duplicates: sets duplicates to
draft, marks groupstatus = "resolved",action_taken = "removed_duplicates" - Flag for Review: marks group
status = "reviewed",action_taken = "flagged"(no listing status change) - Keep All: marks group
status = "resolved",action_taken = "kept_all"(no listing status change)
- Merge: sets all duplicates to
reviewed_attimestamp written to dedicated DB column on every action (PS-299)- Avg Similarity KPI card shows
0(not NaN) when no duplicates have been scored (PS-308)
Workflow 6, Support ticket response
- User submits ticket via help.pasarseken.id
- Ticket appears in Support Inbox with category
- Staff drafts response (AI bot can suggest template)
- Send via Resend
- Mark ticket resolved or escalate
Permission requirements
Access to ops.pasarseken.id requires role in (ops_admin, finance_admin, superadmin).
| Action | Ops admin | Finance admin | Superadmin |
|---|---|---|---|
| View all modules | ✅ | 🟡 read-only | ✅ |
| Approve KTP | ✅ | ❌ | ✅ |
| Resolve disputes | ✅ | ❌ | ✅ |
| Suspend users | ✅ | ❌ | ✅ |
| Approve disbursements | ❌ | ✅ | ✅ |
| Modify roles | ❌ | ❌ | ✅ |
Status summary
| Aspect | Status |
|---|---|
| Mission Control | ✅ Live |
| Operations modules | ✅ 9 of 10 live, Returns 🟡 partial |
| Commerce modules | ✅ All live (7 modules) |
| Growth modules | ✅ All live |
| People modules | ✅ All live |
| System modules | ✅ All live |
| AI bot | ✅ Live (gpt-4o-mini + PII redaction) |
| Total | 51 of 52 modules live (98%) |
Where to look in the codebase
| What you want | Where it lives |
|---|---|
| Ops routing | src/app/routes.ts (createOpsRouter) |
| Ops pages | src/app/pages/ops/ |
| Ops components | src/app/components/ops/ |
| AI bot | src/app/components/ops/StaffAIAssistant.tsx |
| AI bot adapter | infrastructure/adapters/OpsBotAdapter.ts |
Next: Cuan Portal →