Skip to content

Releases: UXDProtocol/uxd-client

Fix MangoDepositoryAccount type

19 Jul 06:40
ecd81ed

Choose a tag to compare

What's Changed

  • replace mintingDisabled with regularMintingDisabled

Full Changelog: v2.0.1...v2.0.2

v2.0.1

18 Jul 07:06
24df98b

Choose a tag to compare

What's Changed

  • Update IDL to fit program v3.1.0
    • Name of the instruction disableDepositoryMinting changed to disableDepositoryRegularMinting

Full Changelog: v2.0.0...v2.0.1

v2.0.0

29 Jun 21:54
f68f2b0

Choose a tag to compare

Fixed

  • Depository.getDeltaNeutralPositionNotionalSizeUI(mango: Mango) now retrieves Mango account, PERP market & price concurrently.
  • Depository.getUnrealizedPnl(mango: Mango, options: ConfirmOptions) now retrieves depository account & delta-neutral position size concurrently.
  • Depository.getFundingRate(mango: Mango) now retrieves Mango Perp market & cache + bids & asks concurrently.
  • Depository.settleMangoDepositoryMangoAccountPnl(payer: Payer, mango: Mango) now retrieves Mango account, cache, PERP market & quote root bank concurrently.

Added

  • Add Client.createQuoteMintWithMangoDepositoryInstruction method.
  • Add Client.createQuoteRedeemWithMangoDepositoryInstruction method.
  • Add Client.createSetMangoDepositoryQuoteMintAndRedeemFeeInstruction method.
  • Add Client.createSetMangoDepositoryQuoteMintAndRedeemSoftCapInstruction method.
  • Add Client.createDisableDepositoryMintingInstruction method.
  • Add Depository.getOffsetUnrealizedPnl(mango: Mango, options: ConfirmOptions) method.
  • Add Depository.getCollateralPerpPriceNativeQuotePerNativeBase(mango: Mango): Promise<I80F48> method.
  • Add Depository.getLimitPrice(slippage: I80F48, perpOrderTakerSide: 'short' | 'long', mango: Mango): Promise<I80F48> method.
  • Export new findMultipleATAAddSync(wallet: PublicKey, mintAddresses: PublicKey[]): [PublicKey, number][] utility function.

Changed

  • Update IDL to match UXD Program version 3.1.0 (audited).
  • Client.createRebalanceMangoDepositoryLiteInstruction now returns Promise<TransactionInstruction> asynchronously to retrieve, compute & enforce the slippage limit price.
  • Client.createMintWithMangoDepositoryInstruction now returns Promise<TransactionInstruction> asynchronously to retrive, compute & enforce the slippage limit price.
  • Client.createRedeemFromMangoDepositoryInstruction now returns Promise<TransactionInstruction> asynchronously to retrieve, compute & enforce the slippage limit price.
  • Depository.getMinTradingSizeCollateralUI(mango: Mango) now returns a number synchronously.
  • getBalance utility function now throws an Error instead of a string when unable to retrieve token account balance.
  • Upgrade @project-serum/anchor to 0.24.2 (from 0.22.0).
  • Upgrade @solana/web3.js to 1.42.0 (from 1.35.1).
  • Add mangoDepositoriesQuoteRedeemableSoftCap!: BN; // u64 property to the Controller account.
  • Add the following properties to the Depository account:
  netQuoteMinted!: BN; // i128  // The signed amount of quote-minted redeemable-tokens, negative means redeemed
  quoteMintAndRedeemFee!: number; // u8 // The fee applied to quote-mint/redeem
  totalQuoteMintAndRedeemFees!: BN; // u128 // The total amount of fee collected
  mintingDisabled!: boolean; // If the depository has disabled both collateral and quote minting
  • All token account required by program instructions now need to be created by the caller. The program does not initialise accounts on behalf of the user anymore

Removed

  • Remove findAddrSync utility function export, use PublicKey.findProgramAddressSync instead.

v1.0.0

06 May 22:13
2b48f14

Choose a tag to compare

Initial release.