@steerprotocol/data-connector-loader 3.1.1 → 3.2.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.
- package/README.md +30 -1
- package/lib/bundle/bundleBase.d.ts +10 -5
- package/lib/bundle/bundleBase.js +65 -11
- package/lib/bundle/bundleDataConnector.d.ts +11 -4
- package/lib/bundle/bundleDataConnector.js +49 -13
- package/lib/esm/bundle/bundleBase.d.ts +10 -5
- package/lib/esm/bundle/bundleBase.js +60 -11
- package/lib/esm/bundle/bundleDataConnector.d.ts +11 -4
- package/lib/esm/bundle/bundleDataConnector.js +46 -11
- package/lib/esm/execution/executionApp.d.ts +52 -7
- package/lib/esm/execution/executionApp.js +557 -113
- package/lib/esm/execution/executionBase.d.ts +4 -4
- package/lib/esm/execution/executionBase.js +11 -12
- package/lib/esm/execution/executionDataConnector.d.ts +4 -2
- package/lib/esm/execution/executionDataConnector.js +56 -25
- package/lib/esm/index.d.ts +6 -4
- package/lib/esm/index.js +3 -4
- package/lib/esm/types.d.ts +17 -4
- package/lib/esm/utils/blockFinder.d.ts +1 -1
- package/lib/esm/utils/consts.js +43 -1
- package/lib/esm/utils/pluginManager.d.ts +1 -1
- package/lib/esm/utils/providerUtils.d.ts +4 -0
- package/lib/esm/utils/providerUtils.js +37 -0
- package/lib/esm/utils/replace-old-subgraphs.d.ts +23 -0
- package/lib/esm/utils/replace-old-subgraphs.js +123 -0
- package/lib/esm/utils/utils.d.ts +7 -6
- package/lib/esm/utils/utils.js +8 -9
- package/lib/execution/executionApp.d.ts +52 -7
- package/lib/execution/executionApp.js +556 -117
- package/lib/execution/executionBase.d.ts +4 -4
- package/lib/execution/executionBase.js +11 -12
- package/lib/execution/executionDataConnector.d.ts +4 -2
- package/lib/execution/executionDataConnector.js +61 -29
- package/lib/index.d.ts +6 -4
- package/lib/index.js +6 -21
- package/lib/types.d.ts +17 -4
- package/lib/utils/blockFinder.d.ts +1 -1
- package/lib/utils/consts.js +43 -1
- package/lib/utils/pluginManager.d.ts +1 -1
- package/lib/utils/providerUtils.d.ts +4 -0
- package/lib/utils/providerUtils.js +43 -0
- package/lib/utils/replace-old-subgraphs.d.ts +23 -0
- package/lib/utils/replace-old-subgraphs.js +129 -0
- package/lib/utils/utils.d.ts +7 -6
- package/lib/utils/utils.js +15 -16
- package/package.json +12 -3
|
@@ -1,17 +1,62 @@
|
|
|
1
|
-
import { ethers } from 'ethers';
|
|
2
|
-
import { EtherRpcConfig } from '../types';
|
|
3
|
-
import { ExecutionBase } from './executionBase';
|
|
4
|
-
export
|
|
1
|
+
import type { ethers } from 'ethers';
|
|
2
|
+
import type { EtherRpcConfig, JobDetails } from '../types.js';
|
|
3
|
+
import { ExecutionBase } from './executionBase.js';
|
|
4
|
+
export interface ExecutionAppConfig {
|
|
5
|
+
/** Vault address used for execution context and subgraph queries. */
|
|
6
|
+
vault: string;
|
|
7
|
+
/** Chain ID used to resolve RPC configuration and on-chain reads. */
|
|
8
|
+
chainId: number;
|
|
9
|
+
/** Subgraph endpoint used for protocol data queries. */
|
|
5
10
|
steerSubgraph: string;
|
|
11
|
+
poolType: {
|
|
12
|
+
/** Set true when the pool uses Algebra v1 semantics. */
|
|
13
|
+
isAlgebraPool: boolean;
|
|
14
|
+
/** Set true when the pool uses Algebra Integral semantics. */
|
|
15
|
+
isAlgebraIntegralPool: boolean;
|
|
16
|
+
/** Set true when the pool uses directional pool semantics. */
|
|
17
|
+
isDirectionalPool: boolean;
|
|
18
|
+
/** Set true when the pool uses PoolShark semantics. */
|
|
19
|
+
isPoolSharkPool: boolean;
|
|
20
|
+
/** Set true when the pool uses Aerodrome semantics. */
|
|
21
|
+
isAerodromePool: boolean;
|
|
22
|
+
};
|
|
23
|
+
apiKeys: {
|
|
24
|
+
/** API key for The Graph Studio / gateway endpoints. */
|
|
25
|
+
subgraphStudioKey: string;
|
|
26
|
+
/** API key for Sentio endpoints, if applicable. */
|
|
27
|
+
sentioApiKey: string;
|
|
28
|
+
};
|
|
29
|
+
/** Maximum number of retries for execution operations. */
|
|
30
|
+
maxRetries?: number;
|
|
31
|
+
}
|
|
32
|
+
export declare class ExecutionApp extends ExecutionBase {
|
|
6
33
|
vault: string;
|
|
34
|
+
steerSubgraph: string;
|
|
35
|
+
chainId: number;
|
|
7
36
|
isAlgebraPool: boolean;
|
|
37
|
+
isAlgebraIntegralPool: boolean;
|
|
8
38
|
isDirectionalPool: boolean;
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
39
|
+
isPoolSharkPool: boolean;
|
|
40
|
+
isAerodromePool: boolean;
|
|
41
|
+
subgraphStudioKey: string;
|
|
42
|
+
sentioApiKey: string;
|
|
43
|
+
config: ExecutionAppConfig;
|
|
44
|
+
constructor(config: ExecutionAppConfig);
|
|
45
|
+
execute<T>(_wasmFile: string | ArrayBuffer, _vaultConfig: string, _data: Array<any>, _identity?: ethers.Provider, _etherRpcConfig?: EtherRpcConfig, forceDeposit?: boolean): Promise<Array<T>>;
|
|
46
|
+
executeStabilityVault<T>(_wasmFile: string | ArrayBuffer, _vaultConfig: string, _data: Array<any>, _identity?: ethers.Provider, _etherRpcConfig?: EtherRpcConfig, forceDeposit?: boolean): Promise<Array<T>>;
|
|
47
|
+
executeDynamicJobs<T>(_wasmFile: string | ArrayBuffer, _vaultConfig: string, _data: Array<any>, _job: JobDetails, _identity?: ethers.Provider, _etherRpcConfig?: EtherRpcConfig, forceDeposit?: boolean): Promise<Array<T>>;
|
|
12
48
|
private getSmartPoolExecutionContext;
|
|
13
49
|
private getPoolCurrentTick;
|
|
50
|
+
private getTickSpacing;
|
|
51
|
+
/**
|
|
52
|
+
* Converts a value to string, handling both native bigint and serialized bigint objects
|
|
53
|
+
* from the centralized API
|
|
54
|
+
*/
|
|
55
|
+
private convertToString;
|
|
56
|
+
private getTotalAmounts;
|
|
14
57
|
private getVaultPoolAddress;
|
|
15
58
|
private getSlot0;
|
|
59
|
+
private getSlot0Aerodrome;
|
|
60
|
+
private getGlobalStateAbi;
|
|
16
61
|
private getGlobalState;
|
|
17
62
|
}
|