@xoxno/types 1.0.470 → 1.0.473

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 (28) hide show
  1. package/dist/common/kusto/lending-position-status.js +1 -1
  2. package/dist/cosmos-db/documents/lending/lending-oracle.d.ts +12 -11
  3. package/dist/cosmos-db/documents/lending/lending-oracle.js +19 -62
  4. package/dist/enums/lending-governance.enum.d.ts +26 -29
  5. package/dist/enums/lending-governance.enum.js +25 -28
  6. package/dist/enums/stellar-lending-topic.enum.d.ts +39 -4
  7. package/dist/enums/stellar-lending-topic.enum.js +39 -4
  8. package/dist/index.d.ts +1 -0
  9. package/dist/index.js +1 -0
  10. package/dist/requests/lending/defillama-lending-export.dto.d.ts +238 -0
  11. package/dist/requests/lending/defillama-lending-export.dto.js +862 -0
  12. package/dist/requests/lending/stellar-lending-events.dto.d.ts +37 -1
  13. package/dist/requests/lending/stellar-lending-events.dto.js +74 -11
  14. package/dist/stellar-lending/api-dto.d.ts +12 -3
  15. package/dist/stellar-lending/documents/asset.doc.d.ts +6 -2
  16. package/dist/stellar-lending/documents/asset.doc.js +4 -0
  17. package/dist/stellar-lending/documents/spoke-asset.doc.d.ts +2 -2
  18. package/dist/stellar-lending/documents/spoke-asset.doc.js +2 -1
  19. package/dist/stellar-lending/enums/activity.enum.d.ts +2 -0
  20. package/dist/stellar-lending/enums/activity.enum.js +2 -0
  21. package/dist/stellar-lending/enums/governance.enum.d.ts +28 -23
  22. package/dist/stellar-lending/enums/governance.enum.js +27 -22
  23. package/dist/stellar-lending/kusto/activity-data.d.ts +16 -1
  24. package/dist/stellar-lending/list.d.ts +1 -1
  25. package/dist/stellar-lending/live-state.d.ts +21 -1
  26. package/dist/stellar-lending/oracle-provider.d.ts +102 -33
  27. package/dist/stellar-lending/oracle-provider.js +8 -0
  28. package/package.json +1 -1
