Create Wallet

post
PostCreateWallet

https://lnpay.co/v1/wallet
Create a new wallet and corresponding access keys
Request
Response
Request
Body Parameters
user_label
required
string
An internal identifier for this wallet
Response
200: OK
Wallet Created
{
"id":"w_Noii2dJQmJjXdq",
"created_at":1577985279,
"updated_at":1577985279,
"user_label":"Tester API Wallet",
"balance":0,
"statusType": {
"id": 200,
"type": "wallet",
"name": "active",
"display_name": "Active"
},
"access_keys":{
"Wallet Admin":[
"wa_JEa9ZqCRT6oD4FsMgwWmqf1"
],
"Wallet Invoice":[
"wi_u7SjGDIG9a2EYTv4HyvXz3SW"
],
"Wallet Read":[
"wr_fWQd82MvofmBRrdT2x5YkGJ2"
]
}
}
curl
JavaScript
Python
curl
$ curl -u pak_O0iUMxk8kK_qUzkT4YKFvp1ZsUtp: \
-H "Content-Type: application/json" \
-X POST \
-d '{"user_label":"Tester API Wallet"}' \
https://lnpay.co/v1/wallet
JavaScript
LNPay.Initialize('pak_O0iUMxk8kK_qUzkT4YKFvp1ZsUtp');
let walletParams = {"user_label":"My wallet"};
LNPay.createWallet(walletParams,
function(result) {
console.log(result);
}
);
Python
lnpay_py.initialize('pak_O0iUMxk8kK_qUzkT4YKFvp1ZsUtp')
wallet_params = {
'user_label': 'My wallet'
}
new_wallet = lnpay_py.create_wallet(wallet_params)
print(new_wallet)

The access keys generated will NOT be available via the API again! You must save and store them