VoltrVault: {
accounts: [
{
discriminator: [142, 12, 85, 77, 46, 110, 192, 204];
name: "adaptorStrategy";
},
{ discriminator: [211, 8, 232, 43, 2, 152, 117, 119]; name: "vault" },
];
address: "EwAei87GBsgeLueC7mShT2TNbH3BYumP4RskusxUFBn6";
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 account input."; name: "invalidAccountInput" },
{ code: 6005; msg: "Not rent exempt."; name: "notRentExempt" },
{ code: 6006; msg: "Math overflow."; name: "mathOverflow" },
{ code: 6007; msg: "Max cap exceeded."; name: "maxCapExceeded" },
{ code: 6008; msg: "Strategy not empty."; name: "strategyNotEmpty" },
];
instructions: [
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "admin"; relations: ["vault"]; signer: true },
{ name: "vault"; writable: true },
{
name: "adaptorStrategy";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
115,
116,
114,
97,
116,
101,
103,
121,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "strategy" },
{ name: "adaptorProgram" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [];
discriminator: [64, 123, 127, 227, 192, 234, 198, 20];
name: "addStrategy";
},
{
accounts: [
{ name: "userTransferAuthority"; signer: true },
{ name: "vault"; writable: true },
{ name: "vaultAssetMint" },
{ name: "vaultLpMint"; 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"; relations: ["vault"]; signer: true },
{ name: "vault"; writable: true },
{
name: "adaptorStrategy";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
115,
116,
114,
97,
116,
101,
103,
121,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
},
{ docs: ["CHECK"]; name: "strategy"; writable: true },
{ name: "vaultStrategy"; writable: true },
{ docs: ["CHECK"]; 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: "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: "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: "counterpartyAssetTa"; writable: true },
{ name: "assetTokenProgram" },
{ name: "lpTokenProgram" },
{ name: "protocolProgram" },
];
args: [{ name: "amount"; type: "u64" }];
discriminator: [246, 82, 57, 226, 131, 222, 253, 249];
name: "depositStrategy";
},
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "manager" },
{ name: "admin" },
{ 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: "vaultConfiguration" } } },
{ 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"; relations: ["vault"]; signer: true },
{ name: "vault"; writable: true },
{
name: "adaptorStrategy";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
115,
116,
114,
97,
116,
101,
103,
121,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
},
{ docs: ["CHECK"]; name: "strategy" },
{ name: "vaultStrategy"; writable: true },
{ docs: ["CHECK"]; 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: "protocolProgram" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [];
discriminator: [208, 119, 144, 145, 178, 57, 105, 252];
name: "initializeStrategy";
},
{
accounts: [
{ name: "admin"; relations: ["vault"]; signer: true; writable: true },
{ name: "vault"; writable: true },
{
name: "adaptorStrategy";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
115,
116,
114,
97,
116,
101,
103,
121,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "strategy" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [];
discriminator: [185, 238, 33, 91, 134, 210, 97, 26];
name: "removeStrategy";
},
{
accounts: [
{
docs: [
"The authority that owns the LP tokens and wants to redeem them",
];
name: "userTransferAuthority";
signer: true;
writable: true;
},
{ name: "vault"; writable: true },
{ name: "vaultAssetMint" },
{ name: "vaultLpMint"; 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"; relations: ["vault"]; signer: true },
{ name: "vault"; writable: true },
{
name: "adaptorStrategy";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
115,
116,
114,
97,
116,
101,
103,
121,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
},
{ name: "vaultStrategy"; writable: true },
{ docs: ["CHECK"]; name: "strategy"; writable: true },
{ docs: ["CHECK"]; 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: "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: "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: "counterpartyAssetTa"; writable: true },
{ name: "counterpartyAssetTaAuth"; writable: true },
{ name: "assetTokenProgram" },
{ name: "lpTokenProgram" },
{ name: "protocolProgram" },
];
args: [{ name: "amount"; type: "u64" }];
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: "adaptorStrategy";
type: {
fields: [
{ name: "adaptorProgram"; type: "pubkey" },
{ name: "strategy"; type: "pubkey" },
{ name: "vault"; type: "pubkey" },
];
kind: "struct";
};
},
{
name: "vault";
type: {
fields: [
{ name: "name"; type: { array: ["u8", 32] } },
{ name: "description"; type: { array: ["u8", 64] } },
{ name: "asset"; type: { defined: { name: "vaultAsset" } } },
{ name: "lp"; type: { defined: { name: "vaultLp" } } },
{ name: "manager"; type: "pubkey" },
{ name: "admin"; type: "pubkey" },
{
name: "configuration";
type: { defined: { name: "vaultConfiguration" } };
},
{ name: "lastUpdateSlot"; type: "u64" },
];
kind: "struct";
};
},
{
name: "vaultAsset";
type: {
fields: [
{ name: "assetMint"; type: "pubkey" },
{ name: "idleAta"; type: "pubkey" },
{ name: "totalAmount"; type: "u64" },
];
kind: "struct";
};
},
{
name: "vaultConfiguration";
type: {
fields: [
{ name: "managementFee"; type: "u16" },
{ name: "performanceFee"; type: "u16" },
{ name: "maxCap"; type: "u64" },
];
kind: "struct";
};
},
{
name: "vaultLp";
type: {
fields: [
{ name: "lpMint"; type: "pubkey" },
{ name: "feeAta"; type: "pubkey" },
];
kind: "struct";
};
},
];
}
Type declaration
accounts: [
{
discriminator: [142, 12, 85, 77, 46, 110, 192, 204];
name: "adaptorStrategy";
},
{ discriminator: [211, 8, 232, 43, 2, 152, 117, 119]; name: "vault" },
]
address: "EwAei87GBsgeLueC7mShT2TNbH3BYumP4RskusxUFBn6"
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 account input."; name: "invalidAccountInput" },
{ code: 6005; msg: "Not rent exempt."; name: "notRentExempt" },
{ code: 6006; msg: "Math overflow."; name: "mathOverflow" },
{ code: 6007; msg: "Max cap exceeded."; name: "maxCapExceeded" },
{ code: 6008; msg: "Strategy not empty."; name: "strategyNotEmpty" },
]
instructions: [
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "admin"; relations: ["vault"]; signer: true },
{ name: "vault"; writable: true },
{
name: "adaptorStrategy";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
115,
116,
114,
97,
116,
101,
103,
121,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "strategy" },
{ name: "adaptorProgram" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [];
discriminator: [64, 123, 127, 227, 192, 234, 198, 20];
name: "addStrategy";
},
{
accounts: [
{ name: "userTransferAuthority"; signer: true },
{ name: "vault"; writable: true },
{ name: "vaultAssetMint" },
{ name: "vaultLpMint"; 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"; relations: ["vault"]; signer: true },
{ name: "vault"; writable: true },
{
name: "adaptorStrategy";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
115,
116,
114,
97,
116,
101,
103,
121,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
},
{ docs: ["CHECK"]; name: "strategy"; writable: true },
{ name: "vaultStrategy"; writable: true },
{ docs: ["CHECK"]; 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: "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: "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: "counterpartyAssetTa"; writable: true },
{ name: "assetTokenProgram" },
{ name: "lpTokenProgram" },
{ name: "protocolProgram" },
];
args: [{ name: "amount"; type: "u64" }];
discriminator: [246, 82, 57, 226, 131, 222, 253, 249];
name: "depositStrategy";
},
{
accounts: [
{ name: "payer"; signer: true; writable: true },
{ name: "manager" },
{ name: "admin" },
{ 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: "vaultConfiguration" } } },
{ 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"; relations: ["vault"]; signer: true },
{ name: "vault"; writable: true },
{
name: "adaptorStrategy";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
115,
116,
114,
97,
116,
101,
103,
121,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
},
{ docs: ["CHECK"]; name: "strategy" },
{ name: "vaultStrategy"; writable: true },
{ docs: ["CHECK"]; 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: "protocolProgram" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [];
discriminator: [208, 119, 144, 145, 178, 57, 105, 252];
name: "initializeStrategy";
},
{
accounts: [
{ name: "admin"; relations: ["vault"]; signer: true; writable: true },
{ name: "vault"; writable: true },
{
name: "adaptorStrategy";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
115,
116,
114,
97,
116,
101,
103,
121,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
writable: true;
},
{ name: "strategy" },
{ address: "11111111111111111111111111111111"; name: "systemProgram" },
];
args: [];
discriminator: [185, 238, 33, 91, 134, 210, 97, 26];
name: "removeStrategy";
},
{
accounts: [
{
docs: [
"The authority that owns the LP tokens and wants to redeem them",
];
name: "userTransferAuthority";
signer: true;
writable: true;
},
{ name: "vault"; writable: true },
{ name: "vaultAssetMint" },
{ name: "vaultLpMint"; 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"; relations: ["vault"]; signer: true },
{ name: "vault"; writable: true },
{
name: "adaptorStrategy";
pda: {
seeds: [
{
kind: "const";
value: [
97,
100,
97,
112,
116,
111,
114,
95,
115,
116,
114,
97,
116,
101,
103,
121,
];
},
{ kind: "account"; path: "vault" },
{ kind: "account"; path: "strategy" },
];
};
},
{ name: "vaultStrategy"; writable: true },
{ docs: ["CHECK"]; name: "strategy"; writable: true },
{ docs: ["CHECK"]; 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: "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: "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: "counterpartyAssetTa"; writable: true },
{ name: "counterpartyAssetTaAuth"; writable: true },
{ name: "assetTokenProgram" },
{ name: "lpTokenProgram" },
{ name: "protocolProgram" },
];
args: [{ name: "amount"; type: "u64" }];
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: "adaptorStrategy";
type: {
fields: [
{ name: "adaptorProgram"; type: "pubkey" },
{ name: "strategy"; type: "pubkey" },
{ name: "vault"; type: "pubkey" },
];
kind: "struct";
};
},
{
name: "vault";
type: {
fields: [
{ name: "name"; type: { array: ["u8", 32] } },
{ name: "description"; type: { array: ["u8", 64] } },
{ name: "asset"; type: { defined: { name: "vaultAsset" } } },
{ name: "lp"; type: { defined: { name: "vaultLp" } } },
{ name: "manager"; type: "pubkey" },
{ name: "admin"; type: "pubkey" },
{
name: "configuration";
type: { defined: { name: "vaultConfiguration" } };
},
{ name: "lastUpdateSlot"; type: "u64" },
];
kind: "struct";
};
},
{
name: "vaultAsset";
type: {
fields: [
{ name: "assetMint"; type: "pubkey" },
{ name: "idleAta"; type: "pubkey" },
{ name: "totalAmount"; type: "u64" },
];
kind: "struct";
};
},
{
name: "vaultConfiguration";
type: {
fields: [
{ name: "managementFee"; type: "u16" },
{ name: "performanceFee"; type: "u16" },
{ name: "maxCap"; type: "u64" },
];
kind: "struct";
};
},
{
name: "vaultLp";
type: {
fields: [
{ name: "lpMint"; type: "pubkey" },
{ name: "feeAta"; type: "pubkey" },
];
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
.