@crypticdot/defituna-api 1.10.12 → 1.10.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -53,7 +53,6 @@ __export(schemas_exports, {
53
53
  PoolPriceCandle: () => PoolPriceCandle,
54
54
  PoolProvider: () => PoolProvider,
55
55
  PoolProviderSchema: () => PoolProviderSchema,
56
- PoolSnapshot: () => PoolSnapshot,
57
56
  PoolSubscriptionTopic: () => PoolSubscriptionTopic,
58
57
  PoolSubscriptionTopicSchema: () => PoolSubscriptionTopicSchema,
59
58
  PoolSwap: () => PoolSwap,
@@ -117,7 +116,7 @@ __export(schemas_exports, {
117
116
  WalletSubscriptionTopic: () => WalletSubscriptionTopic,
118
117
  WalletSubscriptionTopicSchema: () => WalletSubscriptionTopicSchema
119
118
  });
120
- import { z as z10 } from "zod";
119
+ import { z as z11 } from "zod";
121
120
 
122
121
  // src/client/schemas/basic.ts
123
122
  import { z } from "zod";
@@ -188,7 +187,7 @@ var Pool = z3.object({
188
187
  });
189
188
 
190
189
  // src/client/schemas/state_snapshot.ts
191
- import z9 from "zod";
190
+ import z10 from "zod";
192
191
 
193
192
  // src/client/schemas/limit_orders.ts
194
193
  import { z as z4 } from "zod";
@@ -512,44 +511,68 @@ var TunaLpPositionAction = z6.object({
512
511
  })
513
512
  });
514
513
 
514
+ // src/client/schemas/market.ts
515
+ import { z as z7 } from "zod";
516
+ var Market = z7.object({
517
+ address: z7.string(),
518
+ addressLookupTable: z7.string(),
519
+ maxLeverage: z7.number(),
520
+ maxSwapSlippage: z7.number(),
521
+ protocolFee: z7.number(),
522
+ protocolFeeOnCollateral: z7.number(),
523
+ liquidationFee: z7.number(),
524
+ liquidationThreshold: z7.number(),
525
+ oraclePriceDeviationThreshold: z7.number(),
526
+ rebalanceProtocolFee: z7.number(),
527
+ borrowedFundsA: AmountWithUsdSchema,
528
+ borrowedFundsB: AmountWithUsdSchema,
529
+ borrowLimitA: AmountWithUsdSchema,
530
+ borrowLimitB: AmountWithUsdSchema,
531
+ maxSpotPositionSizeA: AmountWithUsdSchema,
532
+ maxSpotPositionSizeB: AmountWithUsdSchema,
533
+ pool: Pool,
534
+ disabled: z7.boolean(),
535
+ createdAt: z7.coerce.date()
536
+ });
537
+
515
538
  // src/client/schemas/order_book.ts
