Skip to content

Commit 8377c08

Browse files
authored
Merge pull request #401 from SetuHQ/DATA-2829
docs(DATA-2829): RPD docs update
2 parents 739640f + f3c9cb1 commit 8377c08

1 file changed

Lines changed: 91 additions & 138 deletions

File tree

content/data/bav/reverse-penny-drop/api-integration.mdx

Lines changed: 91 additions & 138 deletions
Original file line numberDiff line numberDiff line change
@@ -140,14 +140,14 @@ If successful, you will get a JSON response. Two of the fields in the response w
140140
"shortUrl": "https://sandbox.bills.pe/wh9kk4mwuktg",
141141
"status": "BAV_REVERSE_PENNY_DROP_CREATED",
142142
"traceId": "1-640f227f-784ece1c005e4f9e653947ca",
143-
"upiBillId": "1114053970646533628",
144-
"upiLink": "upi://pay?pa=bauvatest@kaypay&pn=BauvaTest&am=1.00&tr=1114053970646533628&tn=Account%20Verification&cu=INR&mode=04",
143+
"upiBillId": "a6577bb0ae4d9301cf47c1",
144+
"upiLink": "upi://pay?pa=bauvatest@kaypay&pn=BauvaTest&am=1.00&tr=a6577bb0ae4d9301cf47c1&tn=Account%20Verification&cu=INR&mode=04",
145145
"validUpto": "2023-03-13T13:20:52.277688"
146146
} `}
147147
</CodeBlockWithCopy>
148148
<Callout type="tip">
149149
Note: This 'id' is your 'requestId'. Please use
150-
this 'requestId' for rest the API reference.
150+
this 'requestId' for rest of the API reference.
151151
</Callout>
152152
</>
153153
),
@@ -265,9 +265,8 @@ This API lets you test the end to end flow without an actual payment. This will
265265
{`POST /api/verify/ban/reverse/mock_payment/:requestId
266266
267267
{
268-
"paymentStatus": "successful" // or 'expired'. Default = 'successful'
269-
}
270-
268+
"paymentStatus": "successful" // or 'expired' or 'failed'
269+
}
271270
`}
272271
</CodeBlockWithCopy>
273272
<hr className="tertiary" />
@@ -383,7 +382,7 @@ Setu provides webhook authentication. For more details, refer to <a href="/data/
383382

384383
<hr className="tertiary" />
385384

386-
##### 1. RPD_VERIFICATION_UPDATE Webhook
385+
##### RPD_VERIFICATION_UPDATE Webhook
387386

388387
This webhook is sent when the end user makes a payments.
389388

@@ -404,7 +403,7 @@ _`accountType` can be `BANK_ACCOUNT`, `PPI` or `UNKNOWN`_
404403
<br />
405404

406405
_`bankAccountType` is an optional data field, you may not receive the value always. (Please contact with Setu team to know more about this feature.)_
407-
_The value can be `SAVINGS`, `CURRENT`, `NRO`, `NRE`_
406+
_The value can be `SAVINGS`, `CURRENT`, `VIRTUAL_ACCOUNT`, `OVERDRAFT`, `UOD`, `SOD`, `PPIWALLET`
408407

409408
###### Examples
410409

@@ -426,7 +425,7 @@ _The value can be `SAVINGS`, `CURRENT`, `NRO`, `NRE`_
426425
"rpd" : {
427426
"success" : true,
428427
"id" : "7097e53a-ba29-48a2-983d-878433b4f33e", // the RPD request id
429-
"upiBillId" : "907442106379798024",
428+
"upiBillId" : "a6577bb0ae4d9301cf47c1",
430429
"data" : {
431430
"bankAccountName" : "Eve",
432431
"bankAccountIfsc" : "SBIN0000001",
@@ -452,13 +451,17 @@ _The value can be `SAVINGS`, `CURRENT`, `NRO`, `NRE`_
452451
"swift": "",
453452
"upi": "true"
454453
}
455-
}
454+
},
456455
"additionalData": { // if you have specified while creating RPD request
457456
"key1" : "value1",
458457
"key2" : "value2"
459-
}
458+
},
459+
"receiptId": "AXI75fc85a15ce6449491b79f8509c55a96",
460+
"transactionId": "602185974626"
460461
}
461-
}
462+
},
463+
"status": "BAV_REVERSE_PENNY_DROP_PAYMENT_SUCCESSFUL",
464+
"productInstanceId": "abcdefgh-c1b5-4219-a64b-abcabc123456",
462465
"traceId" : "7097e53a-baq9-4122-9d3d-8s8433b4f33e",
463466
}
464467
`}
@@ -471,6 +474,73 @@ _The value can be `SAVINGS`, `CURRENT`, `NRO`, `NRE`_
471474
Example 2
472475
</Text>
473476

