@xoxno/types 1.0.474 → 1.0.476
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.
|
@@ -8,14 +8,14 @@ export declare class LendingIndexesDto {
|
|
|
8
8
|
egldPriceShort: number;
|
|
9
9
|
usdPrice: string;
|
|
10
10
|
usdPriceShort: number;
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
11
|
+
primaryPriceEgld: string;
|
|
12
|
+
primaryPriceEgldShort: number;
|
|
13
|
+
primaryPriceUsd: string;
|
|
14
|
+
primaryPriceUsdShort: number;
|
|
15
|
+
anchorPriceEgld: string;
|
|
16
|
+
anchorPriceEgldShort: number;
|
|
17
|
+
anchorPriceUsd: string;
|
|
18
|
+
anchorPriceUsdShort: number;
|
|
19
19
|
withinFirstTolerance?: boolean;
|
|
20
20
|
withinSecondTolerance?: boolean;
|
|
21
21
|
chain?: ActivityChain;
|
|
@@ -65,7 +65,7 @@ __decorate([
|
|
|
65
65
|
], LendingIndexesDto.prototype, "egldPriceShort", void 0);
|
|
66
66
|
__decorate([
|
|
67
67
|
(0, swagger_1.ApiProperty)({
|
|
68
|
-
description: 'USD price
|
|
68
|
+
description: 'Final composed USD price as a string to preserve precision',
|
|
69
69
|
example: '1.0',
|
|
70
70
|
type: String,
|
|
71
71
|
}),
|
|
@@ -73,7 +73,7 @@ __decorate([
|
|
|
73
73
|
], LendingIndexesDto.prototype, "usdPrice", void 0);
|
|
74
74
|
__decorate([
|
|
75
75
|
(0, swagger_1.ApiProperty)({
|
|
76
|
-
description: 'USD price
|
|
76
|
+
description: 'Final composed USD price as a number',
|
|
77
77
|
example: 1.0,
|
|
78
78
|
type: Number,
|
|
79
79
|
}),
|
|
@@ -81,68 +81,68 @@ __decorate([
|
|
|
81
81
|
], LendingIndexesDto.prototype, "usdPriceShort", void 0);
|
|
82
82
|
__decorate([
|
|
83
83
|
(0, swagger_1.ApiProperty)({
|
|
84
|
-
description: '
|
|
84
|
+
description: 'Primary (first) oracle leg in EGLD as a string. Equals the final/anchor under single-source configs. (MVX dual-source leg; Stellar leaves this unused or equal to primary USD denoms.)',
|
|
85
85
|
example: '1000000000000000000',
|
|
86
86
|
type: String,
|
|
87
87
|
}),
|
|
88
88
|
__metadata("design:type", String)
|
|
89
|
-
], LendingIndexesDto.prototype, "
|
|
89
|
+
], LendingIndexesDto.prototype, "primaryPriceEgld", void 0);
|
|
90
90
|
__decorate([
|
|
91
91
|
(0, swagger_1.ApiProperty)({
|
|
92
|
-
description: '
|
|
92
|
+
description: 'Primary oracle leg in EGLD as a number (may lose precision)',
|
|
93
93
|
example: 1,
|
|
94
94
|
type: Number,
|
|
95
95
|
}),
|
|
96
96
|
__metadata("design:type", Number)
|
|
97
|
-
], LendingIndexesDto.prototype, "
|
|
97
|
+
], LendingIndexesDto.prototype, "primaryPriceEgldShort", void 0);
|
|
98
98
|
__decorate([
|
|
99
99
|
(0, swagger_1.ApiProperty)({
|
|
100
|
-
description: '
|
|
100
|
+
description: 'Primary (first) independent oracle leg in USD as a string to preserve precision',
|
|
101
101
|
example: '16124645832563882000',
|
|
102
102
|
type: String,
|
|
103
103
|
}),
|
|
104
104
|
__metadata("design:type", String)
|
|
105
|
-
], LendingIndexesDto.prototype, "
|
|
105
|
+
], LendingIndexesDto.prototype, "primaryPriceUsd", void 0);
|
|
106
106
|
__decorate([
|
|
107
107
|
(0, swagger_1.ApiProperty)({
|
|
108
|
-
description: '
|
|
108
|
+
description: 'Primary oracle leg in USD as a number (may lose precision)',
|
|
109
109
|
example: 16.124645832563882,
|
|
110
110
|
type: Number,
|
|
111
111
|
}),
|
|
112
112
|
__metadata("design:type", Number)
|
|
113
|
-
], LendingIndexesDto.prototype, "
|
|
113
|
+
], LendingIndexesDto.prototype, "primaryPriceUsdShort", void 0);
|
|
114
114
|
__decorate([
|
|
115
115
|
(0, swagger_1.ApiProperty)({
|
|
116
|
-
description: '
|
|
116
|
+
description: 'Anchor (second) oracle leg in EGLD as a string. Equals primary under single-source configs.',
|
|
117
117
|
example: '1000000000000000000',
|
|
118
118
|
type: String,
|
|
119
119
|
}),
|
|
120
120
|
__metadata("design:type", String)
|
|
121
|
-
], LendingIndexesDto.prototype, "
|
|
121
|
+
], LendingIndexesDto.prototype, "anchorPriceEgld", void 0);
|
|
122
122
|
__decorate([
|
|
123
123
|
(0, swagger_1.ApiProperty)({
|
|
124
|
-
description: '
|
|
124
|
+
description: 'Anchor oracle leg in EGLD as a number (may lose precision)',
|
|
125
125
|
example: 1,
|
|
126
126
|
type: Number,
|
|
127
127
|
}),
|
|
128
128
|
__metadata("design:type", Number)
|
|
129
|
-
], LendingIndexesDto.prototype, "
|
|
129
|
+
], LendingIndexesDto.prototype, "anchorPriceEgldShort", void 0);
|
|
130
130
|
__decorate([
|
|
131
131
|
(0, swagger_1.ApiProperty)({
|
|
132
|
-
description: '
|
|
132
|
+
description: 'Anchor (second) independent oracle leg in USD as a string to preserve precision',
|
|
133
133
|
example: '16124645832563882000',
|
|
134
134
|
type: String,
|
|
135
135
|
}),
|
|
136
136
|
__metadata("design:type", String)
|
|
137
|
-
], LendingIndexesDto.prototype, "
|
|
137
|
+
], LendingIndexesDto.prototype, "anchorPriceUsd", void 0);
|
|
138
138
|
__decorate([
|
|
139
139
|
(0, swagger_1.ApiProperty)({
|
|
140
|
-
description: '
|
|
140
|
+
description: 'Anchor oracle leg in USD as a number (may lose precision)',
|
|
141
141
|
example: 16.124645832563882,
|
|
142
142
|
type: Number,
|
|
143
143
|
}),
|
|
144
144
|
__metadata("design:type", Number)
|
|
145
|
-
], LendingIndexesDto.prototype, "
|
|
145
|
+
], LendingIndexesDto.prototype, "anchorPriceUsdShort", void 0);
|
|
146
146
|
__decorate([
|
|
147
147
|
(0, swagger_1.ApiProperty)({
|
|
148
148
|
description: 'Whether the oracle price is within the first (tightest) deviation tolerance band. MVX-only; absent for chains whose oracle does not expose tolerance bands (e.g. Stellar). The UI borrow/withdraw flow reads this flag.',
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import type { ActivityChain } from '../enums/common.enum';
|
|
2
2
|
/**
|
|
3
3
|
* Live controller `MarketIndexView` for one hub market, plus client short
|
|
4
|
-
* scales. `hubId` is client-attached (view has no hub field)
|
|
5
|
-
*
|
|
6
|
-
*
|
|
4
|
+
* scales. `hubId` is client-attached (view has no hub field).
|
|
5
|
+
*
|
|
6
|
+
* Price legs: `usdPrice` = final composed answer; `primaryPriceUsd` /
|
|
7
|
+
* `anchorPriceUsd` = independent oracle legs (equal under single-source).
|
|
7
8
|
*/
|
|
8
9
|
export interface StellarMarketIndexByHub {
|
|
9
10
|
hubId: number;
|
|
@@ -15,23 +16,46 @@ export interface StellarMarketIndexByHub {
|
|
|
15
16
|
/** Final composed USD WAD (`price_wad`). */
|
|
16
17
|
usdPrice: string;
|
|
17
18
|
usdPriceShort: number;
|
|
18
|
-
/**
|
|
19
|
-
* Primary/first oracle leg WAD (`safe_price_wad` — historical ABI name, not a
|
|
20
|
-
* safety flag).
|
|
21
|
-
*/
|
|
19
|
+
/** First independent oracle leg WAD (`primary_price_wad`). */
|
|
22
20
|
primaryPriceUsd: string;
|
|
23
21
|
primaryPriceUsdShort: number;
|
|
24
22
|
/**
|
|
25
|
-
*
|
|
26
|
-
*
|
|
23
|
+
* Second independent oracle leg WAD (`anchor_price_wad`).
|
|
24
|
+
* Equals primary under single-source configs.
|
|
27
25
|
*/
|
|
28
26
|
anchorPriceUsd: string;
|
|
29
27
|
anchorPriceUsdShort: number;
|
|
30
|
-
/** Freshness timestamp of the final blend (seconds). */
|
|
28
|
+
/** Freshness timestamp of the final blend (seconds). Optional on live-state. */
|
|
29
|
+
priceTimestamp?: number;
|
|
30
|
+
stale?: boolean;
|
|
31
|
+
deviation?: boolean;
|
|
32
|
+
/** True when the price would pass the fail-closed solvency path. */
|
|
33
|
+
valid?: boolean;
|
|
34
|
+
chain: ActivityChain;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Full soft-status market row from controller `get_market_indexes_detailed`
|
|
38
|
+
* (api-v2 `/stellar-lending/detailed-markets`). Same price legs as
|
|
39
|
+
* `MarketIndexView` with required validity flags.
|
|
40
|
+
*/
|
|
41
|
+
export interface StellarDetailedMarketDto {
|
|
42
|
+
hubId: number;
|
|
43
|
+
asset: string;
|
|
44
|
+
supplyIndex: string;
|
|
45
|
+
supplyIndexShort: number;
|
|
46
|
+
borrowIndex: string;
|
|
47
|
+
borrowIndexShort: number;
|
|
48
|
+
usdPrice: string;
|
|
49
|
+
usdPriceShort: number;
|
|
50
|
+
/** First independent oracle leg (`primary_price_wad`). */
|
|
51
|
+
primaryPriceUsd: string;
|
|
52
|
+
primaryPriceUsdShort: number;
|
|
53
|
+
/** Second independent oracle leg (`anchor_price_wad`). */
|
|
54
|
+
anchorPriceUsd: string;
|
|
55
|
+
anchorPriceUsdShort: number;
|
|
31
56
|
priceTimestamp: number;
|
|
32
57
|
stale: boolean;
|
|
33
58
|
deviation: boolean;
|
|
34
|
-
/** True when the price would pass the fail-closed solvency path. */
|
|
35
59
|
valid: boolean;
|
|
36
60
|
chain: ActivityChain;
|
|
37
61
|
}
|