OpenReceive for Sylius

Accept Bitcoin & Stablecoin Payments With Sylius

Take Bitcoin Lightning in Sylius with the OpenReceive plugin: the customer places the order in Sylius's checkout and pays on the shop's own pay page, straight into your own wallet. Stablecoin payments are optional.

Plugin

Copy agent directions — Paste into Claude Code, Codex or Cursor to add OpenReceive to your Sylius app.

Why OpenReceive

Try the checkout your customers will see

Sylius customers see this same checkout on the shop's pay page after placing the order; here it runs in the openreceive.org demo shop. The live demo needs JavaScript: open the OpenReceive home page.

Six steps, no payment code

Requires Sylius 2.2 or 2.3 (2.3 needs PHP 8.3), PHP ≥ 8.2 with GMP, sodium and mbstring.

1. Get a receive-only NWC code — get one here. It can issue invoices and watch for payment, and it can never spend from your wallet.

2. Get an LSC code for swaps (optional) — from a swap provider, only if customers should be able to pay in USDT, USDC, ETH or SOL.

3. Install the plugin

composer require openreceive/sylius-plugin

4. Register it and create the tables — Add OpenReceiveBundle and OpenReceiveSyliusPlugin to config/bundles.php, import the plugin's config and routes, then run bin/console doctrine:migrations:migrate and bin/console assets:install. The Sylius quickstart has each line.

5. Connect the wallet — In the admin, open Configuration > Payment methods > Create and choose Bitcoin Lightning (OpenReceive). Paste the NWC code, plus the LSC code if you want swaps, enable the method on your channels and save. Saving asks the wallet first and refuses a code that can spend.

6. Add the cron line — Run bin/console openreceive:reconcile from cron every minute. It records payments whose customer paid and closed the pay page.

Full Sylius quickstart · Plugin source

How it runs

Tested on
Sylius 2.3.3 on MariaDB 11.4 end to end; the PHPUnit suite on PHP 8.2, 8.3 and 8.4
Databases
MySQL, MariaDB or PostgreSQL, Sylius's own database through Doctrine
Secrets
The payment method's gateway configuration, encrypted with Sylius's payment encryption key
Refunds
Refund a settled Lightning payment from your own wallet: the wallet code is receive-only. A customer reclaims a swap deposit that never converted from the order's pay page.
Mobile apps
No app SDK. Payers pay on the store's web checkout, and an app that opens it follows the same app store rules as any web checkout.

Practical questions

Which currencies can customers pay with?
Bitcoin over Lightning, always. With a swap provider configured, also USDT on Tron, Solana or Ethereum, USDC on Solana or Ethereum, ETH and SOL, each converted into the same Lightning payment. Automated swaps guide
Where does the Bitcoin go?
Into the wallet behind the receive-only NWC code. OpenReceive never holds funds: the invoice is minted in your wallet and the sats land there. The plugin completes the order's payment with Sylius's own transition, in the same database transaction that records it, so the order reads Paid. Sylius quickstart
What wallet do I need?
Any wallet that issues receive-only NWC (Nostr Wallet Connect) codes, hosted or self-run. The code must be able to create invoices and read their status, and must not be able to spend. Get a receive-only NWC code
What does it cost?
OpenReceive is completely free and open source (MIT). For Bitcoin Lightning payments, every listed NWC provider charges 0% to receive; for stablecoin, ETH and SOL payments, your payer pays the swap provider's fee, not you. See full pricing & fee breakdown
What do I need to deploy?
Sylius 2.2 or 2.3 (2.3 needs PHP 8.3) on MySQL, MariaDB or PostgreSQL, 64-bit PHP 8.2 or later with GMP, sodium and mbstring, and a cron line for openreceive:reconcile. The codes are saved on the payment method's form, encrypted with Sylius's payment encryption key. Sylius quickstart

Add OpenReceive to Sylius

Copy agent directions · Full quickstart · Plugin source · API reference · Guides

Related

Symfony