@@ -0,0 +1,238 @@
1
+ import { ActivityChain } from '../../enums/common.enum';
2
+ /**
3
+ * Per-token (aggregated) market row for DeFiLlama / Dune integrations.
4
+ *
5
+ * TVL semantics (P2): two documented measures coexist —
6
+ * - `tvlCash*` / legacy `tvl*` = available pool cash (`hubAsset.cash`) × price
7
+ * - `tvlSupplied*` (= `supplied*`) = total supplied × price (Kusto/stats TVL)
8
+ *
9
+ * APY / utilization (P15): decimal fractions in [0, 1] (e.g. 0.05 = 5%).
10
+ */
11
+ export declare class DefillamaLendingMarketExport {
12
+ chain: ActivityChain;
13
+ project: string;
14
+ symbol: string;
15
+ token: string;
16
+ marketAddress: string;
17
+ decimals: number;
18
+ marketStatus?: string;
19
+ reserveFactorBps: number;
20
+ tvlRaw: string;
21
+ tvlCashRaw: string;
22
+ tvlSuppliedRaw: string;
23
+ suppliedRaw: string;
24
+ borrowedRaw: string;
25
+ tvlUsd: number;
26
+ tvlCashUsd: number;
27
+ tvlSuppliedUsd: number;
28
+ suppliedUsd: number;
29
+ borrowedUsd: number;
30
+ supplyApy: number;
31
+ borrowApy: number;
32
+ utilizationRate: number;
33
+ usdPrice: number;
34
+ cumulativeProtocolRevenueRaw: string;
35
+ cumulativeProtocolRevenueUsd: number;
36
+ participantsCount: number;
37
+ }
38
+ /**
39
+ * Per-(hub, asset) market row. Same fields as the aggregated per-token row
40
+ * plus `hubId` / `poolId` so DeFiLlama can emit one pool per (hub, asset).
41
+ */
42
+ export declare class DefillamaLendingHubMarketExport {
43
+ chain: ActivityChain;
44
+ project: string;
45
+ hubId: number;
46
+ hubName: string | null;
47
+ poolId: string;
48
+ url: string;
49
+ symbol: string;
50
+ token: string;
51
+ marketAddress: string;
52
+ decimals: number;
53
+ marketStatus?: string;
54
+ reserveFactorBps: number;
55
+ tvlRaw: string;
56
+ tvlCashRaw: string;
57
+ tvlSuppliedRaw: string;
58
+ suppliedRaw: string;
59
+ borrowedRaw: string;
60
+ tvlUsd: number;
61
+ tvlCashUsd: number;
62
+ tvlSuppliedUsd: number;
63
+ suppliedUsd: number;
64
+ borrowedUsd: number;
65
+ supplyApy: number;
66
+ borrowApy: number;
67
+ utilizationRate: number;
68
+ usdPrice: number;
69
+ cumulativeProtocolRevenueRaw: string;
70
+ cumulativeProtocolRevenueUsd: number;
71
+ }
72
+ /**
73
+ * Per-(spoke, hub, asset) risk/borrow-routing row for DefiLlama routing pools.
74
+ */
75
+ export declare class DefillamaLendingSpokeMarketExport {
76
+ chain: ActivityChain;
77
+ project: string;
78
+ spokeId: number;
79
+ spokeName: string | null;
80
+ hubId: number;
81
+ hubName: string | null;
82
+ poolId: string;
83
+ url: string;
84
+ symbol: string;
85
+ token: string;
86
+ marketAddress: string;
87
+ decimals: number;
88
+ active: boolean;
89
+ collateral: boolean;
90
+ borrowable: boolean;
91
+ ltv: number;
92
+ liquidationThreshold: number;
93
+ totalBorrowRaw: string;
94
+ totalBorrowUsd: number;
95
+ availableBorrowUsd: number;
96
+ usdPrice: number;
97
+ }
98
+ export declare class DefillamaLendingExportSummary {
99
+ marketCount: number;
100
+ tvlUsd: number;
101
+ tvlCashUsd: number;
102
+ tvlSuppliedUsd: number;
103
+ suppliedUsd: number;
104
+ borrowedUsd: number;
105
+ cumulativeProtocolRevenueUsd: number;
106
+ participantsCount: number;
107
+ uniqueMarketParticipants: number;
108
+ }
109
+ export declare class DefillamaLendingExportMethodology {
110
+ tvl: string;
111
+ tvlCash: string;
112
+ tvlSupplied: string;
113
+ supplied: string;
114
+ borrowed: string;
115
+ apy: string;
116
+ revenue: string;
117
+ participants: string;
118
+ }
119
+ /**
120
+ * Canonical Stellar lending market export for `/integrations/lending/stellar`
121
+ * (and the excluded `/defillama/lending/stellar` alias).
122
+ */
123
+ export declare class DefillamaLendingExport {
124
+ project: string;
125
+ chain: ActivityChain;
126
+ generatedAt: string;
127
+ markets: DefillamaLendingMarketExport[];
128
+ hubMarkets: DefillamaLendingHubMarketExport[];
129
+ spokeMarkets: DefillamaLendingSpokeMarketExport[];
130
+ summary: DefillamaLendingExportSummary;
131
+ methodology: DefillamaLendingExportMethodology;
132
+ }
133
+ export declare class DefillamaLendingHistoryMarketExport {
134
+ chain: ActivityChain;
135
+ project: string;
136
+ token: string;
137
+ twapSupplyApy: number;
138
+ twapBorrowApy: number;
139
+ twapUtilizationRate: number;
140
+ twapSupplyAmount: number;
141
+ twapBorrowAmount: number;
142
+ }
143
+ export declare class DefillamaLendingHistoryPointExport {
144
+ chain: ActivityChain;
145
+ project: string;
146
+ token: string;
147
+ timestamp: string;
148
+ minSupplyApy: number;
149
+ maxSupplyApy: number;
150
+ avgSupplyApy: number;
151
+ minBorrowApy: number;
152
+ maxBorrowApy: number;
153
+ avgBorrowApy: number;
154
+ minUtilizationRate: number;
155
+ maxUtilizationRate: number;
156
+ avgUtilizationRate: number;
157
+ minSupplyAmount: number;
158
+ maxSupplyAmount: number;
159
+ avgSupplyAmount: number;
160
+ minBorrowAmount: number;
161
+ maxBorrowAmount: number;
162
+ avgBorrowAmount: number;
163
+ }
164
+ export declare class DefillamaLendingHistoryExport {
165
+ project: string;
166
+ chain: ActivityChain;
167
+ generatedAt: string;
168
+ startTime: string;
169
+ endTime: string;
170
+ bin: string;
171
+ markets: DefillamaLendingHistoryMarketExport[];
172
+ points: DefillamaLendingHistoryPointExport[];
173
+ }
174
+ export declare class DefillamaLendingRevenuePointExport {
175
+ chain: ActivityChain;
176
+ project: string;
177
+ timestamp: string;
178
+ dailyFeesUsd: number;
179
+ dailyRevenueUsd: number;
180
+ dailyProtocolRevenueUsd: number;
181
+ dailyInterestRevenueUsd: number;
182
+ dailyStrategyFeeRevenueUsd: number;
183
+ dailyFlashLoanRevenueUsd: number;
184
+ dailySupplySideRevenueUsd: number;
185
+ cumulativeProtocolRevenueUsd: number;
186
+ }
187
+ export declare class DefillamaLendingRevenueMarketPointExport {
188
+ chain: ActivityChain;
189
+ project: string;
190
+ timestamp: string;
191
+ token: string;
192
+ symbol: string;
193
+ dailyFeesNative: number;
194
+ dailyFeesUsd: number;
195
+ dailyProtocolRevenueNative: number;
196
+ dailyProtocolRevenueUsd: number;
197
+ dailyInterestRevenueNative: number;
198
+ dailyInterestRevenueUsd: number;
199
+ dailyStrategyFeeRevenueNative: number;
200
+ dailyStrategyFeeRevenueUsd: number;
201
+ dailyFlashLoanRevenueNative: number;
202
+ dailyFlashLoanRevenueUsd: number;
203
+ cumulativeProtocolRevenueNative: number;
204
+ cumulativeProtocolRevenueUsd: number;
205
+ usdPrice: number;
206
+ }
207
+ export declare class DefillamaLendingRevenueMethodology {
208
+ fees: string;
209
+ revenue: string;
210
+ breakdown: string;
211
+ nativeMarketValues: string;
212
+ supplySideRevenue: string;
213
+ }
214
+ export declare class DefillamaLendingRevenueExport {
215
+ project: string;
216
+ chain: ActivityChain;
217
+ generatedAt: string;
218
+ startTime: string;
219
+ endTime: string;
220
+ points: DefillamaLendingRevenuePointExport[];
221
+ markets: DefillamaLendingRevenueMarketPointExport[];
222
+ methodology: DefillamaLendingRevenueMethodology;
223
+ }
224
+ /**
225
+ * Windowed lending user stats. Users are counted by OWNER (wallet address);
226
+ * `activeAccounts` is the sub-account count.
227
+ */
228
+ export declare class StellarLendingUserStatsExport {
229
+ project: string;
230
+ chain: ActivityChain;
231
+ generatedAt: string;
232
+ startTime: string;
233
+ endTime: string;
234
+ activeUsers: number;
235
+ newUsers: number;
236
+ activeAccounts: number;
237
+ transactions: number;
238
+ }