Permits an SPL token mint on the instance and creates the escrow's associated token account for that mint. Deposits for this mint become possible after this call.
Accounts
| Account | Writable | Signer | Description |
|---|---|---|---|
payer | ✓ | ✓ | Fee payer |
admin | ✓ | Instance admin | |
instance | Instance PDA | ||
mint | SPL token mint to allow | ||
allowed_mint | ✓ | AllowedMint PDA (created by this instruction) | |
instance_ata | ✓ | Escrow's associated token account for this mint (created by this instruction) | |
system_program | System Program | ||
token_program | SPL Token Program | ||
associated_token_program | Associated Token Program | ||
event_authority | Event authority PDA | ||
private_channel_escrow_program | Escrow Program |
Parameters
| Parameter | Type | Description |
|---|---|---|
bump | u8 | Bump seed for the allowed_mint PDA. Optional: the Async client auto-derives it if omitted |
The IDL contains a
discriminator: u8argument (value1) that is auto-set by the generated client and should not be passed manually.
Important Notes
- Use
getAllowMintInstructionAsync; it auto-derivesbump,allowed_mint, andinstance_atawhen they are not provided. Pass your ownbumponly if you already computed it viaPubkey::find_program_address(&[b"allowed_mint", instance_pda, mint], &PROGRAM_ID) - Also creates
instance_ata, the escrow's ATA for this mint - Mints with a transfer hook extension are explicitly blocked: attempting to
allow such a mint throws
TransferHookNotAllowed - Emits an event via
EmitEventCPI
Is this page helpful?