@injectivelabs/indexer-proto-ts-v2 1.0.0
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/generated/event_provider_api_pb.client.d.ts +156 -0
- package/generated/event_provider_api_pb.client.js +76 -0
- package/generated/event_provider_api_pb.d.ts +1980 -0
- package/generated/event_provider_api_pb.js +1776 -0
- package/generated/health_pb.client.d.ts +53 -0
- package/generated/health_pb.client.js +22 -0
- package/generated/health_pb.d.ts +309 -0
- package/generated/health_pb.js +265 -0
- package/generated/injective_accounts_rpc_pb.client.d.ts +211 -0
- package/generated/injective_accounts_rpc_pb.client.js +105 -0
- package/generated/injective_accounts_rpc_pb.d.ts +5307 -0
- package/generated/injective_accounts_rpc_pb.js +4784 -0
- package/generated/injective_archiver_rpc_pb.client.d.ts +224 -0
- package/generated/injective_archiver_rpc_pb.client.js +112 -0
- package/generated/injective_archiver_rpc_pb.d.ts +2944 -0
- package/generated/injective_archiver_rpc_pb.js +2603 -0
- package/generated/injective_auction_rpc_pb.client.d.ts +190 -0
- package/generated/injective_auction_rpc_pb.client.js +94 -0
- package/generated/injective_auction_rpc_pb.d.ts +2131 -0
- package/generated/injective_auction_rpc_pb.js +1917 -0
- package/generated/injective_campaign_rpc_pb.client.d.ts +138 -0
- package/generated/injective_campaign_rpc_pb.client.js +67 -0
- package/generated/injective_campaign_rpc_pb.d.ts +2766 -0
- package/generated/injective_campaign_rpc_pb.js +2542 -0
- package/generated/injective_chart_rpc_pb.client.d.ts +159 -0
- package/generated/injective_chart_rpc_pb.client.js +78 -0
- package/generated/injective_chart_rpc_pb.d.ts +1840 -0
- package/generated/injective_chart_rpc_pb.js +1690 -0
- package/generated/injective_derivative_exchange_rpc_pb.client.d.ts +504 -0
- package/generated/injective_derivative_exchange_rpc_pb.client.js +259 -0
- package/generated/injective_derivative_exchange_rpc_pb.d.ts +9214 -0
- package/generated/injective_derivative_exchange_rpc_pb.js +8407 -0
- package/generated/injective_exchange_rpc_pb.client.d.ts +155 -0
- package/generated/injective_exchange_rpc_pb.client.js +76 -0
- package/generated/injective_exchange_rpc_pb.d.ts +1925 -0
- package/generated/injective_exchange_rpc_pb.js +1740 -0
- package/generated/injective_explorer_rpc_pb.client.d.ts +495 -0
- package/generated/injective_explorer_rpc_pb.client.js +255 -0
- package/generated/injective_explorer_rpc_pb.d.ts +9394 -0
- package/generated/injective_explorer_rpc_pb.js +8921 -0
- package/generated/injective_insurance_rpc_pb.client.d.ts +87 -0
- package/generated/injective_insurance_rpc_pb.client.js +40 -0
- package/generated/injective_insurance_rpc_pb.d.ts +904 -0
- package/generated/injective_insurance_rpc_pb.js +807 -0
- package/generated/injective_megavault_rpc_pb.client.d.ts +155 -0
- package/generated/injective_megavault_rpc_pb.client.js +76 -0
- package/generated/injective_megavault_rpc_pb.d.ts +3408 -0
- package/generated/injective_megavault_rpc_pb.js +3019 -0
- package/generated/injective_meta_rpc_pb.client.d.ts +124 -0
- package/generated/injective_meta_rpc_pb.client.js +59 -0
- package/generated/injective_meta_rpc_pb.d.ts +825 -0
- package/generated/injective_meta_rpc_pb.js +716 -0
- package/generated/injective_oracle_rpc_pb.client.d.ts +124 -0
- package/generated/injective_oracle_rpc_pb.client.js +59 -0
- package/generated/injective_oracle_rpc_pb.d.ts +1117 -0
- package/generated/injective_oracle_rpc_pb.js +987 -0
- package/generated/injective_portfolio_rpc_pb.client.d.ts +105 -0
- package/generated/injective_portfolio_rpc_pb.client.js +49 -0
- package/generated/injective_portfolio_rpc_pb.d.ts +1492 -0
- package/generated/injective_portfolio_rpc_pb.js +1314 -0
- package/generated/injective_referral_rpc_pb.client.d.ts +89 -0
- package/generated/injective_referral_rpc_pb.client.js +41 -0
- package/generated/injective_referral_rpc_pb.d.ts +575 -0
- package/generated/injective_referral_rpc_pb.js +497 -0
- package/generated/injective_rfqrpc_pb.client.d.ts +208 -0
- package/generated/injective_rfqrpc_pb.client.js +103 -0
- package/generated/injective_rfqrpc_pb.d.ts +2241 -0
- package/generated/injective_rfqrpc_pb.js +1940 -0
- package/generated/injective_spot_exchange_rpc_pb.client.d.ts +343 -0
- package/generated/injective_spot_exchange_rpc_pb.client.js +175 -0
- package/generated/injective_spot_exchange_rpc_pb.d.ts +5958 -0
- package/generated/injective_spot_exchange_rpc_pb.js +5426 -0
- package/generated/injective_trading_rpc_pb.client.d.ts +90 -0
- package/generated/injective_trading_rpc_pb.client.js +40 -0
- package/generated/injective_trading_rpc_pb.d.ts +1882 -0
- package/generated/injective_trading_rpc_pb.js +1754 -0
- package/index.d.ts +43 -0
- package/index.js +78 -0
- package/package.json +37 -0
|
@@ -0,0 +1,1840 @@
|
|
|
1
|
+
// @generated by protobuf-ts 2.11.1 with parameter add_pb_suffix
|
|
2
|
+
// @generated from protobuf file "injective_chart_rpc.proto" (package "injective_chart_rpc", syntax proto3)
|
|
3
|
+
// tslint:disable
|
|
4
|
+
//
|
|
5
|
+
// Code generated with goa v3.7.0, DO NOT EDIT.
|
|
6
|
+
//
|
|
7
|
+
// InjectiveChartRPC protocol buffer definition
|
|
8
|
+
//
|
|
9
|
+
// Command:
|
|
10
|
+
// $ goa gen github.com/InjectiveLabs/injective-indexer/api/design -o ../
|
|
11
|
+
//
|
|
12
|
+
import { ServiceType } from "@protobuf-ts/runtime-rpc";
|
|
13
|
+
import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
|
|
14
|
+
import type { IBinaryWriter } from "@protobuf-ts/runtime";
|
|
15
|
+
import { WireType } from "@protobuf-ts/runtime";
|
|
16
|
+
import type { BinaryReadOptions } from "@protobuf-ts/runtime";
|
|
17
|
+
import type { IBinaryReader } from "@protobuf-ts/runtime";
|
|
18
|
+
import { UnknownFieldHandler } from "@protobuf-ts/runtime";
|
|
19
|
+
import type { PartialMessage } from "@protobuf-ts/runtime";
|
|
20
|
+
import { reflectionMergePartial } from "@protobuf-ts/runtime";
|
|
21
|
+
import { MessageType } from "@protobuf-ts/runtime";
|
|
22
|
+
/**
|
|
23
|
+
* @generated from protobuf message injective_chart_rpc.SpotMarketHistoryRequest
|
|
24
|
+
*/
|
|
25
|
+
export interface SpotMarketHistoryRequest {
|
|
26
|
+
/**
|
|
27
|
+
* Specify unique ticker to search
|
|
28
|
+
*
|
|
29
|
+
* @generated from protobuf field: string symbol = 1
|
|
30
|
+
*/
|
|
31
|
+
symbol: string;
|
|
32
|
+
/**
|
|
33
|
+
* As an alternative is possible to provide a marketId
|
|
34
|
+
*
|
|
35
|
+
* @generated from protobuf field: string market_id = 2
|
|
36
|
+
*/
|
|
37
|
+
marketId: string;
|
|
38
|
+
/**
|
|
39
|
+
* Symbol resolution. Possible resolutions are daily (D or 1D, 2D ... ), weekly
|
|
40
|
+
* (1W, 2W ...), monthly (1M, 2M...) and an intra-day resolution – minutes(1, 2
|
|
41
|
+
* ...).
|
|
42
|
+
*
|
|
43
|
+
* @generated from protobuf field: string resolution = 3
|
|
44
|
+
*/
|
|
45
|
+
resolution: string;
|
|
46
|
+
/**
|
|
47
|
+
* Unix timestamp (UTC) of the leftmost required bar, including from
|
|
48
|
+
*
|
|
49
|
+
* @generated from protobuf field: sint32 from = 4
|
|
50
|
+
*/
|
|
51
|
+
from: number;
|
|
52
|
+
/**
|
|
53
|
+
* Unix timestamp (UTC) of the rightmost required bar, including to. It can be
|
|
54
|
+
* in the future. In this case, the rightmost required bar is the latest
|
|
55
|
+
* available bar.
|
|
56
|
+
*
|
|
57
|
+
* @generated from protobuf field: sint32 to = 5
|
|
58
|
+
*/
|
|
59
|
+
to: number;
|
|
60
|
+
/**
|
|
61
|
+
* Number of bars (higher priority than from) starting with to. If countback is
|
|
62
|
+
* set, from should be ignored.
|
|
63
|
+
*
|
|
64
|
+
* @generated from protobuf field: sint32 countback = 6
|
|
65
|
+
*/
|
|
66
|
+
countback: number;
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* @generated from protobuf message injective_chart_rpc.SpotMarketHistoryResponse
|
|
70
|
+
*/
|
|
71
|
+
export interface SpotMarketHistoryResponse {
|
|
72
|
+
/**
|
|
73
|
+
* Bar time, Unix timestamp (UTC). Daily bars should only have the date part,
|
|
74
|
+
* time should be 0.
|
|
75
|
+
*
|
|
76
|
+
* @generated from protobuf field: repeated sint32 t = 1
|
|
77
|
+
*/
|
|
78
|
+
t: number[];
|
|
79
|
+
/**
|
|
80
|
+
* Open price.
|
|
81
|
+
*
|
|
82
|
+
* @generated from protobuf field: repeated double o = 2
|
|
83
|
+
*/
|
|
84
|
+
o: number[];
|
|
85
|
+
/**
|
|
86
|
+
* High price.
|
|
87
|
+
*
|
|
88
|
+
* @generated from protobuf field: repeated double h = 3
|
|
89
|
+
*/
|
|
90
|
+
h: number[];
|
|
91
|
+
/**
|
|
92
|
+
* Low price.
|
|
93
|
+
*
|
|
94
|
+
* @generated from protobuf field: repeated double l = 4
|
|
95
|
+
*/
|
|
96
|
+
l: number[];
|
|
97
|
+
/**
|
|
98
|
+
* Close price.
|
|
99
|
+
*
|
|
100
|
+
* @generated from protobuf field: repeated double c = 5
|
|
101
|
+
*/
|
|
102
|
+
c: number[];
|
|
103
|
+
/**
|
|
104
|
+
* Volume.
|
|
105
|
+
*
|
|
106
|
+
* @generated from protobuf field: repeated double v = 6
|
|
107
|
+
*/
|
|
108
|
+
v: number[];
|
|
109
|
+
/**
|
|
110
|
+
* Status of the request.
|
|
111
|
+
*
|
|
112
|
+
* @generated from protobuf field: string s = 7
|
|
113
|
+
*/
|
|
114
|
+
s: string;
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* @generated from protobuf message injective_chart_rpc.DerivativeMarketHistoryRequest
|
|
118
|
+
*/
|
|
119
|
+
export interface DerivativeMarketHistoryRequest {
|
|
120
|
+
/**
|
|
121
|
+
* Specify unique ticker to search.
|
|
122
|
+
*
|
|
123
|
+
* @generated from protobuf field: string symbol = 1
|
|
124
|
+
*/
|
|
125
|
+
symbol: string;
|
|
126
|
+
/**
|
|
127
|
+
* As an alternative is possible to provide a marketId
|
|
128
|
+
*
|
|
129
|
+
* @generated from protobuf field: string market_id = 2
|
|
130
|
+
*/
|
|
131
|
+
marketId: string;
|
|
132
|
+
/**
|
|
133
|
+
* Symbol resolution. Possible resolutions are daily (D or 1D, 2D ... ), weekly
|
|
134
|
+
* (1W, 2W ...), monthly (1M, 2M...) and an intra-day resolution – minutes(1, 2
|
|
135
|
+
* ...).
|
|
136
|
+
*
|
|
137
|
+
* @generated from protobuf field: string resolution = 3
|
|
138
|
+
*/
|
|
139
|
+
resolution: string;
|
|
140
|
+
/**
|
|
141
|
+
* Unix timestamp (UTC) of the leftmost required bar, including from
|
|
142
|
+
*
|
|
143
|
+
* @generated from protobuf field: sint32 from = 4
|
|
144
|
+
*/
|
|
145
|
+
from: number;
|
|
146
|
+
/**
|
|
147
|
+
* Unix timestamp (UTC) of the rightmost required bar, including to. It can be
|
|
148
|
+
* in the future. In this case, the rightmost required bar is the latest
|
|
149
|
+
* available bar.
|
|
150
|
+
*
|
|
151
|
+
* @generated from protobuf field: sint32 to = 5
|
|
152
|
+
*/
|
|
153
|
+
to: number;
|
|
154
|
+
/**
|
|
155
|
+
* Number of bars (higher priority than from) starting with to. If countback is
|
|
156
|
+
* set, from should be ignored.
|
|
157
|
+
*
|
|
158
|
+
* @generated from protobuf field: sint32 countback = 6
|
|
159
|
+
*/
|
|
160
|
+
countback: number;
|
|
161
|
+
}
|
|
162
|
+
/**
|
|
163
|
+
* @generated from protobuf message injective_chart_rpc.DerivativeMarketHistoryResponse
|
|
164
|
+
*/
|
|
165
|
+
export interface DerivativeMarketHistoryResponse {
|
|
166
|
+
/**
|
|
167
|
+
* Bar time, Unix timestamp (UTC). Daily bars should only have the date part,
|
|
168
|
+
* time should be 0.
|
|
169
|
+
*
|
|
170
|
+
* @generated from protobuf field: repeated sint32 t = 1
|
|
171
|
+
*/
|
|
172
|
+
t: number[];
|
|
173
|
+
/**
|
|
174
|
+
* Open price.
|
|
175
|
+
*
|
|
176
|
+
* @generated from protobuf field: repeated double o = 2
|
|
177
|
+
*/
|
|
178
|
+
o: number[];
|
|
179
|
+
/**
|
|
180
|
+
* High price.
|
|
181
|
+
*
|
|
182
|
+
* @generated from protobuf field: repeated double h = 3
|
|
183
|
+
*/
|
|
184
|
+
h: number[];
|
|
185
|
+
/**
|
|
186
|
+
* Low price.
|
|
187
|
+
*
|
|
188
|
+
* @generated from protobuf field: repeated double l = 4
|
|
189
|
+
*/
|
|
190
|
+
l: number[];
|
|
191
|
+
/**
|
|
192
|
+
* Close price.
|
|
193
|
+
*
|
|
194
|
+
* @generated from protobuf field: repeated double c = 5
|
|
195
|
+
*/
|
|
196
|
+
c: number[];
|
|
197
|
+
/**
|
|
198
|
+
* Volume.
|
|
199
|
+
*
|
|
200
|
+
* @generated from protobuf field: repeated double v = 6
|
|
201
|
+
*/
|
|
202
|
+
v: number[];
|
|
203
|
+
/**
|
|
204
|
+
* Status of the request.
|
|
205
|
+
*
|
|
206
|
+
* @generated from protobuf field: string s = 7
|
|
207
|
+
*/
|
|
208
|
+
s: string;
|
|
209
|
+
}
|
|
210
|
+
/**
|
|
211
|
+
* @generated from protobuf message injective_chart_rpc.SpotMarketSummaryRequest
|
|
212
|
+
*/
|
|
213
|
+
export interface SpotMarketSummaryRequest {
|
|
214
|
+
/**
|
|
215
|
+
* Market ID of the spot market
|
|
216
|
+
*
|
|
217
|
+
* @generated from protobuf field: string market_id = 1
|
|
218
|
+
*/
|
|
219
|
+
marketId: string;
|
|
220
|
+
/**
|
|
221
|
+
* Specify the resolution
|
|
222
|
+
*
|
|
223
|
+
* @generated from protobuf field: string resolution = 2
|
|
224
|
+
*/
|
|
225
|
+
resolution: string;
|
|
226
|
+
}
|
|
227
|
+
/**
|
|
228
|
+
* @generated from protobuf message injective_chart_rpc.SpotMarketSummaryResponse
|
|
229
|
+
*/
|
|
230
|
+
export interface SpotMarketSummaryResponse {
|
|
231
|
+
/**
|
|
232
|
+
* Market ID of the derivativeMarket market
|
|
233
|
+
*
|
|
234
|
+
* @generated from protobuf field: string market_id = 1
|
|
235
|
+
*/
|
|
236
|
+
marketId: string;
|
|
237
|
+
/**
|
|
238
|
+
* Open price.
|
|
239
|
+
*
|
|
240
|
+
* @generated from protobuf field: double open = 2
|
|
241
|
+
*/
|
|
242
|
+
open: number;
|
|
243
|
+
/**
|
|
244
|
+
* High price.
|
|
245
|
+
*
|
|
246
|
+
* @generated from protobuf field: double high = 3
|
|
247
|
+
*/
|
|
248
|
+
high: number;
|
|
249
|
+
/**
|
|
250
|
+
* Low price.
|
|
251
|
+
*
|
|
252
|
+
* @generated from protobuf field: double low = 4
|
|
253
|
+
*/
|
|
254
|
+
low: number;
|
|
255
|
+
/**
|
|
256
|
+
* Volume.
|
|
257
|
+
*
|
|
258
|
+
* @generated from protobuf field: double volume = 5
|
|
259
|
+
*/
|
|
260
|
+
volume: number;
|
|
261
|
+
/**
|
|
262
|
+
* Current price based on latest fill event.
|
|
263
|
+
*
|
|
264
|
+
* @generated from protobuf field: double price = 6
|
|
265
|
+
*/
|
|
266
|
+
price: number;
|
|
267
|
+
/**
|
|
268
|
+
* Change percent from opening price.
|
|
269
|
+
*
|
|
270
|
+
* @generated from protobuf field: double change = 7
|
|
271
|
+
*/
|
|
272
|
+
change: number;
|
|
273
|
+
}
|
|
274
|
+
/**
|
|
275
|
+
* @generated from protobuf message injective_chart_rpc.AllSpotMarketSummaryRequest
|
|
276
|
+
*/
|
|
277
|
+
export interface AllSpotMarketSummaryRequest {
|
|
278
|
+
/**
|
|
279
|
+
* Specify the resolution
|
|
280
|
+
*
|
|
281
|
+
* @generated from protobuf field: string resolution = 1
|
|
282
|
+
*/
|
|
283
|
+
resolution: string;
|
|
284
|
+
}
|
|
285
|
+
/**
|
|
286
|
+
* @generated from protobuf message injective_chart_rpc.AllSpotMarketSummaryResponse
|
|
287
|
+
*/
|
|
288
|
+
export interface AllSpotMarketSummaryResponse {
|
|
289
|
+
/**
|
|
290
|
+
* @generated from protobuf field: repeated injective_chart_rpc.MarketSummaryResp field = 1
|
|
291
|
+
*/
|
|
292
|
+
field: MarketSummaryResp[];
|
|
293
|
+
}
|
|
294
|
+
/**
|
|
295
|
+
* @generated from protobuf message injective_chart_rpc.MarketSummaryResp
|
|
296
|
+
*/
|
|
297
|
+
export interface MarketSummaryResp {
|
|
298
|
+
/**
|
|
299
|
+
* Market ID of the derivativeMarket market
|
|
300
|
+
*
|
|
301
|
+
* @generated from protobuf field: string market_id = 1
|
|
302
|
+
*/
|
|
303
|
+
marketId: string;
|
|
304
|
+
/**
|
|
305
|
+
* Open price.
|
|
306
|
+
*
|
|
307
|
+
* @generated from protobuf field: double open = 2
|
|
308
|
+
*/
|
|
309
|
+
open: number;
|
|
310
|
+
/**
|
|
311
|
+
* High price.
|
|
312
|
+
*
|
|
313
|
+
* @generated from protobuf field: double high = 3
|
|
314
|
+
*/
|
|
315
|
+
high: number;
|
|
316
|
+
/**
|
|
317
|
+
* Low price.
|
|
318
|
+
*
|
|
319
|
+
* @generated from protobuf field: double low = 4
|
|
320
|
+
*/
|
|
321
|
+
low: number;
|
|
322
|
+
/**
|
|
323
|
+
* Volume.
|
|
324
|
+
*
|
|
325
|
+
* @generated from protobuf field: double volume = 5
|
|
326
|
+
*/
|
|
327
|
+
volume: number;
|
|
328
|
+
/**
|
|
329
|
+
* Current price based on latest fill event.
|
|
330
|
+
*
|
|
331
|
+
* @generated from protobuf field: double price = 6
|
|
332
|
+
*/
|
|
333
|
+
price: number;
|
|
334
|
+
/**
|
|
335
|
+
* Change percent from opening price.
|
|
336
|
+
*
|
|
337
|
+
* @generated from protobuf field: double change = 7
|
|
338
|
+
*/
|
|
339
|
+
change: number;
|
|
340
|
+
}
|
|
341
|
+
/**
|
|
342
|
+
* @generated from protobuf message injective_chart_rpc.DerivativeMarketSummaryRequest
|
|
343
|
+
*/
|
|
344
|
+
export interface DerivativeMarketSummaryRequest {
|
|
345
|
+
/**
|
|
346
|
+
* Market ID of the derivative market
|
|
347
|
+
*
|
|
348
|
+
* @generated from protobuf field: string market_id = 1
|
|
349
|
+
*/
|
|
350
|
+
marketId: string;
|
|
351
|
+
/**
|
|
352
|
+
* Request the summary of index price feed
|
|
353
|
+
*
|
|
354
|
+
* @generated from protobuf field: bool index_price = 2
|
|
355
|
+
*/
|
|
356
|
+
indexPrice: boolean;
|
|
357
|
+
/**
|
|
358
|
+
* Specify the resolution
|
|
359
|
+
*
|
|
360
|
+
* @generated from protobuf field: string resolution = 3
|
|
361
|
+
*/
|
|
362
|
+
resolution: string;
|
|
363
|
+
}
|
|
364
|
+
/**
|
|
365
|
+
* @generated from protobuf message injective_chart_rpc.DerivativeMarketSummaryResponse
|
|
366
|
+
*/
|
|
367
|
+
export interface DerivativeMarketSummaryResponse {
|
|
368
|
+
/**
|
|
369
|
+
* Market ID of the derivativeMarket market
|
|
370
|
+
*
|
|
371
|
+
* @generated from protobuf field: string market_id = 1
|
|
372
|
+
*/
|
|
373
|
+
marketId: string;
|
|
374
|
+
/**
|
|
375
|
+
* Open price.
|
|
376
|
+
*
|
|
377
|
+
* @generated from protobuf field: double open = 2
|
|
378
|
+
*/
|
|
379
|
+
open: number;
|
|
380
|
+
/**
|
|
381
|
+
* High price.
|
|
382
|
+
*
|
|
383
|
+
* @generated from protobuf field: double high = 3
|
|
384
|
+
*/
|
|
385
|
+
high: number;
|
|
386
|
+
/**
|
|
387
|
+
* Low price.
|
|
388
|
+
*
|
|
389
|
+
* @generated from protobuf field: double low = 4
|
|
390
|
+
*/
|
|
391
|
+
low: number;
|
|
392
|
+
/**
|
|
393
|
+
* Volume.
|
|
394
|
+
*
|
|
395
|
+
* @generated from protobuf field: double volume = 5
|
|
396
|
+
*/
|
|
397
|
+
volume: number;
|
|
398
|
+
/**
|
|
399
|
+
* Current price based on latest fill event.
|
|
400
|
+
*
|
|
401
|
+
* @generated from protobuf field: double price = 6
|
|
402
|
+
*/
|
|
403
|
+
price: number;
|
|
404
|
+
/**
|
|
405
|
+
* Change percent from opening price.
|
|
406
|
+
*
|
|
407
|
+
* @generated from protobuf field: double change = 7
|
|
408
|
+
*/
|
|
409
|
+
change: number;
|
|
410
|
+
}
|
|
411
|
+
/**
|
|
412
|
+
* @generated from protobuf message injective_chart_rpc.AllDerivativeMarketSummaryRequest
|
|
413
|
+
*/
|
|
414
|
+
export interface AllDerivativeMarketSummaryRequest {
|
|
415
|
+
/**
|
|
416
|
+
* Specify the resolution
|
|
417
|
+
*
|
|
418
|
+
* @generated from protobuf field: string resolution = 1
|
|
419
|
+
*/
|
|
420
|
+
resolution: string;
|
|
421
|
+
}
|
|
422
|
+
/**
|
|
423
|
+
* @generated from protobuf message injective_chart_rpc.AllDerivativeMarketSummaryResponse
|
|
424
|
+
*/
|
|
425
|
+
export interface AllDerivativeMarketSummaryResponse {
|
|
426
|
+
/**
|
|
427
|
+
* @generated from protobuf field: repeated injective_chart_rpc.MarketSummaryResp field = 1
|
|
428
|
+
*/
|
|
429
|
+
field: MarketSummaryResp[];
|
|
430
|
+
}
|
|
431
|
+
/**
|
|
432
|
+
* @generated from protobuf message injective_chart_rpc.MarketSnapshotRequest
|
|
433
|
+
*/
|
|
434
|
+
export interface MarketSnapshotRequest {
|
|
435
|
+
/**
|
|
436
|
+
* Specify multiple marketIDs to search.
|
|
437
|
+
*
|
|
438
|
+
* @generated from protobuf field: repeated string market_i_ds = 1
|
|
439
|
+
*/
|
|
440
|
+
marketIDs: string[];
|
|
441
|
+
/**
|
|
442
|
+
* Symbols resolution(minutes). Default is 1
|
|
443
|
+
*
|
|
444
|
+
* @generated from protobuf field: string resolution = 2
|
|
445
|
+
*/
|
|
446
|
+
resolution: string;
|
|
447
|
+
/**
|
|
448
|
+
* Number of bars returned, starting from the recent ones.
|
|
449
|
+
*
|
|
450
|
+
* @generated from protobuf field: sint32 countback = 3
|
|
451
|
+
*/
|
|
452
|
+
countback: number;
|
|
453
|
+
}
|
|
454
|
+
/**
|
|
455
|
+
* @generated from protobuf message injective_chart_rpc.MarketSnapshotResponse
|
|
456
|
+
*/
|
|
457
|
+
export interface MarketSnapshotResponse {
|
|
458
|
+
/**
|
|
459
|
+
* @generated from protobuf field: repeated injective_chart_rpc.MarketSnapshotHistoryResponse field = 1
|
|
460
|
+
*/
|
|
461
|
+
field: MarketSnapshotHistoryResponse[];
|
|
462
|
+
}
|
|
463
|
+
/**
|
|
464
|
+
* @generated from protobuf message injective_chart_rpc.MarketSnapshotHistoryResponse
|
|
465
|
+
*/
|
|
466
|
+
export interface MarketSnapshotHistoryResponse {
|
|
467
|
+
/**
|
|
468
|
+
* Market identifier.
|
|
469
|
+
*
|
|
470
|
+
* @generated from protobuf field: string market_id = 1
|
|
471
|
+
*/
|
|
472
|
+
marketId: string;
|
|
473
|
+
/**
|
|
474
|
+
* Symbol resolution
|
|
475
|
+
*
|
|
476
|
+
* @generated from protobuf field: string resolution = 2
|
|
477
|
+
*/
|
|
478
|
+
resolution: string;
|
|
479
|
+
/**
|
|
480
|
+
* Bar time, Unix timestamp (UTC). Daily bars should only have the date part,
|
|
481
|
+
* time should be 0.
|
|
482
|
+
*
|
|
483
|
+
* @generated from protobuf field: repeated sint32 t = 3
|
|
484
|
+
*/
|
|
485
|
+
t: number[];
|
|
486
|
+
/**
|
|
487
|
+
* Open price.
|
|
488
|
+
*
|
|
489
|
+
* @generated from protobuf field: repeated double o = 4
|
|
490
|
+
*/
|
|
491
|
+
o: number[];
|
|
492
|
+
/**
|
|
493
|
+
* High price.
|
|
494
|
+
*
|
|
495
|
+
* @generated from protobuf field: repeated double h = 5
|
|
496
|
+
*/
|
|
497
|
+
h: number[];
|
|
498
|
+
/**
|
|
499
|
+
* Low price.
|
|
500
|
+
*
|
|
501
|
+
* @generated from protobuf field: repeated double l = 6
|
|
502
|
+
*/
|
|
503
|
+
l: number[];
|
|
504
|
+
/**
|
|
505
|
+
* Close price.
|
|
506
|
+
*
|
|
507
|
+
* @generated from protobuf field: repeated double c = 7
|
|
508
|
+
*/
|
|
509
|
+
c: number[];
|
|
510
|
+
/**
|
|
511
|
+
* Volume.
|
|
512
|
+
*
|
|
513
|
+
* @generated from protobuf field: repeated double v = 8
|
|
514
|
+
*/
|
|
515
|
+
v: number[];
|
|
516
|
+
}
|
|
517
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
518
|
+
class SpotMarketHistoryRequest$Type extends MessageType<SpotMarketHistoryRequest> {
|
|
519
|
+
constructor() {
|
|
520
|
+
super("injective_chart_rpc.SpotMarketHistoryRequest", [
|
|
521
|
+
{ no: 1, name: "symbol", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
522
|
+
{ no: 2, name: "market_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
523
|
+
{ no: 3, name: "resolution", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
524
|
+
{ no: 4, name: "from", kind: "scalar", T: 17 /*ScalarType.SINT32*/ },
|
|
525
|
+
{ no: 5, name: "to", kind: "scalar", T: 17 /*ScalarType.SINT32*/ },
|
|
526
|
+
{ no: 6, name: "countback", kind: "scalar", T: 17 /*ScalarType.SINT32*/ }
|
|
527
|
+
]);
|
|
528
|
+
}
|
|
529
|
+
create(value?: PartialMessage<SpotMarketHistoryRequest>): SpotMarketHistoryRequest {
|
|
530
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
531
|
+
message.symbol = "";
|
|
532
|
+
message.marketId = "";
|
|
533
|
+
message.resolution = "";
|
|
534
|
+
message.from = 0;
|
|
535
|
+
message.to = 0;
|
|
536
|
+
message.countback = 0;
|
|
537
|
+
if (value !== undefined)
|
|
538
|
+
reflectionMergePartial<SpotMarketHistoryRequest>(this, message, value);
|
|
539
|
+
return message;
|
|
540
|
+
}
|
|
541
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SpotMarketHistoryRequest): SpotMarketHistoryRequest {
|
|
542
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
543
|
+
while (reader.pos < end) {
|
|
544
|
+
let [fieldNo, wireType] = reader.tag();
|
|
545
|
+
switch (fieldNo) {
|
|
546
|
+
case /* string symbol */ 1:
|
|
547
|
+
message.symbol = reader.string();
|
|
548
|
+
break;
|
|
549
|
+
case /* string market_id */ 2:
|
|
550
|
+
message.marketId = reader.string();
|
|
551
|
+
break;
|
|
552
|
+
case /* string resolution */ 3:
|
|
553
|
+
message.resolution = reader.string();
|
|
554
|
+
break;
|
|
555
|
+
case /* sint32 from */ 4:
|
|
556
|
+
message.from = reader.sint32();
|
|
557
|
+
break;
|
|
558
|
+
case /* sint32 to */ 5:
|
|
559
|
+
message.to = reader.sint32();
|
|
560
|
+
break;
|
|
561
|
+
case /* sint32 countback */ 6:
|
|
562
|
+
message.countback = reader.sint32();
|
|
563
|
+
break;
|
|
564
|
+
default:
|
|
565
|
+
let u = options.readUnknownField;
|
|
566
|
+
if (u === "throw")
|
|
567
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
568
|
+
let d = reader.skip(wireType);
|
|
569
|
+
if (u !== false)
|
|
570
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
571
|
+
}
|
|
572
|
+
}
|
|
573
|
+
return message;
|
|
574
|
+
}
|
|
575
|
+
internalBinaryWrite(message: SpotMarketHistoryRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
576
|
+
/* string symbol = 1; */
|
|
577
|
+
if (message.symbol !== "")
|
|
578
|
+
writer.tag(1, WireType.LengthDelimited).string(message.symbol);
|
|
579
|
+
/* string market_id = 2; */
|
|
580
|
+
if (message.marketId !== "")
|
|
581
|
+
writer.tag(2, WireType.LengthDelimited).string(message.marketId);
|
|
582
|
+
/* string resolution = 3; */
|
|
583
|
+
if (message.resolution !== "")
|
|
584
|
+
writer.tag(3, WireType.LengthDelimited).string(message.resolution);
|
|
585
|
+
/* sint32 from = 4; */
|
|
586
|
+
if (message.from !== 0)
|
|
587
|
+
writer.tag(4, WireType.Varint).sint32(message.from);
|
|
588
|
+
/* sint32 to = 5; */
|
|
589
|
+
if (message.to !== 0)
|
|
590
|
+
writer.tag(5, WireType.Varint).sint32(message.to);
|
|
591
|
+
/* sint32 countback = 6; */
|
|
592
|
+
if (message.countback !== 0)
|
|
593
|
+
writer.tag(6, WireType.Varint).sint32(message.countback);
|
|
594
|
+
let u = options.writeUnknownFields;
|
|
595
|
+
if (u !== false)
|
|
596
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
597
|
+
return writer;
|
|
598
|
+
}
|
|
599
|
+
}
|
|
600
|
+
/**
|
|
601
|
+
* @generated MessageType for protobuf message injective_chart_rpc.SpotMarketHistoryRequest
|
|
602
|
+
*/
|
|
603
|
+
export const SpotMarketHistoryRequest = new SpotMarketHistoryRequest$Type();
|
|
604
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
605
|
+
class SpotMarketHistoryResponse$Type extends MessageType<SpotMarketHistoryResponse> {
|
|
606
|
+
constructor() {
|
|
607
|
+
super("injective_chart_rpc.SpotMarketHistoryResponse", [
|
|
608
|
+
{ no: 1, name: "t", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 17 /*ScalarType.SINT32*/ },
|
|
609
|
+
{ no: 2, name: "o", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
610
|
+
{ no: 3, name: "h", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
611
|
+
{ no: 4, name: "l", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
612
|
+
{ no: 5, name: "c", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
613
|
+
{ no: 6, name: "v", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
614
|
+
{ no: 7, name: "s", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
|
|
615
|
+
]);
|
|
616
|
+
}
|
|
617
|
+
create(value?: PartialMessage<SpotMarketHistoryResponse>): SpotMarketHistoryResponse {
|
|
618
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
619
|
+
message.t = [];
|
|
620
|
+
message.o = [];
|
|
621
|
+
message.h = [];
|
|
622
|
+
message.l = [];
|
|
623
|
+
message.c = [];
|
|
624
|
+
message.v = [];
|
|
625
|
+
message.s = "";
|
|
626
|
+
if (value !== undefined)
|
|
627
|
+
reflectionMergePartial<SpotMarketHistoryResponse>(this, message, value);
|
|
628
|
+
return message;
|
|
629
|
+
}
|
|
630
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SpotMarketHistoryResponse): SpotMarketHistoryResponse {
|
|
631
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
632
|
+
while (reader.pos < end) {
|
|
633
|
+
let [fieldNo, wireType] = reader.tag();
|
|
634
|
+
switch (fieldNo) {
|
|
635
|
+
case /* repeated sint32 t */ 1:
|
|
636
|
+
if (wireType === WireType.LengthDelimited)
|
|
637
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
638
|
+
message.t.push(reader.sint32());
|
|
639
|
+
else
|
|
640
|
+
message.t.push(reader.sint32());
|
|
641
|
+
break;
|
|
642
|
+
case /* repeated double o */ 2:
|
|
643
|
+
if (wireType === WireType.LengthDelimited)
|
|
644
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
645
|
+
message.o.push(reader.double());
|
|
646
|
+
else
|
|
647
|
+
message.o.push(reader.double());
|
|
648
|
+
break;
|
|
649
|
+
case /* repeated double h */ 3:
|
|
650
|
+
if (wireType === WireType.LengthDelimited)
|
|
651
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
652
|
+
message.h.push(reader.double());
|
|
653
|
+
else
|
|
654
|
+
message.h.push(reader.double());
|
|
655
|
+
break;
|
|
656
|
+
case /* repeated double l */ 4:
|
|
657
|
+
if (wireType === WireType.LengthDelimited)
|
|
658
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
659
|
+
message.l.push(reader.double());
|
|
660
|
+
else
|
|
661
|
+
message.l.push(reader.double());
|
|
662
|
+
break;
|
|
663
|
+
case /* repeated double c */ 5:
|
|
664
|
+
if (wireType === WireType.LengthDelimited)
|
|
665
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
666
|
+
message.c.push(reader.double());
|
|
667
|
+
else
|
|
668
|
+
message.c.push(reader.double());
|
|
669
|
+
break;
|
|
670
|
+
case /* repeated double v */ 6:
|
|
671
|
+
if (wireType === WireType.LengthDelimited)
|
|
672
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
673
|
+
message.v.push(reader.double());
|
|
674
|
+
else
|
|
675
|
+
message.v.push(reader.double());
|
|
676
|
+
break;
|
|
677
|
+
case /* string s */ 7:
|
|
678
|
+
message.s = reader.string();
|
|
679
|
+
break;
|
|
680
|
+
default:
|
|
681
|
+
let u = options.readUnknownField;
|
|
682
|
+
if (u === "throw")
|
|
683
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
684
|
+
let d = reader.skip(wireType);
|
|
685
|
+
if (u !== false)
|
|
686
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
687
|
+
}
|
|
688
|
+
}
|
|
689
|
+
return message;
|
|
690
|
+
}
|
|
691
|
+
internalBinaryWrite(message: SpotMarketHistoryResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
692
|
+
/* repeated sint32 t = 1; */
|
|
693
|
+
if (message.t.length) {
|
|
694
|
+
writer.tag(1, WireType.LengthDelimited).fork();
|
|
695
|
+
for (let i = 0; i < message.t.length; i++)
|
|
696
|
+
writer.sint32(message.t[i]);
|
|
697
|
+
writer.join();
|
|
698
|
+
}
|
|
699
|
+
/* repeated double o = 2; */
|
|
700
|
+
if (message.o.length) {
|
|
701
|
+
writer.tag(2, WireType.LengthDelimited).fork();
|
|
702
|
+
for (let i = 0; i < message.o.length; i++)
|
|
703
|
+
writer.double(message.o[i]);
|
|
704
|
+
writer.join();
|
|
705
|
+
}
|
|
706
|
+
/* repeated double h = 3; */
|
|
707
|
+
if (message.h.length) {
|
|
708
|
+
writer.tag(3, WireType.LengthDelimited).fork();
|
|
709
|
+
for (let i = 0; i < message.h.length; i++)
|
|
710
|
+
writer.double(message.h[i]);
|
|
711
|
+
writer.join();
|
|
712
|
+
}
|
|
713
|
+
/* repeated double l = 4; */
|
|
714
|
+
if (message.l.length) {
|
|
715
|
+
writer.tag(4, WireType.LengthDelimited).fork();
|
|
716
|
+
for (let i = 0; i < message.l.length; i++)
|
|
717
|
+
writer.double(message.l[i]);
|
|
718
|
+
writer.join();
|
|
719
|
+
}
|
|
720
|
+
/* repeated double c = 5; */
|
|
721
|
+
if (message.c.length) {
|
|
722
|
+
writer.tag(5, WireType.LengthDelimited).fork();
|
|
723
|
+
for (let i = 0; i < message.c.length; i++)
|
|
724
|
+
writer.double(message.c[i]);
|
|
725
|
+
writer.join();
|
|
726
|
+
}
|
|
727
|
+
/* repeated double v = 6; */
|
|
728
|
+
if (message.v.length) {
|
|
729
|
+
writer.tag(6, WireType.LengthDelimited).fork();
|
|
730
|
+
for (let i = 0; i < message.v.length; i++)
|
|
731
|
+
writer.double(message.v[i]);
|
|
732
|
+
writer.join();
|
|
733
|
+
}
|
|
734
|
+
/* string s = 7; */
|
|
735
|
+
if (message.s !== "")
|
|
736
|
+
writer.tag(7, WireType.LengthDelimited).string(message.s);
|
|
737
|
+
let u = options.writeUnknownFields;
|
|
738
|
+
if (u !== false)
|
|
739
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
740
|
+
return writer;
|
|
741
|
+
}
|
|
742
|
+
}
|
|
743
|
+
/**
|
|
744
|
+
* @generated MessageType for protobuf message injective_chart_rpc.SpotMarketHistoryResponse
|
|
745
|
+
*/
|
|
746
|
+
export const SpotMarketHistoryResponse = new SpotMarketHistoryResponse$Type();
|
|
747
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
748
|
+
class DerivativeMarketHistoryRequest$Type extends MessageType<DerivativeMarketHistoryRequest> {
|
|
749
|
+
constructor() {
|
|
750
|
+
super("injective_chart_rpc.DerivativeMarketHistoryRequest", [
|
|
751
|
+
{ no: 1, name: "symbol", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
752
|
+
{ no: 2, name: "market_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
753
|
+
{ no: 3, name: "resolution", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
754
|
+
{ no: 4, name: "from", kind: "scalar", T: 17 /*ScalarType.SINT32*/ },
|
|
755
|
+
{ no: 5, name: "to", kind: "scalar", T: 17 /*ScalarType.SINT32*/ },
|
|
756
|
+
{ no: 6, name: "countback", kind: "scalar", T: 17 /*ScalarType.SINT32*/ }
|
|
757
|
+
]);
|
|
758
|
+
}
|
|
759
|
+
create(value?: PartialMessage<DerivativeMarketHistoryRequest>): DerivativeMarketHistoryRequest {
|
|
760
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
761
|
+
message.symbol = "";
|
|
762
|
+
message.marketId = "";
|
|
763
|
+
message.resolution = "";
|
|
764
|
+
message.from = 0;
|
|
765
|
+
message.to = 0;
|
|
766
|
+
message.countback = 0;
|
|
767
|
+
if (value !== undefined)
|
|
768
|
+
reflectionMergePartial<DerivativeMarketHistoryRequest>(this, message, value);
|
|
769
|
+
return message;
|
|
770
|
+
}
|
|
771
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DerivativeMarketHistoryRequest): DerivativeMarketHistoryRequest {
|
|
772
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
773
|
+
while (reader.pos < end) {
|
|
774
|
+
let [fieldNo, wireType] = reader.tag();
|
|
775
|
+
switch (fieldNo) {
|
|
776
|
+
case /* string symbol */ 1:
|
|
777
|
+
message.symbol = reader.string();
|
|
778
|
+
break;
|
|
779
|
+
case /* string market_id */ 2:
|
|
780
|
+
message.marketId = reader.string();
|
|
781
|
+
break;
|
|
782
|
+
case /* string resolution */ 3:
|
|
783
|
+
message.resolution = reader.string();
|
|
784
|
+
break;
|
|
785
|
+
case /* sint32 from */ 4:
|
|
786
|
+
message.from = reader.sint32();
|
|
787
|
+
break;
|
|
788
|
+
case /* sint32 to */ 5:
|
|
789
|
+
message.to = reader.sint32();
|
|
790
|
+
break;
|
|
791
|
+
case /* sint32 countback */ 6:
|
|
792
|
+
message.countback = reader.sint32();
|
|
793
|
+
break;
|
|
794
|
+
default:
|
|
795
|
+
let u = options.readUnknownField;
|
|
796
|
+
if (u === "throw")
|
|
797
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
798
|
+
let d = reader.skip(wireType);
|
|
799
|
+
if (u !== false)
|
|
800
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
801
|
+
}
|
|
802
|
+
}
|
|
803
|
+
return message;
|
|
804
|
+
}
|
|
805
|
+
internalBinaryWrite(message: DerivativeMarketHistoryRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
806
|
+
/* string symbol = 1; */
|
|
807
|
+
if (message.symbol !== "")
|
|
808
|
+
writer.tag(1, WireType.LengthDelimited).string(message.symbol);
|
|
809
|
+
/* string market_id = 2; */
|
|
810
|
+
if (message.marketId !== "")
|
|
811
|
+
writer.tag(2, WireType.LengthDelimited).string(message.marketId);
|
|
812
|
+
/* string resolution = 3; */
|
|
813
|
+
if (message.resolution !== "")
|
|
814
|
+
writer.tag(3, WireType.LengthDelimited).string(message.resolution);
|
|
815
|
+
/* sint32 from = 4; */
|
|
816
|
+
if (message.from !== 0)
|
|
817
|
+
writer.tag(4, WireType.Varint).sint32(message.from);
|
|
818
|
+
/* sint32 to = 5; */
|
|
819
|
+
if (message.to !== 0)
|
|
820
|
+
writer.tag(5, WireType.Varint).sint32(message.to);
|
|
821
|
+
/* sint32 countback = 6; */
|
|
822
|
+
if (message.countback !== 0)
|
|
823
|
+
writer.tag(6, WireType.Varint).sint32(message.countback);
|
|
824
|
+
let u = options.writeUnknownFields;
|
|
825
|
+
if (u !== false)
|
|
826
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
827
|
+
return writer;
|
|
828
|
+
}
|
|
829
|
+
}
|
|
830
|
+
/**
|
|
831
|
+
* @generated MessageType for protobuf message injective_chart_rpc.DerivativeMarketHistoryRequest
|
|
832
|
+
*/
|
|
833
|
+
export const DerivativeMarketHistoryRequest = new DerivativeMarketHistoryRequest$Type();
|
|
834
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
835
|
+
class DerivativeMarketHistoryResponse$Type extends MessageType<DerivativeMarketHistoryResponse> {
|
|
836
|
+
constructor() {
|
|
837
|
+
super("injective_chart_rpc.DerivativeMarketHistoryResponse", [
|
|
838
|
+
{ no: 1, name: "t", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 17 /*ScalarType.SINT32*/ },
|
|
839
|
+
{ no: 2, name: "o", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
840
|
+
{ no: 3, name: "h", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
841
|
+
{ no: 4, name: "l", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
842
|
+
{ no: 5, name: "c", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
843
|
+
{ no: 6, name: "v", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
844
|
+
{ no: 7, name: "s", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
|
|
845
|
+
]);
|
|
846
|
+
}
|
|
847
|
+
create(value?: PartialMessage<DerivativeMarketHistoryResponse>): DerivativeMarketHistoryResponse {
|
|
848
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
849
|
+
message.t = [];
|
|
850
|
+
message.o = [];
|
|
851
|
+
message.h = [];
|
|
852
|
+
message.l = [];
|
|
853
|
+
message.c = [];
|
|
854
|
+
message.v = [];
|
|
855
|
+
message.s = "";
|
|
856
|
+
if (value !== undefined)
|
|
857
|
+
reflectionMergePartial<DerivativeMarketHistoryResponse>(this, message, value);
|
|
858
|
+
return message;
|
|
859
|
+
}
|
|
860
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DerivativeMarketHistoryResponse): DerivativeMarketHistoryResponse {
|
|
861
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
862
|
+
while (reader.pos < end) {
|
|
863
|
+
let [fieldNo, wireType] = reader.tag();
|
|
864
|
+
switch (fieldNo) {
|
|
865
|
+
case /* repeated sint32 t */ 1:
|
|
866
|
+
if (wireType === WireType.LengthDelimited)
|
|
867
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
868
|
+
message.t.push(reader.sint32());
|
|
869
|
+
else
|
|
870
|
+
message.t.push(reader.sint32());
|
|
871
|
+
break;
|
|
872
|
+
case /* repeated double o */ 2:
|
|
873
|
+
if (wireType === WireType.LengthDelimited)
|
|
874
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
875
|
+
message.o.push(reader.double());
|
|
876
|
+
else
|
|
877
|
+
message.o.push(reader.double());
|
|
878
|
+
break;
|
|
879
|
+
case /* repeated double h */ 3:
|
|
880
|
+
if (wireType === WireType.LengthDelimited)
|
|
881
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
882
|
+
message.h.push(reader.double());
|
|
883
|
+
else
|
|
884
|
+
message.h.push(reader.double());
|
|
885
|
+
break;
|
|
886
|
+
case /* repeated double l */ 4:
|
|
887
|
+
if (wireType === WireType.LengthDelimited)
|
|
888
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
889
|
+
message.l.push(reader.double());
|
|
890
|
+
else
|
|
891
|
+
message.l.push(reader.double());
|
|
892
|
+
break;
|
|
893
|
+
case /* repeated double c */ 5:
|
|
894
|
+
if (wireType === WireType.LengthDelimited)
|
|
895
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
896
|
+
message.c.push(reader.double());
|
|
897
|
+
else
|
|
898
|
+
message.c.push(reader.double());
|
|
899
|
+
break;
|
|
900
|
+
case /* repeated double v */ 6:
|
|
901
|
+
if (wireType === WireType.LengthDelimited)
|
|
902
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
903
|
+
message.v.push(reader.double());
|
|
904
|
+
else
|
|
905
|
+
message.v.push(reader.double());
|
|
906
|
+
break;
|
|
907
|
+
case /* string s */ 7:
|
|
908
|
+
message.s = reader.string();
|
|
909
|
+
break;
|
|
910
|
+
default:
|
|
911
|
+
let u = options.readUnknownField;
|
|
912
|
+
if (u === "throw")
|
|
913
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
914
|
+
let d = reader.skip(wireType);
|
|
915
|
+
if (u !== false)
|
|
916
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
917
|
+
}
|
|
918
|
+
}
|
|
919
|
+
return message;
|
|
920
|
+
}
|
|
921
|
+
internalBinaryWrite(message: DerivativeMarketHistoryResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
922
|
+
/* repeated sint32 t = 1; */
|
|
923
|
+
if (message.t.length) {
|
|
924
|
+
writer.tag(1, WireType.LengthDelimited).fork();
|
|
925
|
+
for (let i = 0; i < message.t.length; i++)
|
|
926
|
+
writer.sint32(message.t[i]);
|
|
927
|
+
writer.join();
|
|
928
|
+
}
|
|
929
|
+
/* repeated double o = 2; */
|
|
930
|
+
if (message.o.length) {
|
|
931
|
+
writer.tag(2, WireType.LengthDelimited).fork();
|
|
932
|
+
for (let i = 0; i < message.o.length; i++)
|
|
933
|
+
writer.double(message.o[i]);
|
|
934
|
+
writer.join();
|
|
935
|
+
}
|
|
936
|
+
/* repeated double h = 3; */
|
|
937
|
+
if (message.h.length) {
|
|
938
|
+
writer.tag(3, WireType.LengthDelimited).fork();
|
|
939
|
+
for (let i = 0; i < message.h.length; i++)
|
|
940
|
+
writer.double(message.h[i]);
|
|
941
|
+
writer.join();
|
|
942
|
+
}
|
|
943
|
+
/* repeated double l = 4; */
|
|
944
|
+
if (message.l.length) {
|
|
945
|
+
writer.tag(4, WireType.LengthDelimited).fork();
|
|
946
|
+
for (let i = 0; i < message.l.length; i++)
|
|
947
|
+
writer.double(message.l[i]);
|
|
948
|
+
writer.join();
|
|
949
|
+
}
|
|
950
|
+
/* repeated double c = 5; */
|
|
951
|
+
if (message.c.length) {
|
|
952
|
+
writer.tag(5, WireType.LengthDelimited).fork();
|
|
953
|
+
for (let i = 0; i < message.c.length; i++)
|
|
954
|
+
writer.double(message.c[i]);
|
|
955
|
+
writer.join();
|
|
956
|
+
}
|
|
957
|
+
/* repeated double v = 6; */
|
|
958
|
+
if (message.v.length) {
|
|
959
|
+
writer.tag(6, WireType.LengthDelimited).fork();
|
|
960
|
+
for (let i = 0; i < message.v.length; i++)
|
|
961
|
+
writer.double(message.v[i]);
|
|
962
|
+
writer.join();
|
|
963
|
+
}
|
|
964
|
+
/* string s = 7; */
|
|
965
|
+
if (message.s !== "")
|
|
966
|
+
writer.tag(7, WireType.LengthDelimited).string(message.s);
|
|
967
|
+
let u = options.writeUnknownFields;
|
|
968
|
+
if (u !== false)
|
|
969
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
970
|
+
return writer;
|
|
971
|
+
}
|
|
972
|
+
}
|
|
973
|
+
/**
|
|
974
|
+
* @generated MessageType for protobuf message injective_chart_rpc.DerivativeMarketHistoryResponse
|
|
975
|
+
*/
|
|
976
|
+
export const DerivativeMarketHistoryResponse = new DerivativeMarketHistoryResponse$Type();
|
|
977
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
978
|
+
class SpotMarketSummaryRequest$Type extends MessageType<SpotMarketSummaryRequest> {
|
|
979
|
+
constructor() {
|
|
980
|
+
super("injective_chart_rpc.SpotMarketSummaryRequest", [
|
|
981
|
+
{ no: 1, name: "market_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
982
|
+
{ no: 2, name: "resolution", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
|
|
983
|
+
]);
|
|
984
|
+
}
|
|
985
|
+
create(value?: PartialMessage<SpotMarketSummaryRequest>): SpotMarketSummaryRequest {
|
|
986
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
987
|
+
message.marketId = "";
|
|
988
|
+
message.resolution = "";
|
|
989
|
+
if (value !== undefined)
|
|
990
|
+
reflectionMergePartial<SpotMarketSummaryRequest>(this, message, value);
|
|
991
|
+
return message;
|
|
992
|
+
}
|
|
993
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SpotMarketSummaryRequest): SpotMarketSummaryRequest {
|
|
994
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
995
|
+
while (reader.pos < end) {
|
|
996
|
+
let [fieldNo, wireType] = reader.tag();
|
|
997
|
+
switch (fieldNo) {
|
|
998
|
+
case /* string market_id */ 1:
|
|
999
|
+
message.marketId = reader.string();
|
|
1000
|
+
break;
|
|
1001
|
+
case /* string resolution */ 2:
|
|
1002
|
+
message.resolution = reader.string();
|
|
1003
|
+
break;
|
|
1004
|
+
default:
|
|
1005
|
+
let u = options.readUnknownField;
|
|
1006
|
+
if (u === "throw")
|
|
1007
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1008
|
+
let d = reader.skip(wireType);
|
|
1009
|
+
if (u !== false)
|
|
1010
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1011
|
+
}
|
|
1012
|
+
}
|
|
1013
|
+
return message;
|
|
1014
|
+
}
|
|
1015
|
+
internalBinaryWrite(message: SpotMarketSummaryRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1016
|
+
/* string market_id = 1; */
|
|
1017
|
+
if (message.marketId !== "")
|
|
1018
|
+
writer.tag(1, WireType.LengthDelimited).string(message.marketId);
|
|
1019
|
+
/* string resolution = 2; */
|
|
1020
|
+
if (message.resolution !== "")
|
|
1021
|
+
writer.tag(2, WireType.LengthDelimited).string(message.resolution);
|
|
1022
|
+
let u = options.writeUnknownFields;
|
|
1023
|
+
if (u !== false)
|
|
1024
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1025
|
+
return writer;
|
|
1026
|
+
}
|
|
1027
|
+
}
|
|
1028
|
+
/**
|
|
1029
|
+
* @generated MessageType for protobuf message injective_chart_rpc.SpotMarketSummaryRequest
|
|
1030
|
+
*/
|
|
1031
|
+
export const SpotMarketSummaryRequest = new SpotMarketSummaryRequest$Type();
|
|
1032
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1033
|
+
class SpotMarketSummaryResponse$Type extends MessageType<SpotMarketSummaryResponse> {
|
|
1034
|
+
constructor() {
|
|
1035
|
+
super("injective_chart_rpc.SpotMarketSummaryResponse", [
|
|
1036
|
+
{ no: 1, name: "market_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
1037
|
+
{ no: 2, name: "open", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1038
|
+
{ no: 3, name: "high", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1039
|
+
{ no: 4, name: "low", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1040
|
+
{ no: 5, name: "volume", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1041
|
+
{ no: 6, name: "price", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1042
|
+
{ no: 7, name: "change", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ }
|
|
1043
|
+
]);
|
|
1044
|
+
}
|
|
1045
|
+
create(value?: PartialMessage<SpotMarketSummaryResponse>): SpotMarketSummaryResponse {
|
|
1046
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1047
|
+
message.marketId = "";
|
|
1048
|
+
message.open = 0;
|
|
1049
|
+
message.high = 0;
|
|
1050
|
+
message.low = 0;
|
|
1051
|
+
message.volume = 0;
|
|
1052
|
+
message.price = 0;
|
|
1053
|
+
message.change = 0;
|
|
1054
|
+
if (value !== undefined)
|
|
1055
|
+
reflectionMergePartial<SpotMarketSummaryResponse>(this, message, value);
|
|
1056
|
+
return message;
|
|
1057
|
+
}
|
|
1058
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SpotMarketSummaryResponse): SpotMarketSummaryResponse {
|
|
1059
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1060
|
+
while (reader.pos < end) {
|
|
1061
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1062
|
+
switch (fieldNo) {
|
|
1063
|
+
case /* string market_id */ 1:
|
|
1064
|
+
message.marketId = reader.string();
|
|
1065
|
+
break;
|
|
1066
|
+
case /* double open */ 2:
|
|
1067
|
+
message.open = reader.double();
|
|
1068
|
+
break;
|
|
1069
|
+
case /* double high */ 3:
|
|
1070
|
+
message.high = reader.double();
|
|
1071
|
+
break;
|
|
1072
|
+
case /* double low */ 4:
|
|
1073
|
+
message.low = reader.double();
|
|
1074
|
+
break;
|
|
1075
|
+
case /* double volume */ 5:
|
|
1076
|
+
message.volume = reader.double();
|
|
1077
|
+
break;
|
|
1078
|
+
case /* double price */ 6:
|
|
1079
|
+
message.price = reader.double();
|
|
1080
|
+
break;
|
|
1081
|
+
case /* double change */ 7:
|
|
1082
|
+
message.change = reader.double();
|
|
1083
|
+
break;
|
|
1084
|
+
default:
|
|
1085
|
+
let u = options.readUnknownField;
|
|
1086
|
+
if (u === "throw")
|
|
1087
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1088
|
+
let d = reader.skip(wireType);
|
|
1089
|
+
if (u !== false)
|
|
1090
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1091
|
+
}
|
|
1092
|
+
}
|
|
1093
|
+
return message;
|
|
1094
|
+
}
|
|
1095
|
+
internalBinaryWrite(message: SpotMarketSummaryResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1096
|
+
/* string market_id = 1; */
|
|
1097
|
+
if (message.marketId !== "")
|
|
1098
|
+
writer.tag(1, WireType.LengthDelimited).string(message.marketId);
|
|
1099
|
+
/* double open = 2; */
|
|
1100
|
+
if (message.open !== 0)
|
|
1101
|
+
writer.tag(2, WireType.Bit64).double(message.open);
|
|
1102
|
+
/* double high = 3; */
|
|
1103
|
+
if (message.high !== 0)
|
|
1104
|
+
writer.tag(3, WireType.Bit64).double(message.high);
|
|
1105
|
+
/* double low = 4; */
|
|
1106
|
+
if (message.low !== 0)
|
|
1107
|
+
writer.tag(4, WireType.Bit64).double(message.low);
|
|
1108
|
+
/* double volume = 5; */
|
|
1109
|
+
if (message.volume !== 0)
|
|
1110
|
+
writer.tag(5, WireType.Bit64).double(message.volume);
|
|
1111
|
+
/* double price = 6; */
|
|
1112
|
+
if (message.price !== 0)
|
|
1113
|
+
writer.tag(6, WireType.Bit64).double(message.price);
|
|
1114
|
+
/* double change = 7; */
|
|
1115
|
+
if (message.change !== 0)
|
|
1116
|
+
writer.tag(7, WireType.Bit64).double(message.change);
|
|
1117
|
+
let u = options.writeUnknownFields;
|
|
1118
|
+
if (u !== false)
|
|
1119
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1120
|
+
return writer;
|
|
1121
|
+
}
|
|
1122
|
+
}
|
|
1123
|
+
/**
|
|
1124
|
+
* @generated MessageType for protobuf message injective_chart_rpc.SpotMarketSummaryResponse
|
|
1125
|
+
*/
|
|
1126
|
+
export const SpotMarketSummaryResponse = new SpotMarketSummaryResponse$Type();
|
|
1127
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1128
|
+
class AllSpotMarketSummaryRequest$Type extends MessageType<AllSpotMarketSummaryRequest> {
|
|
1129
|
+
constructor() {
|
|
1130
|
+
super("injective_chart_rpc.AllSpotMarketSummaryRequest", [
|
|
1131
|
+
{ no: 1, name: "resolution", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
|
|
1132
|
+
]);
|
|
1133
|
+
}
|
|
1134
|
+
create(value?: PartialMessage<AllSpotMarketSummaryRequest>): AllSpotMarketSummaryRequest {
|
|
1135
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1136
|
+
message.resolution = "";
|
|
1137
|
+
if (value !== undefined)
|
|
1138
|
+
reflectionMergePartial<AllSpotMarketSummaryRequest>(this, message, value);
|
|
1139
|
+
return message;
|
|
1140
|
+
}
|
|
1141
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AllSpotMarketSummaryRequest): AllSpotMarketSummaryRequest {
|
|
1142
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1143
|
+
while (reader.pos < end) {
|
|
1144
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1145
|
+
switch (fieldNo) {
|
|
1146
|
+
case /* string resolution */ 1:
|
|
1147
|
+
message.resolution = reader.string();
|
|
1148
|
+
break;
|
|
1149
|
+
default:
|
|
1150
|
+
let u = options.readUnknownField;
|
|
1151
|
+
if (u === "throw")
|
|
1152
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1153
|
+
let d = reader.skip(wireType);
|
|
1154
|
+
if (u !== false)
|
|
1155
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1156
|
+
}
|
|
1157
|
+
}
|
|
1158
|
+
return message;
|
|
1159
|
+
}
|
|
1160
|
+
internalBinaryWrite(message: AllSpotMarketSummaryRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1161
|
+
/* string resolution = 1; */
|
|
1162
|
+
if (message.resolution !== "")
|
|
1163
|
+
writer.tag(1, WireType.LengthDelimited).string(message.resolution);
|
|
1164
|
+
let u = options.writeUnknownFields;
|
|
1165
|
+
if (u !== false)
|
|
1166
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1167
|
+
return writer;
|
|
1168
|
+
}
|
|
1169
|
+
}
|
|
1170
|
+
/**
|
|
1171
|
+
* @generated MessageType for protobuf message injective_chart_rpc.AllSpotMarketSummaryRequest
|
|
1172
|
+
*/
|
|
1173
|
+
export const AllSpotMarketSummaryRequest = new AllSpotMarketSummaryRequest$Type();
|
|
1174
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1175
|
+
class AllSpotMarketSummaryResponse$Type extends MessageType<AllSpotMarketSummaryResponse> {
|
|
1176
|
+
constructor() {
|
|
1177
|
+
super("injective_chart_rpc.AllSpotMarketSummaryResponse", [
|
|
1178
|
+
{ no: 1, name: "field", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => MarketSummaryResp }
|
|
1179
|
+
]);
|
|
1180
|
+
}
|
|
1181
|
+
create(value?: PartialMessage<AllSpotMarketSummaryResponse>): AllSpotMarketSummaryResponse {
|
|
1182
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1183
|
+
message.field = [];
|
|
1184
|
+
if (value !== undefined)
|
|
1185
|
+
reflectionMergePartial<AllSpotMarketSummaryResponse>(this, message, value);
|
|
1186
|
+
return message;
|
|
1187
|
+
}
|
|
1188
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AllSpotMarketSummaryResponse): AllSpotMarketSummaryResponse {
|
|
1189
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1190
|
+
while (reader.pos < end) {
|
|
1191
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1192
|
+
switch (fieldNo) {
|
|
1193
|
+
case /* repeated injective_chart_rpc.MarketSummaryResp field */ 1:
|
|
1194
|
+
message.field.push(MarketSummaryResp.internalBinaryRead(reader, reader.uint32(), options));
|
|
1195
|
+
break;
|
|
1196
|
+
default:
|
|
1197
|
+
let u = options.readUnknownField;
|
|
1198
|
+
if (u === "throw")
|
|
1199
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1200
|
+
let d = reader.skip(wireType);
|
|
1201
|
+
if (u !== false)
|
|
1202
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1203
|
+
}
|
|
1204
|
+
}
|
|
1205
|
+
return message;
|
|
1206
|
+
}
|
|
1207
|
+
internalBinaryWrite(message: AllSpotMarketSummaryResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1208
|
+
/* repeated injective_chart_rpc.MarketSummaryResp field = 1; */
|
|
1209
|
+
for (let i = 0; i < message.field.length; i++)
|
|
1210
|
+
MarketSummaryResp.internalBinaryWrite(message.field[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
1211
|
+
let u = options.writeUnknownFields;
|
|
1212
|
+
if (u !== false)
|
|
1213
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1214
|
+
return writer;
|
|
1215
|
+
}
|
|
1216
|
+
}
|
|
1217
|
+
/**
|
|
1218
|
+
* @generated MessageType for protobuf message injective_chart_rpc.AllSpotMarketSummaryResponse
|
|
1219
|
+
*/
|
|
1220
|
+
export const AllSpotMarketSummaryResponse = new AllSpotMarketSummaryResponse$Type();
|
|
1221
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1222
|
+
class MarketSummaryResp$Type extends MessageType<MarketSummaryResp> {
|
|
1223
|
+
constructor() {
|
|
1224
|
+
super("injective_chart_rpc.MarketSummaryResp", [
|
|
1225
|
+
{ no: 1, name: "market_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
1226
|
+
{ no: 2, name: "open", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1227
|
+
{ no: 3, name: "high", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1228
|
+
{ no: 4, name: "low", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1229
|
+
{ no: 5, name: "volume", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1230
|
+
{ no: 6, name: "price", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1231
|
+
{ no: 7, name: "change", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ }
|
|
1232
|
+
]);
|
|
1233
|
+
}
|
|
1234
|
+
create(value?: PartialMessage<MarketSummaryResp>): MarketSummaryResp {
|
|
1235
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1236
|
+
message.marketId = "";
|
|
1237
|
+
message.open = 0;
|
|
1238
|
+
message.high = 0;
|
|
1239
|
+
message.low = 0;
|
|
1240
|
+
message.volume = 0;
|
|
1241
|
+
message.price = 0;
|
|
1242
|
+
message.change = 0;
|
|
1243
|
+
if (value !== undefined)
|
|
1244
|
+
reflectionMergePartial<MarketSummaryResp>(this, message, value);
|
|
1245
|
+
return message;
|
|
1246
|
+
}
|
|
1247
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: MarketSummaryResp): MarketSummaryResp {
|
|
1248
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1249
|
+
while (reader.pos < end) {
|
|
1250
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1251
|
+
switch (fieldNo) {
|
|
1252
|
+
case /* string market_id */ 1:
|
|
1253
|
+
message.marketId = reader.string();
|
|
1254
|
+
break;
|
|
1255
|
+
case /* double open */ 2:
|
|
1256
|
+
message.open = reader.double();
|
|
1257
|
+
break;
|
|
1258
|
+
case /* double high */ 3:
|
|
1259
|
+
message.high = reader.double();
|
|
1260
|
+
break;
|
|
1261
|
+
case /* double low */ 4:
|
|
1262
|
+
message.low = reader.double();
|
|
1263
|
+
break;
|
|
1264
|
+
case /* double volume */ 5:
|
|
1265
|
+
message.volume = reader.double();
|
|
1266
|
+
break;
|
|
1267
|
+
case /* double price */ 6:
|
|
1268
|
+
message.price = reader.double();
|
|
1269
|
+
break;
|
|
1270
|
+
case /* double change */ 7:
|
|
1271
|
+
message.change = reader.double();
|
|
1272
|
+
break;
|
|
1273
|
+
default:
|
|
1274
|
+
let u = options.readUnknownField;
|
|
1275
|
+
if (u === "throw")
|
|
1276
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1277
|
+
let d = reader.skip(wireType);
|
|
1278
|
+
if (u !== false)
|
|
1279
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1280
|
+
}
|
|
1281
|
+
}
|
|
1282
|
+
return message;
|
|
1283
|
+
}
|
|
1284
|
+
internalBinaryWrite(message: MarketSummaryResp, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1285
|
+
/* string market_id = 1; */
|
|
1286
|
+
if (message.marketId !== "")
|
|
1287
|
+
writer.tag(1, WireType.LengthDelimited).string(message.marketId);
|
|
1288
|
+
/* double open = 2; */
|
|
1289
|
+
if (message.open !== 0)
|
|
1290
|
+
writer.tag(2, WireType.Bit64).double(message.open);
|
|
1291
|
+
/* double high = 3; */
|
|
1292
|
+
if (message.high !== 0)
|
|
1293
|
+
writer.tag(3, WireType.Bit64).double(message.high);
|
|
1294
|
+
/* double low = 4; */
|
|
1295
|
+
if (message.low !== 0)
|
|
1296
|
+
writer.tag(4, WireType.Bit64).double(message.low);
|
|
1297
|
+
/* double volume = 5; */
|
|
1298
|
+
if (message.volume !== 0)
|
|
1299
|
+
writer.tag(5, WireType.Bit64).double(message.volume);
|
|
1300
|
+
/* double price = 6; */
|
|
1301
|
+
if (message.price !== 0)
|
|
1302
|
+
writer.tag(6, WireType.Bit64).double(message.price);
|
|
1303
|
+
/* double change = 7; */
|
|
1304
|
+
if (message.change !== 0)
|
|
1305
|
+
writer.tag(7, WireType.Bit64).double(message.change);
|
|
1306
|
+
let u = options.writeUnknownFields;
|
|
1307
|
+
if (u !== false)
|
|
1308
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1309
|
+
return writer;
|
|
1310
|
+
}
|
|
1311
|
+
}
|
|
1312
|
+
/**
|
|
1313
|
+
* @generated MessageType for protobuf message injective_chart_rpc.MarketSummaryResp
|
|
1314
|
+
*/
|
|
1315
|
+
export const MarketSummaryResp = new MarketSummaryResp$Type();
|
|
1316
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1317
|
+
class DerivativeMarketSummaryRequest$Type extends MessageType<DerivativeMarketSummaryRequest> {
|
|
1318
|
+
constructor() {
|
|
1319
|
+
super("injective_chart_rpc.DerivativeMarketSummaryRequest", [
|
|
1320
|
+
{ no: 1, name: "market_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
1321
|
+
{ no: 2, name: "index_price", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
|
|
1322
|
+
{ no: 3, name: "resolution", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
|
|
1323
|
+
]);
|
|
1324
|
+
}
|
|
1325
|
+
create(value?: PartialMessage<DerivativeMarketSummaryRequest>): DerivativeMarketSummaryRequest {
|
|
1326
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1327
|
+
message.marketId = "";
|
|
1328
|
+
message.indexPrice = false;
|
|
1329
|
+
message.resolution = "";
|
|
1330
|
+
if (value !== undefined)
|
|
1331
|
+
reflectionMergePartial<DerivativeMarketSummaryRequest>(this, message, value);
|
|
1332
|
+
return message;
|
|
1333
|
+
}
|
|
1334
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DerivativeMarketSummaryRequest): DerivativeMarketSummaryRequest {
|
|
1335
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1336
|
+
while (reader.pos < end) {
|
|
1337
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1338
|
+
switch (fieldNo) {
|
|
1339
|
+
case /* string market_id */ 1:
|
|
1340
|
+
message.marketId = reader.string();
|
|
1341
|
+
break;
|
|
1342
|
+
case /* bool index_price */ 2:
|
|
1343
|
+
message.indexPrice = reader.bool();
|
|
1344
|
+
break;
|
|
1345
|
+
case /* string resolution */ 3:
|
|
1346
|
+
message.resolution = reader.string();
|
|
1347
|
+
break;
|
|
1348
|
+
default:
|
|
1349
|
+
let u = options.readUnknownField;
|
|
1350
|
+
if (u === "throw")
|
|
1351
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1352
|
+
let d = reader.skip(wireType);
|
|
1353
|
+
if (u !== false)
|
|
1354
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1355
|
+
}
|
|
1356
|
+
}
|
|
1357
|
+
return message;
|
|
1358
|
+
}
|
|
1359
|
+
internalBinaryWrite(message: DerivativeMarketSummaryRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1360
|
+
/* string market_id = 1; */
|
|
1361
|
+
if (message.marketId !== "")
|
|
1362
|
+
writer.tag(1, WireType.LengthDelimited).string(message.marketId);
|
|
1363
|
+
/* bool index_price = 2; */
|
|
1364
|
+
if (message.indexPrice !== false)
|
|
1365
|
+
writer.tag(2, WireType.Varint).bool(message.indexPrice);
|
|
1366
|
+
/* string resolution = 3; */
|
|
1367
|
+
if (message.resolution !== "")
|
|
1368
|
+
writer.tag(3, WireType.LengthDelimited).string(message.resolution);
|
|
1369
|
+
let u = options.writeUnknownFields;
|
|
1370
|
+
if (u !== false)
|
|
1371
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1372
|
+
return writer;
|
|
1373
|
+
}
|
|
1374
|
+
}
|
|
1375
|
+
/**
|
|
1376
|
+
* @generated MessageType for protobuf message injective_chart_rpc.DerivativeMarketSummaryRequest
|
|
1377
|
+
*/
|
|
1378
|
+
export const DerivativeMarketSummaryRequest = new DerivativeMarketSummaryRequest$Type();
|
|
1379
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1380
|
+
class DerivativeMarketSummaryResponse$Type extends MessageType<DerivativeMarketSummaryResponse> {
|
|
1381
|
+
constructor() {
|
|
1382
|
+
super("injective_chart_rpc.DerivativeMarketSummaryResponse", [
|
|
1383
|
+
{ no: 1, name: "market_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
1384
|
+
{ no: 2, name: "open", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1385
|
+
{ no: 3, name: "high", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1386
|
+
{ no: 4, name: "low", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1387
|
+
{ no: 5, name: "volume", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1388
|
+
{ no: 6, name: "price", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ },
|
|
1389
|
+
{ no: 7, name: "change", kind: "scalar", T: 1 /*ScalarType.DOUBLE*/ }
|
|
1390
|
+
]);
|
|
1391
|
+
}
|
|
1392
|
+
create(value?: PartialMessage<DerivativeMarketSummaryResponse>): DerivativeMarketSummaryResponse {
|
|
1393
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1394
|
+
message.marketId = "";
|
|
1395
|
+
message.open = 0;
|
|
1396
|
+
message.high = 0;
|
|
1397
|
+
message.low = 0;
|
|
1398
|
+
message.volume = 0;
|
|
1399
|
+
message.price = 0;
|
|
1400
|
+
message.change = 0;
|
|
1401
|
+
if (value !== undefined)
|
|
1402
|
+
reflectionMergePartial<DerivativeMarketSummaryResponse>(this, message, value);
|
|
1403
|
+
return message;
|
|
1404
|
+
}
|
|
1405
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DerivativeMarketSummaryResponse): DerivativeMarketSummaryResponse {
|
|
1406
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1407
|
+
while (reader.pos < end) {
|
|
1408
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1409
|
+
switch (fieldNo) {
|
|
1410
|
+
case /* string market_id */ 1:
|
|
1411
|
+
message.marketId = reader.string();
|
|
1412
|
+
break;
|
|
1413
|
+
case /* double open */ 2:
|
|
1414
|
+
message.open = reader.double();
|
|
1415
|
+
break;
|
|
1416
|
+
case /* double high */ 3:
|
|
1417
|
+
message.high = reader.double();
|
|
1418
|
+
break;
|
|
1419
|
+
case /* double low */ 4:
|
|
1420
|
+
message.low = reader.double();
|
|
1421
|
+
break;
|
|
1422
|
+
case /* double volume */ 5:
|
|
1423
|
+
message.volume = reader.double();
|
|
1424
|
+
break;
|
|
1425
|
+
case /* double price */ 6:
|
|
1426
|
+
message.price = reader.double();
|
|
1427
|
+
break;
|
|
1428
|
+
case /* double change */ 7:
|
|
1429
|
+
message.change = reader.double();
|
|
1430
|
+
break;
|
|
1431
|
+
default:
|
|
1432
|
+
let u = options.readUnknownField;
|
|
1433
|
+
if (u === "throw")
|
|
1434
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1435
|
+
let d = reader.skip(wireType);
|
|
1436
|
+
if (u !== false)
|
|
1437
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1438
|
+
}
|
|
1439
|
+
}
|
|
1440
|
+
return message;
|
|
1441
|
+
}
|
|
1442
|
+
internalBinaryWrite(message: DerivativeMarketSummaryResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1443
|
+
/* string market_id = 1; */
|
|
1444
|
+
if (message.marketId !== "")
|
|
1445
|
+
writer.tag(1, WireType.LengthDelimited).string(message.marketId);
|
|
1446
|
+
/* double open = 2; */
|
|
1447
|
+
if (message.open !== 0)
|
|
1448
|
+
writer.tag(2, WireType.Bit64).double(message.open);
|
|
1449
|
+
/* double high = 3; */
|
|
1450
|
+
if (message.high !== 0)
|
|
1451
|
+
writer.tag(3, WireType.Bit64).double(message.high);
|
|
1452
|
+
/* double low = 4; */
|
|
1453
|
+
if (message.low !== 0)
|
|
1454
|
+
writer.tag(4, WireType.Bit64).double(message.low);
|
|
1455
|
+
/* double volume = 5; */
|
|
1456
|
+
if (message.volume !== 0)
|
|
1457
|
+
writer.tag(5, WireType.Bit64).double(message.volume);
|
|
1458
|
+
/* double price = 6; */
|
|
1459
|
+
if (message.price !== 0)
|
|
1460
|
+
writer.tag(6, WireType.Bit64).double(message.price);
|
|
1461
|
+
/* double change = 7; */
|
|
1462
|
+
if (message.change !== 0)
|
|
1463
|
+
writer.tag(7, WireType.Bit64).double(message.change);
|
|
1464
|
+
let u = options.writeUnknownFields;
|
|
1465
|
+
if (u !== false)
|
|
1466
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1467
|
+
return writer;
|
|
1468
|
+
}
|
|
1469
|
+
}
|
|
1470
|
+
/**
|
|
1471
|
+
* @generated MessageType for protobuf message injective_chart_rpc.DerivativeMarketSummaryResponse
|
|
1472
|
+
*/
|
|
1473
|
+
export const DerivativeMarketSummaryResponse = new DerivativeMarketSummaryResponse$Type();
|
|
1474
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1475
|
+
class AllDerivativeMarketSummaryRequest$Type extends MessageType<AllDerivativeMarketSummaryRequest> {
|
|
1476
|
+
constructor() {
|
|
1477
|
+
super("injective_chart_rpc.AllDerivativeMarketSummaryRequest", [
|
|
1478
|
+
{ no: 1, name: "resolution", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
|
|
1479
|
+
]);
|
|
1480
|
+
}
|
|
1481
|
+
create(value?: PartialMessage<AllDerivativeMarketSummaryRequest>): AllDerivativeMarketSummaryRequest {
|
|
1482
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1483
|
+
message.resolution = "";
|
|
1484
|
+
if (value !== undefined)
|
|
1485
|
+
reflectionMergePartial<AllDerivativeMarketSummaryRequest>(this, message, value);
|
|
1486
|
+
return message;
|
|
1487
|
+
}
|
|
1488
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AllDerivativeMarketSummaryRequest): AllDerivativeMarketSummaryRequest {
|
|
1489
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1490
|
+
while (reader.pos < end) {
|
|
1491
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1492
|
+
switch (fieldNo) {
|
|
1493
|
+
case /* string resolution */ 1:
|
|
1494
|
+
message.resolution = reader.string();
|
|
1495
|
+
break;
|
|
1496
|
+
default:
|
|
1497
|
+
let u = options.readUnknownField;
|
|
1498
|
+
if (u === "throw")
|
|
1499
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1500
|
+
let d = reader.skip(wireType);
|
|
1501
|
+
if (u !== false)
|
|
1502
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1503
|
+
}
|
|
1504
|
+
}
|
|
1505
|
+
return message;
|
|
1506
|
+
}
|
|
1507
|
+
internalBinaryWrite(message: AllDerivativeMarketSummaryRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1508
|
+
/* string resolution = 1; */
|
|
1509
|
+
if (message.resolution !== "")
|
|
1510
|
+
writer.tag(1, WireType.LengthDelimited).string(message.resolution);
|
|
1511
|
+
let u = options.writeUnknownFields;
|
|
1512
|
+
if (u !== false)
|
|
1513
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1514
|
+
return writer;
|
|
1515
|
+
}
|
|
1516
|
+
}
|
|
1517
|
+
/**
|
|
1518
|
+
* @generated MessageType for protobuf message injective_chart_rpc.AllDerivativeMarketSummaryRequest
|
|
1519
|
+
*/
|
|
1520
|
+
export const AllDerivativeMarketSummaryRequest = new AllDerivativeMarketSummaryRequest$Type();
|
|
1521
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1522
|
+
class AllDerivativeMarketSummaryResponse$Type extends MessageType<AllDerivativeMarketSummaryResponse> {
|
|
1523
|
+
constructor() {
|
|
1524
|
+
super("injective_chart_rpc.AllDerivativeMarketSummaryResponse", [
|
|
1525
|
+
{ no: 1, name: "field", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => MarketSummaryResp }
|
|
1526
|
+
]);
|
|
1527
|
+
}
|
|
1528
|
+
create(value?: PartialMessage<AllDerivativeMarketSummaryResponse>): AllDerivativeMarketSummaryResponse {
|
|
1529
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1530
|
+
message.field = [];
|
|
1531
|
+
if (value !== undefined)
|
|
1532
|
+
reflectionMergePartial<AllDerivativeMarketSummaryResponse>(this, message, value);
|
|
1533
|
+
return message;
|
|
1534
|
+
}
|
|
1535
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AllDerivativeMarketSummaryResponse): AllDerivativeMarketSummaryResponse {
|
|
1536
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1537
|
+
while (reader.pos < end) {
|
|
1538
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1539
|
+
switch (fieldNo) {
|
|
1540
|
+
case /* repeated injective_chart_rpc.MarketSummaryResp field */ 1:
|
|
1541
|
+
message.field.push(MarketSummaryResp.internalBinaryRead(reader, reader.uint32(), options));
|
|
1542
|
+
break;
|
|
1543
|
+
default:
|
|
1544
|
+
let u = options.readUnknownField;
|
|
1545
|
+
if (u === "throw")
|
|
1546
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1547
|
+
let d = reader.skip(wireType);
|
|
1548
|
+
if (u !== false)
|
|
1549
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1550
|
+
}
|
|
1551
|
+
}
|
|
1552
|
+
return message;
|
|
1553
|
+
}
|
|
1554
|
+
internalBinaryWrite(message: AllDerivativeMarketSummaryResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1555
|
+
/* repeated injective_chart_rpc.MarketSummaryResp field = 1; */
|
|
1556
|
+
for (let i = 0; i < message.field.length; i++)
|
|
1557
|
+
MarketSummaryResp.internalBinaryWrite(message.field[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
1558
|
+
let u = options.writeUnknownFields;
|
|
1559
|
+
if (u !== false)
|
|
1560
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1561
|
+
return writer;
|
|
1562
|
+
}
|
|
1563
|
+
}
|
|
1564
|
+
/**
|
|
1565
|
+
* @generated MessageType for protobuf message injective_chart_rpc.AllDerivativeMarketSummaryResponse
|
|
1566
|
+
*/
|
|
1567
|
+
export const AllDerivativeMarketSummaryResponse = new AllDerivativeMarketSummaryResponse$Type();
|
|
1568
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1569
|
+
class MarketSnapshotRequest$Type extends MessageType<MarketSnapshotRequest> {
|
|
1570
|
+
constructor() {
|
|
1571
|
+
super("injective_chart_rpc.MarketSnapshotRequest", [
|
|
1572
|
+
{ no: 1, name: "market_i_ds", kind: "scalar", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ },
|
|
1573
|
+
{ no: 2, name: "resolution", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
1574
|
+
{ no: 3, name: "countback", kind: "scalar", T: 17 /*ScalarType.SINT32*/ }
|
|
1575
|
+
]);
|
|
1576
|
+
}
|
|
1577
|
+
create(value?: PartialMessage<MarketSnapshotRequest>): MarketSnapshotRequest {
|
|
1578
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1579
|
+
message.marketIDs = [];
|
|
1580
|
+
message.resolution = "";
|
|
1581
|
+
message.countback = 0;
|
|
1582
|
+
if (value !== undefined)
|
|
1583
|
+
reflectionMergePartial<MarketSnapshotRequest>(this, message, value);
|
|
1584
|
+
return message;
|
|
1585
|
+
}
|
|
1586
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: MarketSnapshotRequest): MarketSnapshotRequest {
|
|
1587
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1588
|
+
while (reader.pos < end) {
|
|
1589
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1590
|
+
switch (fieldNo) {
|
|
1591
|
+
case /* repeated string market_i_ds */ 1:
|
|
1592
|
+
message.marketIDs.push(reader.string());
|
|
1593
|
+
break;
|
|
1594
|
+
case /* string resolution */ 2:
|
|
1595
|
+
message.resolution = reader.string();
|
|
1596
|
+
break;
|
|
1597
|
+
case /* sint32 countback */ 3:
|
|
1598
|
+
message.countback = reader.sint32();
|
|
1599
|
+
break;
|
|
1600
|
+
default:
|
|
1601
|
+
let u = options.readUnknownField;
|
|
1602
|
+
if (u === "throw")
|
|
1603
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1604
|
+
let d = reader.skip(wireType);
|
|
1605
|
+
if (u !== false)
|
|
1606
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1607
|
+
}
|
|
1608
|
+
}
|
|
1609
|
+
return message;
|
|
1610
|
+
}
|
|
1611
|
+
internalBinaryWrite(message: MarketSnapshotRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1612
|
+
/* repeated string market_i_ds = 1; */
|
|
1613
|
+
for (let i = 0; i < message.marketIDs.length; i++)
|
|
1614
|
+
writer.tag(1, WireType.LengthDelimited).string(message.marketIDs[i]);
|
|
1615
|
+
/* string resolution = 2; */
|
|
1616
|
+
if (message.resolution !== "")
|
|
1617
|
+
writer.tag(2, WireType.LengthDelimited).string(message.resolution);
|
|
1618
|
+
/* sint32 countback = 3; */
|
|
1619
|
+
if (message.countback !== 0)
|
|
1620
|
+
writer.tag(3, WireType.Varint).sint32(message.countback);
|
|
1621
|
+
let u = options.writeUnknownFields;
|
|
1622
|
+
if (u !== false)
|
|
1623
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1624
|
+
return writer;
|
|
1625
|
+
}
|
|
1626
|
+
}
|
|
1627
|
+
/**
|
|
1628
|
+
* @generated MessageType for protobuf message injective_chart_rpc.MarketSnapshotRequest
|
|
1629
|
+
*/
|
|
1630
|
+
export const MarketSnapshotRequest = new MarketSnapshotRequest$Type();
|
|
1631
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1632
|
+
class MarketSnapshotResponse$Type extends MessageType<MarketSnapshotResponse> {
|
|
1633
|
+
constructor() {
|
|
1634
|
+
super("injective_chart_rpc.MarketSnapshotResponse", [
|
|
1635
|
+
{ no: 1, name: "field", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => MarketSnapshotHistoryResponse }
|
|
1636
|
+
]);
|
|
1637
|
+
}
|
|
1638
|
+
create(value?: PartialMessage<MarketSnapshotResponse>): MarketSnapshotResponse {
|
|
1639
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1640
|
+
message.field = [];
|
|
1641
|
+
if (value !== undefined)
|
|
1642
|
+
reflectionMergePartial<MarketSnapshotResponse>(this, message, value);
|
|
1643
|
+
return message;
|
|
1644
|
+
}
|
|
1645
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: MarketSnapshotResponse): MarketSnapshotResponse {
|
|
1646
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1647
|
+
while (reader.pos < end) {
|
|
1648
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1649
|
+
switch (fieldNo) {
|
|
1650
|
+
case /* repeated injective_chart_rpc.MarketSnapshotHistoryResponse field */ 1:
|
|
1651
|
+
message.field.push(MarketSnapshotHistoryResponse.internalBinaryRead(reader, reader.uint32(), options));
|
|
1652
|
+
break;
|
|
1653
|
+
default:
|
|
1654
|
+
let u = options.readUnknownField;
|
|
1655
|
+
if (u === "throw")
|
|
1656
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1657
|
+
let d = reader.skip(wireType);
|
|
1658
|
+
if (u !== false)
|
|
1659
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1660
|
+
}
|
|
1661
|
+
}
|
|
1662
|
+
return message;
|
|
1663
|
+
}
|
|
1664
|
+
internalBinaryWrite(message: MarketSnapshotResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1665
|
+
/* repeated injective_chart_rpc.MarketSnapshotHistoryResponse field = 1; */
|
|
1666
|
+
for (let i = 0; i < message.field.length; i++)
|
|
1667
|
+
MarketSnapshotHistoryResponse.internalBinaryWrite(message.field[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
1668
|
+
let u = options.writeUnknownFields;
|
|
1669
|
+
if (u !== false)
|
|
1670
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1671
|
+
return writer;
|
|
1672
|
+
}
|
|
1673
|
+
}
|
|
1674
|
+
/**
|
|
1675
|
+
* @generated MessageType for protobuf message injective_chart_rpc.MarketSnapshotResponse
|
|
1676
|
+
*/
|
|
1677
|
+
export const MarketSnapshotResponse = new MarketSnapshotResponse$Type();
|
|
1678
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
1679
|
+
class MarketSnapshotHistoryResponse$Type extends MessageType<MarketSnapshotHistoryResponse> {
|
|
1680
|
+
constructor() {
|
|
1681
|
+
super("injective_chart_rpc.MarketSnapshotHistoryResponse", [
|
|
1682
|
+
{ no: 1, name: "market_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
1683
|
+
{ no: 2, name: "resolution", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
1684
|
+
{ no: 3, name: "t", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 17 /*ScalarType.SINT32*/ },
|
|
1685
|
+
{ no: 4, name: "o", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
1686
|
+
{ no: 5, name: "h", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
1687
|
+
{ no: 6, name: "l", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
1688
|
+
{ no: 7, name: "c", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ },
|
|
1689
|
+
{ no: 8, name: "v", kind: "scalar", repeat: 1 /*RepeatType.PACKED*/, T: 1 /*ScalarType.DOUBLE*/ }
|
|
1690
|
+
]);
|
|
1691
|
+
}
|
|
1692
|
+
create(value?: PartialMessage<MarketSnapshotHistoryResponse>): MarketSnapshotHistoryResponse {
|
|
1693
|
+
const message = globalThis.Object.create((this.messagePrototype!));
|
|
1694
|
+
message.marketId = "";
|
|
1695
|
+
message.resolution = "";
|
|
1696
|
+
message.t = [];
|
|
1697
|
+
message.o = [];
|
|
1698
|
+
message.h = [];
|
|
1699
|
+
message.l = [];
|
|
1700
|
+
message.c = [];
|
|
1701
|
+
message.v = [];
|
|
1702
|
+
if (value !== undefined)
|
|
1703
|
+
reflectionMergePartial<MarketSnapshotHistoryResponse>(this, message, value);
|
|
1704
|
+
return message;
|
|
1705
|
+
}
|
|
1706
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: MarketSnapshotHistoryResponse): MarketSnapshotHistoryResponse {
|
|
1707
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
1708
|
+
while (reader.pos < end) {
|
|
1709
|
+
let [fieldNo, wireType] = reader.tag();
|
|
1710
|
+
switch (fieldNo) {
|
|
1711
|
+
case /* string market_id */ 1:
|
|
1712
|
+
message.marketId = reader.string();
|
|
1713
|
+
break;
|
|
1714
|
+
case /* string resolution */ 2:
|
|
1715
|
+
message.resolution = reader.string();
|
|
1716
|
+
break;
|
|
1717
|
+
case /* repeated sint32 t */ 3:
|
|
1718
|
+
if (wireType === WireType.LengthDelimited)
|
|
1719
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
1720
|
+
message.t.push(reader.sint32());
|
|
1721
|
+
else
|
|
1722
|
+
message.t.push(reader.sint32());
|
|
1723
|
+
break;
|
|
1724
|
+
case /* repeated double o */ 4:
|
|
1725
|
+
if (wireType === WireType.LengthDelimited)
|
|
1726
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
1727
|
+
message.o.push(reader.double());
|
|
1728
|
+
else
|
|
1729
|
+
message.o.push(reader.double());
|
|
1730
|
+
break;
|
|
1731
|
+
case /* repeated double h */ 5:
|
|
1732
|
+
if (wireType === WireType.LengthDelimited)
|
|
1733
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
1734
|
+
message.h.push(reader.double());
|
|
1735
|
+
else
|
|
1736
|
+
message.h.push(reader.double());
|
|
1737
|
+
break;
|
|
1738
|
+
case /* repeated double l */ 6:
|
|
1739
|
+
if (wireType === WireType.LengthDelimited)
|
|
1740
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
1741
|
+
message.l.push(reader.double());
|
|
1742
|
+
else
|
|
1743
|
+
message.l.push(reader.double());
|
|
1744
|
+
break;
|
|
1745
|
+
case /* repeated double c */ 7:
|
|
1746
|
+
if (wireType === WireType.LengthDelimited)
|
|
1747
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
1748
|
+
message.c.push(reader.double());
|
|
1749
|
+
else
|
|
1750
|
+
message.c.push(reader.double());
|
|
1751
|
+
break;
|
|
1752
|
+
case /* repeated double v */ 8:
|
|
1753
|
+
if (wireType === WireType.LengthDelimited)
|
|
1754
|
+
for (let e = reader.int32() + reader.pos; reader.pos < e;)
|
|
1755
|
+
message.v.push(reader.double());
|
|
1756
|
+
else
|
|
1757
|
+
message.v.push(reader.double());
|
|
1758
|
+
break;
|
|
1759
|
+
default:
|
|
1760
|
+
let u = options.readUnknownField;
|
|
1761
|
+
if (u === "throw")
|
|
1762
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
1763
|
+
let d = reader.skip(wireType);
|
|
1764
|
+
if (u !== false)
|
|
1765
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
1766
|
+
}
|
|
1767
|
+
}
|
|
1768
|
+
return message;
|
|
1769
|
+
}
|
|
1770
|
+
internalBinaryWrite(message: MarketSnapshotHistoryResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
|
1771
|
+
/* string market_id = 1; */
|
|
1772
|
+
if (message.marketId !== "")
|
|
1773
|
+
writer.tag(1, WireType.LengthDelimited).string(message.marketId);
|
|
1774
|
+
/* string resolution = 2; */
|
|
1775
|
+
if (message.resolution !== "")
|
|
1776
|
+
writer.tag(2, WireType.LengthDelimited).string(message.resolution);
|
|
1777
|
+
/* repeated sint32 t = 3; */
|
|
1778
|
+
if (message.t.length) {
|
|
1779
|
+
writer.tag(3, WireType.LengthDelimited).fork();
|
|
1780
|
+
for (let i = 0; i < message.t.length; i++)
|
|
1781
|
+
writer.sint32(message.t[i]);
|
|
1782
|
+
writer.join();
|
|
1783
|
+
}
|
|
1784
|
+
/* repeated double o = 4; */
|
|
1785
|
+
if (message.o.length) {
|
|
1786
|
+
writer.tag(4, WireType.LengthDelimited).fork();
|
|
1787
|
+
for (let i = 0; i < message.o.length; i++)
|
|
1788
|
+
writer.double(message.o[i]);
|
|
1789
|
+
writer.join();
|
|
1790
|
+
}
|
|
1791
|
+
/* repeated double h = 5; */
|
|
1792
|
+
if (message.h.length) {
|
|
1793
|
+
writer.tag(5, WireType.LengthDelimited).fork();
|
|
1794
|
+
for (let i = 0; i < message.h.length; i++)
|
|
1795
|
+
writer.double(message.h[i]);
|
|
1796
|
+
writer.join();
|
|
1797
|
+
}
|
|
1798
|
+
/* repeated double l = 6; */
|
|
1799
|
+
if (message.l.length) {
|
|
1800
|
+
writer.tag(6, WireType.LengthDelimited).fork();
|
|
1801
|
+
for (let i = 0; i < message.l.length; i++)
|
|
1802
|
+
writer.double(message.l[i]);
|
|
1803
|
+
writer.join();
|
|
1804
|
+
}
|
|
1805
|
+
/* repeated double c = 7; */
|
|
1806
|
+
if (message.c.length) {
|
|
1807
|
+
writer.tag(7, WireType.LengthDelimited).fork();
|
|
1808
|
+
for (let i = 0; i < message.c.length; i++)
|
|
1809
|
+
writer.double(message.c[i]);
|
|
1810
|
+
writer.join();
|
|
1811
|
+
}
|
|
1812
|
+
/* repeated double v = 8; */
|
|
1813
|
+
if (message.v.length) {
|
|
1814
|
+
writer.tag(8, WireType.LengthDelimited).fork();
|
|
1815
|
+
for (let i = 0; i < message.v.length; i++)
|
|
1816
|
+
writer.double(message.v[i]);
|
|
1817
|
+
writer.join();
|
|
1818
|
+
}
|
|
1819
|
+
let u = options.writeUnknownFields;
|
|
1820
|
+
if (u !== false)
|
|
1821
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
1822
|
+
return writer;
|
|
1823
|
+
}
|
|
1824
|
+
}
|
|
1825
|
+
/**
|
|
1826
|
+
* @generated MessageType for protobuf message injective_chart_rpc.MarketSnapshotHistoryResponse
|
|
1827
|
+
*/
|
|
1828
|
+
export const MarketSnapshotHistoryResponse = new MarketSnapshotHistoryResponse$Type();
|
|
1829
|
+
/**
|
|
1830
|
+
* @generated ServiceType for protobuf service injective_chart_rpc.InjectiveChartRPC
|
|
1831
|
+
*/
|
|
1832
|
+
export const InjectiveChartRPC = new ServiceType("injective_chart_rpc.InjectiveChartRPC", [
|
|
1833
|
+
{ name: "SpotMarketHistory", options: {}, I: SpotMarketHistoryRequest, O: SpotMarketHistoryResponse },
|
|
1834
|
+
{ name: "DerivativeMarketHistory", options: {}, I: DerivativeMarketHistoryRequest, O: DerivativeMarketHistoryResponse },
|
|
1835
|
+
{ name: "SpotMarketSummary", options: {}, I: SpotMarketSummaryRequest, O: SpotMarketSummaryResponse },
|
|
1836
|
+
{ name: "AllSpotMarketSummary", options: {}, I: AllSpotMarketSummaryRequest, O: AllSpotMarketSummaryResponse },
|
|
1837
|
+
{ name: "DerivativeMarketSummary", options: {}, I: DerivativeMarketSummaryRequest, O: DerivativeMarketSummaryResponse },
|
|
1838
|
+
{ name: "AllDerivativeMarketSummary", options: {}, I: AllDerivativeMarketSummaryRequest, O: AllDerivativeMarketSummaryResponse },
|
|
1839
|
+
{ name: "MarketSnapshot", options: {}, I: MarketSnapshotRequest, O: MarketSnapshotResponse }
|
|
1840
|
+
]);
|