curl -u [YOUR_KEY_ID]:[YOUR_KEY_SECRET] \
-X POST https://api.razorpay.com/v1/payment_links/plink_Et2G7ymGcTTuM5/notify_by/email
$api = new Api($key_id, $secret);
$api->paymentLink->fetch($paymentLinkId)->notifyBy($medium);
var instance = new Razorpay({ key_id: 'YOUR_KEY_ID', key_secret: 'YOUR_SECRET' })
instance.paymentLink.notifyBy(paymentLinkId, medium)
import razorpay
client = razorpay.Client(auth=("YOUR_ID", "YOUR_SECRET"))
client.payment_link.notifyBy(paymentLinkId, medium)
import ( razorpay "github.com/razorpay/razorpay-go" )
client := razorpay.NewClient("YOUR_KEY_ID", "YOUR_SECRET")
body, err := client.PaymentLink.NotifyBy("<paymentLinkId>", "<medium>", nil, nil)
require "razorpay"
Razorpay.setup('key_id', 'key_secret')
paymentLinkId = "plink_ExjpAUN3gVHrPJ"
medium = "email"
Razorpay::PaymentLink.notify_by(paymentLinkId, medium)
import org.json.JSONObject;
import com.razorpay.Payment;
import com.razorpay.RazorpayClient;
import com.razorpay.RazorpayException;
RazorpayClient razorpay = new RazorpayClient("[YOUR_KEY_ID]", "[YOUR_KEY_SECRET]");
String paymentLinkId = "plink_FMbhpT6nqDjDei";
String medium = "email";
PaymentLink paymentlink = razorpay.paymentLink.notifyBy(paymentLinkId,medium);
RazorpayClient client = new RazorpayClient("[YOUR_KEY_ID]", "[YOUR_KEY_SECRET]");
string paymentLinkId = "plink_Z6t7VFTb9xHeOs";
string medium = "email";
PaymentLink paymentlink = client.PaymentLink.Fetch(paymentLinkId).NotifyBy(medium);
razorpay payment-links notify plink_ABC123 --medium email
{
"success": true
}
{
"error": {
"code": "BAD_REQUEST_ERROR",
"description": "invalid input [id] = [plink_QX7wiVUHdcOOoW]",
"metadata": [],
"reason": null,
"source": null,
"step": null
}
}
Payment Links
Send or Resend Notifications
Send or resend Payment Link notifications to your customers by email using this endpoint.
POST
/
v1
/
payment_links
/
:id
/
notify_by
/
:medium
curl -u [YOUR_KEY_ID]:[YOUR_KEY_SECRET] \
-X POST https://api.razorpay.com/v1/payment_links/plink_Et2G7ymGcTTuM5/notify_by/email
$api = new Api($key_id, $secret);
$api->paymentLink->fetch($paymentLinkId)->notifyBy($medium);
var instance = new Razorpay({ key_id: 'YOUR_KEY_ID', key_secret: 'YOUR_SECRET' })
instance.paymentLink.notifyBy(paymentLinkId, medium)
import razorpay
client = razorpay.Client(auth=("YOUR_ID", "YOUR_SECRET"))
client.payment_link.notifyBy(paymentLinkId, medium)
import ( razorpay "github.com/razorpay/razorpay-go" )
client := razorpay.NewClient("YOUR_KEY_ID", "YOUR_SECRET")
body, err := client.PaymentLink.NotifyBy("<paymentLinkId>", "<medium>", nil, nil)
require "razorpay"
Razorpay.setup('key_id', 'key_secret')
paymentLinkId = "plink_ExjpAUN3gVHrPJ"
medium = "email"
Razorpay::PaymentLink.notify_by(paymentLinkId, medium)
import org.json.JSONObject;
import com.razorpay.Payment;
import com.razorpay.RazorpayClient;
import com.razorpay.RazorpayException;
RazorpayClient razorpay = new RazorpayClient("[YOUR_KEY_ID]", "[YOUR_KEY_SECRET]");
String paymentLinkId = "plink_FMbhpT6nqDjDei";
String medium = "email";
PaymentLink paymentlink = razorpay.paymentLink.notifyBy(paymentLinkId,medium);
RazorpayClient client = new RazorpayClient("[YOUR_KEY_ID]", "[YOUR_KEY_SECRET]");
string paymentLinkId = "plink_Z6t7VFTb9xHeOs";
string medium = "email";
PaymentLink paymentlink = client.PaymentLink.Fetch(paymentLinkId).NotifyBy(medium);
razorpay payment-links notify plink_ABC123 --medium email
{
"success": true
}
{
"error": {
"code": "BAD_REQUEST_ERROR",
"description": "invalid input [id] = [plink_QX7wiVUHdcOOoW]",
"metadata": [],
"reason": null,
"source": null,
"step": null
}
}
Available in🇮🇳 India🇲🇾 Malaysia🇸🇬 Singapore🇺🇸 United States
Use this endpoint to send or resend Payment Link notifications to your customers by email.
Watch Out!
- SMS isn’t available for Payment Links in Malaysia. Malaysian Communications and Multimedia Commission (MCMC) rules let telcos block SMS messages that contain links. The customer receives the SMS with the link replaced by asterisks (
*), so they can’t open it. Useemailas themedium. - A resend uses only the notification channels enabled when you created the Payment Link, and you can’t change them later. The link is sent by email only if
notify.emailwastrueat creation. If it wasfalse, the API returns"success": truebut no email is sent. Share the Payment Link URL with the customer yourself, or create a new Payment Link withnotify.emailset totrue.
curl -u [YOUR_KEY_ID]:[YOUR_KEY_SECRET] \
-X POST https://api.razorpay.com/v1/payment_links/plink_Et2G7ymGcTTuM5/notify_by/email
$api = new Api($key_id, $secret);
$api->paymentLink->fetch($paymentLinkId)->notifyBy($medium);
var instance = new Razorpay({ key_id: 'YOUR_KEY_ID', key_secret: 'YOUR_SECRET' })
instance.paymentLink.notifyBy(paymentLinkId, medium)
import razorpay
client = razorpay.Client(auth=("YOUR_ID", "YOUR_SECRET"))
client.payment_link.notifyBy(paymentLinkId, medium)
import ( razorpay "github.com/razorpay/razorpay-go" )
client := razorpay.NewClient("YOUR_KEY_ID", "YOUR_SECRET")
body, err := client.PaymentLink.NotifyBy("<paymentLinkId>", "<medium>", nil, nil)
require "razorpay"
Razorpay.setup('key_id', 'key_secret')
paymentLinkId = "plink_ExjpAUN3gVHrPJ"
medium = "email"
Razorpay::PaymentLink.notify_by(paymentLinkId, medium)
import org.json.JSONObject;
import com.razorpay.Payment;
import com.razorpay.RazorpayClient;
import com.razorpay.RazorpayException;
RazorpayClient razorpay = new RazorpayClient("[YOUR_KEY_ID]", "[YOUR_KEY_SECRET]");
String paymentLinkId = "plink_FMbhpT6nqDjDei";
String medium = "email";
PaymentLink paymentlink = razorpay.paymentLink.notifyBy(paymentLinkId,medium);
RazorpayClient client = new RazorpayClient("[YOUR_KEY_ID]", "[YOUR_KEY_SECRET]");
string paymentLinkId = "plink_Z6t7VFTb9xHeOs";
string medium = "email";
PaymentLink paymentlink = client.PaymentLink.Fetch(paymentLinkId).NotifyBy(medium);
razorpay payment-links notify plink_ABC123 --medium email
{
"success": true
}
{
"error": {
"code": "BAD_REQUEST_ERROR",
"description": "invalid input [id] = [plink_QX7wiVUHdcOOoW]",
"metadata": [],
"reason": null,
"source": null,
"step": null
}
}
Path Parameters
string
required
Unique identifier of the Payment Link that should be resent.
string
required
Medium through which the Payment Link must be resent. Possible value is
email.SMS isn’t available for Payment Links in Malaysia, so don’t pass sms.Response Parameters
boolean
Indicates whether the notification was sent successfully. Possible value is
true, which means the notification was sent successfully.Errors
not a valid notification medium
not a valid notification medium
Code:
400Occurs when you try to resend a Payment Link to customers and medium of notification is not valid.Solution: Ensure that you use the correct medium to resend a payment link.The id provided does not exist.
The id provided does not exist.
Code:
400The Payment Link id passed in the URL does not exist or does not belong to the requesting merchant.Solution: Use a valid Payment Link id returned from POST /v1/payment_links. Confirm by fetching the link before retrying.Length of id should be exactly 14.
Length of id should be exactly 14.
Code:
400The Payment Link id in the URL is not 14 characters long (excluding the plink_ prefix). Razorpay Curlec-issued ids are always exactly 14 characters.Solution: Use the Payment Link id exactly as it was returned in the create response (for example, plink_HZbgjy1cnaCFqM).Request rate limit exceeded. Please try again later.
Request rate limit exceeded. Please try again later.
Code:
429You have exceeded the per-link / per-medium notification rate limit. Razorpay Curlec caps how often the same notification can be re-sent for a given Payment Link.Solution: Wait a short while before retrying. If you need a higher sustained rate, contact Razorpay Curlec support.