Interest Protocol
  • 👋Welcome to Interest Protocol
  • Overview
    • Sui💧
      • Contracts
        • Memez
        • Libs 📚
      • Suicoins
        • Swap
        • Dollar-Cost Averaging (DCA)
        • Airdrop
          • Suiplay Airdrop
        • Incinerator
        • Send
        • Merger
        • Suicoins Terminal
      • Memez.gg
        • Coins on Memez.GG
        • Memez.Fun
          • SDK
            • Pump API
            • Interfaces
          • Configuration
          • Migrators
          • Bonding Curve
          • Fees
      • IPX Coin Standard
    • Movement
      • Interest Protocol Decentralized Exchange (DEX)
        • Key Features
        • Core Innovations
      • sr-AMM
      • Token
        • Tokenomics
        • Utility
      • GTM
    • Audits
    • Security
    • Deprecated
      • Coin X Oracle 🔮
        • Pyth Network
        • Switchboard
      • Sui Tears 💧
        • Airdrop
          • Airdrop
          • Airdrop Utils
          • Linear Vesting Airdrop
        • Capabilities
          • Access Control
          • Owner
          • Quest
          • Timelock
        • Collections
          • Bitmap
          • Coin Decimals
        • DeFi
          • Oracle
          • Farm
          • Fund
          • Linear Vesting Wallet
          • Linear Clawback Vesting Wallet
          • Vesting
        • Governance
          • DAO
          • DAO Admin
          • DAO Treasury
        • Utils
          • ASCII
          • Comparator
          • Merkle Proof
          • Vectors
        • Math
          • Fixed Point 64
          • Fixed Point Roll
          • Fixed Point Wad
          • Int
          • Math64
          • Math128
          • Math256
      • CLAMM🐚
        • Hooks
      • Whitepapers
  • Glossary
Powered by GitBook
On this page
  • MemezPool
  • PumpState
  • Network
  • Packages
  • Shared Objects
  • Config Keys
  • Migrator Witnesses

Was this helpful?

Export as PDF
  1. Overview
  2. Sui💧
  3. Memez.gg
  4. Memez.Fun
  5. SDK

Interfaces

PreviousPump APINextConfiguration

Last updated 3 months ago

Was this helpful?

MemezPool

It represents a Memez Pool.

export interface MemezPool<T> {
  objectId: string;
  poolType: string;
  curveType: string;
  memeCoinType: string;
  quoteCoinType: string;
  usesTokenStandard: boolean;
  ipxMemeCoinTreasury: string;
  metadata: Record<string, string>;
  migrationWitness: string;
  progress: string;
  stateId: string;
  dynamicFieldDataId: string;
  curveState: T;
}
  • objectId: The Sui Object id of this pool.

  • poolType: The struct tag of the pool.

  • curveType: It denotes the possible variants of the pool. E.g. Stable, Auction and Pump.

  • memeCoinType: The struct tag of the Meme coin.

  • quoteCoinType: The struct tag of the Quote coin.

  • usesTokenStandard: Denotes if the pool uses the token standard.

  • ipxMemeCoinTreasury: The id of the Meme coin Treasury.

  • metadata: A map of the meme coin metadata.

  • migrationWitness: The struct tag of the migrator witness. It shows to which DEX the pool is going to migrate to.

  • progress: The current status of the pool. E.g. Bonding, Migrating or Migrated.

  • stateId: The id of of the state object to fetch the inner state.

  • dynamicFieldDataId: The id of the dynamic field holding the inner state.

  • curveState: The inner state related to the variant.

PumpState

Represents the state of the Pump Pool that will be saved in the property curveState in the Memez Pool.

export interface PumpState {
  devPurchase: bigint;
  liquidityProvision: bigint;
  migrationFee: bigint;
  virtualLiquidity: bigint;
  targetQuoteLiquidity: bigint;
  quoteBalance: bigint;
  memeBalance: bigint;
  burnTax: number;
  swapFee: number;
  allocation: Allocation
}
  • devPurchase: The coins bought by the developer.

  • liquidityProvision: The amount of meme coin that will be added liquidity.

  • migrationFee: The payment in Sui that will be charged during migration.

  • virtualLiquidity: The virtual Sui liquidity to set a floor price.

  • targetSuiLiquidity: The amount of Sui required to migrate.

  • quoteBalance: The current amount of Sui in the pool.

  • memeBalance: The amount of meme coin in the pool.

  • burnTax: The burn tax percentage in bps.

  • swapTax: The swap fee percentage in bps.

  • allocation: Balance of meme coins to be sent o stake holders after migration.

Network

An enum referring to the current network being used.

export enum Network {
  Mainnet = 'mainnet',
  Testnet = 'testnet',
}
  • Mainnet: Sui Network main net

  • Testnet: Sui Network test net.

Packages

An object containing the packages to interact with Memez.

