@scallop-io/sui-scallop-sdk 1.5.0-alpha.1 → 1.5.1

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.
Files changed (104) hide show
  1. package/dist/index.d.mts +3161 -0
  2. package/dist/index.d.ts +3161 -3
  3. package/dist/index.js +78 -9966
  4. package/dist/index.mjs +15 -9892
  5. package/package.json +5 -6
  6. package/src/builders/coreBuilder.ts +10 -14
  7. package/src/builders/oracle.ts +10 -2
  8. package/src/constants/coinGecko.ts +14 -4
  9. package/src/constants/common.ts +8 -1
  10. package/src/constants/enum.ts +28 -57
  11. package/src/constants/poolAddress.ts +294 -344
  12. package/src/constants/pyth.ts +4 -1
  13. package/src/constants/testAddress.ts +487 -61
  14. package/src/constants/xoracle.ts +18 -16
  15. package/src/models/scallopAddress.ts +54 -0
  16. package/src/models/scallopQuery.ts +8 -12
  17. package/src/queries/coreQuery.ts +4 -4
  18. package/src/queries/poolAddressesQuery.ts +2 -2
  19. package/src/queries/portfolioQuery.ts +7 -8
  20. package/src/queries/xOracleQuery.ts +15 -7
  21. package/src/types/address.ts +5 -0
  22. package/src/types/model.ts +1 -0
  23. package/src/utils/util.ts +8 -3
  24. package/dist/builders/borrowIncentiveBuilder.d.ts +0 -12
  25. package/dist/builders/coreBuilder.d.ts +0 -12
  26. package/dist/builders/index.d.ts +0 -12
  27. package/dist/builders/loyaltyProgramBuilder.d.ts +0 -12
  28. package/dist/builders/oracle.d.ts +0 -14
  29. package/dist/builders/referralBuilder.d.ts +0 -12
  30. package/dist/builders/sCoinBuilder.d.ts +0 -4
  31. package/dist/builders/spoolBuilder.d.ts +0 -12
  32. package/dist/builders/vescaBuilder.d.ts +0 -25
  33. package/dist/constants/cache.d.ts +0 -14
  34. package/dist/constants/coinGecko.d.ts +0 -2
  35. package/dist/constants/common.d.ts +0 -20
  36. package/dist/constants/enum.d.ts +0 -14
  37. package/dist/constants/flashloan.d.ts +0 -2
  38. package/dist/constants/index.d.ts +0 -13
  39. package/dist/constants/poolAddress.d.ts +0 -27
  40. package/dist/constants/pyth.d.ts +0 -5
  41. package/dist/constants/queryKeys.d.ts +0 -54
  42. package/dist/constants/rpc.d.ts +0 -1
  43. package/dist/constants/testAddress.d.ts +0 -2
  44. package/dist/constants/vesca.d.ts +0 -5
  45. package/dist/constants/xoracle.d.ts +0 -2
  46. package/dist/index.js.map +0 -1
  47. package/dist/index.mjs.map +0 -1
  48. package/dist/models/index.d.ts +0 -8
  49. package/dist/models/scallop.d.ts +0 -73
  50. package/dist/models/scallopAddress.d.ts +0 -150
  51. package/dist/models/scallopBuilder.d.ts +0 -90
  52. package/dist/models/scallopCache.d.ts +0 -81
  53. package/dist/models/scallopClient.d.ts +0 -321
  54. package/dist/models/scallopIndexer.d.ts +0 -90
  55. package/dist/models/scallopPrice.d.ts +0 -0
  56. package/dist/models/scallopQuery.d.ts +0 -704
  57. package/dist/models/scallopUtils.d.ts +0 -229
  58. package/dist/models/suiKit.d.ts +0 -2
  59. package/dist/queries/borrowIncentiveQuery.d.ts +0 -82
  60. package/dist/queries/borrowLimitQuery.d.ts +0 -9
  61. package/dist/queries/coreQuery.d.ts +0 -171
  62. package/dist/queries/index.d.ts +0 -15
  63. package/dist/queries/isolatedAssetQuery.d.ts +0 -14
  64. package/dist/queries/loyaltyProgramQuery.d.ts +0 -10
  65. package/dist/queries/objectsQuery.d.ts +0 -2
  66. package/dist/queries/poolAddressesQuery.d.ts +0 -29
  67. package/dist/queries/portfolioQuery.d.ts +0 -143
  68. package/dist/queries/priceQuery.d.ts +0 -58
  69. package/dist/queries/referralQuery.d.ts +0 -7
  70. package/dist/queries/sCoinQuery.d.ts +0 -41
  71. package/dist/queries/spoolQuery.d.ts +0 -74
  72. package/dist/queries/supplyLimitQuery.d.ts +0 -9
  73. package/dist/queries/vescaQuery.d.ts +0 -36
  74. package/dist/queries/xOracleQuery.d.ts +0 -13
  75. package/dist/types/address.d.ts +0 -108
  76. package/dist/types/builder/borrowIncentive.d.ts +0 -35
  77. package/dist/types/builder/core.d.ts +0 -56
  78. package/dist/types/builder/index.d.ts +0 -24
  79. package/dist/types/builder/loyaltyProgram.d.ts +0 -23
  80. package/dist/types/builder/referral.d.ts +0 -30
  81. package/dist/types/builder/sCoin.d.ts +0 -37
  82. package/dist/types/builder/spool.d.ts +0 -29
  83. package/dist/types/builder/vesca.d.ts +0 -51
  84. package/dist/types/constant/common.d.ts +0 -24
  85. package/dist/types/constant/enum.d.ts +0 -48
  86. package/dist/types/constant/index.d.ts +0 -3
  87. package/dist/types/constant/xOracle.d.ts +0 -9
  88. package/dist/types/index.d.ts +0 -6
  89. package/dist/types/model.d.ts +0 -60
  90. package/dist/types/query/borrowIncentive.d.ts +0 -124
  91. package/dist/types/query/core.d.ts +0 -380
  92. package/dist/types/query/index.d.ts +0 -7
  93. package/dist/types/query/loyaltyProgram.d.ts +0 -5
  94. package/dist/types/query/portfolio.d.ts +0 -119
  95. package/dist/types/query/sCoin.d.ts +0 -1
  96. package/dist/types/query/spool.d.ts +0 -142
  97. package/dist/types/query/vesca.d.ts +0 -26
  98. package/dist/types/utils.d.ts +0 -22
  99. package/dist/utils/builder.d.ts +0 -15
  100. package/dist/utils/core.d.ts +0 -2
  101. package/dist/utils/index.d.ts +0 -5
  102. package/dist/utils/indexer.d.ts +0 -17
  103. package/dist/utils/query.d.ts +0 -62
  104. package/dist/utils/util.d.ts +0 -27
