How ewostatewos18/payment_verification_frontend works
This is a Next.js frontend for verifying Ethiopian bank and mobile-money payments. Users choose Telebirr, BOA, or CBE, provide transaction details or a receipt image (upload or camera capture), and submit for backend verification; the result is presented as success, failure, validation, or manual-entry guidance. Bank pages coordinate input and verification, while shared components handle history and result presentation. The README documents all three bank APIs and image verification. Some source is only partially excerpted, so unverified internal calls are omitted.
Main entry points: ResultModal.tsx Result dispatcher · telebirr/page.tsx Telebirr verification · boa/page.tsx BOA verification · cbe/page.tsx CBE verification
Components 18
Bank verification
- Bank selection
src/app/page.tsx - Telebirr verification
src/app/telebirr/page.tsx - BOA verification
src/app/boa/page.tsx - CBE verification
src/app/cbe/page.tsx
Shared interface
- Bank layout
src/components/BankVerificationLayout.tsx - History input
src/components/HistoryInput.tsx - Result dispatcher
src/components/ResultModal.tsx - Success display
src/components/modals/SuccessModal.tsx - Error display
src/components/modals/ErrorModal.tsx - Manual verification
src/components/modals/ManualVerificationModal.tsx - Validation display
src/components/modals/ValidationErrorModal.tsx
Verification services
- Result formatting
src/utils/modalHelpers.ts - API client
src/lib/api.ts - Error handling
src/lib/errorHandler.ts - Verification history
src/utils/verificationHistory.ts - Verification types
src/types/verification.ts
Other components
- User
- Laravel API
Connections 25
- User → Bank selection: selects bank
README.md - User → Telebirr verification: submits details
README.md - User → BOA verification: submits details
README.md - User → CBE verification: submits details
README.md - Telebirr verification → API client: requests verification
src/app/telebirr/page.tsx - BOA verification → API client: requests verification
src/app/boa/page.tsx - CBE verification → API client: requests verification
src/app/cbe/page.tsx - API client → Laravel API: posts verification
src/lib/api.ts - Telebirr verification → Error handling: processes errors
src/app/telebirr/page.tsx - BOA verification → Error handling: processes errors
src/app/boa/page.tsx - CBE verification → Error handling: processes errors
src/app/cbe/page.tsx - Telebirr verification → Result dispatcher: shows response
src/app/telebirr/page.tsx - BOA verification → Result dispatcher: shows response
src/app/boa/page.tsx - CBE verification → Result dispatcher: shows response
src/app/cbe/page.tsx - Telebirr verification → History input: renders input
src/app/telebirr/page.tsx - BOA verification → History input: renders input
src/app/boa/page.tsx - CBE verification → History input: renders input
src/app/cbe/page.tsx - History input → Verification history: loads history
src/components/HistoryInput.tsx - Bank layout → Result dispatcher: renders result
src/components/BankVerificationLayout.tsx - Result dispatcher → Result formatting: evaluates response
src/components/ResultModal.tsx - Result dispatcher → Success display: renders success
src/components/ResultModal.tsx - Result dispatcher → Error display: renders failure
src/components/ResultModal.tsx - Result dispatcher → Manual verification: renders manual flow
src/components/ResultModal.tsx - Result dispatcher → Validation display: renders validation
src/components/ResultModal.tsx - Error display → Result formatting: gets error info
src/components/modals/ErrorModal.tsx