To help developers use LNbits to manage their users, the User Manager extension allows the creation and management of users and wallets.
For example, a games developer may be developing a game that needs each user to have their own wallet, LNbits can be included in the develpoers stack as the user and wallet manager.
Created by, Ben Arc
GET /usermanager/api/v1/users
JSON list of users
curl -X GET {{ request.url_root }}usermanager/api/v1/users -H "X-Api-Key: {{ g.user.wallets[0].inkey }}"
GET /usermanager/api/v1/wallets/<user_id>
{"X-Api-Key": <string>}
JSON wallet data
curl -X GET {{ request.url_root }}usermanager/api/v1/wallets/<user_id> -H "X-Api-Key: {{ g.user.wallets[0].inkey }}"
GET /usermanager/api/v1/wallets<wallet_id>
{"X-Api-Key": <string>}
JSON a wallets transactions
curl -X GET {{ request.url_root }}usermanager/api/v1/wallets<wallet_id> -H "X-Api-Key: {{ g.user.wallets[0].inkey }}"
POST /usermanager/api/v1/users
{"X-Api-Key": <string>, "Content-type": "application/json"}
{"admin_id": <string>, "user_name": <string>, "wallet_name": <string>}
{"checking_id": <string>,"payment_request": <string>}
curl -X POST {{ request.url_root }}usermanager/api/v1/users -d '{"admin_id": "{{ g.user.id }}", "wallet_name": <string>, "user_name": <string>}' -H "X-Api-Key: {{ g.user.wallets[0].inkey }}" -H "Content-type: application/json"
POST /usermanager/api/v1/wallets
{"X-Api-Key": <string>, "Content-type": "application/json"}
{"user_id": <string>, "wallet_name": <string>, "admin_id": <string>}
{"checking_id": <string>,"payment_request": <string>}
curl -X POST {{ request.url_root }}usermanager/api/v1/wallets -d '{"user_id": <string>, "wallet_name": <string>, "admin_id": "{{ g.user.id }}"}' -H "X-Api-Key: {{ g.user.wallets[0].inkey }}" -H "Content-type: application/json"
DELETE /usermanager/api/v1/users/<user_id>
{"X-Api-Key": <string>}
curl -X DELETE {{ request.url_root }}usermanager/api/v1/users/<user_id> -H "X-Api-Key: {{ g.user.wallets[0].inkey }}"
DELETE /usermanager/api/v1/wallets/<wallet_id>
{"X-Api-Key": <string>}
curl -X DELETE {{ request.url_root }}usermanager/api/v1/wallets/<wallet_id> -H "X-Api-Key: {{ g.user.wallets[0].inkey }}"