{
  "address": "DumpFunGAgW6kPHzWMA3Nnqecyrd6SGnLZvNGp2aHwEa",
  "metadata": { "name": "dump_contract", "version": "0.1.0", "spec": "0.1.0", "description": "Created with Anchor" },
  "instructions": [
    {
      "name": "buy_exact_tokens",
      "discriminator": [129, 145, 209, 75, 88, 169, 142, 8],
      "accounts": [
        { "name": "user", "writable": true, "signer": true },
        { "name": "platform_fee_wallet", "writable": true },
        { "name": "mint_account", "writable": true },
        {
          "name": "liquidity_pool",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "mint_account" },
              { "kind": "const", "value": [108, 105, 113, 117, 105, 100, 105, 116, 121] }
            ]
          }
        },
        {
          "name": "liquidity_pool_authority",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "liquidity_pool" },
              { "kind": "account", "path": "mint_account" },
              { "kind": "const", "value": [97, 117, 116, 104, 111, 114, 105, 116, 121] }
            ]
          }
        },
        {
          "name": "liquidity_pool_token_account",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "liquidity_pool_authority" },
              { "kind": "account", "path": "token_program" },
              { "kind": "account", "path": "mint_account" }
            ],
            "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
              ]
            }
          }
        },
        {
          "name": "user_token_account",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "user" },
              { "kind": "account", "path": "token_program" },
              { "kind": "account", "path": "mint_account" }
            ],
            "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
              ]
            }
          }
        },
        { "name": "token_program", "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" },
        { "name": "associated_token_program", "address": "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL" },
        { "name": "system_program", "address": "11111111111111111111111111111111" },
        { "name": "rent", "address": "SysvarRent111111111111111111111111111111111" }
      ],
      "args": [
        { "name": "token_out", "type": "u64" },
        { "name": "max_sol_in", "type": "u64" }
      ]
    },
    {
      "name": "buy_tokens_with_exact_sol",
      "discriminator": [107, 198, 250, 226, 105, 48, 89, 135],
      "accounts": [
        { "name": "user", "writable": true, "signer": true },
        { "name": "platform_fee_wallet", "writable": true },
        { "name": "mint_account", "writable": true },
        {
          "name": "liquidity_pool",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "mint_account" },
              { "kind": "const", "value": [108, 105, 113, 117, 105, 100, 105, 116, 121] }
            ]
          }
        },
        {
          "name": "liquidity_pool_authority",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "liquidity_pool" },
              { "kind": "account", "path": "mint_account" },
              { "kind": "const", "value": [97, 117, 116, 104, 111, 114, 105, 116, 121] }
            ]
          }
        },
        {
          "name": "liquidity_pool_token_account",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "liquidity_pool_authority" },
              { "kind": "account", "path": "token_program" },
              { "kind": "account", "path": "mint_account" }
            ],
            "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
              ]
            }
          }
        },
        {
          "name": "user_token_account",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "user" },
              { "kind": "account", "path": "token_program" },
              { "kind": "account", "path": "mint_account" }
            ],
            "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
              ]
            }
          }
        },
        { "name": "token_program", "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" },
        { "name": "associated_token_program", "address": "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL" },
        { "name": "system_program", "address": "11111111111111111111111111111111" },
        { "name": "rent", "address": "SysvarRent111111111111111111111111111111111" }
      ],
      "args": [
        { "name": "sol_in", "type": "u64" },
        { "name": "min_token_out", "type": "u64" }
      ]
    },
    {
      "name": "drain_pool_surplus",
      "discriminator": [172, 123, 233, 0, 98, 159, 144, 191],
      "accounts": [
        {
          "name": "creator_wallet",
          "docs": ["Creator wallet - must be signer and match pool creator"],
          "writable": true,
          "signer": true
        },
        {
          "name": "company_wallet",
          "docs": ["Company wallet - receives remainder from 50/50 split"],
          "writable": true
        },
        { "name": "mint_account", "docs": ["Mint account for the token"], "writable": true },
        {
          "name": "liquidity_pool",
          "docs": ["Liquidity pool account"],
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "mint_account" },
              { "kind": "const", "value": [108, 105, 113, 117, 105, 100, 105, 116, 121] }
            ]
          }
        },
        {
          "name": "liquidity_pool_authority",
          "docs": ["Liquidity pool authority PDA"],
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "liquidity_pool" },
              { "kind": "account", "path": "mint_account" },
              { "kind": "const", "value": [97, 117, 116, 104, 111, 114, 105, 116, 121] }
            ]
          }
        },
        {
          "name": "system_program",
          "docs": ["System program for SOL transfers"],
          "address": "11111111111111111111111111111111"
        }
      ],
      "args": []
    },
    {
      "name": "mint",
      "discriminator": [51, 57, 225, 47, 182, 146, 137, 166],
      "accounts": [
        { "name": "payer", "writable": true, "signer": true },
        {
          "name": "metadata_account",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "const", "value": [109, 101, 116, 97, 100, 97, 116, 97] },
              { "kind": "account", "path": "token_metadata_program" },
              { "kind": "account", "path": "mint_account" }
            ],
            "program": { "kind": "account", "path": "token_metadata_program" }
          }
        },
        { "name": "mint_account", "writable": true, "signer": true },
        {
          "name": "liquidity_pool",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "mint_account" },
              { "kind": "const", "value": [108, 105, 113, 117, 105, 100, 105, 116, 121] }
            ]
          }
        },
        {
          "name": "liquidity_pool_authority",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "liquidity_pool" },
              { "kind": "account", "path": "mint_account" },
              { "kind": "const", "value": [97, 117, 116, 104, 111, 114, 105, 116, 121] }
            ]
          }
        },
        {
          "name": "liquidity_pool_token_account",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "liquidity_pool_authority" },
              { "kind": "account", "path": "token_program" },
              { "kind": "account", "path": "mint_account" }
            ],
            "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
              ]
            }
          }
        },
        { "name": "token_metadata_program", "address": "metaqbxxUerdq28cj1RbAWkYQm3ybzjb6a8bt518x1s" },
        { "name": "token_program", "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" },
        { "name": "associated_token_program", "address": "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL" },
        { "name": "system_program", "address": "11111111111111111111111111111111" },
        { "name": "rent", "address": "SysvarRent111111111111111111111111111111111" }
      ],
      "args": [
        { "name": "token_name", "type": "string" },
        { "name": "token_symbol", "type": "string" },
        { "name": "token_uri", "type": "string" },
        { "name": "sell_lock_period", "type": "i64" },
        { "name": "virtual_sol_reserve", "type": "u64" },
        { "name": "ramping_limits", "type": { "vec": { "defined": { "name": "RampingLimit" } } } }
      ]
    },
    {
      "name": "sell_exact_tokens",
      "discriminator": [34, 198, 103, 105, 28, 0, 138, 92],
      "accounts": [
        { "name": "user", "writable": true, "signer": true },
        { "name": "platform_fee_wallet", "writable": true },
        { "name": "company_tax_wallet", "writable": true },
        { "name": "creator_wallet", "writable": true },
        { "name": "mint_account", "writable": true },
        {
          "name": "liquidity_pool",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "mint_account" },
              { "kind": "const", "value": [108, 105, 113, 117, 105, 100, 105, 116, 121] }
            ]
          }
        },
        {
          "name": "liquidity_pool_authority",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "liquidity_pool" },
              { "kind": "account", "path": "mint_account" },
              { "kind": "const", "value": [97, 117, 116, 104, 111, 114, 105, 116, 121] }
            ]
          }
        },
        {
          "name": "liquidity_pool_token_account",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "liquidity_pool_authority" },
              { "kind": "account", "path": "token_program" },
              { "kind": "account", "path": "mint_account" }
            ],
            "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
              ]
            }
          }
        },
        {
          "name": "user_token_account",
          "writable": true,
          "pda": {
            "seeds": [
              { "kind": "account", "path": "user" },
              { "kind": "account", "path": "token_program" },
              { "kind": "account", "path": "mint_account" }
            ],
            "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
              ]
            }
          }
        },
        { "name": "token_program", "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA" },
        { "name": "associated_token_program", "address": "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL" },
        { "name": "system_program", "address": "11111111111111111111111111111111" },
        { "name": "rent", "address": "SysvarRent111111111111111111111111111111111" }
      ],
      "args": [
        { "name": "token_in", "type": "u64" },
        { "name": "min_sol_out", "type": "u64" }
      ]
    }
  ],
  "accounts": [{ "name": "LiquidityPool", "discriminator": [66, 38, 17, 64, 188, 80, 68, 129] }],
  "events": [
    { "name": "BuyTokenEvent", "discriminator": [90, 138, 104, 84, 222, 143, 82, 123] },
    { "name": "DrainPoolEvent", "discriminator": [116, 220, 198, 208, 98, 61, 234, 65] },
    { "name": "SellTokenEvent", "discriminator": [148, 185, 126, 171, 239, 120, 196, 178] },
    { "name": "TokenCreatedEvent", "discriminator": [96, 122, 113, 138, 50, 227, 149, 57] }
  ],
  "errors": [
    { "code": 6000, "name": "InsufficientBalance", "msg": "Insufficient balance" },
    { "code": 6001, "name": "InsufficientOutput", "msg": "Insufficient output amount" },
    { "code": 6002, "name": "InvalidSellLockPeriod", "msg": "Invalid sell lock period" },
    { "code": 6003, "name": "RampLimitExceeded", "msg": "Ramp limit exceeded" },
    { "code": 6004, "name": "ExcessiveInputAmount", "msg": "Excessive input amount" },
    { "code": 6005, "name": "SellNotUnlocked", "msg": "Sell not unlocked" },
    { "code": 6006, "name": "TooManyRampingLimits", "msg": "Too many ramping limits (max 4 allowed)" },
    {
      "code": 6007,
      "name": "InvalidRampingLimitTime",
      "msg": "Invalid ramping limit time (start_sec must be >= 0 and end_sec > start_sec)"
    },
    {
      "code": 6008,
      "name": "InvalidRampingLimitBps",
      "msg": "Invalid ramping limit bps (must be > 0 and <= 10000)"
    },
    { "code": 6009, "name": "OverlappingRampingLimits", "msg": "Overlapping ramping limit periods" },
    {
      "code": 6010,
      "name": "ExcessiveRampingLimitTime",
      "msg": "Excessive ramping limit time (total time must be <= 1/5 of sell unlock time)"
    },
    { "code": 6011, "name": "RampingLimitExceedsUnlockTime", "msg": "Ramping limit exceeds unlock time" },
    { "code": 6012, "name": "InvalidVirtualSolReserve", "msg": "Invalid virtual SOL reserve" },
    { "code": 6013, "name": "InvalidFeeRate", "msg": "Invalid fee rate" },
    { "code": 6014, "name": "MathOverflow", "msg": "Math overflow" },
    { "code": 6015, "name": "InvalidTokenAccount", "msg": "Invalid token account" },
    { "code": 6016, "name": "Reentrancy", "msg": "Reentrancy" },
    { "code": 6017, "name": "PoolClosed", "msg": "Liquidity pool closed" }
  ],
  "types": [
    {
      "name": "BuyTokenEvent",
      "type": {
        "kind": "struct",
        "fields": [
          { "name": "user", "docs": ["The public key of the user"], "type": "pubkey" },
          { "name": "mint", "docs": ["The public key of the token"], "type": "pubkey" },
          { "name": "sol_in", "docs": ["The amount of sol in"], "type": "u64" },
          { "name": "token_out", "docs": ["The amount of token out"], "type": "u64" },
          { "name": "buy_time", "docs": ["The timestamp of when the token was bought"], "type": "i64" }
        ]
      }
    },
    {
      "name": "DrainPoolEvent",
      "type": {
        "kind": "struct",
        "fields": [
          { "name": "pool", "docs": ["The public key of the liquidity pool"], "type": "pubkey" },
          { "name": "mint", "docs": ["The public key of the mint"], "type": "pubkey" },
          { "name": "creator_wallet", "docs": ["The public key of the creator wallet"], "type": "pubkey" },
          { "name": "company_wallet", "docs": ["The public key of the company wallet"], "type": "pubkey" },
          { "name": "creator_amount", "docs": ["The amount sent to creator (rounded down)"], "type": "u64" },
          { "name": "company_amount", "docs": ["The amount sent to company (remainder)"], "type": "u64" },
          { "name": "total_drained", "docs": ["The total amount drained"], "type": "u64" },
          { "name": "drain_time", "docs": ["The timestamp of when the pool was drained"], "type": "i64" }
        ]
      }
    },
    {
      "name": "LiquidityPool",
      "type": {
        "kind": "struct",
        "fields": [
          { "name": "creator_wallet", "docs": ["Creator wallet of token"], "type": "pubkey" },
          { "name": "platform_fee_wallet", "docs": ["Platform fee wallet"], "type": "pubkey" },
          { "name": "company_tax_wallet", "docs": ["Company tax wallet"], "type": "pubkey" },
          { "name": "mint_account", "docs": ["Mint account of token A"], "type": "pubkey" },
          {
            "name": "sell_lock_period",
            "docs": ["Sell lock period (duration in seconds from pool creation)"],
            "type": "i64"
          },
          { "name": "virtual_sol_reserve", "docs": ["Virtual sol reserve"], "type": "u64" },
          { "name": "total_sol_volume", "docs": ["Total SOL volume"], "type": "u64" },
          { "name": "real_token_reserve", "docs": ["Virtual token reserve"], "type": "u64" },
          { "name": "create_time", "docs": ["Pool creation time"], "type": "i64" },
          {
            "name": "ramping_limits",
            "docs": ["Dynamic ramping limit entries"],
            "type": { "vec": { "defined": { "name": "RampingLimit" } } }
          },
          { "name": "in_use", "docs": ["Reentrancy lock"], "type": "bool" },
          { "name": "closed", "docs": ["Pool closed flag"], "type": "bool" }
        ]
      }
    },
    {
      "name": "RampingLimit",
      "type": {
        "kind": "struct",
        "fields": [
          { "name": "start_sec", "type": "i64" },
          { "name": "end_sec", "type": "i64" },
          { "name": "limit_bps", "type": "u16" }
        ]
      }
    },
    {
      "name": "SellTokenEvent",
      "type": {
        "kind": "struct",
        "fields": [
          { "name": "user", "docs": ["The public key of the user"], "type": "pubkey" },
          { "name": "mint", "docs": ["The public key of the token"], "type": "pubkey" },
          { "name": "token_in", "docs": ["The amount of token in"], "type": "u64" },
          { "name": "sol_out", "docs": ["The amount of sol out"], "type": "u64" },
          { "name": "sell_time", "docs": ["The timestamp of when the token was sold"], "type": "i64" }
        ]
      }
    },
    {
      "name": "TokenCreatedEvent",
      "type": {
        "kind": "struct",
        "fields": [
          { "name": "creator", "docs": ["The public key of the creator of the token"], "type": "pubkey" },
          { "name": "mint", "docs": ["The public key of the mint"], "type": "pubkey" },
          { "name": "create_time", "docs": ["The timestamp of when the token was created"], "type": "i64" },
          { "name": "sell_lock_period", "docs": ["The sell lock period"], "type": "i64" }
        ]
      }
    }
  ],
  "constants": [
    { "name": "PLATFORM_FEE_WALLET", "type": "pubkey", "value": "FeP2VAcRpyfKk6DSaaYm1Zkmf3PhvytewGBJuZs6E2YK" },
    { "name": "TOKEN_DECIMAL", "type": "u8", "value": "6" }
  ]
}
