How ashish-007-700/upi-payment-support-agent works
This repository combines a UPI dispute-resolution app, a browser client, and separate mock bank and merchant APIs. A user can register, create or review a transaction, raise a dispute, and request verification; the agent backend handles dispute verification and can coordinate a refund, while the mock services provide bank-side and merchant-side checks. The client also exposes role-specific dashboards and transaction/dispute history. The README is empty and several workflow modules were not sampled, so uncertain internal calls are omitted; service capabilities and paths reflect the supplied tree and excerpts.
Main entry points: verification_service.py Verification service · app.py Agent API · App.jsx Client routing · dashboardService.js Client API services
Components 26
Web client
- Client routing
client/src/App.jsx - Auth screens
client/src/pages/LoginPage.jsx - Role dashboards
client/src/pages/ClientDashboard.jsx - Transaction flows
client/src/pages/CreateTransactionPage.jsx - Dispute screens
client/src/pages/RaiseDisputePage.jsx - Client API services
client/src/services/dashboardService.js - Auth API service
client/src/services/authService.js
Dispute agent
- Agent API
Agent/Kl_Hackathon/upi_dispute_agent/app.py - Auth routes
Agent/Kl_Hackathon/upi_dispute_agent/routes/auth_routes.py - Verification routes
Agent/Kl_Hackathon/upi_dispute_agent/routes/verification_routes.py - Verification service
Agent/Kl_Hackathon/upi_dispute_agent/services/verification_service.py - Automatic verifier
Agent/Kl_Hackathon/upi_dispute_agent/services/auto_verifier.py - Decision rules
Agent/Kl_Hackathon/upi_dispute_agent/utils/decision_matrix.py - Refund processing
Agent/Kl_Hackathon/upi_dispute_agent/services/refund_service.py
Mock services
- Mock bank API
server/routes/bank_routes.py - Bank operations
server/services/bank_service.py - Mock merchant API
server/routes/merchant_routes.py - Merchant operations
server/services/merchant_service.py
Persistence
- Bank and order records
server/database/db.py - Agent records
Agent/Kl_Hackathon/upi_dispute_agent/database/db.py - Bank transactions
server/models/bank_transaction_model.py - Merchant orders
server/models/merchant_order_model.py - Users, disputes, transactions
Agent/Kl_Hackathon/upi_dispute_agent/models/transaction_model.py
Other components
- UPI user
- Bank service consumer
- Merchant service consumer
Connections 31
- UPI user → Client routing: uses
- Client routing → Auth screens: routes
- Client routing → Role dashboards: routes
- Client routing → Transaction flows: routes
- Client routing → Dispute screens: routes
- Auth screens → Auth API service: authenticates
- Auth API service → Agent API: HTTP requests
- Role dashboards → Client API services: loads records
- Transaction flows → Client API services: API requests
- Dispute screens → Client API services: API requests
- Client API services → Agent API: HTTP requests
- Agent API → Auth routes: dispatches
- Agent API → Verification routes: dispatches
- Agent API → Users, disputes, transactions: reads and writes
- Agent API → Verification service: verifies dispute
- Verification routes → Verification service: verifies dispute
- Verification service → Automatic verifier: invokes
- Verification service → Decision rules: evaluates outcome
- Verification service → Refund processing: requests refund
- Refund processing → Mock bank API: refund requests
- Verification service → Mock bank API: transaction checks
- Verification service → Mock merchant API: payment checks
- Mock bank API → Bank operations: dispatches
- Mock merchant API → Merchant operations: dispatches
- Bank operations → Bank transactions: reads and updates
- Merchant operations → Merchant orders: reads and updates
- Bank transactions → Bank and order records: persists
- Merchant orders → Bank and order records: persists
- Users, disputes, transactions → Agent records: persists
- Bank service consumer → Mock bank API: calls
- Merchant service consumer → Mock merchant API: calls