---
title: "Fund payouts from external wallets"
description: "Let customers pay out from their own EVM, Solana, or Stellar wallets: signed-message registration plus the on-chain authorization step per chain."
date: "2026-08-26"
category: "integrations"
products: ["payouts", "quotes", "compliance"]
---

Paste this prompt into your coding agent when funds live in your users' own wallets, not managed ones, and payouts need an on-chain authorization step.

## Prompt

```text
You are integrating BlindPay payouts funded from customers' own blockchain wallets (not managed wallets) into my application, covering EVM chains, Solana, and Stellar.

Before writing code, read these sources and follow them over any prior knowledge:
- https://blindpay.com/docs/llms.txt (read the blockchain wallets page and the per-chain payout guides: EVM, Solana, Stellar)
- The OpenAPI spec: curl https://api.blindpay.com/doc

Build the flow:
1. Register the wallet: for EVM, fetch the challenge with GET /v1/instances/{instance_id}/customers/{customer_id}/blockchain-wallets/sign-message, have the user sign it in their wallet, then POST /v1/instances/{instance_id}/customers/{customer_id}/blockchain-wallets to get the bw_ ID. Handle the direct-address registration path where the docs allow it.
2. Quote: POST /v1/instances/{instance_id}/quotes with bank_account_id, network, and token. For EVM the response includes a contract object (address, abi, functionName "approve", blindpayContractAddress, amount, network): use it verbatim to build the ERC-20 approve transaction for the user's wallet. Never hardcode contract addresses.
3. Authorize on-chain, per chain: EVM sends the approve transaction; Stellar authorizes and signs the XDR, executed via POST /v1/instances/{instance_id}/payouts/stellar; Solana uses token delegation per the docs.
4. Execute: POST /v1/instances/{instance_id}/payouts/evm (or /stellar) with quote_id and sender_wallet_address, before the quote's expires_at. Because the on-chain step takes time, build the timing carefully: request the quote, get the authorization confirmed, and execute immediately; if the quote expired while waiting for the transaction, re-quote and reuse the existing allowance when it covers the new amount.
5. Track payout.new/update/complete webhooks (Svix-verified) and surface on-chain failure separately from payout failure in my UI.

Constraints:
- API keys stay server-side; wallet signing happens client-side only.
- Test on a development instance with USDB on testnets (base_sepolia or solana_devnet) end to end, including a deliberately expired quote.

Deliverables: wallet registration flow (sign-message UX included), the per-chain authorization module, quote-execute orchestration with the expiry race handled, and webhook handlers.
```

## How to use

1. Tell the agent which chains you support; each has a different authorization step.
2. Wire the signing UX into your existing wallet connection (wagmi, solana wallet adapter, or Freighter).
3. Test the quote-expiry-during-authorization race explicitly; it is the flow's main failure mode.

## Related docs

- [Blockchain wallets](https://blindpay.com/docs/blockchain-wallets)
- [EVM payouts](https://blindpay.com/docs/payout-evm)
- [Stellar payouts](https://blindpay.com/docs/payout-stellar)
- [Solana payouts](https://blindpay.com/docs/payout-solana)
