Introduction
Learn how to use ZBD API using HTTP calls.
Prerequisites
To complete this guide, you will need the following:
- ZBD Project with a Live API key
- cURL, httpie, wget or any other HTTP client
1. Create payment request
To create a Charge on the Bitcoin Lightning Network, use the Charges HTTP API:
Check the data.invoice.request
property on the response payload for the contents of the payment request QR code.
2. Send payment to Bitcoin Lightning invoice
You can pay a Bitcoin Lightning payment request, or Charge, by leveraging the Payments HTTP API:
Check the data.status
property on the response payload to know if the payment was successful. Check Callbacks to understand how to get async payments from ZBD.
3. Send payment to Lightning Address
To send an instant Bitcoin payment to a Lightning Address (e.g. andre @ zbd.gg), you can use the Lightning Address HTTP API:
Check the data.status
property on the response payload to know if the payment was successful. Check Callbacks to understand how to get async payments from ZBD.
Was this page helpful?