curl --request POST \
--url https://sandbox.cashfree.com/verification/reverse-penny-drop \
--header 'Content-Type: application/json' \
--header 'x-client-id: <api-key>' \
--header 'x-client-secret: <api-key>' \
--data '
{
"verification_id": "11",
"name": "John Doe",
"redirect_url": "https://example.com/success"
}
'import requests
url = "https://sandbox.cashfree.com/verification/reverse-penny-drop"
payload = {
"verification_id": "11",
"name": "John Doe",
"redirect_url": "https://example.com/success"
}
headers = {
"x-client-id": "<api-key>",
"x-client-secret": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'x-client-id': '<api-key>',
'x-client-secret': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
verification_id: '11',
name: 'John Doe',
redirect_url: 'https://example.com/success'
})
};
fetch('https://sandbox.cashfree.com/verification/reverse-penny-drop', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.cashfree.com/verification/reverse-penny-drop",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'verification_id' => '11',
'name' => 'John Doe',
'redirect_url' => 'https://example.com/success'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-client-id: <api-key>",
"x-client-secret: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox.cashfree.com/verification/reverse-penny-drop"
payload := strings.NewReader("{\n \"verification_id\": \"11\",\n \"name\": \"John Doe\",\n \"redirect_url\": \"https://example.com/success\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-client-id", "<api-key>")
req.Header.Add("x-client-secret", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://sandbox.cashfree.com/verification/reverse-penny-drop")
.header("x-client-id", "<api-key>")
.header("x-client-secret", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"verification_id\": \"11\",\n \"name\": \"John Doe\",\n \"redirect_url\": \"https://example.com/success\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.cashfree.com/verification/reverse-penny-drop")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-client-id"] = '<api-key>'
request["x-client-secret"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"verification_id\": \"11\",\n \"name\": \"John Doe\",\n \"redirect_url\": \"https://example.com/success\"\n}"
response = http.request(request)
puts response.read_body{
"verification_id": "90909710",
"ref_id": 3905,
"valid_upto": "2024-02-13T13:01:44.000Z",
"upi_link": "upi://pay?pa=success@upi&pn=Cashfree&tn=BAV&am=1.00&cu=INR&tr=3905",
"gpay": "tez://upi/pay?pa=success@upi&pn=Cashfree&tn=BAV&am=1.00&cu=INR&tr=3905",
"bhim": "bhim://upi://pay?pa=success@upi&pn=Cashfree&tn=BAV&am=1.00&cu=INR&tr=3905",
"paytm": "paytmmp://pay?pa=success@upi&pn=Cashfree&tn=BAV&am=1.00&cu=INR&tr=3905",
"phonepe": "phonepe://pay?pa=success@upi&pn=Cashfree&tn=BAV&am=1.00&cu=INR&tr=3905",
"qr_code": "iVBORw0KGgoAAAANSUhEUgAAAQAAAAEAAQMAAABmvDolAAAABlBMVEX///8AAABVwtN+AAACWUlEQVR42uyYy3E7LRDEe4sDR0IglM1sH+XECIUQOHKg1F/1sHrYCkDw/cXBZePfQSNmenoG3/M9/+RZSPKGtYUbVmApdrvqNk0EVAAb0MKBlXkLZN6EIkwFRJbNkzxJl5eyIh5YPduIQNmwNigKPc2cQCJZLY9YsZT5AGWU/lZxqC4U8lvKfRiw4vWphbOuLm8h1XiWt+oeHOjHJwiw64q9vMnp4IAyil1DqwmpKP1oAwHw+tUnVxYml3cm1QGkQ1MBWWq/urKTiGeB1B6Au2fUHAARDlX0zgRFWONJPqt7CmCpcKruXuLxCIm06m4DAUBEOJmcGpe7KkRp9aiLGYCFGdgrenFkSEitcbmH0k4BkGpkamr91B788WKbhwAURTh8clJ7z5tM5f4axegAEJ1alPm160JC+tK4ZgB8t2fy9vJDPaPSLyH9OLAwOx4Sy/PqvIi3kBB/ZgJ0wk0mhxUqZHjNKv4lo6YAokas1Lr1pLXfP0r7cWAhrWRN7ZuS3eddD9Ke3n58ALCAVnVem2sTYEbheH4PEwA+2xzoymWblVaBLxPKAIC9xXnNUtcYZf+76+QcgE0oNkaRLfa6LavPDyGdBHAFMpzyazYMRpuzjucgNgOAFlTdtDDNP+jt8vOxPg88JkLrvNE2Tafp0O/twdjAtWXFNdLedyCzAfd9VF8vyDZH89E/QwHXZq9sgOuffVdkb6u/GQB5e1o7qPFQO/h5EdJZAJpVswW97UDq21r+s0C/Rt9P2shtLeyYCriabp8IYXP37Y9/GB/4nu/5n53/AgAA///QrXLm5G9kaAAAAABJRU5ErkJggg==",
"url": "https://verification-test.cashfree.com/rpd?shortCode=g4lnkgtaho0g"
}Create Reverse Penny Drop Request
Use this API to create a reverse penny drop request. Reverse penny drop is a verification method for validating bank account information.
Your customers or users makes a payment of one rupee through a UPI based transaction and get the one rupee back within 48 hours once the verification is complete.
curl --request POST \
--url https://sandbox.cashfree.com/verification/reverse-penny-drop \
--header 'Content-Type: application/json' \
--header 'x-client-id: <api-key>' \
--header 'x-client-secret: <api-key>' \
--data '
{
"verification_id": "11",
"name": "John Doe",
"redirect_url": "https://example.com/success"
}
'import requests
url = "https://sandbox.cashfree.com/verification/reverse-penny-drop"
payload = {
"verification_id": "11",
"name": "John Doe",
"redirect_url": "https://example.com/success"
}
headers = {
"x-client-id": "<api-key>",
"x-client-secret": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'x-client-id': '<api-key>',
'x-client-secret': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
verification_id: '11',
name: 'John Doe',
redirect_url: 'https://example.com/success'
})
};
fetch('https://sandbox.cashfree.com/verification/reverse-penny-drop', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.cashfree.com/verification/reverse-penny-drop",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'verification_id' => '11',
'name' => 'John Doe',
'redirect_url' => 'https://example.com/success'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-client-id: <api-key>",
"x-client-secret: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox.cashfree.com/verification/reverse-penny-drop"
payload := strings.NewReader("{\n \"verification_id\": \"11\",\n \"name\": \"John Doe\",\n \"redirect_url\": \"https://example.com/success\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-client-id", "<api-key>")
req.Header.Add("x-client-secret", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://sandbox.cashfree.com/verification/reverse-penny-drop")
.header("x-client-id", "<api-key>")
.header("x-client-secret", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"verification_id\": \"11\",\n \"name\": \"John Doe\",\n \"redirect_url\": \"https://example.com/success\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.cashfree.com/verification/reverse-penny-drop")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-client-id"] = '<api-key>'
request["x-client-secret"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"verification_id\": \"11\",\n \"name\": \"John Doe\",\n \"redirect_url\": \"https://example.com/success\"\n}"
response = http.request(request)
puts response.read_body{
"verification_id": "90909710",
"ref_id": 3905,
"valid_upto": "2024-02-13T13:01:44.000Z",
"upi_link": "upi://pay?pa=success@upi&pn=Cashfree&tn=BAV&am=1.00&cu=INR&tr=3905",
"gpay": "tez://upi/pay?pa=success@upi&pn=Cashfree&tn=BAV&am=1.00&cu=INR&tr=3905",
"bhim": "bhim://upi://pay?pa=success@upi&pn=Cashfree&tn=BAV&am=1.00&cu=INR&tr=3905",
"paytm": "paytmmp://pay?pa=success@upi&pn=Cashfree&tn=BAV&am=1.00&cu=INR&tr=3905",
"phonepe": "phonepe://pay?pa=success@upi&pn=Cashfree&tn=BAV&am=1.00&cu=INR&tr=3905",
"qr_code": "iVBORw0KGgoAAAANSUhEUgAAAQAAAAEAAQMAAABmvDolAAAABlBMVEX///8AAABVwtN+AAACWUlEQVR42uyYy3E7LRDEe4sDR0IglM1sH+XECIUQOHKg1F/1sHrYCkDw/cXBZePfQSNmenoG3/M9/+RZSPKGtYUbVmApdrvqNk0EVAAb0MKBlXkLZN6EIkwFRJbNkzxJl5eyIh5YPduIQNmwNigKPc2cQCJZLY9YsZT5AGWU/lZxqC4U8lvKfRiw4vWphbOuLm8h1XiWt+oeHOjHJwiw64q9vMnp4IAyil1DqwmpKP1oAwHw+tUnVxYml3cm1QGkQ1MBWWq/urKTiGeB1B6Au2fUHAARDlX0zgRFWONJPqt7CmCpcKruXuLxCIm06m4DAUBEOJmcGpe7KkRp9aiLGYCFGdgrenFkSEitcbmH0k4BkGpkamr91B788WKbhwAURTh8clJ7z5tM5f4axegAEJ1alPm160JC+tK4ZgB8t2fy9vJDPaPSLyH9OLAwOx4Sy/PqvIi3kBB/ZgJ0wk0mhxUqZHjNKv4lo6YAokas1Lr1pLXfP0r7cWAhrWRN7ZuS3eddD9Ke3n58ALCAVnVem2sTYEbheH4PEwA+2xzoymWblVaBLxPKAIC9xXnNUtcYZf+76+QcgE0oNkaRLfa6LavPDyGdBHAFMpzyazYMRpuzjucgNgOAFlTdtDDNP+jt8vOxPg88JkLrvNE2Tafp0O/twdjAtWXFNdLedyCzAfd9VF8vyDZH89E/QwHXZq9sgOuffVdkb6u/GQB5e1o7qPFQO/h5EdJZAJpVswW97UDq21r+s0C/Rt9P2shtLeyYCriabp8IYXP37Y9/GB/4nu/5n53/AgAA///QrXLm5G9kaAAAAABJRU5ErkJggg==",
"url": "https://verification-test.cashfree.com/rpd?shortCode=g4lnkgtaho0g"
}Authorizations
Your unique client identifier issued by Cashfree. You can find this in your Merchant Dashboard.
The secret key associated with your client ID. Use this to authenticate your API requests. You can find this in your Merchant Dashboard.
Headers
Send the signature if two-factor authentication is selected as Public Key. More details.
Body
Find the request parameters to create a reverse penny drop request.
The URL to redirect the user after payment is completed on the webpage URL in the response. If not provided, the user will be redirected to www.google.com by default.
"https://example.com/success"
Response
Success response for creating a reverse penny drop request.
It displays the generated QR code for the reverse penny drop request in base64-encoded format.
"iVBORw0KGgoAAAANSUhEUgAAAQAAAAEAAQMAAABmvDolAAAABlBMVEX///8AAABVwtN+AAACuklEQVR42uyYwa3jMAxEx/CBR5WgTqzGgtiBG5M7UQk66mB4FkP/3WR/A5aB8PZ/3sGUqOGQ+MY3bhhGklsd6sAdiAASJgz6b70RUADLQQgiuaMBqQ0VGHsCSMvhwFBHrvqDDRjqzLUzYCPrwLWM1FG3qU+g6sMfXg9G5hsCgG3MmOtMFoAZiduviroaOJ/eFF71EdeyR8tt0uX8epuXAh4DDzzDSnKknXX9f1wMWEFSCYRXncsjjjpstkTW911cDkCqNbk+PACMhZ5DOMJ6K8Cy5ZDxDIv/bLTsijJ2BbBNyiOsBbqLZAcSX3XuB1CxSBJ+pHiH0bY2cPnQh8sBxJY8hwOIe1T3NfIIR+CNAKmFNwhZhkck9TaZw8c5XA/o6bUpSHnnMlMFw8MEPNANIOV1uzhz5YIdlpUF0BVQSOiYn3p6UL9QA6nP8OEfrgZ01N55l7DEJarj8nDpHW8EWDGe0wIXzBzZ5Hm2t3voAUC0TDkx9Yu5AC21gVKHv1rdBUAi1UnA+6hVMOwHkKfl4W7Mq7qoxxk/GsodALfiQFJeRR3D/aS63r+4HjC2ZOphS2AZqYvhxkPTRO0JgGcx/9jFlixDDWRHP0Bxu+ifzSVSyjxhAjDXjgCkJh+2BHJxu3iOtPVOgDvzzQVkLQ95MbgQz+9h8nrAXBAAPKGa3tFghx2B7+3B9YB78wMTZHJW3x7YaXLmroDsWQxyYjrqJOH99LQ3AHx6POcFf5nlZy1yfBjOy4FzB1JT9Q+nC8ggO/FO83rg3CaRGnLd9CLJiX244h6Ac5nMOlRNvLsPwaYs/o0PPQC+4ZzwlCkre6QvONzW3AzIYeNpedWaW2pTeNXugHPHxbVQ/mFrCK//F/tXA14wWQ2CexyLTxM+BHcE/F0mL2HHI+5AsmzS2h33Ab7xja7iTwAAAP//HxNnsaD8lqMAAAAASUVORK5CYII="
Webpage URL for the generated UPI link and QR code for the reverse penny drop request. To enable this field, complete the Support Form and contact your account manager.
"https://verification-test.cashfree.com/rpd?shortCode=g4lnkgtaho0g"
Was this page helpful?