export const PACKAGES = {
  [Network.Mainnet]: {
    MEMEZ_FUN: {
      original: normalizeSuiAddress('0x0'),
      latest: normalizeSuiAddress('0x0'),
    },
    ACL: {
      original: normalizeSuiAddress('0x0'),
      latest: normalizeSuiAddress('0x0'),
    },
    VESTING: {
      original: normalizeSuiAddress('0x0'),
      latest: normalizeSuiAddress('0x0'),
    },
    MEMEZ_MIGRATOR: {
      original: normalizeSuiAddress('0x0'),
      latest: normalizeSuiAddress('0x0'),
    },
    MEMEZ_WITNESS: {
      original: normalizeSuiAddress('0x0'),
      latest: normalizeSuiAddress('0x0'),
    },
  },
  [Network.Testnet]: {
    MEMEZ_FUN: {
      original: normalizeSuiAddress(
        '0x63fed690a1154cfc4b31658443227de047cf3d305179aa5836e177c9efa57854'
      ),
      latest: normalizeSuiAddress(
        '0x63fed690a1154cfc4b31658443227de047cf3d305179aa5836e177c9efa57854'
      ),
    },
    ACL: {
      original: normalizeSuiAddress(
        '0x5d406d0307d260f6ffc01f87960b0c28b8c5c3f0e8e71897b1a924a757232179'
      ),
      latest: normalizeSuiAddress(
        '0x5d406d0307d260f6ffc01f87960b0c28b8c5c3f0e8e71897b1a924a757232179'
      ),
    },
    VESTING: {
      original: normalizeSuiAddress(
        '0xdada5d84429db8d56a775593b2893fc030826055dc84fa47ccdfd4933a63d093'
      ),
      latest: normalizeSuiAddress(
        '0xdada5d84429db8d56a775593b2893fc030826055dc84fa47ccdfd4933a63d093'
      ),
    },
    MEMEZ_MIGRATOR: {
      original: normalizeSuiAddress(
        '0x1c709c9f80361a4fb32a122b46a7381f8f6cf267016fdbf6e87b04622ba3476b'
      ),
      latest: normalizeSuiAddress(
        '0x1c709c9f80361a4fb32a122b46a7381f8f6cf267016fdbf6e87b04622ba3476b'
      ),
    },
    MEMEZ_WITNESS: {
      original: normalizeSuiAddress(
        '0x06267071d0eecfb7d16418cb71da4c7b7941b28208a71086ff3e47731c2d263a'
      ),
      latest: normalizeSuiAddress(
        '0x06267071d0eecfb7d16418cb71da4c7b7941b28208a71086ff3e47731c2d263a'
      ),
    }
  },
};
  • MEMEZ_FUN: The address of the core Memez package.

  • ACL: The package of the Memez admin package.

  • VESTING: The package of the vesting package of Memez package.

  • MEMEZ_MIGRATOR: The package of the migrator.

  • MEMEZ_WITNESS: A package containing the configuration witnesses.

Shared Objects

An object containing the shared objects to interact with Memez. Each object has a mutable and immutable reference for optimization purposes.

export const SHARED_OBJECTS = {
  [Network.Mainnet]: {
    ACL: ({ mutable }: { mutable: boolean }) => ({
      objectId: normalizeSuiObjectId('0x0'),
      initialSharedVersion: '1',
      mutable,
    }),
    VERSION: ({ mutable }: { mutable: boolean }) => ({
      objectId: normalizeSuiObjectId('0x0'),
      initialSharedVersion: '1',
      mutable,
    }),
    CONFIG: ({ mutable }: { mutable: boolean }) => ({
      objectId: normalizeSuiObjectId('0x0'),
      initialSharedVersion: '1',
      mutable,
    }),
    MIGRATOR_LIST: ({ mutable }: { mutable: boolean }) => ({
      objectId: normalizeSuiObjectId('0x0'),
      initialSharedVersion: '1',
      mutable,
    }),
  } as const,
  [Network.Testnet]: {
    ACL: ({ mutable }: { mutable: boolean }) => ({
      objectId: normalizeSuiObjectId(
        '0x1b5397ee2f6f8ccfb26016c1ed996f25b2277acb9ed5173fa0bed386360960d8'
      ),
      initialSharedVersion: '384530228',
      mutable,
    }),
    MIGRATOR_LIST: ({ mutable }: { mutable: boolean }) => ({
      objectId: normalizeSuiObjectId(
        '0xf35e6124170d1c7618090bed501edd8fc5f8d8f2d053fbc5f12db93300491ab7'
      ),
      initialSharedVersion: '384530230',
      mutable,
    }),
    VERSION: ({ mutable }: { mutable: boolean }) => ({
      objectId: normalizeSuiObjectId(
        '0x0e74ece4efbc1a15b1ff5bd5653e13281f691b9db8faf669b13783ecc414c848'
      ),
      initialSharedVersion: '384530230',
      mutable,
    }),
    CONFIG: ({ mutable }: { mutable: boolean }) => ({
      objectId: normalizeSuiObjectId(
        '0xd7d747343106d3586f9d96dce4741702de9033875b007f4a485f6593b2e53d79'
      ),
      initialSharedVersion: '384530230',
      mutable,
    }),
  } as const,
};
  • ACL: Shared object holding the current whitelisted admins.

  • VERSION: Shared object containing the latest version of the package.

  • CONFIG: Shared object contain all different configurations:

    • Fees

    • Pump State

    • Stable State

    • Auction State

  • MIGRATION_LIST: Shared object contain the allowed migrators.

Config Keys

The configuration supports various values per integrator. For example the fees for Recrd and Default keys will have different values. This is set by the admin.

export const CONFIG_KEYS = {
  [Network.Mainnet]: {
    DEFAULT: '',
    RECRD: ''
  },
  [Network.Testnet]: {
    DEFAULT: `${PACKAGES[Network.Testnet].MEMEZ_FUN}::memez_config::DefaultKey`,
    RECRD: `${PACKAGES[Network.Testnet].MEMEZ_WITNESS.original}::memez_witness::Recrd`,
  },
} as const;
  • DEFAULT: This is key to get the default parameters.

  • DEFAULT: To be used by RECRD.

Migrator Witnesses

Record of the current allowed migrators.

export const MIGRATOR_WITNESSES = {
  [Network.Mainnet]: {
    TEST: '',
  },
  [Network.Testnet]: {
    TEST: `${PACKAGES[Network.Testnet].MEMEZ_MIGRATOR}::dummy::Witness`,
  },
} as const;
  • TEST: Currently we have a test migrator that returns the balances for testing purposes.

Check out the IPX Treasury standard