loopdclient that wants to do a loop out swap with the Lightning Lab's loop server.
loop out <amount>and hit return.
loopdclient program contacts the loop server to initiate the swap.
aperture. The authentication proxy notices that the client didn't send an LSAT and therefore cannot be granted access to the loop server.
apertureinstructs its own
lndinstance to create an invoice over a small amount that is required to acquire a fresh token.
aperturealso creates a fresh access token that is tied to the invoice. The token is cryptographically constructed in a way that it is only valid once the invoice has been paid.
402 Payment Required.
loopdunderstands this returned error code, extracts the invoice from it and automatically instructs its connected
lndinstance to pay the invoice.
loopdclient now possessing the