SatsPay: Create Onchain/LN charges. Includes webhooks!
Created by, Ben Arc
POST /satspay/api/v1/charge
{"X-Api-Key": <admin_key>}[<charge_object>, ...]
curl -X POST {{ request.url_root }}api/v1/charge -d
'{"onchainwallet": <string, watchonly_wallet_id>,
"description": <string>, "webhook":<string>, "time":
<integer>, "amount": <integer>, "lnbitswallet":
<string, lnbits_wallet_id>}' -H "Content-type:
application/json" -H "X-Api-Key: {{g.user.wallets[0].adminkey }}"
GET
/pay/api/v1/links/<pay_id>
{"X-Api-Key": <invoice_key>}{"lnurl": <string>}
curl -X GET {{ request.url_root }}pay/api/v1/links/<pay_id>
-H "X-Api-Key: {{ g.user.wallets[0].inkey }}"
POST /pay/api/v1/links
{"X-Api-Key": <invoice_key>}{"description": <string> "amount": <integer>}
{ "deliveryId": <string>, "description": <string>,
"webhookId": <string>, "originalDeliveryId": <string>,
"isRedelivery": <boolean>, "type": <string>,
"timestamp": <int>, "paytime": <int>, "storeId":
<string>, "invoiceId": <string>, "manuallyMarked":
<boolean>, "overPaid": <boolean>, "afterExpiration":
<boolean>, "partiallyPaid": <boolean> }
"type" can be InvoiceReceivedPayment, InvoicePaidInFull,
InvoiceExpired, InvoiceConfirmed, and InvoiceInvalid
curl -X POST {{ request.url_root }}pay/api/v1/links -d
'{"description": <string>, "amount": <integer>}' -H
"Content-type: application/json" -H "X-Api-Key: {{
g.user.wallets[0].adminkey }}"
PUT
/pay/api/v1/links/<pay_id>
{"X-Api-Key": <admin_key>}{"description": <string>, "amount": <integer>}
{"lnurl": <string>}
curl -X PUT {{ request.url_root }}pay/api/v1/links/<pay_id>
-d '{"description": <string>, "amount": <integer>}' -H
"Content-type: application/json" -H "X-Api-Key: {{
g.user.wallets[0].adminkey }}"
DELETE
/pay/api/v1/links/<pay_id>
{"X-Api-Key": <admin_key>}
curl -X DELETE {{ request.url_root
}}pay/api/v1/links/<pay_id> -H "X-Api-Key: {{
g.user.wallets[0].adminkey }}"