516
- import z7 from "zod";
517
- var OrderBookEntry = z7.object({
518
- concentratedAmount: z7.coerce.bigint(),
519
- concentratedAmountQuote: z7.coerce.bigint(),
520
- concentratedTotal: z7.coerce.bigint(),
521
- concentratedTotalQuote: z7.coerce.bigint(),
522
- limitAmount: z7.coerce.bigint(),
523
- limitAmountQuote: z7.coerce.bigint(),
524
- limitTotal: z7.coerce.bigint(),
525
- limitTotalQuote: z7.coerce.bigint(),
526
- price: z7.number(),
527
- askSide: z7.boolean()
539
+ import z8 from "zod";
540
+ var OrderBookEntry = z8.object({
541
+ concentratedAmount: z8.coerce.bigint(),
542
+ concentratedAmountQuote: z8.coerce.bigint(),
543
+ concentratedTotal: z8.coerce.bigint(),
544
+ concentratedTotalQuote: z8.coerce.bigint(),
545
+ limitAmount: z8.coerce.bigint(),
546
+ limitAmountQuote: z8.coerce.bigint(),
547
+ limitTotal: z8.coerce.bigint(),
548
+ limitTotalQuote: z8.coerce.bigint(),
549
+ price: z8.number(),
550
+ askSide: z8.boolean()
528
551
  });
529
- var OrderBook = z7.object({
552
+ var OrderBook = z8.object({
530
553
  entries: OrderBookEntry.array(),
531
- poolPrice: z7.number(),
532
- poolAddress: z7.string()
554
+ poolPrice: z8.number(),
555
+ poolAddress: z8.string()
533
556
  });
534
557
 
535
558
  // src/client/schemas/spot_positions.ts
536
- import { z as z8 } from "zod";
559
+ import { z as z9 } from "zod";
537
560
  var TunaSpotPositionState = {
538
561
  OPEN: "open",
539
562
  CLOSED: "closed"
540
563
  };
541
- var TunaSpotPositionStateSchema = z8.enum([
564
+ var TunaSpotPositionStateSchema = z9.enum([
542
565
  TunaSpotPositionState.OPEN,
543
566
  ...Object.values(TunaSpotPositionState)
544
567
  ]);
545
- var TunaSpotPosition = z8.object({
546
- address: z8.string(),
547
- authority: z8.string(),
548
- version: z8.number(),
568
+ var TunaSpotPosition = z9.object({
569
+ address: z9.string(),
570
+ authority: z9.string(),
571
+ version: z9.number(),
549
572
  state: TunaSpotPositionStateSchema,
550
- lowerLimitOrderPrice: z8.number(),
551
- upperLimitOrderPrice: z8.number(),
552
- entryPrice: z8.number(),
573
+ lowerLimitOrderPrice: z9.number(),
574
+ upperLimitOrderPrice: z9.number(),
575
+ entryPrice: z9.number(),
553
576
  pool: Pool,
554
577
  positionToken: TunaPositionPoolTokenSchema,
555
578
  collateralToken: TunaPositionPoolTokenSchema,
@@ -558,85 +581,71 @@ var TunaSpotPosition = z8.object({
558
581
  initialDebt: AmountWithUsdSchema,
559
582
  currentDebt: AmountWithUsdSchema,
560
583
  total: AmountWithUsdSchema,
561
- leverage: z8.number(),
562
- maxLeverage: z8.number(),
563
- liquidationPrice: z8.number(),
584
+ leverage: z9.number(),
585
+ maxLeverage: z9.number(),
586
+ liquidationPrice: z9.number(),
564
587
  pnlUsd: UsdPnlSchema,
565
- openedAt: z8.coerce.date(),
566
- closedAt: z8.nullable(z8.coerce.date())
588
+ openedAt: z9.coerce.date(),
589
+ closedAt: z9.nullable(z9.coerce.date())
567
590
  });
568
- var IncreaseSpotPositionQuote = z8.object({
591
+ var IncreaseSpotPositionQuote = z9.object({
569
592
  /** Required collateral amount */
570
- collateralAmount: z8.coerce.bigint(),
593
+ collateralAmount: z9.coerce.bigint(),
571
594
  /** Required amount to borrow */
572
- borrowAmount: z8.coerce.bigint(),
595
+ borrowAmount: z9.coerce.bigint(),
573
596
  /** Estimated position size in the position token. */
574
- estimatedAmount: z8.coerce.bigint(),
597
+ estimatedAmount: z9.coerce.bigint(),
575
598
  /** Swap input amount. */
576
- swapInputAmount: z8.coerce.bigint(),
599
+ swapInputAmount: z9.coerce.bigint(),
577
600
  /** Minimum swap output amount according to the provided slippage. */
578
- minSwapOutputAmount: z8.coerce.bigint(),
601
+ minSwapOutputAmount: z9.coerce.bigint(),
579
602
  /** Protocol fee in token A */
580
- protocolFeeA: z8.coerce.bigint(),
603
+ protocolFeeA: z9.coerce.bigint(),
581
604
  /** Protocol fee in token B */
582
- protocolFeeB: z8.coerce.bigint(),
605
+ protocolFeeB: z9.coerce.bigint(),
583
606
  /** Price impact in percents */
584
- priceImpact: z8.number(),
607
+ priceImpact: z9.number(),
585
608
  /** Liquidation price */
586
- liquidationPrice: z8.number()
609
+ liquidationPrice: z9.number()
587
610
  });
588
- var DecreaseSpotPositionQuote = z8.object({
611
+ var DecreaseSpotPositionQuote = z9.object({
589
612
  /** Confirmed position decrease percentage (100% = 1.0) */
590
- decreasePercent: z8.number(),
613
+ decreasePercent: z9.number(),
591
614
  /** The maximum acceptable swap input amount for position decrease according to the provided slippage
592
615
  * (if collateral_token == position_token) OR the minimum swap output amount (if collateral_token != position_token).
593
616
  */
594
- requiredSwapAmount: z8.coerce.bigint(),
617
+ requiredSwapAmount: z9.coerce.bigint(),
595
618
  /** Estimated total amount of the adjusted position */
596
- estimatedAmount: z8.coerce.bigint(),
619
+ estimatedAmount: z9.coerce.bigint(),
597
620
  /** Estimated amount of the withdrawn collateral */
598
- estimatedWithdrawnCollateral: z8.coerce.bigint(),
621
+ estimatedWithdrawnCollateral: z9.coerce.bigint(),
599
622
  /** Price impact in percents */
600
- priceImpact: z8.number(),
623
+ priceImpact: z9.number(),
601
624
  /** Liquidation price */
602
- liquidationPrice: z8.number()
625
+ liquidationPrice: z9.number()
603
626
  });
604
- var CloseSpotPositionQuote = z8.object({
627
+ var CloseSpotPositionQuote = z9.object({
605
628
  /** Position decrease percentage */
606
- decreasePercent: z8.number(),
629
+ decreasePercent: z9.number(),
607
630
  /** The maximum acceptable swap input amount for position decrease according to the provided slippage
608
631
  * (if collateral_token == position_token) OR the minimum swap output amount (if collateral_token != position_token).
609
632
  */
610
- requiredSwapAmount: z8.coerce.bigint(),
633
+ requiredSwapAmount: z9.coerce.bigint(),
611
634
  /** Estimated amount of the withdrawn collateral */
612
- estimatedWithdrawnCollateral: z8.coerce.bigint(),
635
+ estimatedWithdrawnCollateral: z9.coerce.bigint(),
613
636
  /** Price impact in percents */
614
- priceImpact: z8.number()
637
+ priceImpact: z9.number()
615
638
  });
616
639
 
617
640
  // src/client/schemas/state_snapshot.ts
618
- var PoolSnapshot = z9.object({
619
- liquidity: z9.coerce.bigint(),
620
- tickCurrentIndex: z9.number(),
621
- price: z9.number(),
622
- sqrtPrice: z9.coerce.bigint(),
623
- tvl: z9.number(),
624
- priceChange24H: z9.number(),
625
- volume24H: z9.number(),
626
- fees24H: z9.number(),
627
- borrowedFundsA: AmountWithUsdSchema,
628
- borrowedFundsB: AmountWithUsdSchema,
629
- borrowLimitA: AmountWithUsdSchema,
630
- borrowLimitB: AmountWithUsdSchema
631
- });
632
- var StateSnapshot = z9.object({
633
- slot: z9.coerce.bigint(),
634
- blockTime: z9.coerce.date(),
635
- pools: z9.optional(z9.record(z9.string(), PoolSnapshot)),
636
- tunaSpotPositions: z9.optional(z9.array(TunaSpotPosition)),
637
- tunaLpPositions: z9.optional(z9.array(TunaLpPositionDtoSchema)),
638
- fusionLimitOrders: z9.optional(z9.array(LimitOrder)),
639
- orderBooks: z9.optional(z9.record(z9.string(), OrderBook))
641
+ var StateSnapshot = z10.object({
642
+ slot: z10.coerce.bigint(),
643
+ blockTime: z10.coerce.date(),
644
+ markets: z10.optional(z10.array(Market)),
645
+ tunaSpotPositions: z10.optional(z10.array(TunaSpotPosition)),
646
+ tunaLpPositions: z10.optional(z10.array(TunaLpPositionDtoSchema)),
647
+ fusionLimitOrders: z10.optional(z10.array(LimitOrder)),
648
+ orderBooks: z10.optional(z10.array(OrderBook))
640
649
  });
641
650
 
642
651
  // src/client/schemas.ts
@@ -712,81 +721,60 @@ var WalletSubscriptionTopic = {
712
721
  TRADE_HISTORY: "trade_history",
713
722
  ORDER_HISTORY: "order_history"
714
723
  };
715
- var NotificationEntitySchema = z10.enum([NotificationEntity.POOL_SWAP, ...Object.values(NotificationEntity)]);
716
- var NotificationActionSchema = z10.enum([NotificationAction.CREATE, ...Object.values(NotificationAction)]);
717
- var TradeHistoryActionSchema = z10.enum([TradeHistoryAction.SWAP, ...Object.values(TradeHistoryAction)]);
718
- var TradeHistoryUIDirectionSchema = z10.enum([
724
+ var NotificationEntitySchema = z11.enum([NotificationEntity.POOL_SWAP, ...Object.values(NotificationEntity)]);
725
+ var NotificationActionSchema = z11.enum([NotificationAction.CREATE, ...Object.values(NotificationAction)]);
726
+ var TradeHistoryActionSchema = z11.enum([TradeHistoryAction.SWAP, ...Object.values(TradeHistoryAction)]);
727
+ var TradeHistoryUIDirectionSchema = z11.enum([
719
728
  TradeHistoryUIDirection.BUY,
720
729
  ...Object.values(TradeHistoryUIDirection)
721
730
  ]);
722
- var OrderHistoryOrderTypeSchema = z10.enum([
731
+ var OrderHistoryOrderTypeSchema = z11.enum([
723
732
  OrderHistoryOrderType.MARKET,
724
733
  ...Object.values(OrderHistoryOrderType)
725
734
  ]);
726
- var OrderHistoryStatusSchema = z10.enum([OrderHistoryStatus.OPEN, ...Object.values(OrderHistoryStatus)]);
727
- var OrderHistoryUIDirectionSchema = z10.enum([
735
+ var OrderHistoryStatusSchema = z11.enum([OrderHistoryStatus.OPEN, ...Object.values(OrderHistoryStatus)]);
736
+ var OrderHistoryUIDirectionSchema = z11.enum([
728
737
  OrderHistoryUIDirection.BUY,
729
738
  ...Object.values(OrderHistoryUIDirection)
730
739
  ]);
731
- var StakingPositionHistoryActionTypeSchema = z10.enum([
740
+ var StakingPositionHistoryActionTypeSchema = z11.enum([
732
741
  StakingPositionHistoryActionType.STAKE,
733
742
  ...Object.values(StakingPositionHistoryActionType)
734
743
  ]);
735
- var PoolSubscriptionTopicSchema = z10.enum([
744
+ var PoolSubscriptionTopicSchema = z11.enum([
736
745
  PoolSubscriptionTopic.ORDER_BOOK,
737
746
  ...Object.values(PoolSubscriptionTopic)
738
747
  ]);
739
- var WalletSubscriptionTopicSchema = z10.enum([
748
+ var WalletSubscriptionTopicSchema = z11.enum([
740
749
  WalletSubscriptionTopic.TUNA_POSITIONS,
741
750
  ...Object.values(WalletSubscriptionTopic)
742
751
  ]);
743
- var PaginationMeta = z10.object({
744
- total: z10.number()
745
- });
746
- var Market = z10.object({
747
- address: z10.string(),
748
- addressLookupTable: z10.string(),
749
- maxLeverage: z10.number(),
750
- maxSwapSlippage: z10.number(),
751
- protocolFee: z10.number(),
752
- protocolFeeOnCollateral: z10.number(),
753
- liquidationFee: z10.number(),
754
- liquidationThreshold: z10.number(),
755
- oraclePriceDeviationThreshold: z10.number(),
756
- rebalanceProtocolFee: z10.number(),
757
- borrowedFundsA: AmountWithUsdSchema,
758
- borrowedFundsB: AmountWithUsdSchema,
759
- borrowLimitA: AmountWithUsdSchema,
760
- borrowLimitB: AmountWithUsdSchema,
761
- maxSpotPositionSizeA: AmountWithUsdSchema,
762
- maxSpotPositionSizeB: AmountWithUsdSchema,
763
- pool: Pool,
764
- disabled: z10.boolean(),
765
- createdAt: z10.coerce.date()
752
+ var PaginationMeta = z11.object({
753
+ total: z11.number()
766
754
  });
767
- var TokenOraclePrice = z10.object({
768
- mint: z10.string(),
769
- price: z10.coerce.bigint(),
770
- decimals: z10.number(),
771
- time: z10.coerce.date()
755
+ var TokenOraclePrice = z11.object({
756
+ mint: z11.string(),
757
+ price: z11.coerce.bigint(),
758
+ decimals: z11.number(),
759
+ time: z11.coerce.date()
772
760
  });
773
- var Vault = z10.object({
774
- address: z10.string(),
775
- mint: z10.string(),
761
+ var Vault = z11.object({
762
+ address: z11.string(),
763
+ mint: z11.string(),
776
764
  depositedFunds: AmountWithUsdSchema,
777
765
  borrowedFunds: AmountWithUsdSchema,
778
766
  supplyLimit: AmountWithUsdSchema,
779
- borrowedShares: z10.coerce.bigint(),
780
- depositedShares: z10.coerce.bigint(),
781
- supplyApy: z10.number(),
782
- borrowApy: z10.number(),
783
- interestRate: z10.coerce.bigint(),
784
- utilization: z10.number(),
785
- pythOracleFeedId: z10.string(),
786
- pythOraclePriceUpdate: z10.string()
767
+ borrowedShares: z11.coerce.bigint(),
768
+ depositedShares: z11.coerce.bigint(),
769
+ supplyApy: z11.number(),
770
+ borrowApy: z11.number(),
771
+ interestRate: z11.coerce.bigint(),
772
+ utilization: z11.number(),
773
+ pythOracleFeedId: z11.string(),
774
+ pythOraclePriceUpdate: z11.string()
787
775
  });
788
- var VaultHistoricalStats = z10.object({
789
- date: z10.preprocess((val, ctx) => {
776
+ var VaultHistoricalStats = z11.object({
777
+ date: z11.preprocess((val, ctx) => {
790
778
  if (typeof val === "string") {
791
779
  const [year, month, day] = val.split("-").map(Number);
792
780
  return new Date(year, month - 1, day);
@@ -795,214 +783,214 @@ var VaultHistoricalStats = z10.object({
795
783
  code: "custom",
796
784
  message: "Not a valid date string"
797
785
  });
798
- return z10.NEVER;
799
- }, z10.date()),
786
+ return z11.NEVER;
787
+ }, z11.date()),
800
788
  supply: AmountWithUsdSchema,
801
789
  borrow: AmountWithUsdSchema,
802
- supplyApy: z10.number(),
803
- borrowApr: z10.number()
790
+ supplyApy: z11.number(),
791
+ borrowApr: z11.number()
804
792
  });
805
- var Tick = z10.object({
806
- index: z10.number(),
807
- liquidity: z10.coerce.bigint()
793
+ var Tick = z11.object({
794
+ index: z11.number(),
795
+ liquidity: z11.coerce.bigint()
808
796
  });
809
- var PoolTicks = z10.object({
810
- tickSpacing: z10.number(),
797
+ var PoolTicks = z11.object({
798
+ tickSpacing: z11.number(),
811
799
  ticks: Tick.array()
812
800
  });
813
- var LendingPosition = z10.object({
814
- address: z10.string(),
815
- authority: z10.string(),
816
- mint: z10.string(),
817
- vault: z10.string(),
818
- shares: z10.coerce.bigint(),
801
+ var LendingPosition = z11.object({
802
+ address: z11.string(),
803
+ authority: z11.string(),
804
+ mint: z11.string(),
805
+ vault: z11.string(),
806
+ shares: z11.coerce.bigint(),
819
807
  funds: AmountWithUsdSchema,
820
808
  earned: AmountWithUsdSchema
821
809
  });
822
- var PoolSwap = z10.object({
823
- id: z10.string(),
824
- amountIn: z10.coerce.bigint(),
825
- amountOut: z10.coerce.bigint(),
826
- amountUsd: z10.number(),
827
- aToB: z10.boolean(),
828
- pool: z10.string(),
829
- time: z10.coerce.date()
810
+ var PoolSwap = z11.object({
811
+ id: z11.string(),
812
+ amountIn: z11.coerce.bigint(),
813
+ amountOut: z11.coerce.bigint(),
814
+ amountUsd: z11.number(),
815
+ aToB: z11.boolean(),
816
+ pool: z11.string(),
817
+ time: z11.coerce.date()
830
818
  });
831
- var TradeHistoryEntry = z10.object({
819
+ var TradeHistoryEntry = z11.object({
832
820
  // Internal entry ID
833
- id: z10.string(),
821
+ id: z11.string(),
834
822
  pool: Pool,
835
- authority: z10.string(),
836
- aToB: z10.boolean(),
823
+ authority: z11.string(),
824
+ aToB: z11.boolean(),
837
825
  // Trade action which created entry
838
826
  action: TradeHistoryActionSchema,
839
827
  // Trade direction formatted for ui display
840
828
  uiDirection: TradeHistoryUIDirectionSchema,
841
829
  // Trade price formatted for ui display
842
- uiPrice: z10.number(),
830
+ uiPrice: z11.number(),
843
831
  baseToken: AmountWithUsdSchema,
844
832
  quoteToken: AmountWithUsdSchema,
845
833
  fee: AmountWithUsdSchema,
846
- pnl: z10.nullable(
847
- z10.object({
848
- usd: z10.number(),
849
- bps: z10.number()
834
+ pnl: z11.nullable(
835
+ z11.object({
836
+ usd: z11.number(),
837
+ bps: z11.number()
850
838
  })
851
839
  ),
852
- txSignature: z10.nullable(z10.string()),
853
- positionAddress: z10.nullable(z10.string()),
854
- slot: z10.coerce.bigint(),
855
- ts: z10.coerce.date()
840
+ txSignature: z11.nullable(z11.string()),
841
+ positionAddress: z11.nullable(z11.string()),
842
+ slot: z11.coerce.bigint(),
843
+ ts: z11.coerce.date()
856
844
  });
857
- var OrderHistoryEntry = z10.object({
845
+ var OrderHistoryEntry = z11.object({
858
846
  // Internal entry ID
859
- id: z10.string(),
847
+ id: z11.string(),
860
848
  pool: Pool,
861
- authority: z10.string(),
849
+ authority: z11.string(),
862
850
  orderType: OrderHistoryOrderTypeSchema,
863
- isReduceOnly: z10.nullable(z10.boolean()),
864
- aToB: z10.boolean(),
851
+ isReduceOnly: z11.nullable(z11.boolean()),
852
+ aToB: z11.boolean(),
865
853
  uiDirection: OrderHistoryUIDirectionSchema,
866
- uiPrice: z10.nullable(z10.number()),
867
- uiExecutionPrice: z10.nullable(z10.number()),
854
+ uiPrice: z11.nullable(z11.number()),
855
+ uiExecutionPrice: z11.nullable(z11.number()),
868
856
  status: OrderHistoryStatusSchema,
869
857
  baseToken: AmountWithUsdSchema,
870
858
  quoteToken: AmountWithUsdSchema,
871
- baseTokenConsumedAmount: z10.nullable(AmountWithUsdSchema),
872
- quoteTokenFilledAmount: z10.nullable(AmountWithUsdSchema),
873
- txSignature: z10.nullable(z10.string()),
874
- positionAddress: z10.nullable(z10.string()),
875
- slot: z10.coerce.bigint(),
876
- ts: z10.coerce.date()
859
+ baseTokenConsumedAmount: z11.nullable(AmountWithUsdSchema),
860
+ quoteTokenFilledAmount: z11.nullable(AmountWithUsdSchema),
861
+ txSignature: z11.nullable(z11.string()),
862
+ positionAddress: z11.nullable(z11.string()),
863
+ slot: z11.coerce.bigint(),
864
+ ts: z11.coerce.date()
877
865
  });
878
- var StakingTreasury = z10.object({
879
- address: z10.string(),
880
- stakedTokenMint: z10.string(),
881
- rewardTokenMint: z10.string(),
882
- apy: z10.number(),
883
- uniqueStakers: z10.number(),
866
+ var StakingTreasury = z11.object({
867
+ address: z11.string(),
868
+ stakedTokenMint: z11.string(),
869
+ rewardTokenMint: z11.string(),
870
+ apy: z11.number(),
871
+ uniqueStakers: z11.number(),
884
872
  totalStaked: AmountWithUsdSchema,
885
873
  totalReward: AmountWithUsdSchema,
886
- unstakeCooldownSeconds: z10.number(),
887
- isStakingEnabled: z10.boolean(),
888
- isUnstakingEnabled: z10.boolean(),
889
- isWithdrawEnabled: z10.boolean()
874
+ unstakeCooldownSeconds: z11.number(),
875
+ isStakingEnabled: z11.boolean(),
876
+ isUnstakingEnabled: z11.boolean(),
877
+ isWithdrawEnabled: z11.boolean()
890
878
  });
891
- var StakingPosition = z10.object({
892
- address: z10.string(),
893
- owner: z10.string(),
879
+ var StakingPosition = z11.object({
880
+ address: z11.string(),
881
+ owner: z11.string(),
894
882
  staked: AmountWithUsdSchema,
895
883
  unstaked: AmountWithUsdSchema,
896
884
  claimedReward: AmountWithUsdSchema,
897
885
  unclaimedReward: AmountWithUsdSchema,
898
- rank: z10.nullable(z10.number()),
899
- vesting: z10.object({
886
+ rank: z11.nullable(z11.number()),
887
+ vesting: z11.object({
900
888
  locked: AmountWithUsdSchema,
901
889
  unlocked: AmountWithUsdSchema,
902
- unlockRate: z10.coerce.bigint(),
903
- unlockEverySeconds: z10.number(),
904
- unlockCliffSeconds: z10.number(),
905
- lockedAt: z10.nullable(z10.coerce.date())
890
+ unlockRate: z11.coerce.bigint(),
891
+ unlockEverySeconds: z11.number(),
892
+ unlockCliffSeconds: z11.number(),
893
+ lockedAt: z11.nullable(z11.coerce.date())
906
894
  }),
907
- lastUnstakedAt: z10.nullable(z10.coerce.date()),
908
- withdrawAvailableAt: z10.nullable(z10.coerce.date())
895
+ lastUnstakedAt: z11.nullable(z11.coerce.date()),
896
+ withdrawAvailableAt: z11.nullable(z11.coerce.date())
909
897
  });
910
- var StakingLeaderboardPosition = z10.object({
911
- rank: z10.number(),
912
- address: z10.string(),
913
- owner: z10.string(),
898
+ var StakingLeaderboardPosition = z11.object({
899
+ rank: z11.number(),
900
+ address: z11.string(),
901
+ owner: z11.string(),
914
902
  staked: AmountWithUsdSchema
915
903
  });
916
- var StakingLeaderboardPage = z10.object({
904
+ var StakingLeaderboardPage = z11.object({
917
905
  data: StakingLeaderboardPosition.array(),
918
906
  meta: PaginationMeta
919
907
  });
920
- var StakingPositionHistoryAction = z10.object({
921
- position: z10.string(),
908
+ var StakingPositionHistoryAction = z11.object({
909
+ position: z11.string(),
922
910
  action: StakingPositionHistoryActionTypeSchema,
923
- txSignature: z10.string(),
924
- amount: z10.coerce.bigint(),
925
- time: z10.coerce.date()
911
+ txSignature: z11.string(),
912
+ amount: z11.coerce.bigint(),
913
+ time: z11.coerce.date()
926
914
  });
927
- var PoolPriceCandle = z10.object({
928
- time: z10.number(),
929
- open: z10.number(),
930
- close: z10.number(),
931
- high: z10.number(),
932
- low: z10.number(),
933
- volume: z10.number()
915
+ var PoolPriceCandle = z11.object({
916
+ time: z11.number(),
917
+ open: z11.number(),
918
+ close: z11.number(),
919
+ high: z11.number(),
920
+ low: z11.number(),
921
+ volume: z11.number()
934
922
  });
935
- var FeesStatsGroup = z10.object({
936
- time: z10.coerce.date(),
937
- addLiquidityFees: z10.number(),
938
- limitOrderFees: z10.number(),
939
- yieldCompoundingFees: z10.number(),
940
- liquidationFees: z10.number(),
941
- totalLiquidationsNetworkFees: z10.number(),
942
- totalLimitOrdersNetworkFees: z10.number(),
943
- totalYieldCompoundingNetworkFees: z10.number(),
944
- failedNetworkFees: z10.number(),
945
- processedNetworkFees: z10.number(),
946
- totalCollectedFees: z10.number(),
947
- totalNetworkFees: z10.number(),
948
- jitoLiquidationFees: z10.number(),
949
- jitoLimitOrderFees: z10.number(),
950
- jitoYieldCompoundingFees: z10.number(),
951
- runningAddLiquidityFees: z10.number(),
952
- runningLimitOrderFees: z10.number(),
953
- runningYieldCompoundingFees: z10.number(),
954
- runningLiquidationFees: z10.number(),
955
- runningTotalLiquidationsNetworkFees: z10.number(),
956
- runningTotalLimitOrdersNetworkFees: z10.number(),
957
- runningTotalYieldCompoundingNetworkFees: z10.number(),
958
- runningFailedNetworkFees: z10.number(),
959
- runningProcessedNetworkFees: z10.number(),
960
- runningJitoLiquidationFees: z10.number(),
961
- runningJitoLimitOrderFees: z10.number(),
962
- runningJitoYieldCompoundingFees: z10.number(),
963
- runningTotalCollectedFees: z10.number(),
964
- runningTotalNetworkFees: z10.number()
923
+ var FeesStatsGroup = z11.object({
924
+ time: z11.coerce.date(),
925
+ addLiquidityFees: z11.number(),
926
+ limitOrderFees: z11.number(),
927
+ yieldCompoundingFees: z11.number(),
928
+ liquidationFees: z11.number(),
929
+ totalLiquidationsNetworkFees: z11.number(),
930
+ totalLimitOrdersNetworkFees: z11.number(),
931
+ totalYieldCompoundingNetworkFees: z11.number(),
932
+ failedNetworkFees: z11.number(),
933
+ processedNetworkFees: z11.number(),
934
+ totalCollectedFees: z11.number(),
935
+ totalNetworkFees: z11.number(),
936
+ jitoLiquidationFees: z11.number(),
937
+ jitoLimitOrderFees: z11.number(),
938
+ jitoYieldCompoundingFees: z11.number(),
939
+ runningAddLiquidityFees: z11.number(),
940
+ runningLimitOrderFees: z11.number(),
941
+ runningYieldCompoundingFees: z11.number(),
942
+ runningLiquidationFees: z11.number(),
943
+ runningTotalLiquidationsNetworkFees: z11.number(),
944
+ runningTotalLimitOrdersNetworkFees: z11.number(),
945
+ runningTotalYieldCompoundingNetworkFees: z11.number(),
946
+ runningFailedNetworkFees: z11.number(),
947
+ runningProcessedNetworkFees: z11.number(),
948
+ runningJitoLiquidationFees: z11.number(),
949
+ runningJitoLimitOrderFees: z11.number(),
950
+ runningJitoYieldCompoundingFees: z11.number(),
951
+ runningTotalCollectedFees: z11.number(),
952
+ runningTotalNetworkFees: z11.number()
965
953
  });
966
- var StakingRevenueStatsGroup = z10.object({
967
- time: z10.coerce.date(),
968
- totalDepositsUsd: z10.number(),
969
- totalDepositsSol: z10.coerce.bigint(),
970
- runningTotalDepositsUsd: z10.number(),
971
- runningTotalDepositsSol: z10.coerce.bigint()
954
+ var StakingRevenueStatsGroup = z11.object({
955
+ time: z11.coerce.date(),
956
+ totalDepositsUsd: z11.number(),
957
+ totalDepositsSol: z11.coerce.bigint(),
958
+ runningTotalDepositsUsd: z11.number(),
959
+ runningTotalDepositsSol: z11.coerce.bigint()
972
960
  });
973
- var SwapQuoteByInput = z10.object({
974
- estimatedAmountOut: z10.coerce.bigint(),
975
- minAmountOut: z10.coerce.bigint(),
976
- feeAmount: z10.coerce.bigint(),
977
- feeUsd: z10.number(),
961
+ var SwapQuoteByInput = z11.object({
962
+ estimatedAmountOut: z11.coerce.bigint(),
963
+ minAmountOut: z11.coerce.bigint(),
964
+ feeAmount: z11.coerce.bigint(),
965
+ feeUsd: z11.number(),
978
966
  /** Price impact in percents */
979
- priceImpact: z10.number()
967
+ priceImpact: z11.number()
980
968
  });
981
- var SwapQuoteByOutput = z10.object({
982
- estimatedAmountIn: z10.coerce.bigint(),
983
- maxAmountIn: z10.coerce.bigint(),
984
- feeAmount: z10.coerce.bigint(),
985
- feeUsd: z10.number(),
969
+ var SwapQuoteByOutput = z11.object({
970
+ estimatedAmountIn: z11.coerce.bigint(),
971
+ maxAmountIn: z11.coerce.bigint(),
972
+ feeAmount: z11.coerce.bigint(),
973
+ feeUsd: z11.number(),
986
974
  /** Price impact in percents */
987
- priceImpact: z10.number()
975
+ priceImpact: z11.number()
988
976
  });
989
- var LimitOrderQuoteByInput = z10.object({
990
- amountOut: z10.coerce.bigint()
977
+ var LimitOrderQuoteByInput = z11.object({
978
+ amountOut: z11.coerce.bigint()
991
979
  });
992
- var LimitOrderQuoteByOutput = z10.object({
993
- amountIn: z10.coerce.bigint()
980
+ var LimitOrderQuoteByOutput = z11.object({
981
+ amountIn: z11.coerce.bigint()
994
982
  });
995
983
  var TradableAmount = AmountWithUsdSchema;
996
- var UpdateStreamSubscriptionResult = z10.object({
997
- status: z10.string()
984
+ var UpdateStreamSubscriptionResult = z11.object({
985
+ status: z11.string()
998
986
  });
999
- var createNotificationSchema = (dataSchema, metaSchema) => z10.object({
987
+ var createNotificationSchema = (dataSchema, metaSchema) => z11.object({
1000
988
  entity: NotificationEntitySchema,
1001
989
  action: NotificationActionSchema,
1002
990
  data: dataSchema,
1003
- id: z10.string(),
1004
- authority: z10.nullish(z10.string()),
1005
- ...metaSchema ? { meta: metaSchema } : { meta: z10.undefined().nullable() }
991
+ id: z11.string(),
992
+ authority: z11.nullish(z11.string()),
993
+ ...metaSchema ? { meta: metaSchema } : { meta: z11.undefined().nullable() }
1006
994
  });
1007
995
  var PoolSwapNotification = createNotificationSchema(PoolSwap);
1008
996
  var LendingPositionNotification = createNotificationSchema(LendingPosition);