VoltrVault: {
accounts: [
{
discriminator: [105, 99, 219, 155, 77, 241, 7, 119];
name: "adaptorAddReceipt";
},
{ discriminator: [45, 39, 101, 43, 115, 72, 131, 40]; name: "protocol" },
{
discriminator: [51, 8, 192, 253, 115, 78, 112, 214];
name: "strategyInitReceipt";
},
{ discriminator: [211, 8, 232, 43, 2, 152, 117, 119]; name: "vault" },
];
address: "vVoLTRjQmtFpiYoegx285Ze4gsLJ8ZxgFKVcuvmG1a8";
errors: [
{ code: 6000; msg: "Invalid amount provided."; name: "invalidAmount" },
{ code: 6001; msg: "Invalid account owner."; name: "invalidAccountOwner" },
{ code: 6002; msg: "Already initialized."; name: "alreadyInitialized" },
{ code: 6003; msg: "Invalid token mint."; name: "invalidTokenMint" },
{ code: 6004; msg: "Invalid token account."; name: "invalidTokenAccount" },
{ code: 6005; msg: "Invalid account input."; name: "invalidAccountInput" },
{ code: 6006; msg: "Not rent exempt."; name: "notRentExempt" },
{ code: 6007; msg: "Math overflow."; name: "mathOverflow" },
{ code: 6008; msg: "Max cap exceeded."; name: "maxCapExceeded" },
{ code: 6009; msg: "Strategy not empty."; name: "strategyNotEmpty" },
{ code: 6010; msg: "Vault not active."; name: "vaultNotActive" },
{
code: 6011;
msg: "Manager not allowed in remaining.";
name: "managerNotAllowed";
},
{ code: 6012; msg: "Operation not allowed."; name: "operationNotAllowed" },
];
instructions: [
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "admin"; relations: ["vault"]; signer: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{
name: "adaptorAddReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
97,
100,
100,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "adaptorProgram" },
];
};
writable: true;
},
{ name: "adaptorProgram" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [];
discriminator: [161, 145, 203, 248, 211, 202, 203, 67];
name: "addAdaptor";
},
{
accounts: [
{ name: "userTransferAuthority"; signer: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{ name: "vaultAssetMint" },
{
name: "vaultLpMint";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
docs: [
"The user's asset ATA from which they are depositing tokens.",
];
name: "userAssetAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "userTransferAuthority" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
docs: ["The vault's associated token account for asset."];
name: "vaultAssetIdleAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultAssetIdleAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultAssetIdleAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
97,
115,
115,
101,
116,
95,
105,
100,
108,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
docs: ["The user's LP ATA where we will mint LP tokens."];
name: "userLpAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "userTransferAuthority" },
{ kind: "account"; path: "lpTokenProgram" },
{ kind: "account"; path: "vaultLpMint" },
];
};
writable: true;
},
{
docs: [
"The PDA authority used to sign mint instructions for LP tokens.",
];
name: "vaultLpMintAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
address: "SysvarC1ock11111111111111111111111111111111";
name: "clock";
},
{ name: "assetTokenProgram" },
{
address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
name: "lpTokenProgram";
},
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [{ name: "amount"; type: "u64" }];
discriminator: [242, 35, 198, 137, 82, 225, 242, 182];
name: "deposit";
},
{
accounts: [
{ name: "manager"; signer: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{ name: "strategy" },
{
name: "adaptorAddReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
97,
100,
100,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "adaptorProgram" },
];
};
},
{
name: "strategyInitReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
115,
116,
114,
97,
116,
101,
103,
121,
95,
105,
110,
105,
116,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{
name: "vaultAssetIdleAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
97,
115,
115,
101,
116,
95,
105,
100,
108,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
name: "vaultLpFeeAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
102,
101,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
name: "vaultStrategyAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
115,
116,
114,
97,
116,
101,
103,
121,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "vaultAssetMint"; writable: true },
{
name: "vaultLpMint";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
docs: ["The vault's associated token account for asset."];
name: "vaultAssetIdleAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultAssetIdleAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultLpFeeAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultLpFeeAuth" },
{ kind: "account"; path: "lpTokenProgram" },
{ kind: "account"; path: "vaultLpMint" },
];
};
writable: true;
},
{
name: "vaultStrategyAssetAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultStrategyAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultLpMintAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{ name: "assetTokenProgram" },
{
address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
name: "lpTokenProgram";
},
{ name: "adaptorProgram" },
];
args: [
{ name: "amount"; type: "u64" },
{ name: "instructionDiscriminator"; type: { option: "bytes" } },
{ name: "additionalArgs"; type: { option: "bytes" } },
];
discriminator: [246, 82, 57, 226, 131, 222, 253, 249];
name: "depositStrategy";
},
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "currentAdmin"; signer: true },
{ name: "newAdmin" },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
writable: true;
},
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [
{ name: "operationalState"; type: "u16" },
{ name: "fee"; type: "u16" },
];
discriminator: [149, 56, 57, 46, 105, 182, 61, 208];
name: "initOrUpdateProtocol";
},
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "manager" },
{ name: "admin" },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; signer: true; writable: true },
{
name: "vaultLpMint";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{ name: "vaultAssetMint" },
{ name: "vaultAssetIdleAta"; writable: true },
{ name: "vaultLpFeeAta"; writable: true },
{
name: "vaultLpMintAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
name: "vaultAssetIdleAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
97,
115,
115,
101,
116,
95,
105,
100,
108,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
name: "vaultLpFeeAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
102,
101,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
address: "SysvarC1ock11111111111111111111111111111111";
name: "clock";
},
{ address: "SysvarRent111111111111111111111111111111111"; name: "rent" },
{
address: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL";
name: "associatedTokenProgram";
},
{ name: "assetTokenProgram" },
{
address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
name: "lpTokenProgram";
},
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [
{
name: "config";
type: { defined: { name: "vaultInitializationInput" } };
},
{ name: "name"; type: "string" },
{ name: "description"; type: "string" },
];
discriminator: [175, 175, 109, 31, 13, 152, 155, 237];
name: "initialize";
},
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "manager"; signer: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault" },
{ name: "strategy" },
{
name: "adaptorAddReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
97,
100,
100,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "adaptorProgram" },
];
};
},
{
name: "strategyInitReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
115,
116,
114,
97,
116,
101,
103,
121,
95,
105,
110,
105,
116,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{
name: "vaultStrategyAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
115,
116,
114,
97,
116,
101,
103,
121,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "adaptorProgram" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [
{ name: "instructionDiscriminator"; type: { option: "bytes" } },
{ name: "additionalArgs"; type: { option: "bytes" } },
];
discriminator: [208, 119, 144, 145, 178, 57, 105, 252];
name: "initializeStrategy";
},
{
accounts: [
{ name: "admin"; relations: ["vault"]; signer: true; writable: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{
name: "adaptorAddReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
97,
100,
100,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "adaptorProgram" },
];
};
writable: true;
},
{ name: "adaptorProgram" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [];
discriminator: [161, 199, 99, 22, 25, 193, 61, 193];
name: "removeAdaptor";
},
{
accounts: [
{
docs: [
"The authority that owns the LP tokens and wants to redeem them",
];
name: "userTransferAuthority";
signer: true;
writable: true;
},
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{ name: "vaultAssetMint" },
{
name: "vaultLpMint";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
docs: [
"The user's LP token account from which LP tokens will be burned.",
];
name: "userLpAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "userTransferAuthority" },
{ kind: "account"; path: "lpTokenProgram" },
{ kind: "account"; path: "vaultLpMint" },
];
};
writable: true;
},
{
docs: ["The vault's associated token account for asset."];
name: "vaultAssetIdleAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultAssetIdleAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultAssetIdleAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
97,
115,
115,
101,
116,
95,
105,
100,
108,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
docs: ["The user's asset ATA to which asset tokens will be sent."];
name: "userAssetAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "userTransferAuthority" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
address: "SysvarC1ock11111111111111111111111111111111";
name: "clock";
},
{ name: "assetTokenProgram" },
{
address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
name: "lpTokenProgram";
},
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [{ name: "amount"; type: "u64" }];
discriminator: [183, 18, 70, 156, 148, 109, 161, 34];
name: "withdraw";
},
{
accounts: [
{ name: "manager"; signer: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{
name: "adaptorAddReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
97,
100,
100,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "adaptorProgram" },
];
};
},
{
name: "strategyInitReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
115,
116,
114,
97,
116,
101,
103,
121,
95,
105,
110,
105,
116,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "strategy" },
{ name: "adaptorProgram" },
{
name: "vaultAssetIdleAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
97,
115,
115,
101,
116,
95,
105,
100,
108,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
name: "vaultLpFeeAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
102,
101,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
name: "vaultStrategyAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
115,
116,
114,
97,
116,
101,
103,
121,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "vaultAssetMint"; writable: true },
{
name: "vaultLpMint";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
docs: ["The vault's associated token account for asset."];
name: "vaultAssetIdleAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultAssetIdleAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultLpFeeAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultLpFeeAuth" },
{ kind: "account"; path: "lpTokenProgram" },
{ kind: "account"; path: "vaultLpMint" },
];
};
writable: true;
},
{
name: "vaultStrategyAssetAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultStrategyAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultLpMintAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{ name: "assetTokenProgram" },
{
address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
name: "lpTokenProgram";
},
];
args: [
{ name: "amount"; type: "u64" },
{ name: "instructionDiscriminator"; type: { option: "bytes" } },
{ name: "additionalArgs"; type: { option: "bytes" } },
];
discriminator: [31, 45, 162, 5, 193, 217, 134, 188];
name: "withdrawStrategy";
},
];
metadata: {
description: "Created with Anchor";
name: "voltrVault";
spec: "0.1.0";
version: "0.1.0";
};
types: [
{
name: "adaptorAddReceipt";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The vault associated with this strategy."];
name: "vault";
type: "pubkey";
},
{
docs: ["The adapter program address."];
name: "adaptorProgram";
type: "pubkey";
},
{ docs: ["A version number (1 byte)."]; name: "version"; type: "u8" },
{
docs: ["The bump for the adaptor add receipt."];
name: "bump";
type: "u8";
},
{
docs: [
"6 bytes of padding to align future 8-byte fields on 8-byte boundaries.",
];
name: "padding0";
type: { array: ["u8", 6] };
},
{
docs: ["Reserved space for future fields"];
name: "reserved";
type: { array: ["u8", 64] };
},
];
kind: "struct";
};
},
{
name: "feeConfiguration";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["Manager performance fee in basis points (BPS)."];
name: "managerPerformanceFee";
type: "u16";
},
{
docs: ["Admin performance fee in basis points (BPS)."];
name: "adminPerformanceFee";
type: "u16";
},
{
docs: ["Manager management fee in basis points (BPS)."];
name: "managerManagementFee";
type: "u16";
},
{
docs: ["Admin management fee in basis points (BPS)."];
name: "adminManagementFee";
type: "u16";
},
{
docs: ["Reserved bytes for future use."];
name: "reserved";
type: { array: ["u8", 96] };
},
];
kind: "struct";
};
},
{
name: "protocol";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The admin of the protocol."];
name: "admin";
type: "pubkey";
},
{
docs: ["The operational state of the protocol."];
name: "operationalState";
type: "u16";
},
{ docs: ["The fee for the protocol."]; name: "fee"; type: "u16" },
{ docs: ["The bump for the protocol."]; name: "bump"; type: "u8" },
{
docs: [
"1 byte of padding to align future 8-byte fields on 8-byte boundaries.",
];
name: "padding0";
type: { array: ["u8", 1] };
},
{
docs: ["Reserved space for future fields"];
name: "reserved";
type: { array: ["u8", 64] };
},
];
kind: "struct";
};
},
{
name: "strategyInitReceipt";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The vault associated with this strategy."];
name: "vault";
type: "pubkey";
},
{ docs: ["The strategy address."]; name: "strategy"; type: "pubkey" },
{ docs: ["The position value."]; name: "positionValue"; type: "u64" },
{
docs: ["The last updated timestamp."];
name: "lastUpdatedTs";
type: "u64";
},
{ docs: ["A version number (1 byte)."]; name: "version"; type: "u8" },
{
docs: ["The bump for the strategy init receipt."];
name: "bump";
type: "u8";
},
{
docs: ["The bump for the vault strategy auth."];
name: "vaultStrategyAuthBump";
type: "u8";
},
{
docs: [
"6 bytes of padding to align future 8-byte fields on 8-byte boundaries.",
];
name: "padding0";
type: { array: ["u8", 5] };
},
{
docs: ["Reserved space for future fields"];
name: "reserved";
type: { array: ["u8", 64] };
},
];
kind: "struct";
};
},
{
name: "vault";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The vault's name."];
name: "name";
type: { array: ["u8", 32] };
},
{
docs: ["A description or summary for this vault."];
name: "description";
type: { array: ["u8", 64] };
},
{
docs: [
"The vault’s main asset configuration (inline nested struct).",
];
name: "asset";
type: { defined: { name: "vaultAsset" } };
},
{
docs: [
"The vault’s LP (share) configuration (inline nested struct).",
];
name: "lp";
type: { defined: { name: "vaultLp" } };
},
{
docs: ["The manager of this vault (has certain permissions)."];
name: "manager";
type: "pubkey";
},
{
docs: [
"The admin of this vault (broader or fallback permissions).",
];
name: "admin";
type: "pubkey";
},
{
docs: [
"The vault fee and cap configuration (inline nested struct).",
];
name: "vaultConfiguration";
type: { defined: { name: "vaultConfiguration" } };
},
{
docs: [
"The vault fee and cap configuration (inline nested struct).",
];
name: "feeConfiguration";
type: { defined: { name: "feeConfiguration" } };
},
{
docs: [
"The last time (Unix timestamp) this vault data was updated.",
];
name: "lastUpdatedTs";
type: "u64";
},
{ docs: ["The version of the vault."]; name: "version"; type: "u8" },
{
docs: [
"padding to align future 8-byte fields on 8-byte boundaries.",
];
name: "padding0";
type: { array: ["u8", 7] };
},
{
docs: ["Reserved bytes for future use."];
name: "reserved";
type: { array: ["u8", 256] };
},
];
kind: "struct";
};
},
{
name: "vaultAsset";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The mint for the vault’s main asset."];
name: "mint";
type: "pubkey";
},
{
docs: ["The “idle” token account holding un-invested assets."];
name: "idleAta";
type: "pubkey";
},
{
docs: ["The total amount of this asset currently in the vault."];
name: "totalValue";
type: "u64";
},
{
docs: ["The bump for the vault asset mint."];
name: "idleAtaAuthBump";
type: "u8";
},
{
docs: ["Reserved bytes for future use."];
name: "reserved";
type: { array: ["u8", 95] };
},
];
kind: "struct";
};
},
{
name: "vaultConfiguration";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The maximum total amount allowed in the vault."];
name: "maxCap";
type: "u64";
},
{ docs: ["active from timestamp"]; name: "startAtTs"; type: "u64" },
{
docs: ["Reserved bytes for future use."];
name: "reserved";
type: { array: ["u8", 64] };
},
];
kind: "struct";
};
},
{
name: "vaultInitializationInput";
type: {
fields: [
{
docs: ["The maximum total amount allowed in the vault."];
name: "maxCap";
type: "u64";
},
{ docs: ["active from timestamp"]; name: "startAtTs"; type: "u64" },
{
docs: ["Manager performance fee in basis points (BPS)."];
name: "managerPerformanceFee";
type: "u16";
},
{
docs: ["Admin performance fee in basis points (BPS)."];
name: "adminPerformanceFee";
type: "u16";
},
{
docs: ["Manager management fee in basis points (BPS)."];
name: "managerManagementFee";
type: "u16";
},
{
docs: ["Admin management fee in basis points (BPS)."];
name: "adminManagementFee";
type: "u16";
},
];
kind: "struct";
};
},
{
name: "vaultLp";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The LP mint (e.g., representing shares in this vault)."];
name: "mint";
type: "pubkey";
},
{
docs: [
"A fee token account for collecting/receiving fees in LP tokens.",
];
name: "feeAta";
type: "pubkey";
},
{
docs: ["The bump for the vault LP mint."];
name: "mintBump";
type: "u8";
},
{
docs: ["The bump for the vault LP mint authority."];
name: "mintAuthBump";
type: "u8";
},
{
docs: ["The bump for the vault LP fee authority."];
name: "feeAtaAuthBump";
type: "u8";
},
{
docs: ["Reserved bytes for future use."];
name: "reserved";
type: { array: ["u8", 93] };
},
];
kind: "struct";
};
},
];
}
Type declaration
accounts: [
{
discriminator: [105, 99, 219, 155, 77, 241, 7, 119];
name: "adaptorAddReceipt";
},
{ discriminator: [45, 39, 101, 43, 115, 72, 131, 40]; name: "protocol" },
{
discriminator: [51, 8, 192, 253, 115, 78, 112, 214];
name: "strategyInitReceipt";
},
{ discriminator: [211, 8, 232, 43, 2, 152, 117, 119]; name: "vault" },
]
address: "vVoLTRjQmtFpiYoegx285Ze4gsLJ8ZxgFKVcuvmG1a8"
errors: [
{ code: 6000; msg: "Invalid amount provided."; name: "invalidAmount" },
{ code: 6001; msg: "Invalid account owner."; name: "invalidAccountOwner" },
{ code: 6002; msg: "Already initialized."; name: "alreadyInitialized" },
{ code: 6003; msg: "Invalid token mint."; name: "invalidTokenMint" },
{ code: 6004; msg: "Invalid token account."; name: "invalidTokenAccount" },
{ code: 6005; msg: "Invalid account input."; name: "invalidAccountInput" },
{ code: 6006; msg: "Not rent exempt."; name: "notRentExempt" },
{ code: 6007; msg: "Math overflow."; name: "mathOverflow" },
{ code: 6008; msg: "Max cap exceeded."; name: "maxCapExceeded" },
{ code: 6009; msg: "Strategy not empty."; name: "strategyNotEmpty" },
{ code: 6010; msg: "Vault not active."; name: "vaultNotActive" },
{
code: 6011;
msg: "Manager not allowed in remaining.";
name: "managerNotAllowed";
},
{ code: 6012; msg: "Operation not allowed."; name: "operationNotAllowed" },
]
instructions: [
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "admin"; relations: ["vault"]; signer: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{
name: "adaptorAddReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
97,
100,
100,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "adaptorProgram" },
];
};
writable: true;
},
{ name: "adaptorProgram" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [];
discriminator: [161, 145, 203, 248, 211, 202, 203, 67];
name: "addAdaptor";
},
{
accounts: [
{ name: "userTransferAuthority"; signer: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{ name: "vaultAssetMint" },
{
name: "vaultLpMint";
pda: {
seeds: [
{
kind: "const";
value: [118, 97, 117, 108, 116, 95, 108, 112, 95, 109, 105, 110, 116];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
docs: ["The user's asset ATA from which they are depositing tokens."];
name: "userAssetAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "userTransferAuthority" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
docs: ["The vault's associated token account for asset."];
name: "vaultAssetIdleAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultAssetIdleAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultAssetIdleAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
97,
115,
115,
101,
116,
95,
105,
100,
108,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
docs: ["The user's LP ATA where we will mint LP tokens."];
name: "userLpAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "userTransferAuthority" },
{ kind: "account"; path: "lpTokenProgram" },
{ kind: "account"; path: "vaultLpMint" },
];
};
writable: true;
},
{
docs: [
"The PDA authority used to sign mint instructions for LP tokens.",
];
name: "vaultLpMintAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{ address: "SysvarC1ock11111111111111111111111111111111"; name: "clock" },
{ name: "assetTokenProgram" },
{
address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
name: "lpTokenProgram";
},
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [{ name: "amount"; type: "u64" }];
discriminator: [242, 35, 198, 137, 82, 225, 242, 182];
name: "deposit";
},
{
accounts: [
{ name: "manager"; signer: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{ name: "strategy" },
{
name: "adaptorAddReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
97,
100,
100,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "adaptorProgram" },
];
};
},
{
name: "strategyInitReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
115,
116,
114,
97,
116,
101,
103,
121,
95,
105,
110,
105,
116,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{
name: "vaultAssetIdleAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
97,
115,
115,
101,
116,
95,
105,
100,
108,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
name: "vaultLpFeeAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
102,
101,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
name: "vaultStrategyAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
115,
116,
114,
97,
116,
101,
103,
121,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "vaultAssetMint"; writable: true },
{
name: "vaultLpMint";
pda: {
seeds: [
{
kind: "const";
value: [118, 97, 117, 108, 116, 95, 108, 112, 95, 109, 105, 110, 116];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
docs: ["The vault's associated token account for asset."];
name: "vaultAssetIdleAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultAssetIdleAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultLpFeeAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultLpFeeAuth" },
{ kind: "account"; path: "lpTokenProgram" },
{ kind: "account"; path: "vaultLpMint" },
];
};
writable: true;
},
{
name: "vaultStrategyAssetAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultStrategyAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultLpMintAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{ name: "assetTokenProgram" },
{
address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
name: "lpTokenProgram";
},
{ name: "adaptorProgram" },
];
args: [
{ name: "amount"; type: "u64" },
{ name: "instructionDiscriminator"; type: { option: "bytes" } },
{ name: "additionalArgs"; type: { option: "bytes" } },
];
discriminator: [246, 82, 57, 226, 131, 222, 253, 249];
name: "depositStrategy";
},
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "currentAdmin"; signer: true },
{ name: "newAdmin" },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
writable: true;
},
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [
{ name: "operationalState"; type: "u16" },
{ name: "fee"; type: "u16" },
];
discriminator: [149, 56, 57, 46, 105, 182, 61, 208];
name: "initOrUpdateProtocol";
},
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "manager" },
{ name: "admin" },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; signer: true; writable: true },
{
name: "vaultLpMint";
pda: {
seeds: [
{
kind: "const";
value: [118, 97, 117, 108, 116, 95, 108, 112, 95, 109, 105, 110, 116];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{ name: "vaultAssetMint" },
{ name: "vaultAssetIdleAta"; writable: true },
{ name: "vaultLpFeeAta"; writable: true },
{
name: "vaultLpMintAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
name: "vaultAssetIdleAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
97,
115,
115,
101,
116,
95,
105,
100,
108,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
name: "vaultLpFeeAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
102,
101,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{ address: "SysvarC1ock11111111111111111111111111111111"; name: "clock" },
{ address: "SysvarRent111111111111111111111111111111111"; name: "rent" },
{
address: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL";
name: "associatedTokenProgram";
},
{ name: "assetTokenProgram" },
{
address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
name: "lpTokenProgram";
},
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [
{
name: "config";
type: { defined: { name: "vaultInitializationInput" } };
},
{ name: "name"; type: "string" },
{ name: "description"; type: "string" },
];
discriminator: [175, 175, 109, 31, 13, 152, 155, 237];
name: "initialize";
},
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "manager"; signer: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault" },
{ name: "strategy" },
{
name: "adaptorAddReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
97,
100,
100,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "adaptorProgram" },
];
};
},
{
name: "strategyInitReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
115,
116,
114,
97,
116,
101,
103,
121,
95,
105,
110,
105,
116,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{
name: "vaultStrategyAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
115,
116,
114,
97,
116,
101,
103,
121,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "adaptorProgram" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [
{ name: "instructionDiscriminator"; type: { option: "bytes" } },
{ name: "additionalArgs"; type: { option: "bytes" } },
];
discriminator: [208, 119, 144, 145, 178, 57, 105, 252];
name: "initializeStrategy";
},
{
accounts: [
{ name: "admin"; relations: ["vault"]; signer: true; writable: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{
name: "adaptorAddReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
97,
100,
100,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "adaptorProgram" },
];
};
writable: true;
},
{ name: "adaptorProgram" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [];
discriminator: [161, 199, 99, 22, 25, 193, 61, 193];
name: "removeAdaptor";
},
{
accounts: [
{
docs: [
"The authority that owns the LP tokens and wants to redeem them",
];
name: "userTransferAuthority";
signer: true;
writable: true;
},
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{ name: "vaultAssetMint" },
{
name: "vaultLpMint";
pda: {
seeds: [
{
kind: "const";
value: [118, 97, 117, 108, 116, 95, 108, 112, 95, 109, 105, 110, 116];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
docs: [
"The user's LP token account from which LP tokens will be burned.",
];
name: "userLpAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "userTransferAuthority" },
{ kind: "account"; path: "lpTokenProgram" },
{ kind: "account"; path: "vaultLpMint" },
];
};
writable: true;
},
{
docs: ["The vault's associated token account for asset."];
name: "vaultAssetIdleAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultAssetIdleAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultAssetIdleAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
97,
115,
115,
101,
116,
95,
105,
100,
108,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
docs: ["The user's asset ATA to which asset tokens will be sent."];
name: "userAssetAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "userTransferAuthority" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{ address: "SysvarC1ock11111111111111111111111111111111"; name: "clock" },
{ name: "assetTokenProgram" },
{
address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
name: "lpTokenProgram";
},
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [{ name: "amount"; type: "u64" }];
discriminator: [183, 18, 70, 156, 148, 109, 161, 34];
name: "withdraw";
},
{
accounts: [
{ name: "manager"; signer: true },
{
name: "protocol";
pda: {
seeds: [
{ kind: "const"; value: [112, 114, 111, 116, 111, 99, 111, 108] },
];
};
},
{ name: "vault"; writable: true },
{
name: "adaptorAddReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
97,
100,
100,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "adaptorProgram" },
];
};
},
{
name: "strategyInitReceipt";
pda: {
seeds: [
{
kind: "const";
value: [
115,
116,
114,
97,
116,
101,
103,
121,
95,
105,
110,
105,
116,
95,
114,
101,
99,
101,
105,
112,
116,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "strategy" },
{ name: "adaptorProgram" },
{
name: "vaultAssetIdleAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
97,
115,
115,
101,
116,
95,
105,
100,
108,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
name: "vaultLpFeeAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
102,
101,
101,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{
name: "vaultStrategyAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
115,
116,
114,
97,
116,
101,
103,
121,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "vaultAssetMint"; writable: true },
{
name: "vaultLpMint";
pda: {
seeds: [
{
kind: "const";
value: [118, 97, 117, 108, 116, 95, 108, 112, 95, 109, 105, 110, 116];
},
{ kind: "account"; path: "vault" },
];
};
writable: true;
},
{
docs: ["The vault's associated token account for asset."];
name: "vaultAssetIdleAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultAssetIdleAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultLpFeeAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultLpFeeAuth" },
{ kind: "account"; path: "lpTokenProgram" },
{ kind: "account"; path: "vaultLpMint" },
];
};
writable: true;
},
{
name: "vaultStrategyAssetAta";
pda: {
program: {
kind: "const";
value: [
140,
151,
37,
143,
78,
36,
137,
241,
187,
61,
16,
41,
20,
142,
13,
131,
11,
90,
19,
153,
218,
255,
16,
132,
4,
142,
123,
216,
219,
233,
248,
89,
];
};
seeds: [
{ kind: "account"; path: "vaultStrategyAuth" },
{ kind: "account"; path: "assetTokenProgram" },
{ kind: "account"; path: "vaultAssetMint" },
];
};
writable: true;
},
{
name: "vaultLpMintAuth";
pda: {
seeds: [
{
kind: "const";
value: [
118,
97,
117,
108,
116,
95,
108,
112,
95,
109,
105,
110,
116,
95,
97,
117,
116,
104,
];
},
{ kind: "account"; path: "vault" },
];
};
},
{ name: "assetTokenProgram" },
{
address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
name: "lpTokenProgram";
},
];
args: [
{ name: "amount"; type: "u64" },
{ name: "instructionDiscriminator"; type: { option: "bytes" } },
{ name: "additionalArgs"; type: { option: "bytes" } },
];
discriminator: [31, 45, 162, 5, 193, 217, 134, 188];
name: "withdrawStrategy";
},
]
metadata: {
description: "Created with Anchor";
name: "voltrVault";
spec: "0.1.0";
version: "0.1.0";
}
types: [
{
name: "adaptorAddReceipt";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The vault associated with this strategy."];
name: "vault";
type: "pubkey";
},
{
docs: ["The adapter program address."];
name: "adaptorProgram";
type: "pubkey";
},
{ docs: ["A version number (1 byte)."]; name: "version"; type: "u8" },
{
docs: ["The bump for the adaptor add receipt."];
name: "bump";
type: "u8";
},
{
docs: [
"6 bytes of padding to align future 8-byte fields on 8-byte boundaries.",
];
name: "padding0";
type: { array: ["u8", 6] };
},
{
docs: ["Reserved space for future fields"];
name: "reserved";
type: { array: ["u8", 64] };
},
];
kind: "struct";
};
},
{
name: "feeConfiguration";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["Manager performance fee in basis points (BPS)."];
name: "managerPerformanceFee";
type: "u16";
},
{
docs: ["Admin performance fee in basis points (BPS)."];
name: "adminPerformanceFee";
type: "u16";
},
{
docs: ["Manager management fee in basis points (BPS)."];
name: "managerManagementFee";
type: "u16";
},
{
docs: ["Admin management fee in basis points (BPS)."];
name: "adminManagementFee";
type: "u16";
},
{
docs: ["Reserved bytes for future use."];
name: "reserved";
type: { array: ["u8", 96] };
},
];
kind: "struct";
};
},
{
name: "protocol";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The admin of the protocol."];
name: "admin";
type: "pubkey";
},
{
docs: ["The operational state of the protocol."];
name: "operationalState";
type: "u16";
},
{ docs: ["The fee for the protocol."]; name: "fee"; type: "u16" },
{ docs: ["The bump for the protocol."]; name: "bump"; type: "u8" },
{
docs: [
"1 byte of padding to align future 8-byte fields on 8-byte boundaries.",
];
name: "padding0";
type: { array: ["u8", 1] };
},
{
docs: ["Reserved space for future fields"];
name: "reserved";
type: { array: ["u8", 64] };
},
];
kind: "struct";
};
},
{
name: "strategyInitReceipt";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The vault associated with this strategy."];
name: "vault";
type: "pubkey";
},
{ docs: ["The strategy address."]; name: "strategy"; type: "pubkey" },
{ docs: ["The position value."]; name: "positionValue"; type: "u64" },
{
docs: ["The last updated timestamp."];
name: "lastUpdatedTs";
type: "u64";
},
{ docs: ["A version number (1 byte)."]; name: "version"; type: "u8" },
{
docs: ["The bump for the strategy init receipt."];
name: "bump";
type: "u8";
},
{
docs: ["The bump for the vault strategy auth."];
name: "vaultStrategyAuthBump";
type: "u8";
},
{
docs: [
"6 bytes of padding to align future 8-byte fields on 8-byte boundaries.",
];
name: "padding0";
type: { array: ["u8", 5] };
},
{
docs: ["Reserved space for future fields"];
name: "reserved";
type: { array: ["u8", 64] };
},
];
kind: "struct";
};
},
{
name: "vault";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The vault's name."];
name: "name";
type: { array: ["u8", 32] };
},
{
docs: ["A description or summary for this vault."];
name: "description";
type: { array: ["u8", 64] };
},
{
docs: [
"The vault’s main asset configuration (inline nested struct).",
];
name: "asset";
type: { defined: { name: "vaultAsset" } };
},
{
docs: [
"The vault’s LP (share) configuration (inline nested struct).",
];
name: "lp";
type: { defined: { name: "vaultLp" } };
},
{
docs: ["The manager of this vault (has certain permissions)."];
name: "manager";
type: "pubkey";
},
{
docs: ["The admin of this vault (broader or fallback permissions)."];
name: "admin";
type: "pubkey";
},
{
docs: [
"The vault fee and cap configuration (inline nested struct).",
];
name: "vaultConfiguration";
type: { defined: { name: "vaultConfiguration" } };
},
{
docs: [
"The vault fee and cap configuration (inline nested struct).",
];
name: "feeConfiguration";
type: { defined: { name: "feeConfiguration" } };
},
{
docs: [
"The last time (Unix timestamp) this vault data was updated.",
];
name: "lastUpdatedTs";
type: "u64";
},
{ docs: ["The version of the vault."]; name: "version"; type: "u8" },
{
docs: [
"padding to align future 8-byte fields on 8-byte boundaries.",
];
name: "padding0";
type: { array: ["u8", 7] };
},
{
docs: ["Reserved bytes for future use."];
name: "reserved";
type: { array: ["u8", 256] };
},
];
kind: "struct";
};
},
{
name: "vaultAsset";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The mint for the vault’s main asset."];
name: "mint";
type: "pubkey";
},
{
docs: ["The “idle” token account holding un-invested assets."];
name: "idleAta";
type: "pubkey";
},
{
docs: ["The total amount of this asset currently in the vault."];
name: "totalValue";
type: "u64";
},
{
docs: ["The bump for the vault asset mint."];
name: "idleAtaAuthBump";
type: "u8";
},
{
docs: ["Reserved bytes for future use."];
name: "reserved";
type: { array: ["u8", 95] };
},
];
kind: "struct";
};
},
{
name: "vaultConfiguration";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The maximum total amount allowed in the vault."];
name: "maxCap";
type: "u64";
},
{ docs: ["active from timestamp"]; name: "startAtTs"; type: "u64" },
{
docs: ["Reserved bytes for future use."];
name: "reserved";
type: { array: ["u8", 64] };
},
];
kind: "struct";
};
},
{
name: "vaultInitializationInput";
type: {
fields: [
{
docs: ["The maximum total amount allowed in the vault."];
name: "maxCap";
type: "u64";
},
{ docs: ["active from timestamp"]; name: "startAtTs"; type: "u64" },
{
docs: ["Manager performance fee in basis points (BPS)."];
name: "managerPerformanceFee";
type: "u16";
},
{
docs: ["Admin performance fee in basis points (BPS)."];
name: "adminPerformanceFee";
type: "u16";
},
{
docs: ["Manager management fee in basis points (BPS)."];
name: "managerManagementFee";
type: "u16";
},
{
docs: ["Admin management fee in basis points (BPS)."];
name: "adminManagementFee";
type: "u16";
},
];
kind: "struct";
};
},
{
name: "vaultLp";
repr: { kind: "c" };
serialization: "bytemuckunsafe";
type: {
fields: [
{
docs: ["The LP mint (e.g., representing shares in this vault)."];
name: "mint";
type: "pubkey";
},
{
docs: [
"A fee token account for collecting/receiving fees in LP tokens.",
];
name: "feeAta";
type: "pubkey";
},
{
docs: ["The bump for the vault LP mint."];
name: "mintBump";
type: "u8";
},
{
docs: ["The bump for the vault LP mint authority."];
name: "mintAuthBump";
type: "u8";
},
{
docs: ["The bump for the vault LP fee authority."];
name: "feeAtaAuthBump";
type: "u8";
},
{
docs: ["Reserved bytes for future use."];
name: "reserved";
type: { array: ["u8", 93] };
},
];
kind: "struct";
};
},
]
Program IDL in camelCase format in order to be used in JS/TS.
Note that this is only a type helper and is not the actual IDL. The original IDL can be found at
target/idl/voltr_vault.json
.