Skip to content

0.9.0

Latest

Choose a tag to compare

@fibanachos fibanachos released this 30 Oct 17:25
· 1 commit to main since this release

Added

  • Cookiebox Zip. Three tools for trailing range orders (program ZiPzPbbM…), behaving like
    Cookiebox's /trade Zip tab: get_zip_orders (read, .cook names accepted), start_zip and
    stop_zip. A Zip sells one token for another across a price range and never fills back: it rests
    as a one-sided Cookiebox CLMM position that the Cookiebox keeper trails, each move paying the
    filled part (plus the LP fees earned) to the wallet. start_zip takes sell, receive, amount
    and the prices from/to as receive per sell (what one sold token fetches; omit them for a
    range from one price step past the market to 10% above it) and an optional fee (the pool the
    order earns in; default the pair's deepest pool). The part of the range the market already beats is
    sold at once, never under from (in the pool, or through the router); the rest starts one price
    step past the market, and a range the market beats entirely is just swapped. A pair with no pool at
    that fee gets one created at from; an empty pool parked on the wrong side has its price moved
    there (trading nothing). Setup is owner-paid and idempotent (pool rent, payout accounts, the
    range's tick arrays), enable pins the Cookiebox keeper as cranker unless told otherwise, and
    every refusal — a hooked mint with no published ExtraAccountMetaList, a mint the CLMM won't pool,
    an amount the wallet doesn't hold — comes before anything is sent. Re-entrant for an external
    signer: each transaction is an intermediate step, a re-call re-prices against the market and
    continues with a same-range position of yours, never selling or opening twice. start_zip with
    position zips a CLMM position you already hold, or repairs a paused order running on it
    (tick arrays, payout accounts, NFT delegation) without stopping it. stop_zip takes everything
    back: closes the order, revokes the delegation, withdraws what is left with its fees and closes the
    position; on a filled order it closes the empty position the keeper left behind. Every order's
    status predicts the keeper's next move from the program's own edge rule (filling, waiting,
    fully-filled, paused for a lost delegation, a closed payout account, a missing tick array or
    an unpublished hook meta list, empty, filled, stale); all prices are receive per sell. Also
    importable from the library entry (cookie-mcp).

  • Several post-graduation NFT mint requests at once. MomoSwap's NFT program now lets a wallet hold
    up to 10 requests open per drop (anchor-launchpad-momoswap#117), so nft_drop_mint with count > 1
    on a target-graduated drop places that many through /v1/nft/tx/request-mint-many, one transaction
    each, each verified and simulated on its own before it is signed.

  • list_nft can list through MomoSwap. With via: "momoswap", a MomoSwap drop's item is listed
    through MomoSwap (/v1/nft/tx/list): the same Auction House sell plus MomoSwap's listing fee. The
    build is held to our own sell and a fee of at most 1% (0.001 COOK minimum) paid to the NFT
    program's fee wallet as the chain names it, then rebuilt from our own instructions. The result says
    via: "momoswap" and the fee paid. Only on request: it is the direct listing with a fee on top, so
    it is never taken as a fallback.

  • get_nft_drop shows a creator's held-back share. After a target graduation the program holds
    part of the creator's share back (anchor-launchpad-momoswap#115), releasing it as items mint and
    forfeiting what is left after a deadline; the creator's view reports both as creatorHeldBack.

  • MomoSwap NFT launchpad. Eight tools for NFT drops on a COOK bonding curve: get_nft_drops and
    get_nft_drop (reads), nft_drop_mint (curve mints, or a random request after a target
    graduation), nft_drop_sell (sell back to the curve), nft_drop_redeem (floor or wind-down
    refund), nft_drop_claim (creator proceeds), create_nft_drop (launch from a folder of art, with a
    dryRun preview) and reveal_nft_drop. Every API build is held to the program's vendored IDL before
    signing, then simulated within a spend budget.

  • Aera lending. Eight tools for the Aera COOK money market (market 0, "Aera Core"):
    get_lending_markets and get_lending_position (reads, .cook names accepted), lend /
    withdraw_lend (supply for aCOOK / abCOOK share tokens), deposit_collateral /
    withdraw_collateral (bCOOK in and out of the obligation in one transaction) and borrow / repay
    (COOK; repay "all" clears the loan). borrow and withdraw_collateral refuse before signing when
    the loan-to-value limit would be exceeded or the health factor would fall under minHealthFactor
    (default 1.1). Aera has no API or IDL, so every instruction is built locally and simulated before
    signing. Also importable as cookie-mcp/lending.

  • NFT drop upkeep. nft_drop_settle pushes a drop's mint queue to your pending request, settling
    each head whose randomness is ready and refunding each whose randomness expired (until now a stuck
    request had no way out). nft_drop_graduate graduates a sold-out drop. Both are checked against the
    IDL like every other NFT build.

  • unwrap_cook closes the wallet's wrapped-COOK account and returns the balance as native COOK.
    This is where launchpad referral earnings and NFT sell-back proceeds collect.

Fixed

  • Post-graduation NFT mints, settles and refunds work with MomoSwap's request slots. The deployed
    NFT program (anchor-launchpad-momoswap#117) gives request_mint a request slot that seeds the
    request address, and takes the request by account on settle_mint / refund_mint. The IDL is
    refreshed to anchor main 08c149c, so the slotted builds the API now returns are verified instead of
    refused, and nft_drop_settle finds this wallet's requests in all ten slots (and the old unslotted
    address) and pushes the queue through every one. Error 6063 gets a hint. The temporary acceptance of
    the creator's token account for a new drop's collection NFT is removed: /v1/nft/status reports
    collectionNftHolder: "program".
  • MomoSwap launch with a dev buy works again. MomoSwap moved both launchpad treasury fields to its
    Squads vault, so the pinned create-pool lookup table CawUNM… no longer matched the live Config and
    every create + dev-buy build was refused. The pin is now the frozen table 9vExLr84…, whose keys [3]
    and [4] are the vault 85gdK5… and its wCOOK account 5jP8CW….
  • NFT launches keep working through MomoSwap's program upgrade. The NFT launchpad IDL is refreshed
    to anchor-launchpad-momoswap main (#108, #110–#116). A create may now pass its royalty partner,
    read-only, after create_collection's accounts, and for one release its collection NFT may sit in
    either the creator's or the program's token account, so builds for the live and the upgraded binary
    both pass. A build whose royalty partner or share differs from the one asked for is refused, as is a
    buy whose max_cost data is missing. create_nft_drop refuses a mint window over 30 days before
    uploading anything, and errors 6055–6062 get hints.
  • A tight maxCookPerItem no longer turns a mint request into "the price moved". nft_drop_mint
    on a target-graduated drop now sends the API a slippage that fits the cap, since the request build
    refuses a stated spend below its own worst case instead of clamping to it as a buy does.