@1delta/margin-fetcher 0.0.330 → 0.0.332
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.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +450 -22
- package/dist/index.js.map +1 -1
- package/dist/lending/public-data/fluid/publicCallParse.d.ts +1 -1
- package/dist/lending/public-data/liquity/convertPublic.d.ts +13 -6
- package/dist/lending/public-data/liquity/convertPublic.d.ts.map +1 -1
- package/dist/lending/public-data/river/convertPublic.d.ts +10 -4
- package/dist/lending/public-data/river/convertPublic.d.ts.map +1 -1
- package/dist/lending/public-data/term/apiClient.d.ts +9 -1
- package/dist/lending/public-data/term/apiClient.d.ts.map +1 -1
- package/dist/lending/public-data/term/index.d.ts +1 -1
- package/dist/lending/public-data/term/index.d.ts.map +1 -1
- package/dist/lending/public-data/term/types.d.ts +49 -0
- package/dist/lending/public-data/term/types.d.ts.map +1 -1
- package/dist/lending/user-data/exactly/userCallParse.d.ts.map +1 -1
- package/dist/lending/user-data/liquity/userCallParse.d.ts +1 -1
- package/dist/lending/user-data/river/userCallParse.d.ts +1 -1
- package/dist/prices/oracle-prices/fetchOraclePrices.d.ts +2 -1
- package/dist/prices/oracle-prices/fetchOraclePrices.d.ts.map +1 -1
- package/dist/prices/oracle-prices/fetchers/exactly.d.ts +420 -0
- package/dist/prices/oracle-prices/fetchers/exactly.d.ts.map +1 -0
- package/dist/prices/oracle-prices/fetchers/index.d.ts +4 -0
- package/dist/prices/oracle-prices/fetchers/index.d.ts.map +1 -1
- package/dist/prices/oracle-prices/fetchers/liquity.d.ts +49 -0
- package/dist/prices/oracle-prices/fetchers/liquity.d.ts.map +1 -0
- package/dist/prices/oracle-prices/fetchers/river.d.ts +269 -0
- package/dist/prices/oracle-prices/fetchers/river.d.ts.map +1 -0
- package/dist/prices/oracle-prices/fetchers/term.d.ts +59 -0
- package/dist/prices/oracle-prices/fetchers/term.d.ts.map +1 -0
- package/package.json +4 -4
|
@@ -29,7 +29,7 @@ export interface FluidLiquidityTokenState {
|
|
|
29
29
|
* data[0] = VaultEntireData[] (VaultResolver.getVaultsEntireData)
|
|
30
30
|
* data[1] = OverallTokenData[] (LiquidityResolver.getAllOverallTokensData)
|
|
31
31
|
*
|
|
32
|
-
* Emits one bucket per vault under lender key `FLUID_<vaultId>` (mirrors the
|
|
32
|
+
* Emits one bucket per vault under lender key `FLUID_<chainId>_<vaultId>` (mirrors the
|
|
33
33
|
* Morpho Blue pattern of one lender per isolated market).
|
|
34
34
|
*
|
|
35
35
|
* fTokens are NOT handled here — they are standalone ERC-4626 vaults on the
|
|
@@ -1,21 +1,28 @@
|
|
|
1
1
|
import { MorphoGeneralPublicResponse } from '../../../types/lender/morpho-types';
|
|
2
2
|
import { AdditionalYields, GenericTokenList } from '../../../types';
|
|
3
3
|
import type { LiquityMarketsRaw } from './types';
|
|
4
|
-
/** Synthesized per-branch lender key, e.g. `LIQUITY_V2_1` (= wstETH branch). */
|
|
5
|
-
export declare function liquityLenderKey(lender: string, collIndex: number): string;
|
|
6
4
|
/**
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
5
|
+
* Synthesized per-branch lender key, e.g. `LIQUITY_V2_1_1` (= mainnet wstETH
|
|
6
|
+
* branch). The CHAIN ID is part of the key (Fluid convention,
|
|
7
|
+
* `FLUID_<chainId>_<vaultId>`) so keys stay GLOBALLY unique for multi-chain
|
|
8
|
+
* deployments (Ebisu spans Ethereum + Plasma) — labels, yield-tracer rows and
|
|
9
|
+
* anything else keyed by lender_key alone would collide otherwise.
|
|
10
|
+
*/
|
|
11
|
+
export declare function liquityLenderKey(lender: string, chainId: string | number, collIndex: number): string;
|
|
12
|
+
/**
|
|
13
|
+
* Recover `{ lender, chainId, collIndex }` from a per-branch key (or
|
|
14
|
+
* undefined for a bare deployment key / non-family key). Fork brands share no
|
|
15
|
+
* prefix, so this matches against the family list.
|
|
10
16
|
*/
|
|
11
17
|
export declare function liquityKeyParts(key: string): {
|
|
12
18
|
lender: string;
|
|
19
|
+
chainId: string;
|
|
13
20
|
collIndex: number;
|
|
14
21
|
} | undefined;
|
|
15
22
|
/**
|
|
16
23
|
* Map one deployment's on-chain branch batch into the shared
|
|
17
24
|
* `MorphoGeneralPublicResponse` shape (identical to Midnight/Term/Exactly),
|
|
18
|
-
* keyed by `<LENDER>_<COLL_INDEX>` — one key per collateral branch.
|
|
25
|
+
* keyed by `<LENDER>_<chainId>_<COLL_INDEX>` — one key per collateral branch.
|
|
19
26
|
*
|
|
20
27
|
* Per branch:
|
|
21
28
|
* - the COLLATERAL entry (branch coll token): totals = branch collateral;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"convertPublic.d.ts","sourceRoot":"","sources":["../../../../src/lending/public-data/liquity/convertPublic.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,2BAA2B,EAAE,MAAM,oCAAoC,CAAA;AAChF,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAA;AAGnE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAA;AAEhD
|
|
1
|
+
{"version":3,"file":"convertPublic.d.ts","sourceRoot":"","sources":["../../../../src/lending/public-data/liquity/convertPublic.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,2BAA2B,EAAE,MAAM,oCAAoC,CAAA;AAChF,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAA;AAGnE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAA;AAEhD;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAC9B,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,MAAM,GAAG,MAAM,EACxB,SAAS,EAAE,MAAM,GAChB,MAAM,CAER;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAC7B,GAAG,EAAE,MAAM,GACV;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAE,GAAG,SAAS,CAOpE;AAkBD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,+BAA+B,CAC7C,GAAG,EAAE,iBAAiB,EACtB,OAAO,EAAE,MAAM,EACf,MAAM,GAAE;IAAE,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAAA;CAAO,EACxC,iBAAiB,GAAE,gBAIlB,EACD,MAAM,GAAE,gBAAqB,GAC5B;IAAE,CAAC,CAAC,EAAE,MAAM,GAAG,2BAA2B,CAAA;CAAE,CA4O9C"}
|
|
@@ -1,16 +1,22 @@
|
|
|
1
1
|
import { MorphoGeneralPublicResponse } from '../../../types/lender/morpho-types';
|
|
2
2
|
import { AdditionalYields, GenericTokenList } from '../../../types';
|
|
3
3
|
import type { RiverMarketsRaw } from './types';
|
|
4
|
-
/**
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
/**
|
|
5
|
+
* Synthesized per-TroveManager lender key, e.g. `RIVER_8453_2` (= Base cbBTC
|
|
6
|
+
* market). The CHAIN ID is part of the key (Fluid convention) so keys stay
|
|
7
|
+
* GLOBALLY unique — River deploys the same factory indexes on BNB, Base and
|
|
8
|
+
* Hemi with different collaterals.
|
|
9
|
+
*/
|
|
10
|
+
export declare function riverLenderKey(lender: string, chainId: string | number, index: number): string;
|
|
11
|
+
/** Recover `{ lender, chainId, index }` from a per-market key (or undefined). */
|
|
7
12
|
export declare function riverKeyParts(key: string): {
|
|
8
13
|
lender: string;
|
|
14
|
+
chainId: string;
|
|
9
15
|
index: number;
|
|
10
16
|
} | undefined;
|
|
11
17
|
/**
|
|
12
18
|
* Map one River deployment's on-chain batch into the shared
|
|
13
|
-
* `MorphoGeneralPublicResponse` shape, keyed by `RIVER_<TM_INDEX>` — one key
|
|
19
|
+
* `MorphoGeneralPublicResponse` shape, keyed by `RIVER_<chainId>_<TM_INDEX>` — one key
|
|
14
20
|
* per TroveManager (collateral market).
|
|
15
21
|
*
|
|
16
22
|
* Per market:
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"convertPublic.d.ts","sourceRoot":"","sources":["../../../../src/lending/public-data/river/convertPublic.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,2BAA2B,EAAE,MAAM,oCAAoC,CAAA;AAChF,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAA;AAGnE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAA;AAE9C
|
|
1
|
+
{"version":3,"file":"convertPublic.d.ts","sourceRoot":"","sources":["../../../../src/lending/public-data/river/convertPublic.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,2BAA2B,EAAE,MAAM,oCAAoC,CAAA;AAChF,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAA;AAGnE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAA;AAE9C;;;;;GAKG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,MAAM,GAAG,MAAM,EACxB,KAAK,EAAE,MAAM,GACZ,MAAM,CAER;AAED,iFAAiF;AACjF,wBAAgB,aAAa,CAC3B,GAAG,EAAE,MAAM,GACV;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,GAAG,SAAS,CAMhE;AAkBD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,6BAA6B,CAC3C,GAAG,EAAE,eAAe,EACpB,OAAO,EAAE,MAAM,EACf,MAAM,GAAE;IAAE,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAAA;CAAO,EACxC,iBAAiB,GAAE,gBAIlB,EACD,MAAM,GAAE,gBAAqB,GAC5B;IAAE,CAAC,CAAC,EAAE,MAAM,GAAG,2BAA2B,CAAA;CAAE,CA6M9C"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { TermMarketConfig } from '@1delta/data-sdk';
|
|
2
|
-
import type { TermBook, TermBookSource, TermBookTop, TermListing } from './types';
|
|
2
|
+
import type { TermAuctionOrders, TermBook, TermBookSource, TermBookTop, TermListing } from './types';
|
|
3
3
|
/** Default Ormi core subgraph endpoints (org 05e9a4e2-…) by chainId. */
|
|
4
4
|
export declare const TERM_SUBGRAPH_BY_CHAIN: Record<string, string>;
|
|
5
5
|
type FetchLike = typeof fetch;
|
|
@@ -29,6 +29,14 @@ export declare class TermSubgraphSource implements TermBookSource {
|
|
|
29
29
|
book: TermBook;
|
|
30
30
|
} | null>;
|
|
31
31
|
getListings(config: TermMarketConfig): Promise<TermListing[] | null>;
|
|
32
|
+
/**
|
|
33
|
+
* A user's primary-auction offers + bids for a repo. Offers/bids link to an
|
|
34
|
+
* `auction`, which links to a `term` (the repo) — so we filter by the
|
|
35
|
+
* submitter AND the nested `auction_.term`. The revealed price is 0 (Bytes
|
|
36
|
+
* `unrevealed*Price` still sealed) until the reveal window; `active` marks
|
|
37
|
+
* submissions whose auction is neither complete nor cancelled.
|
|
38
|
+
*/
|
|
39
|
+
getAuctionOrders(config: TermMarketConfig, account: string): Promise<TermAuctionOrders | null>;
|
|
32
40
|
}
|
|
33
41
|
/** Default Term public-data source for a chain (subgraph via resolved URL). */
|
|
34
42
|
export declare function createTermBookSource(chainId: string, fetchImpl?: FetchLike): TermBookSource;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"apiClient.d.ts","sourceRoot":"","sources":["../../../../src/lending/public-data/term/apiClient.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAA;AACxD,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"apiClient.d.ts","sourceRoot":"","sources":["../../../../src/lending/public-data/term/apiClient.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gBAAgB,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ic';
|
|
3
3
|
export { TermSubgraphSource, createTermBookSource, termApiBaseUrl, } from './apiClient';
|
|
4
4
|
export { termMaintenanceRatioToLtv, termLiquidatedDamagesToPenalty, termDiscountRateToAprPct, } from './math';
|
|
5
|
-
export type { TermBook, TermBookLevel, TermBookSource, TermBookTop, TermListing, TermMarketRaw, } from './types';
|
|
5
|
+
export type { TermAuctionOrder, TermAuctionOrders, TermBook, TermBookLevel, TermBookSource, TermBookTop, TermListing, TermMarketRaw, } from './types';
|
|
6
6
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lending/public-data/term/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAA;AAChD,OAAO,EAAE,4BAA4B,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAC7E,OAAO,EACL,kBAAkB,EAClB,oBAAoB,EACpB,cAAc,GACf,MAAM,aAAa,CAAA;AACpB,OAAO,EACL,yBAAyB,EACzB,8BAA8B,EAC9B,wBAAwB,GACzB,MAAM,QAAQ,CAAA;AACf,YAAY,EACV,QAAQ,EACR,aAAa,EACb,cAAc,EACd,WAAW,EACX,WAAW,EACX,aAAa,GACd,MAAM,SAAS,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lending/public-data/term/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAA;AAChD,OAAO,EAAE,4BAA4B,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAC7E,OAAO,EACL,kBAAkB,EAClB,oBAAoB,EACpB,cAAc,GACf,MAAM,aAAa,CAAA;AACpB,OAAO,EACL,yBAAyB,EACzB,8BAA8B,EAC9B,wBAAwB,GACzB,MAAM,QAAQ,CAAA;AACf,YAAY,EACV,gBAAgB,EAChB,iBAAiB,EACjB,QAAQ,EACR,aAAa,EACb,cAAc,EACd,WAAW,EACX,WAAW,EACX,aAAa,GACd,MAAM,SAAS,CAAA"}
|
|
@@ -47,6 +47,49 @@ export interface TermListing {
|
|
|
47
47
|
/** Effective discount rate in percent, if the source provides it. */
|
|
48
48
|
discountRatePct?: number;
|
|
49
49
|
}
|
|
50
|
+
/**
|
|
51
|
+
* One PRIMARY-auction submission by a user (the sealed-bid book that has no
|
|
52
|
+
* instant-settle counterpart): `offer` = a lend commitment, `bid` = a borrow
|
|
53
|
+
* commitment. Only surfaces AFTER the on-chain entity exists (i.e. locked) —
|
|
54
|
+
* the pre-image price stays sealed (`revealed=false`) until the reveal window.
|
|
55
|
+
* The `active` flag marks submissions whose auction is still running (awaiting
|
|
56
|
+
* reveal/clearing, so still cancellable/actionable); once the auction clears,
|
|
57
|
+
* `assignedAmount` is how much was filled into a position.
|
|
58
|
+
*/
|
|
59
|
+
export interface TermAuctionOrder {
|
|
60
|
+
/** Subgraph entity id (the offer/bid id). */
|
|
61
|
+
id: string;
|
|
62
|
+
side: 'offer' | 'bid';
|
|
63
|
+
/** Auction (offer/bid locker round) this submission belongs to. */
|
|
64
|
+
auctionId: string;
|
|
65
|
+
/** Submitter address (offeror for offers, bidder for bids). */
|
|
66
|
+
account: string;
|
|
67
|
+
/** Submitted amount, purchase(loan)-token base units (raw string). */
|
|
68
|
+
amount: string;
|
|
69
|
+
/** Same amount decimal-scaled to loan-token assets (human number). */
|
|
70
|
+
assets: number;
|
|
71
|
+
/** Amount assigned when the auction cleared, base units (raw; 0 while pending). */
|
|
72
|
+
assignedAmount: string;
|
|
73
|
+
/** Still locked in the auction locker. */
|
|
74
|
+
locked: boolean;
|
|
75
|
+
/** True once the sealed price has been revealed (revealed price > 0). */
|
|
76
|
+
revealed: boolean;
|
|
77
|
+
/** Revealed annualized rate (WAD, raw string) or null while still sealed. */
|
|
78
|
+
revealedPriceWad: string | null;
|
|
79
|
+
/** Auction still open — not complete and not cancelled (actionable). */
|
|
80
|
+
active: boolean;
|
|
81
|
+
auctionComplete: boolean;
|
|
82
|
+
auctionCancelled: boolean;
|
|
83
|
+
/** Reveal window opens (unix seconds). */
|
|
84
|
+
revealTime: number;
|
|
85
|
+
/** Auction closes / clears (unix seconds). */
|
|
86
|
+
auctionEndTime: number;
|
|
87
|
+
}
|
|
88
|
+
/** A user's primary-auction submissions for one repo, split by side. */
|
|
89
|
+
export interface TermAuctionOrders {
|
|
90
|
+
offers: TermAuctionOrder[];
|
|
91
|
+
bids: TermAuctionOrder[];
|
|
92
|
+
}
|
|
50
93
|
/**
|
|
51
94
|
* Pluggable Term public-data source. The hosted subgraph is the source today;
|
|
52
95
|
* an on-chain reader could implement the same interface later. All methods
|
|
@@ -57,6 +100,12 @@ export interface TermBookSource {
|
|
|
57
100
|
getBookTop(config: TermMarketConfig): Promise<TermBookTop | null>;
|
|
58
101
|
/** Active secondary listings for a repo, or null when unavailable. */
|
|
59
102
|
getListings?(config: TermMarketConfig): Promise<TermListing[] | null>;
|
|
103
|
+
/**
|
|
104
|
+
* A user's PRIMARY-auction submissions (offers + bids) for a repo — the
|
|
105
|
+
* sealed-bid book that has no continuous/instant surface. Returns null when
|
|
106
|
+
* no subgraph is configured. Prices stay sealed until reveal.
|
|
107
|
+
*/
|
|
108
|
+
getAuctionOrders?(config: TermMarketConfig, account: string): Promise<TermAuctionOrders | null>;
|
|
60
109
|
/**
|
|
61
110
|
* ONE query → the aggregate top PLUS a bounded book slice (top `maxLevels`
|
|
62
111
|
* per side). The public batch uses this so it captures a chunk of the order
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/lending/public-data/term/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAA;AAExD;;;;;;;;GAQG;AACH,MAAM,WAAW,WAAW;IAC1B,8EAA8E;IAC9E,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,yDAAyD;IAC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AA4E;IAC5E,IAAI,CAAC,EAAE,QAAQ,GAAG,IAAI,CAAA;CACvB"}
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/lending/public-data/term/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAA;AAExD;;;;;;;;GAQG;AACH,MAAM,WAAW,WAAW;IAC1B,8EAA8E;IAC9E,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,yDAAyD;IACzD,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,0EAA0E;IAC1E,eAAe,EAAE,MAAM,CAAA;IACvB,4EAA4E;IAC5E,eAAe,EAAE,MAAM,CAAA;CACxB;AAED,gEAAgE;AAChE,MAAM,WAAW,aAAa;IAC5B,8CAA8C;IAC9C,GAAG,EAAE,MAAM,CAAA;IACX,0DAA0D;IAC1D,KAAK,EAAE,MAAM,CAAA;IACb,wDAAwD;IACxD,MAAM,EAAE,MAAM,CAAA;CACf;AAED;;;;;GAKG;AACH,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,aAAa,EAAE,CAAA;IACrB,IAAI,EAAE,aAAa,EAAE,CAAA;CACtB;AAED,wFAAwF;AACxF,MAAM,WAAW,WAAW;IAC1B,SAAS,EAAE,MAAM,CAAA;IACjB,MAAM,EAAE,MAAM,CAAA;IACd,SAAS,EAAE,MAAM,CAAA;IACjB,sDAAsD;IACtD,MAAM,EAAE,MAAM,CAAA;IACd,qEAAqE;IACrE,eAAe,CAAC,EAAE,MAAM,CAAA;CACzB;AAED;;;;;;;;GAQG;AACH,MAAM,WAAW,gBAAgB;IAC/B,6CAA6C;IAC7C,EAAE,EAAE,MAAM,CAAA;IACV,IAAI,EAAE,OAAO,GAAG,KAAK,CAAA;IACrB,mEAAmE;IACnE,SAAS,EAAE,MAAM,CAAA;IACjB,+DAA+D;IAC/D,OAAO,EAAE,MAAM,CAAA;IACf,sEAAsE;IACtE,MAAM,EAAE,M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CAAA;IACxB,GAAG,EAAE,WAAW,GAAG,IAAI,CAAA;IACvB,4EAA4E;IAC5E,IAAI,CAAC,EAAE,QAAQ,GAAG,IAAI,CAAA;CACvB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"userCallParse.d.ts","sourceRoot":"","sources":["../../../../src/lending/user-data/exactly/userCallParse.ts"],"names":[],"mappings":"AAKA,OAAO,EAEL,2BAA2B,EAC3B,QAAQ,EACT,MAAM,gBAAgB,CAAA;AASvB,iFAAiF;AACjF,MAAM,WAAW,wBAAwB;IACvC,oBAAoB;IACpB,QAAQ,EAAE,MAAM,CAAA;IAChB,2BAA2B;IAC3B,IAAI,EAAE,SAAS,GAAG,QAAQ,CAAA;IAC1B,uCAAuC;IACvC,SAAS,EAAE,MAAM,CAAA;IACjB,sDAAsD;IACtD,GAAG,EAAE,MAAM,CAAA;IACX;yDACqD;IACrD,YAAY,EAAE,MAAM,CAAA;IACpB;oDACgD;IAChD,OAAO,EAAE,OAAO,CAAA;CACjB;AAqBD;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,2BAA2B,GACtC,SAAS,MAAM,EACf,SAAS,MAAM,EACf,SAAS,MAAM,EACf,OAAO,2BAA2B,KACjC,CAAC,CAAC,IAAI,EAAE,GAAG,EAAE,KAAK;IAAE,CAAC,MAAM,EAAE,MAAM,GAAG,QAAQ,CAAA;CAAE,GAAG,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"userCallParse.d.ts","sourceRoot":"","sources":["../../../../src/lending/user-data/exactly/userCallParse.ts"],"names":[],"mappings":"AAKA,OAAO,EAEL,2BAA2B,EAC3B,QAAQ,EACT,MAAM,gBAAgB,CAAA;AASvB,iFAAiF;AACjF,MAAM,WAAW,wBAAwB;IACvC,oBAAoB;IACpB,QAAQ,EAAE,MAAM,CAAA;IAChB,2BAA2B;IAC3B,IAAI,EAAE,SAAS,GAAG,QAAQ,CAAA;IAC1B,uCAAuC;IACvC,SAAS,EAAE,MAAM,CAAA;IACjB,sDAAsD;IACtD,GAAG,EAAE,MAAM,CAAA;IACX;yDACqD;IACrD,YAAY,EAAE,MAAM,CAAA;IACpB;oDACgD;IAChD,OAAO,EAAE,OAAO,CAAA;CACjB;AAqBD;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,2BAA2B,GACtC,SAAS,MAAM,EACf,SAAS,MAAM,EACf,SAAS,MAAM,EACf,OAAO,2BAA2B,KACjC,CAAC,CAAC,IAAI,EAAE,GAAG,EAAE,KAAK;IAAE,CAAC,MAAM,EAAE,MAAM,GAAG,QAAQ,CAAA;CAAE,GAAG,SAAS,EAAE,MAAM,CAgLtE,CAAA"}
|
|
@@ -35,7 +35,7 @@ export interface LiquitySpInfo {
|
|
|
35
35
|
*
|
|
36
36
|
* Layout mirrors `buildLiquityUserCall` (reconstructed from the discovery
|
|
37
37
|
* cache + branch config — both deterministic within the request). Emits one
|
|
38
|
-
* `UserData` per BRANCH key `<LENDER>_<COLL_INDEX>`, each containing:
|
|
38
|
+
* `UserData` per BRANCH key `<LENDER>_<chainId>_<COLL_INDEX>`, each containing:
|
|
39
39
|
*
|
|
40
40
|
* - one sub-account PER TROVE (`accountId` = decimal troveId): collateral
|
|
41
41
|
* row (`entireColl`) + stable debt row (`entireDebt`, incl. accrued
|
|
@@ -11,7 +11,7 @@ export interface RiverPositionInfo {
|
|
|
11
11
|
*
|
|
12
12
|
* Layout mirrors `buildRiverUserCall` (deterministic from config — no
|
|
13
13
|
* discovery cache needed). Emits one `UserData` per market key
|
|
14
|
-
* `RIVER_<TM_INDEX>`, each with a single sub-account `'0'` (troves are
|
|
14
|
+
* `RIVER_<chainId>_<TM_INDEX>`, each with a single sub-account `'0'` (troves are
|
|
15
15
|
* address-keyed: at most ONE per user per market): collateral row
|
|
16
16
|
* (entire coll incl. pending redistribution) + satUSD debt row (entire debt)
|
|
17
17
|
* with `riverInfo` (collateral surplus). The single per-chain StabilityPool
|
|
@@ -40,7 +40,8 @@ export interface FetchOraclePricesOptions {
|
|
|
40
40
|
/**
|
|
41
41
|
* Only run these fetcher groups. Useful for debugging individual protocols.
|
|
42
42
|
* Values: 'aave', 'compoundV2', 'compoundV3', 'lista', 'eulerV2', 'aaveV4',
|
|
43
|
-
* 'morpho', 'midnight', '
|
|
43
|
+
* 'morpho', 'midnight', 'exactly', 'term', 'liquity', 'river', 'siloV2',
|
|
44
|
+
* 'siloV3', 'fluid'.
|
|
44
45
|
* If omitted, all fetchers run.
|
|
45
46
|
*/
|
|
46
47
|
onlyFetchers?: string[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fetchOraclePrices.d.ts","sourceRoot":"","sources":["../../../src/prices/oracle-prices/fetchOraclePrices.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,WAAW,EAEX,YAAY,EAKZ,kBAAkB,EAEnB,MAAM,SAAS,CAAA;AAChB,OAAO,
|
|
1
|
+
{"version":3,"file":"fetchOraclePrices.d.ts","sourceRoot":"","sources":["../../../src/prices/oracle-prices/fetchOraclePrices.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,WAAW,EAEX,YAAY,EAKZ,kBAAkB,EAEnB,MAAM,SAAS,CAAA;AAChB,OAAO,EAyBL,KAAK,qBAAqB,EAC1B,KAAK,oBAAoB,EAC1B,MAAM,YAAY,CAAA;AAiBnB;;;GAGG;AACH,MAAM,MAAM,cAAc,GAAG;IAC3B,CAAC,OAAO,EAAE,MAAM,GAAG,YAAY,CAAA;CAChC,CAAA;AAED;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC,2CAA2C;IAC3C,YAAY,CAAC,EAAE;QAAE,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;KAAE,CAAA;IAC9C,sEAAsE;IACtE,KAAK,CAAC,EAAE,cAAc,CAAA;IACtB,sCAAsC;IACtC,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,mDAAmD;IACnD,SAAS,CAAC,EAAE;QAAE,CA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