Bank e-mandates, checkout to routing rules · Jul 2024 – Apr 2025, redesigned Jan 2026
Bank mandates for insurance premiums, from the checkout to the routing rules
Insurance premiums repeat, so customers set up a bank e-mandate once and the insurer collects each premium automatically. A mandate is a serious promise to sign, often on a phone, and a wrong account or a failed bank hand-off means a missed premium. I built the whole journey in our orchestration checkout, from the first field to the final status, and later redesigned it.
- Role
- Frontend engineer
- When
- Jul 2024 – Apr 2025, redesigned Jan 2026
- Where
- PayGlocal
- Stack
- ReactRedux ToolkitTailwindNPCI e-mandates
The situation
A bank e-mandate asks a lot of a customer: the right bank, an account number typed twice, a way to authenticate that their bank supports, and a trip to the bank or an OTP to approve it. Each bank supports different authentication modes. The account holder isn’t always the policy holder. And every failure needs a clear next step, because a mandate that silently fails means the next premium bounces. There was a second half, too: the orchestration checkout doesn’t process payments itself, it routes each one to a processor by rules. A mandate payment only reached a customer’s bank if the operations team could write a rule that sent it there, and the rule editor in our operations console didn’t know mandates existed.
What I built
- Authentication modes per bank, with instructions for each, Aadhaar placed first as the recommended option, an eNACH tag when the mandate goes through NPCI, a warning when a bank offers no mode, and automatic selection when it offers only one.
- The registration form: account number and confirmation with masking that keeps the caret in place and blocks pasting into the confirm field, optional customer details (phone, email, PAN) that open themselves when prefilled, PAN validation, and the mandate’s purpose, amount and dates shown up front.
- A name check: if the policy holder’s name and the account holder’s name differ after removing titles and normalising spacing and case, a drawer asks the customer to confirm, and that consent is sent with the request. It was later extended to card payments.
- The hand-off: a form that auto-submits to the bank with the URL and payload from our server for NPCI flows, and for OTP flows a verification screen with a timer, resend with remaining attempts, and encrypted request payloads.
- Status, retry and partial retry pages that fill in the mandate reference, bank and account, with the same guidance on every failure.
- In the operations console’s routing-rule editor: digital bank mandate allowed as a condition, so the team could route mandate payments to the right processor, alongside surcharge routing for EMI. Each condition got a “Mandatory” switch with an explanation, condition values became searchable, and a rule couldn’t move to the next step while any condition had a field but no value.
- A readable rule summary, built once and reused: conditions joined with “AND”, bank IDs shown as bank names, and the same summary on a transaction’s gateway details, so anyone looking at a payment can see which rule sent it where. Plus a distinct colour for rules with a configuration error, and fixes so mandate banks didn’t duplicate when a rule was edited and disabling a mandate acted on the right merchant.
- Refinements from the insurer’s own review: alert styles, mandate details, header, default bank logos, phone validation and resetting the OTP on resend.
- In 2026, a redesign of the registration page, mandate details, cancel dialog, retry page and status pages, with status pages for success, pending and failure sharing one set of styles across mandates and ordinary payments.
The journey, screen by screen
The modes come from the bank: net banking, debit card or Aadhaar. Aadhaar sits at the top as the recommended one. An eNACH tag shows when the mandate goes through NPCI, and if the bank offers no mode, the bank field warns before the customer goes further. With only one mode, it’s chosen for them.
Configuring the route
The checkout doesn’t process the mandate; a routing rule in the operations console decides which processor gets it. A simplified version of that editor, with sample banks.
Summary, as shown on a payment’s gateway details:
Where the work went
My commits on each part of the journey, July 2024 to April 2025. A 2026 redesign of the same screens came on top.
Decisions
Let the bank decide the options
Authentication modes come from the bank, not a fixed list. The page shows what this bank supports, recommends the easiest, and picks it when there’s only one. Customers never see a mode their bank would reject.
Ask before a mismatch becomes a failure
A different name on the account is often fine, a spouse or parent paying, but it should be a choice, not an accident. A short confirmation catches typos and records consent instead of failing later at the bank.
Every failure gets a next step
A mandate that fails quietly means a missed premium. Status pages always say what happened, and failures offer a retry, or a partial retry when only part of the flow went wrong.
Rules should read like sentences
Operations staff check routing rules under pressure, often while a payment is stuck. “Payment method is digital bank mandate AND bank is one of Sample Bank, Example Bank” is checkable at a glance; a list of IDs isn’t. Building the summary once meant the editor and the transaction details always agree.
One status design for every outcome
In the 2026 redesign, success, pending and failure share helpers for icons, colours and backgrounds, across mandates and regular payments. A new state looks right without new styling.
Outcome
| What | Before | After | Detail |
|---|---|---|---|
| Journey screens built | form, name check, OTP, status, retry | end to end | |
| Commits on the journey | 98 | Jul 2024 – Apr 2025 | |
| Lines added | ~2,850 | before the 2026 redesign | |
| Routing-rule editor in the console | no mandate conditions | mandates routable | 7 commits, +289 / −63 |