x402-powered outbound pharmacy rails. Prescription submitted → USDC sent. Zero chargebacks, zero float, zero reconciliation. Settles in 2 seconds on Base.
~2s
Settlement time
$0.001
Gas per payment
0
Chargebacks possible
1
Env var to activate
Every pharmacy operator running on card or ACH is paying a hidden tax. x402 eliminates it.
ACH takes 2–5 days
Base settles in ~2 seconds
Credit cards: 2.9% + interchange
USDC: $0.001 gas. No interchange.
Chargebacks freeze your pharmacy account
USDC is final. Zero chargeback risk.
Reconciliation is manual and error-prone
Every payment is on-chain — verifiable forever.
Float: you pay before you're paid
Pay at prescription submission, not at billing.
Processor risk: Stripe can freeze medical merchants
On-chain payments have no processor risk.
The prescription flow doesn't change. The money flow does.
Prescription approved
MDI fires case_approved → email sent to patient
Rx submitted to pharmacy
MDI fires offering_submitted → DoseSpot sends to GoGoMeds
x402 payment triggered
payPharmacy() calls Shulam bridge with caseId + amount
USDC settled on Base
Shulam executes EIP-3009 transfer → ~2s confirmation
pharmacy.payment.settled event
Event logged to DB, morning brief updated
Medication ships
GoGoMeds fulfills. Tracking number in order_tracking_number_changed
Rx submitted → USDC sent. Automatically.
When MDI fires offering_submitted (Rx sent to pharmacy via DoseSpot), x402PharmacyService.payPharmacy() executes immediately. No manual AP queue. No remittance email. The money moves with the prescription.
USDC settlements are final. GoGoMeds can't dispute them.
Card chargebacks cost 2–3% per disputed transaction and can trigger Stripe frozen accounts for medical merchants. USDC has no chargeback mechanism. Payment is final at block confirmation (~2 seconds on Base).
Every pharmacy payment logged with case ID, medication label, and on-chain tx hash.
Revenue Analyst soul tracks pharmacy cost per SKU alongside patient charge. Net margin per unit is exact: patient_charge − pharmacy_cost − provider_fee − x402_gas = margin. No estimates.
SHULAM_X402_ENABLED=true. That's the whole migration.
The architecture is already wired. Set SHULAM_X402_ENABLED=true and the pharmacy's USDC wallet address on Railway. No rebuild, no downtime, no migration. Flipping back is the same operation.
Disabled? ACH/manual flow continues unchanged.
When x402 is disabled, the system logs the intent ('Would have paid GoGoMeds $80.00 USDC') and returns silently. No patient impact. The webhook fires, the prescription ships, the audit trail is clean.
GoGoMeds, MediVera, Wedgewood, or any 503B with a USDC address.
PharmacyPartner enum: 'gogomeds' | 'medivera' | 'wedgewood' | 'other'. Each partner maps to an env var (GOGOMEDS_USDC_WALLET, MEDIVERA_USDC_WALLET). Adding a new pharmacy is one env var and one line of code.
When MDI fires offering_submitted, Pharmacy Rails automatically calls payPharmacy(). No queue. No webhook. No manual AP run.
// MDI offering_submitted webhook handler
// Fires when Rx is sent to GoGoMeds via DoseSpot
x402PharmacyService.payPharmacy({
caseId,
partner: 'gogomeds',
medicationLabel,
costCents: 8000, // $80.00 USDC
offeringIds,
});
// That's it.
// Shulam handles the rest:
// → EIP-3009 authorization
// → Base on-chain transfer
// → pharmacy.payment.settled event
// → morning brief + audit logNo rebuild. No downtime. No migration.
Ask GoGoMeds or MediVera for their Base USDC wallet address. Most pharmacy operators will have one by end of 2026.
SHULAM_X402_ENABLED=true + GOGOMEDS_USDC_WALLET=0x... on Railway. One deploy.
Every pharmacy payment appears in your admin dashboard and morning brief with on-chain tx hash.
Ziv Health → GoGoMeds via Shulam. Architecture wired. Activates when GoGoMeds confirms their USDC wallet address. Ziv is already deployed on Railway — one env var flip away.
Patient-facing crypto checkout requires wallet adoption that doesn't exist yet for most patients. But your pharmacy partners are businesses — they can hold a USDC address today.
Outbound rails give you the gains immediately: no chargebacks from GoGoMeds, instant settlement confirmation, per-payment cost accounting, and on-chain audit trail for every Rx disbursement.
Patient USDC checkout is a 12–18 month story when Base wallets hit Apple Pay UX. Pharmacy USDC payment is a one-week story once you have their address.
The Gary Tan principle:
"Stripe for patients — keep it invisible. Authorize.net as hot standby — flip the env var, not a rebuild. x402 on the outbound rails first — that's where it earns its keep."
| Tier | Price | Pharmacy Rails |
|---|---|---|
| Starter | $149/mo | Not included — standalone $99/mo add-on |
| Growth | $249/mo | ✓ Included — outbound USDC + event logging |
| Enterprise | $399/mo | ✓ Included — full module + per-SKU margin tracking + Shulam BARUCH receipts |
On-chain gas (~$0.001/transaction on Base) billed at cost. No markup.
Shulam Pharmacy Rails puts USDC between you and your pharmacy partner. Zero chargebacks. Instant settlement. On-chain audit trail. Ziv Health is live. You can be next.