UNPKG

goosefx-amm-sdk

Version:

SDK for the GooseFx AMM

2,179 lines (2,178 loc) 136 kB
{ "address": "GAMMA7meSFWaBXF25oSUgmGRwaW6sCMFLmBNiMSdbHVT", "metadata": { "name": "gamma", "version": "0.1.0", "spec": "0.1.0", "description": "Created with Anchor" }, "instructions": [ { "name": "add_partner", "docs": [ "Admin-permissioned instruction to add a new partner to a pool", "", "* `ctx` - The context of accounts", "" ], "discriminator": [ 180, 111, 45, 157, 241, 187, 234, 88 ], "accounts": [ { "name": "authority", "signer": true }, { "name": "amm_config" }, { "name": "pool_state", "writable": true, "relations": [ "partner" ] }, { "name": "pool_partners", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 112, 97, 114, 116, 110, 101, 114, 95, 105, 110, 102, 111, 115 ] }, { "kind": "account", "path": "pool_state" } ] } }, { "name": "partner" } ], "args": [] }, { "name": "calculate_rewards", "docs": [ "Calculate rewards for the user", "", "* `ctx` - The context of accounts", "" ], "discriminator": [ 199, 115, 201, 124, 71, 81, 143, 252 ], "accounts": [ { "name": "signer", "writable": true, "signer": true }, { "name": "user", "docs": [ "User for which we are calculating rewards" ] }, { "name": "pool_state" }, { "name": "reward_info", "pda": { "seeds": [ { "kind": "const", "value": [ 114, 101, 119, 97, 114, 100, 95, 105, 110, 102, 111, 95, 115, 101, 101, 100 ] }, { "kind": "account", "path": "pool_state" }, { "kind": "account", "path": "reward_info.start_at", "account": "RewardInfo" }, { "kind": "account", "path": "reward_info.mint", "account": "RewardInfo" } ] } }, { "name": "user_reward_info", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 117, 115, 101, 114, 95, 114, 101, 119, 97, 114, 100, 95, 105, 110, 102, 111, 95, 115, 101, 101, 100 ] }, { "kind": "account", "path": "reward_info" }, { "kind": "account", "path": "user" } ] } }, { "name": "user_pool_liquidity", "docs": [ "User pool liquidity account" ], "pda": { "seeds": [ { "kind": "const", "value": [ 117, 115, 101, 114, 45, 112, 111, 111, 108, 45, 108, 105, 113, 117, 105, 100, 105, 116, 121 ] }, { "kind": "account", "path": "pool_state" }, { "kind": "account", "path": "user" } ] } }, { "name": "system_program", "address": "11111111111111111111111111111111" } ], "args": [] }, { "name": "claim_partner_fees", "docs": [ "Claim fees for a particular partner", "", "* `ctx` - The context of accounts", "" ], "discriminator": [ 114, 71, 103, 57, 160, 205, 242, 185 ], "accounts": [ { "name": "partner" }, { "name": "authority", "pda": { "seeds": [ { "kind": "const", "value": [ 118, 97, 117, 108, 116, 95, 97, 110, 100, 95, 108, 112, 95, 109, 105, 110, 116, 95, 97, 117, 116, 104, 95, 115, 101, 101, 100 ] } ] } }, { "name": "pool_state" }, { "name": "token_0_vault", "docs": [ "The address that holds pool tokens for token_0" ], "writable": true }, { "name": "token_1_vault", "docs": [ "The address that holds pool tokens for token_1" ], "writable": true }, { "name": "vault_0_mint", "docs": [ "The mint of token_0 vault" ] }, { "name": "vault_1_mint", "docs": [ "The mint of token_1 vault" ] }, { "name": "pool_partners", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 112, 97, 114, 116, 110, 101, 114, 95, 105, 110, 102, 111, 115 ] }, { "kind": "account", "path": "pool_state" } ] } }, { "name": "token_0_token_account", "writable": true, "relations": [ "partner" ] }, { "name": "token_1_token_account", "writable": true, "relations": [ "partner" ] }, { "name": "token_program", "docs": [ "The SPL program to perform token transfers" ], "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" }, { "name": "token_program_2022", "docs": [ "The SPL program 2022 to perform token transfers" ], "address": "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb" } ], "args": [] }, { "name": "claim_rewards", "docs": [ "Claim rewards for the user", "Transfers the amount of tokens calculated for the user to their reward token account", "", "# Arguments", "", "* `ctx` - The context of accounts", "" ], "discriminator": [ 4, 144, 132, 71, 116, 23, 151, 80 ], "accounts": [ { "name": "user", "writable": true, "signer": true }, { "name": "authority", "pda": { "seeds": [ { "kind": "const", "value": [ 118, 97, 117, 108, 116, 95, 97, 110, 100, 95, 108, 112, 95, 109, 105, 110, 116, 95, 97, 117, 116, 104, 95, 115, 101, 101, 100 ] } ] } }, { "name": "pool_state" }, { "name": "reward_info", "pda": { "seeds": [ { "kind": "const", "value": [ 114, 101, 119, 97, 114, 100, 95, 105, 110, 102, 111, 95, 115, 101, 101, 100 ] }, { "kind": "account", "path": "pool_state" }, { "kind": "account", "path": "reward_info.start_at", "account": "RewardInfo" }, { "kind": "account", "path": "reward_info.mint", "account": "RewardInfo" } ] } }, { "name": "reward_vault", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 114, 101, 119, 97, 114, 100, 95, 118, 97, 117, 108, 116, 95, 115, 101, 101, 100 ] }, { "kind": "account", "path": "reward_info" } ] } }, { "name": "user_token_account", "writable": true }, { "name": "user_reward_info", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 117, 115, 101, 114, 95, 114, 101, 119, 97, 114, 100, 95, 105, 110, 102, 111, 95, 115, 101, 101, 100 ] }, { "kind": "account", "path": "reward_info" }, { "kind": "account", "path": "user" } ] } }, { "name": "reward_mint", "writable": true }, { "name": "token_program", "docs": [ "token Program" ], "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" }, { "name": "token_program_2022", "docs": [ "Token program 2022" ], "address": "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb" }, { "name": "system_program", "address": "11111111111111111111111111111111" } ], "args": [] }, { "name": "collect_fund_fee", "docs": [ "Collect the fund fee accrued to the pool", "", "# Arguments", "", "* `ctx` - The context of accounts", "* `amount_0_requested` - The maximum amount of token_0 to send, can be 0 to collect fees in only token_1", "* `amount_1_requested` - The maximum amount of token_1 to send, can be 0 to collect fees in only token_0", "" ], "discriminator": [ 167, 138, 78, 149, 223, 194, 6, 126 ], "accounts": [ { "name": "owner", "docs": [ "Only admin or fund_owner can collect fee now" ], "signer": true }, { "name": "authority", "pda": { "seeds": [ { "kind": "const", "value": [ 118, 97, 117, 108, 116, 95, 97, 110, 100, 95, 108, 112, 95, 109, 105, 110, 116, 95, 97, 117, 116, 104, 95, 115, 101, 101, 100 ] } ] } }, { "name": "pool_state", "docs": [ "Pool state stores accumulated protocol fee amount" ], "writable": true }, { "name": "amm_config", "docs": [ "Amm config account stores fund_owner" ] }, { "name": "token_0_vault", "docs": [ "The address that holds pool tokens for token_0" ], "writable": true }, { "name": "token_1_vault", "docs": [ "The address that holds pool tokens for token_1" ], "writable": true }, { "name": "vault_0_mint", "docs": [ "The mint of token_0 vault" ] }, { "name": "vault_1_mint", "docs": [ "The mint of token_1 vault" ] }, { "name": "recipient_token_0_account", "docs": [ "The address that receives the collected token_0 fund fees" ], "writable": true }, { "name": "recipient_token_1_account", "docs": [ "The address that receives the collected token_1 fund fees" ], "writable": true }, { "name": "token_program", "docs": [ "The SPL program to perform token transfers" ], "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" }, { "name": "token_program_2022", "docs": [ "The SPL program 2022 to perform token transfers" ], "address": "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb" } ], "args": [ { "name": "amount_0_requested", "type": "u64" }, { "name": "amount_1_requested", "type": "u64" } ] }, { "name": "collect_protocol_fee", "docs": [ "Collect the protocol fee accrued to the pool", "", "# Arguments", "", "* `ctx` - The context of accounts", "* `amount_0_requested` - The maximum amount of token_0 to send, can be 0 to collect fees in only token_1", "* `amount_1_requested` - The maximum amount of token_1 to send, can be 0 to collect fees in only token_0", "" ], "discriminator": [ 136, 136, 252, 221, 194, 66, 126, 89 ], "accounts": [ { "name": "owner", "docs": [ "Only admin or owner can collect fee now" ], "signer": true }, { "name": "authority", "pda": { "seeds": [ { "kind": "const", "value": [ 118, 97, 117, 108, 116, 95, 97, 110, 100, 95, 108, 112, 95, 109, 105, 110, 116, 95, 97, 117, 116, 104, 95, 115, 101, 101, 100 ] } ] } }, { "name": "pool_state", "docs": [ "Pool state stores accumulated protocol fee amount" ], "writable": true }, { "name": "amm_config", "docs": [ "Amm config account stores owner" ] }, { "name": "token_0_vault", "docs": [ "The address that holds pool tokens for token_0" ], "writable": true }, { "name": "token_1_vault", "docs": [ "The address that holds pool tokens for token_1" ], "writable": true }, { "name": "vault_0_mint", "docs": [ "The mint of token_0 vault" ] }, { "name": "vault_1_mint", "docs": [ "The mint of token_1 vault" ] }, { "name": "recipient_token_0_account", "docs": [ "The address that receives the collected token_0 protocol fees" ], "writable": true }, { "name": "recipient_token_1_account", "docs": [ "The address that receives the collected token_1 protocol fees" ], "writable": true }, { "name": "token_program", "docs": [ "The SPL program to perform token transfers" ], "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" }, { "name": "token_program_2022", "docs": [ "The SPL program 2022 to perform token transfers" ], "address": "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb" } ], "args": [ { "name": "amount_0_requested", "type": "u64" }, { "name": "amount_1_requested", "type": "u64" } ] }, { "name": "create_amm_config", "docs": [ "The configuation of AMM protocol, include trade fee and protocol fee", "# Arguments", "", "* `ctx`- The accounts needed by instruction.", "* `index` - The index of amm config, there may be multiple config.", "* `trade_fee_rate` - Trade fee rate, can be changed.", "* `protocol_fee_rate` - The rate of protocol fee within tarde fee.", "* `fund_fee_rate` - The rate of fund fee within tarde fee.", "" ], "discriminator": [ 137, 52, 237, 212, 215, 117, 108, 104 ], "accounts": [ { "name": "owner", "docs": [ "Address to be set as protocol owner." ], "writable": true, "signer": true, "address": "9QcHinaHcJFdzSHeiF1yGchcuQk3qPFNV13q6dZJbAny" }, { "name": "amm_config", "docs": [ "Initialize AmmConfig state account to store protocol owner address and fee rates" ], "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 97, 109, 109, 95, 99, 111, 110, 102, 105, 103 ] }, { "kind": "arg", "path": "index" } ] } }, { "name": "system_program", "address": "11111111111111111111111111111111" } ], "args": [ { "name": "index", "type": "u16" }, { "name": "trade_fee_rate", "type": "u64" }, { "name": "protocol_fee_rate", "type": "u64" }, { "name": "fund_fee_rate", "type": "u64" }, { "name": "create_pool_fee", "type": "u64" }, { "name": "max_open_time", "type": "u64" } ] }, { "name": "create_rewards", "docs": [ "Create rewards for the pool", "Initializes a new reward info account and a reward vault account", "Transfers the rewards to the reward vault", "", "# Arguments", "", "* `ctx` - The context of accounts", "* `start_time` - The start time of the reward", "* `end_time` - The end time of the reward", "* `reward_amount` - The amount of the reward", "" ], "discriminator": [ 124, 251, 145, 232, 5, 173, 159, 223 ], "accounts": [ { "name": "reward_provider", "writable": true, "signer": true }, { "name": "authority", "pda": { "seeds": [ { "kind": "const", "value": [ 118, 97, 117, 108, 116, 95, 97, 110, 100, 95, 108, 112, 95, 109, 105, 110, 116, 95, 97, 117, 116, 104, 95, 115, 101, 101, 100 ] } ] } }, { "name": "pool_state" }, { "name": "reward_info", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 114, 101, 119, 97, 114, 100, 95, 105, 110, 102, 111, 95, 115, 101, 101, 100 ] }, { "kind": "account", "path": "pool_state" }, { "kind": "arg", "path": "start_time" }, { "kind": "account", "path": "reward_mint" } ] } }, { "name": "reward_providers_token_account", "writable": true }, { "name": "reward_vault", "docs": [ "For reward to deposit into." ], "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 114, 101, 119, 97, 114, 100, 95, 118, 97, 117, 108, 116, 95, 115, 101, 101, 100 ] }, { "kind": "account", "path": "reward_info" } ] } }, { "name": "reward_mint", "writable": true }, { "name": "token_program", "docs": [ "token Program" ], "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" }, { "name": "token_program_2022", "docs": [ "Token program 2022" ], "address": "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb" }, { "name": "system_program", "address": "11111111111111111111111111111111" } ], "args": [ { "name": "start_time", "type": "u64" }, { "name": "end_time", "type": "u64" }, { "name": "reward_amount", "type": "u64" } ] }, { "name": "create_swap_referral", "docs": [ "Initialize swap referrals for an existing AMM config", "# Arguments", "", "* `ctx` - The accounts needed by the instruction, including those used by cpi to the referral program", "* `name` - The project name, passed to the referral program. Must be less than 50 chars in length", "* `default_share_bps` - Percentage share of fees to referrers. Must be less than 10_000" ], "discriminator": [ 67, 131, 93, 236, 56, 6, 40, 77 ], "accounts": [ { "name": "admin", "docs": [ "Admin signer for this operation" ], "signer": true }, { "name": "owner", "address": "9QcHinaHcJFdzSHeiF1yGchcuQk3qPFNV13q6dZJbAny" }, { "name": "payer", "writable": true, "signer": true }, { "name": "amm_config", "docs": [ "The config acts as the base for its referral project" ], "writable": true }, { "name": "project", "writable": true }, { "name": "system_program", "address": "11111111111111111111111111111111" }, { "name": "referral_program", "address": "REFER4ZgmyYx9c6He5XfaTMiGfdLwRnkV4RPp9t9iF3" } ], "args": [ { "name": "name", "type": "string" }, { "name": "default_share_bps", "type": "u16" } ] }, { "name": "deposit", "docs": [ "Creates a pool for the given token pair and the initial price", "", "# Arguments", "", "* `ctx`- The context of accounts", "* `lp_token_amount` - Pool token amount to transfer. token_a and token_b amount are set by the current exchange rate and size of the pool", "* `maximum_token_0_amount` - Maximum token 0 amount to deposit, prevents excessive slippage", "* `maximum_token_1_amount` - Maximum token 1 amount to deposit, prevents excessive slippage", "" ], "discriminator": [ 242, 35, 198, 137, 82, 225, 242, 182 ], "accounts": [ { "name": "owner", "docs": [ "Owner of the liquidity provided" ], "signer": true }, { "name": "authority", "pda": { "seeds": [ { "kind": "const", "value": [ 118, 97, 117, 108, 116, 95, 97, 110, 100, 95, 108, 112, 95, 109, 105, 110, 116, 95, 97, 117, 116, 104, 95, 115, 101, 101, 100 ] } ] } }, { "name": "pool_state", "docs": [ "Pool state the owner is depositing into" ], "writable": true }, { "name": "user_pool_liquidity", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 117, 115, 101, 114, 45, 112, 111, 111, 108, 45, 108, 105, 113, 117, 105, 100, 105, 116, 121 ] }, { "kind": "account", "path": "pool_state" }, { "kind": "account", "path": "owner" } ] } }, { "name": "token_0_account", "docs": [ "The payer's token account to deposit token_0" ], "writable": true }, { "name": "token_1_account", "docs": [ "The payer's token account to deposit token_1" ], "writable": true }, { "name": "token_0_vault", "docs": [ "Pool vault for token_0 to deposit into", "The address that holds pool tokens for token_0" ], "writable": true }, { "name": "token_1_vault", "docs": [ "Pool vault for token_1 to deposit into", "The address that holds pool tokens for token_1" ], "writable": true }, { "name": "token_program", "docs": [ "token Program" ], "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" }, { "name": "token_program_2022", "docs": [ "Token program 2022" ], "address": "TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb" }, { "name": "vault_0_mint", "docs": [ "The mint of token_0 vault" ] }, { "name": "vault_1_mint", "docs": [ "The mint of token_1 vault" ] }, { "name": "pool_partners", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 112, 97, 114, 116, 110, 101, 114, 95, 105, 110, 102, 111, 115 ] }, { "kind": "account", "path": "pool_state" } ] } } ], "args": [ { "name": "lp_token_amount", "type": "u64" }, { "name": "maximum_token_0_amount", "type": "u64" }, { "name": "maximum_token_1_amount", "type": "u64" } ] }, { "name": "init_user_pool_liquidity", "discriminator": [ 227, 221, 200, 212, 36, 107, 149, 36 ], "accounts": [ { "name": "user", "writable": true, "signer": true }, { "name": "pool_state" }, { "name": "user_pool_liquidity", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 117, 115, 101, 114, 45, 112, 111, 111, 108, 45, 108, 105, 113, 117, 105, 100, 105, 116, 121 ] }, { "kind": "account", "path": "pool_state" }, { "kind": "account", "path": "user" } ] } }, { "name": "pool_partners", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 112, 97, 114, 116, 110, 101, 114, 95, 105, 110, 102, 111, 115 ] }, { "kind": "account", "path": "pool_state" } ] } }, { "name": "system_program", "docs": [ "To create a new program account" ], "address": "11111111111111111111111111111111" } ], "args": [ { "name": "partner", "type": { "option": "pubkey" } } ] }, { "name": "initialize", "docs": [ "Creates a pool for the given token pair and the initial price", "", "# Arguments", "", "* `ctx`- The context of accounts", "* `init_amount_0` - the initial amount_0 to deposit", "* `init_amount_1` - the initial amount_1 to deposit", "* `open_time` - the timestamp allowed for swap", "* `max_trade_fee_rate` - The maximum trade fee that can be charged on swaps", "* `volatility_factor` - The volatility factor of the pool to determine the trade fee", "" ], "discriminator": [ 175, 175, 109, 31, 13, 152, 155, 237 ], "accounts": [ { "name": "creator", "docs": [ "Address paying to create the pool. It can be anyone." ], "writable": true, "signer": true }, { "name": "amm_config", "docs": [ "Which amm config the pool belongs to" ] }, { "name": "authority", "docs": [ "sign transactions on behalf of the pool", "for vault and lp_mint" ], "pda": { "seeds": [ { "kind": "const", "value": [ 118, 97, 117, 108, 116, 95, 97, 110, 100, 95, 108, 112, 95, 109, 105, 110, 116, 95, 97, 117, 116, 104, 95, 115, 101, 101, 100 ] } ] } }, { "name": "pool_state", "docs": [ "Initialize an account to store the pool state" ], "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 112, 111, 111, 108 ] }, { "kind": "account", "path": "amm_config" }, { "kind": "account", "path": "token_0_mint" }, { "kind": "account", "path": "token_1_mint" } ] } }, { "name": "user_pool_liquidity", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 117, 115, 101, 114, 45, 112, 111, 111, 108, 45, 108, 105, 113, 117, 105, 100, 105, 116, 121 ] }, { "kind": "account", "path": "pool_state" }, { "kind": "account", "path": "creator" } ] } }, { "name": "token_0_mint", "docs": [ "Token_0 mint, the key must smaller than token_1 mint." ] }, { "name": "token_1_mint", "docs": [ "Token_1 mint, the key must greater than token_0 mint." ] }, { "name": "creator_token_0", "docs": [ "creator token 0 account" ], "writable": true }, { "name": "creator_token_1", "docs": [ "creator token 1 account" ], "writable": true }, { "name": "token_0_vault", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 112, 111, 111, 108, 95, 118, 97, 117, 108, 116 ] }, { "kind": "account", "path": "pool_state" }, { "kind": "account", "path": "token_0_mint" } ] } }, { "name": "token_1_vault", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 112, 111, 111, 108, 95, 118, 97, 117, 108, 116 ] }, { "kind": "account", "path": "pool_state" }, { "kind": "account", "path": "token_1_mint" } ] } }, { "name": "create_pool_fee", "docs": [ "create pool fee account" ], "writable": true, "address": "8PhehuioLjhJ35A5eavazJSwoXcA4J7WwzgoWDBDFSuY" }, { "name": "observation_state", "docs": [ "an account to store oracle observations" ], "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 111, 98, 115, 101, 114, 118, 97, 116, 105, 111, 110 ] }, { "kind": "account", "path": "pool_state" } ] } }, { "name": "pool_partners", "docs": [ "account storing partner infos" ], "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 112, 97, 114, 116, 110, 101, 114, 95, 105, 110, 102, 111, 115 ] }, { "kind": "account", "path": "pool_state" } ] } }, { "name": "token_program", "docs": [ "Program to create mint account and mint tokens" ], "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" }, { "name": "token_0_program", "docs": [ "Spl token program or token program 2022" ] }, { "name": "token_1_program", "docs": [ "Spl token program or token program 2022" ] }, { "name": "associated_token_program", "docs": [ "Program to create an ATA for receiving position NFT" ], "address": "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL" }, { "name": "system_program", "docs": [ "To create a new program account" ], "address": "11111111111111111111111111111111" }, { "name": "rent", "docs": [ "Sysvar for program account" ], "address": "SysvarRent111111111111111111111111111111111" } ], "args": [ { "name": "init_amount_0", "type": "u64" }, { "name": "init_amount_1", "type": "u64" }, { "name": "open_time", "type": "u64" }, { "name": "max_trade_fee_rate", "type": "u64" }, { "name": "volatility_factor", "type": "u64" } ] }, { "name": "initialize_partner", "docs": [ "Creates a new `Partner` account associated with a certain pool", "", "* `ctx` - The context of accounts", "* `name` - The name associated with the partner", "* `token_0_token_account` - Token account for receiving token0 tokens", "* `token_1_token_account` - Token account for receiving token1 tokens", "" ], "discriminator": [ 165, 62, 179, 112, 129, 50, 173, 144 ], "accounts": [ { "name": "payer", "writable": true, "signer": true }, { "name": "authority", "signer": true }, { "name": "pool_state" }, { "name": "pool_partners", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 112, 97, 114, 116, 110, 101, 114, 95, 105, 110, 102, 111, 115 ] }, { "kind": "account", "path": "pool_state" } ] } }, { "name": "partner", "writable": true, "signer": true }, { "name": "system_program", "address": "11111111111111111111111111111111" } ], "args": [ { "name": "name", "type": "string" }, { "name": "token_0_token_account", "type": "pubkey" }, { "name": "token_1_token_account", "type": "pubkey" } ] }, { "name": "initialize_pool_partners", "docs": [ "Initializes a new `PoolPartnerInfos` account unique to a particular pool", "", "* `ctx` - The context of accounts", "* `partner_share_rate` - A fraction representing the partner's share of protocol fees", "" ], "discriminator": [ 99, 11, 108, 186, 1, 126, 209, 251 ], "accounts": [ { "name": "payer", "writable": true, "signer": true }, { "name": "pool_state", "writable": true }, { "name": "pool_partners", "writable": true, "pda": { "seeds": [ { "kind": "const", "value": [ 112, 97, 114, 116, 110, 101, 114, 95, 105, 110, 102, 111, 115 ] }, { "kind": "account", "path": "pool_state" } ] } }, { "name": "system_program", "address": "11111111111111111111111111111111" } ], "args": [ { "name": "partner_share_rate", "type": "u64" } ] }, { "name": "migrate_meteora_dlmm_to_gamma", "docs": [ "Migrate from Meteora Dlmm to Gamma" ], "discriminator": [ 166, 33, 209, 228, 15, 46, 252, 67 ], "accounts": [ { "name": "dlmm_position", "writable": true }, { "name": "dlmm_lb_pair", "writable": true }, { "name": "dlmm_bin_array_bitmap_extension", "writable": true, "optional": true }, { "name": "dlmm_reserve_x", "writable": true }, { "name": "dlmm_reserve_y", "writable": true }, { "name": "dlmm_bin_array_lower", "writable": true }, { "name": "dlmm_bin_array_upper", "writable": true }, { "name": "dlmm_program", "address": "LBUZKhRxPF3XUpBCjp4YzTKgLccjZhTSDM9YuVaPwxo" },