Taking payments from your app
Most integrations look the same: your backend decides what’s owed, your site shows checkout, and your backend hears when it’s paid.
-
Your backend creates a payment link for the order with
@kite-01/sdk, with your order ID as itsreference, and hands the link’s ID to your frontend.const { data: link } = await kite.paymentLinks.create({body: {title: "Pro plan",currency: "USD",amount: "49",reference: order.id,},}); -
Your site opens checkout over the page with
@kite-01/js, or sends the customer to/pay/<id>on your Kite server.openCheckout({ baseUrl: "https://pay.example.com", paymentLinkId });
-
Kite calls your webhook when the payment settles. Your backend verifies it, reads the
reference, and fulfils the order.
The price is always set on your server, where customers can’t change it. The browser only opens a link that already exists, and only a verified webhook marks an order paid.
Not using JavaScript?
Section titled “Not using JavaScript?”Everything the packages do is plain HTTP. Sign requests as in Signing requests, link customers to /pay/<id>, and verify webhooks as in Webhooks.