Documentation Index
Fetch the complete documentation index at: https://v2-docs.exponent.finance/llms.txt
Use this file to discover all available pages before exploring further.
createWrapperAddPolicyInstruction
Adds a Squads policy to the vault via self-CPI using the vault’s signer seeds. This instruction enforces that the vault has zero AUM (empty vault only), ensuring policies are configured before any deposits are accepted. Typically called during initial vault setup to establish the execution policies that govern strategy allocations. Once the vault holds depositor funds (AUM > 0), use a governance proposal withPolicyAction instead. See Propose Action.
Usage
Accounts
| Name | Signer | Writable | Description |
|---|---|---|---|
payer | Yes | Yes | Fee payer for account creation |
vault | No | Yes | Vault account (must have zero AUM) |
squadsSettings | No | Yes | Squads multisig settings account |
squadsSettingsTransaction | No | Yes | Squads settings transaction account |
squadsProposal | No | Yes | Squads proposal account |
squadsPolicy | No | Yes | Squads policy account to create |
squadsProgram | No | No | Squads program |
systemProgram | No | No | System program |
Args
| Name | Type | Description |
|---|---|---|
policyConfig | PolicyConfig | Configuration for the new policy including threshold, permissions, and members |
Returns
TransactionInstruction — a transaction instruction ready to be added to a transaction.