477+
<Card padding="nano" shape="rounded" marginBottom="micro">
478+
<details>
479+
<summary>
480+
In case of successful bank verification, with add-on schema configured
481+
</summary>
482+
<hr className="tertiary" />
483+
<CodeBlockWithCopy language="json">{`
484+
{
485+
"event" : "RPD_VERIFICATION_UPDATE",
486+
"timeStamp" : "2021-11-12T00:12:29+05:30",
487+
"data" : {
488+
"rpd" : {
489+
"success" : true,
490+
"id" : "7097e53a-ba29-48a2-983d-878433b4f33e", // the RPD request id
491+
"upiBillId" : "a6577bb0ae4d9301cf47c1",
492+
"data" : {
493+
"bankAccountName" : "Eve",
494+
"bankAccountIfsc" : "SBIN0000001",
495+
"bankAccountNumber" : "48097036412",
496+
"payerVpa" : "test@upi",
497+
"accountType" : "BANK_ACCOUNT", // or UNKNOWN or PPI
498+
"bankAccountType" : "SAVINGS", // Optional, can be null
499+
"ifscCrossCheck" : true,
500+
"ifscDetails" : {
501+
"address": "EXPRESS TOWERS,GROUND FLOOR,NARIMAN POINT,MUMBAI 400021",
502+
"branch": "Development Bank of Singapore IMPS",
503+
"center": "MUMBAI",
504+
"city": "MUMBAI",
505+
"contact": "+912266388888",
506+
"district": "MUMBAI",
507+
"imps": "true",
508+
"iso3166": "IN-MH",
509+
"micr": "400641002",
510+
"name": "Development Bank of Singapore",
511+
"neft": "true",
512+
"rtgs": "true",
513+
"state": "MAHARASHTRA",
514+
"swift": "",
515+
"upi": "true"
516+
}
517+
},
518+
"additionalData": { // if you have specified while creating RPD request
519+
"key1" : "value1",
520+
"key2" : "value2"
521+
},
522+
"receiptId": "AXI75fc85a15ce6449491b79f8509c55a96",
523+
"transactionId": "602185974626",
524+
"addOnFields": {
525+
"psp_app": "PayApp"
526+
}
527+
}
528+
},
529+
"status": "BAV_REVERSE_PENNY_DROP_PAYMENT_SUCCESSFUL",
530+
"traceId" : "7097e53a-baq9-4122-9d3d-8s8433b4f33e",
531+
"productInstanceId": "abcdefgh-c1b5-4219-a64b-abcabc123456",
532+
}
533+
`}
534+
</CodeBlockWithCopy>
535+
536+
</details>
537+
</Card>
538+
539+
540+
<Text size="small" weight="600">
541+
Example 3
542+
</Text>
543+
474544
<Card padding="nano" shape="rounded" marginBottom="micro">
475545
<details>
476546
<summary>
@@ -486,7 +556,7 @@ _The value can be `SAVINGS`, `CURRENT`, `NRO`, `NRE`_
486556
"rpd" : {
487557
"success" : false,
488558
"id" : "7097e53a-ba29-48a2-983d-878433b4f33e",
489-
"upiBillId" : "907442106379798024",
559+
"upiBillId" : "a6577bb0ae4d9301cf47c1",
490560
"data" : null,
491561
"error" : {
492562
"code" : "BAV_REVERSE_PENNY_DROP_EXPIRED", // or BAV_REVERSE_PENNY_DROP_FAILED
@@ -502,7 +572,7 @@ _The value can be `SAVINGS`, `CURRENT`, `NRO`, `NRE`_
502572
</Card>
503573

504574
<Text size="small" weight="600">
505-
Example 3
575+
Example 4
506576
</Text>
507577

508578
<Card padding="nano" shape="rounded" marginBottom="micro">
@@ -517,7 +587,7 @@ _The value can be `SAVINGS`, `CURRENT`, `NRO`, `NRE`_
517587
"rpd": {
518588
"success": true,
519589
"id": "1af36b4e-681e-48a2-a15c-3b92da00e4c4",
520-
"upiBillId": "1005100812449350916",
590+
"upiBillId": "a6577bb0ae4d9301cf47c1",
521591
"data": null,
522592
"additionalData": {
523593
"key1": value1,
@@ -540,123 +610,6 @@ _The value can be `SAVINGS`, `CURRENT`, `NRO`, `NRE`_
540610
</details>
541611
</Card>
542612

543-
##### 2. RPD_DEBIT_ATTEMPT_FAILED Webhook
544-
545-
This webhook is sent when the end user tries to make a payments but the debit fails due to some reason.
546-
547-
<Card padding="nano" shape="rounded">
548-
<details>
549-
<summary>statusCode of this event can be one of the following:</summary>
550-
<table>
551-
<tr>
552-
<th>statusCode</th>
553-
<th>statusDescription</th>
554-
</tr>
555-
<tr>
556-
<td>R01</td>
557-
<td>The customer's debit attempt failed.</td>
558-
</tr>
559-
<tr>
560-
<td>R02</td>
561-
<td>Payment authorization took too long.</td>
562-
</tr>
563-
<tr>
564-
<td>R03</td>
565-
<td>The customer's bank is taking too long to respond.</td>
566-
</tr>
567-
<tr>
568-
<td>R04</td>
569-
<td>The debit process took too long.</td>
570-
</tr>
571-
<tr>
572-
<td>R05</td>
573-
<td>Connection timed out during the credit request process.</td>
574-
</tr>
575-
<tr>
576-
<td>R06</td>
577-
<td>The transaction exceeds the risk threshold.</td>
578-
</tr>
579-
<tr>
580-
<td>R07</td>
581-
<td>The customer's bank is unavailable.</td>
582-
</tr>
583-
<tr>
584-
<td>R08</td>
585-
<td>This transaction isn't permitted for the beneficiary.</td>
586-
</tr>
587-
<tr>
588-
<td>R09</td>
589-
<td>Connection timed out during the debit request process.</td>
590-
</tr>
591-
<tr>
592-
<td>R12</td>
593-
<td>Beneficiary bank response time is too high.</td>
594-
</tr>
595-
<tr>
596-
<td>R13</td>
597-
<td>The total debit amount exceeded the set limit.</td>
598-
</tr>
599-
<tr>
600-
<td>R14</td>
601-
<td>Transaction details mismatch.</td>
602-
</tr>
603-
<tr>
604-
<td>R16</td>
605-
<td>
606-
The requested function is not supported for the beneficiary.
607-
</td>
608-
</tr>
609-
<tr>
610-
<td>R20</td>
611-
<td>
612-
Receiver/beneficiary is not available, causing a timeout.
613-
</td>
614-
</tr>
615-
<tr>
616-
<td>R22</td>
617-
<td>The debit acknowledgement was not received.</td>
618-
</tr>
619-
<tr>
620-
<td>R25</td>
621-
<td>Duplicate transaction request.</td>
622-
</tr>
623-
<tr>
624-
<td>R100</td>
625-
<td>Any other upstream server error.</td>
626-
</tr>
627-
</table>
628-
</details>
629-
</Card>
630-
631-
###### Examples
632-
633-
<Text size="small" weight="600">
634-
Example 1
635-
</Text>
636-
637-
<Card padding="nano" shape="rounded" marginBottom="micro">
638-
<details>
639-
<summary>In case of customer's debit attempt failed</summary>
640-
<hr className="tertiary" />
641-
<CodeBlockWithCopy language="json">
642-
{`
643-
{
644-
"data": {
645-
"rpd": {
646-
"id": "178ce32b-bf43-4797-9423-027d3722df08",
647-
"additionalData": null, // customer's own data if they provided
648-
"statusCode": "R01",
649-
"statusDescription": "The customer's debit attempt failed."
650-
}
651-
},
652-
"event": "RPD_DEBIT_ATTEMPT_FAILED",
653-
"timeStamp": "2023-08-24T12:59:11.427233"
654-
}
655-
`}
656-
</CodeBlockWithCopy>
657-
</details>
658-
</Card>
659-
660613
<hr class="tertiary" />
661614

662615
#### Get Details API
@@ -728,9 +681,9 @@ This is an optional API. This API lets you know the bank verification status.
728681
"payerVpa": "customer@vpa"
729682
},
730683
"id": "1b740e7a-5a81-4b88-ad43-110a08935286",
731-
"shortUrl": "https://sandbox.bills.pe/wh9kk4mwuktg",
732-
"upiBillId": "1114053970646533628",
733-
"upiLink": "upi://pay?pa=bauvatest@kaypay&pn=BauvaTest&am=1.00&tr=1114053970646533628&tn=Account%20Verification&cu=INR&mode=04",
684+
"shortUrl": "https://sandbox.bills.pe/a6577bb0ae4d9301cf47c1",
685+
"upiBillId": "a6577bb0ae4d9301cf47c1",
686+
"upiLink": "upi://pay?pa=bauvatest@kaypay&pn=BauvaTest&am=1.00&tr=a6577bb0ae4d9301cf47c1&tn=Account%20Verification&cu=INR&mode=04",
734687
"validUpto": "2023-03-13T13:20:52.277688"
735688
"traceId": "1-640f228a-4dded97e470971343adae3da",
736689
"additionalData": {
@@ -766,9 +719,9 @@ This is an optional API. This API lets you know the bank verification status.
766719
"status": "BAV_REVERSE_PENNY_DROP_PII_PURGED",
767720
"data": null,
768721
"id": "1b740e7a-5a81-4b88-ad43-110a08935286",
769-
"shortUrl": "https://sandbox.bills.pe/wh9kk4mwuktg",
770-
"upiBillId": "1114053970646533628",
771-
"upiLink": "upi://pay?pa=bauvatest@kaypay&pn=BauvaTest&am=1.00&tr=1114053970646533628&tn=Account%20Verification&cu=INR&mode=04",
722+
"shortUrl": "https://sandbox.bills.pe/a6577bb0ae4d9301cf47c1",
723+
"upiBillId": "a6577bb0ae4d9301cf47c1",
724+
"upiLink": "upi://pay?pa=bauvatest@kaypay&pn=BauvaTest&am=1.00&tr=a6577bb0ae4d9301cf47c1&tn=Account%20Verification&cu=INR&mode=04",
772725
"validUpto": "2023-03-13T13:20:52.277688"
773726
"traceId": "1-640f228a-4dded97e470971343adae3da",
774727
"additionalData": {

0 commit comments

Comments
 (0)