curl --request POST \
--url https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices \
--header 'API-Key: <api-key>' \
--header 'API-Nonce: <api-key>' \
--header 'API-Sign: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"asset_symbol": "BTC",
"amount": "0.0005"
}
'import requests
url = "https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices"
payload = {
"asset_symbol": "BTC",
"amount": "0.0005"
}
headers = {
"API-Key": "<api-key>",
"API-Sign": "<api-key>",
"API-Nonce": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'API-Key': '<api-key>',
'API-Sign': '<api-key>',
'API-Nonce': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({asset_symbol: 'BTC', amount: '0.0005'})
};
fetch('https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'asset_symbol' => 'BTC',
'amount' => '0.0005'
]),
CURLOPT_HTTPHEADER => [
"API-Key: <api-key>",
"API-Nonce: <api-key>",
"API-Sign: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices"
payload := strings.NewReader("{\n \"asset_symbol\": \"BTC\",\n \"amount\": \"0.0005\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("API-Key", "<api-key>")
req.Header.Add("API-Sign", "<api-key>")
req.Header.Add("API-Nonce", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices")
.header("API-Key", "<api-key>")
.header("API-Sign", "<api-key>")
.header("API-Nonce", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"asset_symbol\": \"BTC\",\n \"amount\": \"0.0005\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["API-Key"] = '<api-key>'
request["API-Sign"] = '<api-key>'
request["API-Nonce"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"asset_symbol\": \"BTC\",\n \"amount\": \"0.0005\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"invoice": "lnbc500u1p3xnhl2pp5jptserfk3zk4qy42tlucycrfwxhydvlemu9pqr93tuzlv9cc7g3sqdqqcqzpgxqyz5vqsp5usyc4lk9chsfp53kvcnvq456ganh60d89reykdngsmtj6yw3nhvq9qyyssqjcewm5cjwz4a6rfjx77c490yced6pemk0upkxhy89cmm7sct66k8gneanwykzgdrwrfje69h9u5u0w57rrcsysas7gadwmzxc8c6t0spjazup6",
"expires_at": "2026-08-03T12:34:56Z"
}
}Create Lightning invoice
Creates a single-use BOLT11 invoice for a fixed-amount Bitcoin Lightning deposit. Each request creates a new invoice and is non-idempotent; after an unknown outcome, request a new invoice.
curl --request POST \
--url https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices \
--header 'API-Key: <api-key>' \
--header 'API-Nonce: <api-key>' \
--header 'API-Sign: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"asset_symbol": "BTC",
"amount": "0.0005"
}
'import requests
url = "https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices"
payload = {
"asset_symbol": "BTC",
"amount": "0.0005"
}
headers = {
"API-Key": "<api-key>",
"API-Sign": "<api-key>",
"API-Nonce": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'API-Key': '<api-key>',
'API-Sign': '<api-key>',
'API-Nonce': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({asset_symbol: 'BTC', amount: '0.0005'})
};
fetch('https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'asset_symbol' => 'BTC',
'amount' => '0.0005'
]),
CURLOPT_HTTPHEADER => [
"API-Key: <api-key>",
"API-Nonce: <api-key>",
"API-Sign: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices"
payload := strings.NewReader("{\n \"asset_symbol\": \"BTC\",\n \"amount\": \"0.0005\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("API-Key", "<api-key>")
req.Header.Add("API-Sign", "<api-key>")
req.Header.Add("API-Nonce", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices")
.header("API-Key", "<api-key>")
.header("API-Sign", "<api-key>")
.header("API-Nonce", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"asset_symbol\": \"BTC\",\n \"amount\": \"0.0005\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.services.payward.com/v1/accounts/{account_id}/funds/deposits/lightning-invoices")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["API-Key"] = '<api-key>'
request["API-Sign"] = '<api-key>'
request["API-Nonce"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"asset_symbol\": \"BTC\",\n \"amount\": \"0.0005\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"invoice": "lnbc500u1p3xnhl2pp5jptserfk3zk4qy42tlucycrfwxhydvlemu9pqr93tuzlv9cc7g3sqdqqcqzpgxqyz5vqsp5usyc4lk9chsfp53kvcnvq456ganh60d89reykdngsmtj6yw3nhvq9qyyssqjcewm5cjwz4a6rfjx77c490yced6pemk0upkxhy89cmm7sct66k8gneanwykzgdrwrfje69h9u5u0w57rrcsysas7gadwmzxc8c6t0spjazup6",
"expires_at": "2026-08-03T12:34:56Z"
}
}Authorizations
Your public API key. Identifies the partner making the request.
HMAC signature over the request, computed with your private key.
Monotonically increasing nonce included in the request signature.
Path Parameters
Globally unique public identifier for an account.
14 - 42Body
Asset and exact amount the Lightning invoice should request.
Public symbol of the asset to deposit over the Bitcoin Lightning Network.
1 - 16Exact amount requested by the invoice, denominated in asset_symbol and represented as a string to preserve precision.
1 - 64^[0-9]+(\.[0-9]+)?$Response
Lightning invoice created for the selected account.
Lightning invoice created for the selected account.
Created Lightning invoice.
Show child attributes
Show child attributes