razorpay / razorpay-node

Razorpay node.js bindings
MIT License
182 stars 111 forks source link

Update for Payment Links API -https://api.razorpay.com/v1/payment_links #193

Closed sachi097 closed 2 years ago

sachi097 commented 3 years ago

As of 01 Sep 2020, Razorpay introduced new API end point for payment link.

Old API URL: https://api.razorpay.com/v1/invoices New API URL: https://api.razorpay.com/v1/payment_links

Could you please let us know when the new API end point be available in razorpay-node client.

Thanks in advance

PavanDongare commented 3 years ago

@sachi097 for now the only way to use new payment-link API is to use Axios/fetch type HTTP call?

sachi097 commented 3 years ago

@PavanDongare Yes I could make it work using Axios.

vikasg603 commented 3 years ago

https://github.com/vikasg603/razorpay-typescript

I implemented the new unofficial library, reasons: 1) typescript support. 2) Removed legacy callbacks ( If you were using the promise API, then you don't have to change anything at all) 3) Improved code to not require any module inside the function (This was the major reason I opted to create my own library, as requiring module is CPU intensive synchronous task, and requiring it inside the function can block other requests) 4) Added support for payment-links 5) Removed deprecated request and request-promise and shifted to Axios. 6) Removed the legacy error handling where you have to handle the synchronous and promise errors (added the standard RazorpayError class for handling all the errors). 7) Any many more reasons

DevT0ny commented 3 years ago

from docs

For Payment Links , please pass type as link for creation, updation and search APIs

ankitdas13 commented 2 years ago

@sachi097 Sorry for the late response. i hope this has been fixed also our sdk is updated now. you can use paymentlink and other new api's .

ankitdas13 commented 2 years ago

Closing this issue because the feature has already been added in one of the recent updates.

Please let us know if you need any help.