Lightning Nodes
...
Node Guides
Macaroons
Generate Macaroons with lncli
3min
To generate a new macaroon, you use the lncli bakemacaroon command. You can specify the permissions (read, write, etc.) that you want the macaroon to have.
This command will create a new macaroon with the specified permissions. The permissions should be in the format service:method. For example, to create a macaroon that can read invoices and write invoices, you would use invoice:read and invoices:write.
You can also add the --timeout <seconds> flag to add automatic expiration to any macaroon you generate.
Updated 10 Oct 2024
Did this page help you?