Skip to main content

BTCPay Server Plugin

Use Blink as a lightning provider in BTCPay Server.
Add the default wallet or select between BTC and Stablesats.

Available in BTCPay Server v1.12.0 and later.

How to Activate the Plugin

  • login to the BTCPay Server instance as an admin user

  • select Manage Plugins in the left sidebar and install the Blink plugin:

    BTCPay Server plugin
  • restart the BTCPay Server instance.

How to Connect

  • Create an API key on dashboard.blink.sv

    • log in with your registered email or a phone number or create a new account if you are new to Blink

    • select API Keys in the menu on the left

    • create an API key with the + button

    • for the most secure option choose the Read and Receive scopes - this will allow to create invoices and receive payments to your Blink account, but will not be allowed to send payments with the BTCPay Server plugin.
      Currently using only the Read scope also works, but it is better to add the Receive scope as well to ensure compatibility in the future when the plugin is updated.
      Only use the Write scope if you are planning to send payments from BTCPay Server for example with Pull Payments or connecting bolt cards. Be aware that the BTCPay Server admin can access your API key therefore could spend your balance when using the Write scope. The best is to use a self-hosted BTCPay Server instance for this purpose.

      Read and Receive key
    • the BTCPay connection strings contain the API key and the ID of the chosen wallet in the format ready to be pasted in the BTCPay Server interface:

      API key
  • the option to connect to their Blink will be available for logged in users under:

    • in case of a new store:
      Set up a lightning nodeUse custom node
    • in case of an existing store:
      LightningSettingsChange connectionUse custom node
  • the connection string for BTCPay Server is minimum:

    type=blink;api-key=blink_...
    BTCPay Server plugin
  • If adding only the API key the default wallet will be used on the Blink server (https://api.blink.sv/graphql).

  • the default wallet can be changed in the Blink app under SettingsDefault wallet, but this would only affect the BTCPay Plugin when the connection string is reloaded.

note

If using the USD wallet the requested invoice amount needs to be at least 1 USDcent even if you are using another fiat denomination or SATS.

Specify the BTC or USD Wallet (Optional)

  • to use a specific wallet (BTC or USD) use the specific BTCPay connection string with the Wallet Id included or copy the chosen the Wallet Id from your dashboard.blink.sv

    Dashboard wallets
  • use the full connection string as:

    type=blink;server=https://api.blink.sv/graphql;api-key=blink_...;wallet-id=xyz
  • can also set a custom server for development or to use an other instance of the Galoy backend

Finalize the Connection

  • Click Test connection to verify the connection

    The message:

    BTCPay Server plugin successful

    is expected as the Blink plugin is connected to a Blink account, not a lightning node directly, but the connection is working.

  • Click Save to save the connection.

  • instant inbound lightning liquidity
  • no channel management
  • no need to worry about backups
  • get notified of the received payments in the Blink app

Source Code

github.com/Kukks/BTCPayServerPlugins/tree/master/Plugins/BTCPayServer.Plugins.Blink

More Reading