MedusaJS Headless Mağazalarında Kripto Kabul Edin

Drop XPayr 0.5% non-custodial USDC, USDT, EURC, SOL, ETH, and BTC checkout into MedusaJS v1 & v2 AbstractPaymentProvider modules and Next.js Starter storefronts.

Integration Details

Version 0.2.0
Last Updated 2026-11-12
Compatibility MedusaJS v1.20+ & v2.x · Node.js 20+
Open-Source Repo v1.0.0 Release
Install @xpayr/node-sdk

How to add XPayr to MedusaJS in 10 minutes

  1. Install @xpayr/node-sdk in your Medusa backend workspace
  2. Implement initiatePayment() and authorizePayment() in your Medusa Payment Module
  3. Enable XPayr across multi-currency Medusa Regions (USD, EUR, GBP, SGD, AED)
  4. Verify X-XPayr-Signature in getWebhookActionAndData() to auto-capture Medusa carts

5-Step Medusa v2 Payment Provider Setup

  1. Run pnpm add @xpayr/node-sdk or npm install @xpayr/node-sdk inside your Medusa server.
  2. Register your custom XPayr provider inside medusa-config.ts with XPAYR_API_KEY and XPAYR_WEBHOOK_SECRET.
  3. In initiatePayment(), call client.payments.create() passing cart_id and region currency in sessionData.
  4. Render checkout_url or mount xpayr-pay-button.js inside your Medusa Next.js Storefront checkout step.
  5. Implement getWebhookActionAndData() verifying rawBody HMAC-SHA256 and returning action: "captured".

Why headless MedusaJS engineers choose XPayr

Native TypeScript SDK fit

@xpayr/node-sdk drops cleanly into Medusa v2 modular TypeScript workflows and MikroORM.

Multi-region EURC & USDC

Map EU Medusa regions to MiCA-aligned EURC and global regions to Base/Solana/TRON USDC & USDT.

Zero GMV platform tax

Keep Medusa open-source economics intact — flat 0.5% settlement straight to your Safe multisig.

AI & MCP developer speed

Scaffold your entire Medusa payment provider inside Cursor using npx -y @xpayr/mcp-server.

Composable Non-Custodial Crypto Checkout for Headless Commerce

Brands adopt MedusaJS to escape Shopify Plus lock-in and build custom multi-region B2B and D2C commerce engines. Pairing Medusa v2 with XPayr gives headless storefronts instant 12-chain Web3 + Doğrudan Borsa QR settlement at 0.5% with deterministic cart-to-order webhook capture.

FAQ

MedusaJS Crypto Payment Provider FAQ

Yes. @xpayr/node-sdk works cleanly inside Medusa v1 AbstractPaymentProcessor classes as well as Medusa v2 Payment Module Providers.

Map both payment.completed and payment.underpaid_accepted (1% max $0.50 tolerance) to Medusa "captured" status so Binance/Bybit buyers never stall order creation.

Yes — see both this guide and /plugins/nextjs for App Router Server Action patterns.

Yes. Use sk_test_ API keys on Base Sepolia, Solana Geliştirici Ağı (Devnet), or Circle Arc Testnet.

Ship 0.5% crypto checkout on MedusaJS.

Keep 99.5% of headless GMV in your own self-custodial treasury wallet.