DigiPay embed demo

This page exercises digipay.js. It's not a merchant-facing page — just a harness.

1. Declarative checkout trigger

Any element with data-digipay-checkout + data-session-id opens the hosted checkout as an in-page modal on click.

<script src="/embed/digipay.js"></script>
<button data-digipay-checkout data-session-id="ses_...">Pay with DigiByte</button>

2. Programmatic API

DigiPay.checkout({ sessionId: 'ses_...' });
DigiPay.close();

3. Donation / tip button

DigiPay.button({ address: 'dgb1...', amount: 5, name: 'Creator' });

4. Declarative button

<span data-digipay-button data-address="dgb1..." data-amount="2.5">Tip</span>
Tip 2.5 DGB

5. Full lifecycle simulation live sandbox

Walks a fresh sandbox session through all its state transitions without needing a chain tx. Renders the checkout inline (not as a modal) so the Advance buttons stay reachable.

Not started. Click "Create session" to begin.

Each Advance click walks the session pending → detected → paid → confirmed. The status pill flips, QR / countdown stay live throughout.