Take Plaza withdrawals in your app
Register a deposit address as a venue, then credit each withdrawal that arrives with the set it was proven against.
This guide is for an exchange, a desk or any service that credits deposits. Plaza withdrawals arrive at your deposit address as ordinary SOL or token transfers from Plaza's payout account; the program has already checked that each one was proven against a set you accept.
1. Register the deposit address
Register each deposit address you want to receive at, from the key that holds it, with the sets you accept:
node cli/plaza.mjs venue register --keypair ./deposit-address.json --name "Your venue" --accept OPEN_SET_ID/venues → Register a venue → Name, Accepted sets → Register venueWhen the operator key and the deposit address differ, pass the operator as --keypair and add --deposit-address and --destination-keypair; both sign. See Accept sets as a venue.
2. Recognise a Plaza withdrawal
A withdrawal is a transaction that calls the Plaza program's transact and pays your address. Its Spent event, an inner instruction of the Plaza program, carries asp, root, nullifier, destination, mint, amount (gross) and fee; see Events. Your address receives amount - fee.
The API serves the same facts by signature:
import { createClient } from '@plaza/contract'
const api = createClient('http://127.0.0.1:5902')
const DEPOSIT_ADDRESS = 'your deposit address'
export async function plazaCredit(signature: string) {
const { status, spend } = await api.proof(signature)
if (status !== 'confirmed' || !spend || spend.kind !== 'withdraw') return null
if (spend.destination !== DEPOSIT_ADDRESS || spend.amount === null || spend.fee === null) return null
return {
mint: spend.mint,
credited: BigInt(spend.amount) - BigInt(spend.fee),
set: spend.asp,
setName: spend.setName,
root: spend.root,
}
}Store set and root with the credit: they name the policy the money passed. A receipt from a localnet SPL withdrawal to a venue, where the venue was credited 411,108 base units:
{
"signature": "5ZFuhqPzxuCDkAi4CYzGPPrJemEzRrMSzPW4xjgbiW1Uuy811o9vbDS2TuDpFDcJkNPPSNg4ZZ15Ua266JRDj3HP",
"status": "confirmed",
"spend": {
"kind": "withdraw",
"asp": "3WxJhXZgFExF6uCWPwxNwXLfdqZ1gZTZ2KiEZ8cqNNFS",
"root": "20913605449245576461379441486952689435134595823059134918374118998512819677455",
"setName": "Open Set",
"nullifiers": ["20555725485863955436956444241218211759069237724122572498233317165532043955450"],
"mint": "GEtv7zpLUFgnHMDCCkAZuQf9t39sTyC717tXHqdMhw4D",
"amount": "412345",
"destination": "EBKPSLzcX1ZCfPueLFZGgbNfndPcLztzfEmWmktVXzCp",
"fee": "1237",
"networkFee": "5000",
"slot": "13297",
"time": "2026-11-23T14:15:53.000Z"
}
}3. Change what you accept
plaza venue accept --deposit-address ADDRESS --accept ASP,ASP replaces the list. Withdrawals proven against a set you dropped fail on chain with VenueRefused once the change lands.
Ragequits
A ragequit pays only the original depositor, so it never arrives at a venue's address unless that address made the deposit itself.