@@ -1,27 +0,0 @@
1
- import { OptionalKeys, SupportPoolCoins } from 'src/types';
2
- export declare const POOL_ADDRESSES: OptionalKeys<Record<SupportPoolCoins, {
3
- coinName: string;
4
- symbol: string;
5
- coinType: string;
6
- lendingPoolAddress: string;
7
- borrowDynamic: string;
8
- interestModel: string;
9
- borrowFeeKey: string;
10
- coinMetadataId: string;
11
- decimals: number;
12
- pythFeed: string;
13
- pythFeedObjectId: string;
14
- collateralPoolAddress?: string;
15
- riskModel?: string;
16
- supplyLimitKey?: string;
17
- borrowLimitKey?: string;
18
- sCoinType?: string;
19
- sCoinName?: string;
20
- sCoinSymbol?: string;
21
- sCoinMetadataId?: string;
22
- sCoinTreasury?: string;
23
- isolatedAssetKey?: string;
24
- spool?: string;
25
- spoolReward?: string;
26
- spoolName?: string;
27
- }>>;
@@ -1,5 +0,0 @@
1
- import { SupportPoolCoins } from 'src/types';
2
- export declare const PYTH_ENDPOINTS: {
3
- [k in 'mainnet' | 'testnet']: string[];
4
- };
5
- export declare const PYTH_FEED_IDS: Record<SupportPoolCoins, string>;
@@ -1,54 +0,0 @@
1
- import type { GetDynamicFieldObjectParams, GetDynamicFieldsParams, GetOwnedObjectsParams, SuiObjectData, SuiObjectDataOptions } from '@mysten/sui/client';
2
- import type { SuiObjectArg, SuiTxArg } from '@scallop-io/sui-kit';
3
- export declare const queryKeys: {
4
- api: {
5
- getAddresses: (addressesId?: string) => (string | {
6
- addressesId: string | undefined;
7
- })[];
8
- getMarket: () => string[];
9
- getSpools: () => string[];
10
- getBorrowIncentivePool: () => string[];
11
- getTotalValueLocked: () => string[];
12
- };
13
- rpc: {
14
- getInspectTxn: (queryTarget?: string, args?: SuiObjectArg[], typeArgs?: any[]) => (string | {
15
- queryTarget: string | undefined;
16
- args: string;
17
- typeArgs: string | undefined;
18
- })[];
19
- getObject: (objectId?: string, options?: SuiObjectDataOptions) => (string | {
20
- objectId: string | undefined;
21
- options: SuiObjectDataOptions | undefined;
22
- })[];
23
- getObjects: (objectIds?: string[]) => (string | {
24
- objectIds: string;
25
- })[];
26
- getOwnedObjects: (input?: Partial<GetOwnedObjectsParams>) => (string | {
27
- walletAddress: string | undefined;
28
- cursor: string | undefined;
29
- options: SuiObjectDataOptions | undefined;
30
- filter: string;
31
- limit: number | undefined;
32
- })[];
33
- getDynamicFields: (input?: Partial<GetDynamicFieldsParams>) => (string | {
34
- parentId: string | undefined;
35
- cursor: string | undefined;
36
- limit: number | undefined;
37
- })[];
38
- getDynamicFieldObject: (input?: Partial<GetDynamicFieldObjectParams>) => (string | {
39
- parentId: string | undefined;
40
- name: string;
41
- })[];
42
- getTotalVeScaTreasuryAmount: (refreshArgs?: any[], vescaAmountArgs?: (string | SuiObjectData | SuiTxArg)[]) => (string | {
43
- refreshArgs: string;
44
- vescaAmountArgs: string;
45
- })[];
46
- getAllCoinBalances: (owner?: string) => (string | {
47
- owner: string | undefined;
48
- })[];
49
- getNormalizedMoveFunction: (target?: string) => (string | undefined)[];
50
- };
51
- oracle: {
52
- getPythLatestPriceFeeds: () => string[];
53
- };
54
- };
@@ -1 +0,0 @@
1
- export declare const RPC_PROVIDERS: string[];
@@ -1,2 +0,0 @@
1
- import { AddressesInterface } from 'src/types';
2
- export declare const TEST_ADDRESSES: AddressesInterface;
@@ -1,5 +0,0 @@
1
- export declare const UNLOCK_ROUND_DURATION: number;
2
- export declare const MAX_LOCK_ROUNDS: 1460;
3
- export declare const MAX_LOCK_DURATION: number;
4
- export declare const MIN_INITIAL_LOCK_AMOUNT: 10000000000;
5
- export declare const MIN_TOP_UP_AMOUNT: 1000000000;
@@ -1,2 +0,0 @@
1
- import { xOracleListType } from 'src/types';
2
- export declare const xOracleList: xOracleListType;