API Reference
Lightning Address
Create LN Withdrawal [POST]

Create LN-Withdrawal

https://sandboxapi.bitnob.co/api/v1/lnurl/createLnUrlWithdrawal (opens in a new tab)

Create an ln-withdrawal


Body Parameters

ParametertypeRequired
customerEmail
email of customer creating the withdrawal
string
description
message to add to the withdrawal
int32
satoshis
amount to withdraw in satoshis
int32

Request

lightning address/ Create LN-Withdrawal
curl --request POST \
     --url https://sandboxapi.bitnob.co/api/v1/lnurl/createLnUrlWithdrawal \
     --header 'Authorization: Bearer API-KEY' \
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --data '
{
  "customerEmail": "satoshi@bitcoin.org",
  "description": "Have some gifts for the holidays",
  "satoshis": 1000
}
'

Responses

🟢 200 - Result example
{
"status": true,
"message": "lnUrl Withdrawal successfully created",
"data": {
  "tld": "https:bitcoin.org",
  "identifier": "1b59fb916e0449d82a9e",
  "lnUrl": "LNURL1DP68GURN8GHJ7UM5V9NKJMN894SHQ6FWVEKX7AM9WF6X7UPW0PUH5TMSDVHXZWPH8PNZUETYXD3RQDRYX3JXYVFJ89SNXC34VYHKCMN4WFK8WTE3VG6NJENZ8YCNVEFSXS6RJEPCXFSNJEG5MZMLE",
  "lnUrlQR": "https://chart.googleapis.com/chart?chs=500x500&cht=qr&chl=LNURL1DP68GURN8GHJ7UM5V9NKJMN894SHQ6FWVEKX7AM9WF6X7UPW0PUH5TMSDVHXZWPH8PNZUETYXD3RQDRYX3JXYVFJ89SNXC34VYHKCMN4WFK8WTE3VG6NJENZ8YCNVEFSXS6RJEPCXFSNJEG5MZMLE",
  "lnUrlTag": "withdrawalRequest",
  "k1": "a578c66f1ae7",
  "satMinWithdrawable": "1000",
  "satMaxWithdrawable": "1000",
  "identifierType": null,
  "description": null,
  "image": null,
  "id": "ba23d74c-f5df-4f86-92ff-ba66145d3f9f",
  "createdAt": "2021-12-05T01:43:43.021Z",
  "updatedAt": "2021-12-05T01:43:43.021Z"
}
}
 
Last updated on