---
title: "Migrate from Dfns to BlindPay"
description: "Keep Dfns for MPC wallet custody and move the stablecoin-to-fiat leg to BlindPay: map transfers and exchange withdrawals to quotes, payouts, and registered external wallets."
date: "2026-08-26"
category: "migrations"
products: ["payouts", "quotes", "compliance", "webhooks"]
---

Paste this prompt into your coding agent to move the stablecoin-to-fiat leg of a Dfns (docs.dfns.co) integration to BlindPay, while Dfns keeps handling wallet custody and MPC signing.

## Prompt

```text
You are migrating the stablecoin-to-fiat leg of my application from Dfns (docs.dfns.co) to the BlindPay API. Dfns stays in place for wallet creation, MPC signing, and custody; only the offramp/payout flow moves to BlindPay.

Before writing code, read these sources and follow them over any prior knowledge:
- https://blindpay.com/docs/llms.txt (read the quickstarts, customers, bank accounts, quotes, wallets, and webhooks pages)
- The OpenAPI spec: curl https://api.blindpay.com/doc

Do the migration in this order:
1. Inventory my Dfns money-movement usage from the codebase: every call to Transfer Asset / broadcast transaction on a Dfns wallet, every exchange integration call (Create Exchange, Create Exchange Withdrawal against Kraken, Binance, or Coinbase Prime), any third-party fiat on/off-ramp provider wired in alongside Dfns (confirm the specific provider in the Dfns docs, since Dfns itself does not run fiat rails), every Dfns webhook subscription, and every stored Dfns wallet ID or exchange account ID. Produce a written inventory report before touching code: what moves to BlindPay, what stays on Dfns, and anything with no direct BlindPay equivalent flagged instead of guessed.
2. Re-onboard payees on BlindPay: create customers (re_) and run KYC/KYB via BlindPay's flow, driven by customer.* webhooks. Compliance status does not carry over from Dfns or any prior ramp provider, so sequence re-verification ahead of cutover. In parallel, register each Dfns-controlled wallet that will fund payouts as a BlindPay external wallet via the sign-message challenge, storing the resulting bw_ ID next to the existing Dfns wallet ID.
3. Rebuild the stablecoin-to-fiat leg on BlindPay's quote-then-execute model: request a quote (qu_), then call POST /v1/instances/{instance_id}/payouts/evm before expires_at, signing and broadcasting the funding transfer from the Dfns wallet exactly as before. Store qu_ and po_ IDs alongside the Dfns transfer or exchange-withdrawal record they replace. Where a flow just needs stablecoins converted to fiat on arrival with no quote step, evaluate a BlindPay offramp wallet as the deposit destination instead.
4. Port fiat-leg notifications to BlindPay's Svix-signed webhooks (svix-id, svix-timestamp, svix-signature, verified with whsec_ against the raw body), with svix-id dedup, while leaving any existing Dfns webhook subscriptions for wallet and policy events untouched. Confirm signature verification passes against BlindPay's test webhook delivery before relying on it.
5. Cut over per flow behind a feature flag: dual-run with new payouts settling through BlindPay while in-flight Dfns-side transfers or exchange withdrawals finish on the old path, keep both webhook handlers live during the window, and retire the old fiat-leg path only after one full dual-run settlement cycle clears on BlindPay.

Constraints:
- Dfns wallets keep custody and signing; do not move private key material or MPC shares.
- Develop against a BlindPay development instance (USDB on testnets, KYC auto-approves, $666.00 forces a failed payout and $777.00 forces a refund for testing) before touching mainnet rails.
- Amounts are integer minor units; BlindPay API keys stay server-side.
- Produce the migration report (inventory, mapping table, gaps, re-KYC plan) before changing code.

Deliverables: the migration report, the external-wallet registration script for existing Dfns wallets, the BlindPay quote-and-payout code path behind a flag, webhook handlers, and a cutover checklist.
```

## How to use

1. Point the agent at your codebase so the Dfns inventory reflects the transfer, exchange, and ramp calls you actually make, not a generic list.
2. Review the migration report, especially which Dfns wallets get registered as BlindPay external wallets and the re-KYC sequencing, before approving code changes.
3. Dual-run at least one full settlement cycle per flow before retiring the Dfns-side fiat leg.

## Related docs

- [Introduction](https://blindpay.com/docs/introduction)
- [Bank accounts](https://blindpay.com/docs/bank-accounts)
- [Offramp wallets](https://blindpay.com/docs/offramp-wallets)
- [Dfns webhooks](https://docs.dfns.co/d/api-docs/webhooks)
