@monolythium/core-sdk 0.1.0 → 0.2.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/README.md +115 -24
- package/dist/crypto/index.cjs +62 -12
- package/dist/crypto/index.cjs.map +1 -1
- package/dist/crypto/index.d.cts +4 -115
- package/dist/crypto/index.d.ts +4 -115
- package/dist/crypto/index.js +61 -13
- package/dist/crypto/index.js.map +1 -1
- package/dist/ethers/index.cjs +2116 -0
- package/dist/ethers/index.cjs.map +1 -0
- package/dist/ethers/index.d.cts +300 -0
- package/dist/ethers/index.d.ts +300 -0
- package/dist/ethers/index.js +2107 -0
- package/dist/ethers/index.js.map +1 -0
- package/dist/index.cjs +7435 -1555
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1555 -346
- package/dist/index.d.ts +1555 -346
- package/dist/index.js +7193 -1548
- package/dist/index.js.map +1 -1
- package/dist/native-events-BEkkGoak.d.cts +3708 -0
- package/dist/native-events-BEkkGoak.d.ts +3708 -0
- package/dist/network-BK2u9br2.d.cts +31 -0
- package/dist/network-BK2u9br2.d.ts +31 -0
- package/dist/submission-BrsftNSl.d.cts +131 -0
- package/dist/submission-CelGfDRQ.d.ts +131 -0
- package/package.json +8 -2
- package/dist/client-CpnpVkrR.d.cts +0 -2237
- package/dist/client-CpnpVkrR.d.ts +0 -2237
|
@@ -1,2237 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Market metadata returned inside `lyth_clobMarket`.
|
|
3
|
-
*/
|
|
4
|
-
type ClobMarketRecord = {
|
|
5
|
-
/**
|
|
6
|
-
* Base token id.
|
|
7
|
-
*/
|
|
8
|
-
baseToken: string;
|
|
9
|
-
/**
|
|
10
|
-
* Quote token id.
|
|
11
|
-
*/
|
|
12
|
-
quoteToken: string;
|
|
13
|
-
/**
|
|
14
|
-
* Best bid price as a decimal string.
|
|
15
|
-
*/
|
|
16
|
-
bestBidPrice: string;
|
|
17
|
-
/**
|
|
18
|
-
* Best ask price as a decimal string.
|
|
19
|
-
*/
|
|
20
|
-
bestAskPrice: string;
|
|
21
|
-
/**
|
|
22
|
-
* Last trade price as a decimal string.
|
|
23
|
-
*/
|
|
24
|
-
lastTradePrice: string;
|
|
25
|
-
/**
|
|
26
|
-
* Total traded base volume as a decimal string.
|
|
27
|
-
*/
|
|
28
|
-
totalVolumeBase: string;
|
|
29
|
-
/**
|
|
30
|
-
* Taker fee in basis points.
|
|
31
|
-
*/
|
|
32
|
-
takerFeeBps: number;
|
|
33
|
-
/**
|
|
34
|
-
* Tick size as a decimal string.
|
|
35
|
-
*/
|
|
36
|
-
tickSize: string;
|
|
37
|
-
/**
|
|
38
|
-
* Lot size as a decimal string.
|
|
39
|
-
*/
|
|
40
|
-
lotSize: string;
|
|
41
|
-
/**
|
|
42
|
-
* Minimum notional as a decimal string.
|
|
43
|
-
*/
|
|
44
|
-
minNotional: string;
|
|
45
|
-
/**
|
|
46
|
-
* Whether the market is registered on-chain.
|
|
47
|
-
*/
|
|
48
|
-
isRegistered: boolean;
|
|
49
|
-
/**
|
|
50
|
-
* Registration block.
|
|
51
|
-
*/
|
|
52
|
-
registeredAtBlock: bigint;
|
|
53
|
-
};
|
|
54
|
-
|
|
55
|
-
/**
|
|
56
|
-
* `lyth_clobMarket` response.
|
|
57
|
-
*/
|
|
58
|
-
type ClobMarketResponse = {
|
|
59
|
-
/**
|
|
60
|
-
* Response schema version.
|
|
61
|
-
*/
|
|
62
|
-
schemaVersion: number;
|
|
63
|
-
/**
|
|
64
|
-
* Queried market id.
|
|
65
|
-
*/
|
|
66
|
-
marketId: string;
|
|
67
|
-
/**
|
|
68
|
-
* Market metadata, or `null` when the market is not found.
|
|
69
|
-
*/
|
|
70
|
-
market: ClobMarketRecord | null;
|
|
71
|
-
};
|
|
72
|
-
|
|
73
|
-
/**
|
|
74
|
-
* `lyth_getAccountPolicy` response.
|
|
75
|
-
*/
|
|
76
|
-
type AccountPolicy = {
|
|
77
|
-
/**
|
|
78
|
-
* Policy mode label — `"public"`, `"stealth"`, `"confidential"`,
|
|
79
|
-
* `"shielded"`.
|
|
80
|
-
*/
|
|
81
|
-
mode: string;
|
|
82
|
-
/**
|
|
83
|
-
* Whether the account accepts shielded transfers.
|
|
84
|
-
*/
|
|
85
|
-
allowShielded: boolean;
|
|
86
|
-
/**
|
|
87
|
-
* Whether the account accepts confidential transfers.
|
|
88
|
-
*/
|
|
89
|
-
allowConfidential: boolean;
|
|
90
|
-
/**
|
|
91
|
-
* Whether the account accepts stealth payments.
|
|
92
|
-
*/
|
|
93
|
-
acceptStealth: boolean;
|
|
94
|
-
/**
|
|
95
|
-
* Whether the account requires originator proof.
|
|
96
|
-
*/
|
|
97
|
-
requireOriginatorProof: boolean;
|
|
98
|
-
/**
|
|
99
|
-
* Whether the account requires allowlist proof.
|
|
100
|
-
*/
|
|
101
|
-
requireAllowlistProof: boolean;
|
|
102
|
-
/**
|
|
103
|
-
* Raw flag word, `0x`-hex two-digit byte.
|
|
104
|
-
*/
|
|
105
|
-
flags: string;
|
|
106
|
-
/**
|
|
107
|
-
* `true` when the account has explicitly set policy bits.
|
|
108
|
-
*/
|
|
109
|
-
explicit: boolean;
|
|
110
|
-
};
|
|
111
|
-
|
|
112
|
-
/**
|
|
113
|
-
* Account proof envelope returned by `eth_getBalance` /
|
|
114
|
-
* `eth_getStorageAt` / `lyth_registryStateProof`.
|
|
115
|
-
*
|
|
116
|
-
* `value` is the raw quantity (or 32-byte word for storage) as returned
|
|
117
|
-
* by the chain. `state_root` is the trie root the proof is verified
|
|
118
|
-
* against. `proof` is `null` when the chain provider could not produce
|
|
119
|
-
* an inclusion proof for this slot at the requested block.
|
|
120
|
-
*/
|
|
121
|
-
type AccountProofResponse = {
|
|
122
|
-
/**
|
|
123
|
-
* `0x`-hex value (balance, storage word, or peer id depending on
|
|
124
|
-
* the calling method).
|
|
125
|
-
*/
|
|
126
|
-
value: string;
|
|
127
|
-
/**
|
|
128
|
-
* State-root hex the proof verifies against.
|
|
129
|
-
*/
|
|
130
|
-
state_root: string;
|
|
131
|
-
/**
|
|
132
|
-
* Block height the proof was generated against.
|
|
133
|
-
*/
|
|
134
|
-
block_number: bigint;
|
|
135
|
-
/**
|
|
136
|
-
* Inclusion proof envelope, omitted when the chain didn't produce
|
|
137
|
-
* one. The shape is intentionally opaque at this layer — callers
|
|
138
|
-
* that need to verify the proof bring an internal state crate in
|
|
139
|
-
* directly.
|
|
140
|
-
*/
|
|
141
|
-
proof?: unknown | null;
|
|
142
|
-
};
|
|
143
|
-
|
|
144
|
-
/**
|
|
145
|
-
* Retention metadata returned by `lyth_addressActivityKind` for
|
|
146
|
-
* pruned address activity windows.
|
|
147
|
-
*/
|
|
148
|
-
type AddressActivityArchiveRedirect = {
|
|
149
|
-
/**
|
|
150
|
-
* Human-readable archival hint supplied by the node.
|
|
151
|
-
*/
|
|
152
|
-
hint: string;
|
|
153
|
-
};
|
|
154
|
-
|
|
155
|
-
/**
|
|
156
|
-
* One row in `lyth_getAddressActivity`.
|
|
157
|
-
*/
|
|
158
|
-
type AddressActivityEntry = {
|
|
159
|
-
/**
|
|
160
|
-
* Block height the event landed in.
|
|
161
|
-
*/
|
|
162
|
-
blockHeight: bigint;
|
|
163
|
-
/**
|
|
164
|
-
* Tx index within the block.
|
|
165
|
-
*/
|
|
166
|
-
txIndex: number;
|
|
167
|
-
/**
|
|
168
|
-
* Log index within the tx.
|
|
169
|
-
*/
|
|
170
|
-
logIndex: number;
|
|
171
|
-
/**
|
|
172
|
-
* Source kind: transfer, swap, staking, or delegation.
|
|
173
|
-
*/
|
|
174
|
-
kind: string;
|
|
175
|
-
/**
|
|
176
|
-
* Direction relative to the queried address, when directional.
|
|
177
|
-
*/
|
|
178
|
-
direction: string | null;
|
|
179
|
-
/**
|
|
180
|
-
* Counterparty address for directional value movement.
|
|
181
|
-
*/
|
|
182
|
-
counterparty: string | null;
|
|
183
|
-
/**
|
|
184
|
-
* 32-byte token id when the event involves a token.
|
|
185
|
-
*/
|
|
186
|
-
tokenId: string | null;
|
|
187
|
-
/**
|
|
188
|
-
* Decimal-string amount when the event has an amount.
|
|
189
|
-
*/
|
|
190
|
-
amount: string | null;
|
|
191
|
-
/**
|
|
192
|
-
* Cluster id when the event involves a cluster.
|
|
193
|
-
*/
|
|
194
|
-
cluster: number | null;
|
|
195
|
-
/**
|
|
196
|
-
* Delegation weight in basis points.
|
|
197
|
-
*/
|
|
198
|
-
weightBps: number | null;
|
|
199
|
-
/**
|
|
200
|
-
* Kind-specific sub-label such as delegated, unstake, or stake.
|
|
201
|
-
*/
|
|
202
|
-
subKind: string | null;
|
|
203
|
-
};
|
|
204
|
-
|
|
205
|
-
/**
|
|
206
|
-
* Retention bounds returned by `lyth_addressActivityKind`.
|
|
207
|
-
*/
|
|
208
|
-
type AddressActivityKindRetention = {
|
|
209
|
-
/**
|
|
210
|
-
* Earliest retained block for indexed activity.
|
|
211
|
-
*/
|
|
212
|
-
earliestRetained: bigint;
|
|
213
|
-
/**
|
|
214
|
-
* Optional archive redirect hint.
|
|
215
|
-
*/
|
|
216
|
-
archiveRedirect?: AddressActivityArchiveRedirect;
|
|
217
|
-
};
|
|
218
|
-
|
|
219
|
-
/**
|
|
220
|
-
* `lyth_addressActivityKind` response.
|
|
221
|
-
*/
|
|
222
|
-
type AddressActivityKindResponse = {
|
|
223
|
-
/**
|
|
224
|
-
* Response schema version.
|
|
225
|
-
*/
|
|
226
|
-
schemaVersion: number;
|
|
227
|
-
/**
|
|
228
|
-
* Queried address.
|
|
229
|
-
*/
|
|
230
|
-
address: string;
|
|
231
|
-
/**
|
|
232
|
-
* `found`, `not_found`, `indexer_disabled`, `pruned`, `private`,
|
|
233
|
-
* or a forward-compatible node-supplied string.
|
|
234
|
-
*/
|
|
235
|
-
kind: string;
|
|
236
|
-
/**
|
|
237
|
-
* Retention metadata when the activity window was pruned.
|
|
238
|
-
*/
|
|
239
|
-
retention?: AddressActivityKindRetention;
|
|
240
|
-
};
|
|
241
|
-
|
|
242
|
-
/**
|
|
243
|
-
* Address-label row surfaced by `lyth_getAddressLabel`.
|
|
244
|
-
*/
|
|
245
|
-
type AddressLabelRecord = {
|
|
246
|
-
/**
|
|
247
|
-
* Labeled address.
|
|
248
|
-
*/
|
|
249
|
-
address: string;
|
|
250
|
-
/**
|
|
251
|
-
* Lowercase category name, e.g. `foundation`, `exchange`,
|
|
252
|
-
* `bridge`, `treasury`, `contract`, or `operator`.
|
|
253
|
-
*/
|
|
254
|
-
category: string;
|
|
255
|
-
/**
|
|
256
|
-
* Optional human-readable display name.
|
|
257
|
-
*/
|
|
258
|
-
displayName: string | null;
|
|
259
|
-
/**
|
|
260
|
-
* Block height the label was last asserted at.
|
|
261
|
-
*/
|
|
262
|
-
updatedAtBlock: bigint;
|
|
263
|
-
};
|
|
264
|
-
|
|
265
|
-
/**
|
|
266
|
-
* `lyth_getAssetPolicy` response.
|
|
267
|
-
*/
|
|
268
|
-
type AssetPolicy = {
|
|
269
|
-
/**
|
|
270
|
-
* Policy mode label.
|
|
271
|
-
*/
|
|
272
|
-
mode: string;
|
|
273
|
-
/**
|
|
274
|
-
* Whether the asset allows shielded transfers.
|
|
275
|
-
*/
|
|
276
|
-
allowShielded: boolean;
|
|
277
|
-
/**
|
|
278
|
-
* Whether the asset allows confidential transfers.
|
|
279
|
-
*/
|
|
280
|
-
allowConfidential: boolean;
|
|
281
|
-
/**
|
|
282
|
-
* Whether the asset allows stealth transfers.
|
|
283
|
-
*/
|
|
284
|
-
allowStealth: boolean;
|
|
285
|
-
/**
|
|
286
|
-
* Whether the asset allows transparent transfers.
|
|
287
|
-
*/
|
|
288
|
-
allowTransparent: boolean;
|
|
289
|
-
/**
|
|
290
|
-
* KYC requirement bit.
|
|
291
|
-
*/
|
|
292
|
-
requireKyc: boolean;
|
|
293
|
-
/**
|
|
294
|
-
* Raw levels byte, `0x`-hex two-digit.
|
|
295
|
-
*/
|
|
296
|
-
levels: string;
|
|
297
|
-
/**
|
|
298
|
-
* `true` when the asset has explicitly set policy.
|
|
299
|
-
*/
|
|
300
|
-
explicit: boolean;
|
|
301
|
-
};
|
|
302
|
-
|
|
303
|
-
/**
|
|
304
|
-
* Block header surfaced via `eth_getBlockByNumber` / `eth_getBlockByHash`.
|
|
305
|
-
*
|
|
306
|
-
* Field naming mirrors the on-wire shape — fields use snake_case in
|
|
307
|
-
* the v0.0.1 server. A future server version may upgrade to camelCase;
|
|
308
|
-
* when that happens we add a serde alias.
|
|
309
|
-
*/
|
|
310
|
-
type BlockHeader = {
|
|
311
|
-
/**
|
|
312
|
-
* Block number (height).
|
|
313
|
-
*/
|
|
314
|
-
number: bigint;
|
|
315
|
-
/**
|
|
316
|
-
* Block hash (32 bytes hex).
|
|
317
|
-
*/
|
|
318
|
-
hash: string;
|
|
319
|
-
/**
|
|
320
|
-
* Parent block hash.
|
|
321
|
-
*/
|
|
322
|
-
parent_hash: string;
|
|
323
|
-
/**
|
|
324
|
-
* State-root commitment.
|
|
325
|
-
*/
|
|
326
|
-
state_root: string;
|
|
327
|
-
/**
|
|
328
|
-
* UNIX seconds.
|
|
329
|
-
*/
|
|
330
|
-
timestamp: bigint;
|
|
331
|
-
/**
|
|
332
|
-
* Total gas consumed.
|
|
333
|
-
*/
|
|
334
|
-
gas_used: bigint;
|
|
335
|
-
/**
|
|
336
|
-
* Block gas limit.
|
|
337
|
-
*/
|
|
338
|
-
gas_limit: bigint;
|
|
339
|
-
};
|
|
340
|
-
|
|
341
|
-
/**
|
|
342
|
-
* EVM block tag. Use [`BlockSelector`] when sending to the wire — this
|
|
343
|
-
* is the strongly-typed half of an `eth_*` block argument.
|
|
344
|
-
*/
|
|
345
|
-
type BlockTag = "latest" | "earliest" | "finalized" | "safe" | "pending";
|
|
346
|
-
|
|
347
|
-
/**
|
|
348
|
-
* BLS aggregate certificate response used by the AUD-0074 certificate RPCs.
|
|
349
|
-
*/
|
|
350
|
-
type BlsCertificateResponse = {
|
|
351
|
-
/**
|
|
352
|
-
* Round at which the certificate sealed.
|
|
353
|
-
*/
|
|
354
|
-
round: bigint;
|
|
355
|
-
/**
|
|
356
|
-
* `0x`-prefixed aggregate BLS signature.
|
|
357
|
-
*/
|
|
358
|
-
signature: string;
|
|
359
|
-
/**
|
|
360
|
-
* Signer-set bitmap as `0x`-hex bytes.
|
|
361
|
-
*/
|
|
362
|
-
signers_bitmap: string;
|
|
363
|
-
/**
|
|
364
|
-
* Operator indices decoded from the signer bitmap.
|
|
365
|
-
*/
|
|
366
|
-
signer_indices: Array<number>;
|
|
367
|
-
/**
|
|
368
|
-
* Number of signing operators.
|
|
369
|
-
*/
|
|
370
|
-
signer_count: number;
|
|
371
|
-
};
|
|
372
|
-
|
|
373
|
-
/**
|
|
374
|
-
* Argument shape for `eth_call` / `eth_estimateGas`.
|
|
375
|
-
*
|
|
376
|
-
* Every field is optional — the chain rejects payloads that omit
|
|
377
|
-
* required fields with an `InvalidParams` error.
|
|
378
|
-
*/
|
|
379
|
-
type CallRequest = {
|
|
380
|
-
/**
|
|
381
|
-
* Source address.
|
|
382
|
-
*/
|
|
383
|
-
from?: string;
|
|
384
|
-
/**
|
|
385
|
-
* Destination address. `None` is interpreted as contract
|
|
386
|
-
* creation by the chain.
|
|
387
|
-
*/
|
|
388
|
-
to?: string;
|
|
389
|
-
/**
|
|
390
|
-
* Gas limit.
|
|
391
|
-
*/
|
|
392
|
-
gas?: string;
|
|
393
|
-
/**
|
|
394
|
-
* Gas price (legacy / non-EIP-1559).
|
|
395
|
-
*/
|
|
396
|
-
gasPrice?: string;
|
|
397
|
-
/**
|
|
398
|
-
* Wei to transfer.
|
|
399
|
-
*/
|
|
400
|
-
value?: string;
|
|
401
|
-
/**
|
|
402
|
-
* Calldata (`data` is canonical; chains accept `input` as alias).
|
|
403
|
-
*/
|
|
404
|
-
data?: string;
|
|
405
|
-
};
|
|
406
|
-
|
|
407
|
-
/**
|
|
408
|
-
* One entry in the `lyth_capabilities` keyed capability map.
|
|
409
|
-
*/
|
|
410
|
-
type CapabilityDescriptor = {
|
|
411
|
-
/**
|
|
412
|
-
* 20-byte precompile address, `0x`-hex.
|
|
413
|
-
*/
|
|
414
|
-
address: string;
|
|
415
|
-
/**
|
|
416
|
-
* Stable capability id from the milestone registry.
|
|
417
|
-
*/
|
|
418
|
-
capabilityId: string;
|
|
419
|
-
/**
|
|
420
|
-
* Human-readable capability/precompile name.
|
|
421
|
-
*/
|
|
422
|
-
capabilityName: string;
|
|
423
|
-
/**
|
|
424
|
-
* Gate class: `gateable`, `non-gateable`, or `retired-rejecting`.
|
|
425
|
-
*/
|
|
426
|
-
kind: string;
|
|
427
|
-
/**
|
|
428
|
-
* Whether the capability is currently dispatchable.
|
|
429
|
-
*/
|
|
430
|
-
active: boolean;
|
|
431
|
-
/**
|
|
432
|
-
* Height of the milestone that activated this capability, when any.
|
|
433
|
-
*/
|
|
434
|
-
activationHeight: bigint | null;
|
|
435
|
-
};
|
|
436
|
-
|
|
437
|
-
/**
|
|
438
|
-
* `lyth_capabilities` response.
|
|
439
|
-
*/
|
|
440
|
-
type CapabilitiesResponse = {
|
|
441
|
-
/**
|
|
442
|
-
* Block height sampled by the node.
|
|
443
|
-
*/
|
|
444
|
-
blockNumber: bigint;
|
|
445
|
-
/**
|
|
446
|
-
* Address-keyed capability map.
|
|
447
|
-
*/
|
|
448
|
-
capabilities: {
|
|
449
|
-
[key in string]?: CapabilityDescriptor;
|
|
450
|
-
};
|
|
451
|
-
};
|
|
452
|
-
|
|
453
|
-
/**
|
|
454
|
-
* One signature row in `lyth_getLatestCheckpoint`.
|
|
455
|
-
*/
|
|
456
|
-
type CheckpointRecord = {
|
|
457
|
-
/**
|
|
458
|
-
* Block height the checkpoint commits to.
|
|
459
|
-
*/
|
|
460
|
-
blockHeight: bigint;
|
|
461
|
-
/**
|
|
462
|
-
* State-root commitment at the checkpointed block.
|
|
463
|
-
*/
|
|
464
|
-
stateRoot: string;
|
|
465
|
-
/**
|
|
466
|
-
* Hex-encoded ML-DSA-65 signer public key.
|
|
467
|
-
*/
|
|
468
|
-
signerPubkeyHex: string;
|
|
469
|
-
/**
|
|
470
|
-
* Hex-encoded ML-DSA-65 signature.
|
|
471
|
-
*/
|
|
472
|
-
signatureHex: string;
|
|
473
|
-
};
|
|
474
|
-
|
|
475
|
-
/**
|
|
476
|
-
* `lyth_getClusterDelegators` response.
|
|
477
|
-
*/
|
|
478
|
-
type ClusterDelegatorsResponse = {
|
|
479
|
-
/**
|
|
480
|
-
* Queried cluster id.
|
|
481
|
-
*/
|
|
482
|
-
cluster: number;
|
|
483
|
-
/**
|
|
484
|
-
* Delegator wallet addresses.
|
|
485
|
-
*/
|
|
486
|
-
delegators: Array<string>;
|
|
487
|
-
/**
|
|
488
|
-
* Number of delegator slots scanned by the node.
|
|
489
|
-
*/
|
|
490
|
-
count: number;
|
|
491
|
-
/**
|
|
492
|
-
* Block selector echoed by the node.
|
|
493
|
-
*/
|
|
494
|
-
block: unknown;
|
|
495
|
-
};
|
|
496
|
-
|
|
497
|
-
/**
|
|
498
|
-
* `lyth_getClusterEntity` response.
|
|
499
|
-
*/
|
|
500
|
-
type ClusterEntityResponse = {
|
|
501
|
-
/**
|
|
502
|
-
* Queried cluster id.
|
|
503
|
-
*/
|
|
504
|
-
cluster: number;
|
|
505
|
-
/**
|
|
506
|
-
* Entity label, e.g. `"independent"` or `"mono-labs"`.
|
|
507
|
-
*/
|
|
508
|
-
entity: string;
|
|
509
|
-
/**
|
|
510
|
-
* Raw entity enum discriminant.
|
|
511
|
-
*/
|
|
512
|
-
entityCode: number;
|
|
513
|
-
/**
|
|
514
|
-
* Block selector echoed by the node.
|
|
515
|
-
*/
|
|
516
|
-
block: unknown;
|
|
517
|
-
};
|
|
518
|
-
|
|
519
|
-
/**
|
|
520
|
-
* One row from `lyth_getClusterResignations`.
|
|
521
|
-
*/
|
|
522
|
-
type ClusterResignationRow = {
|
|
523
|
-
/**
|
|
524
|
-
* `0x`-prefixed 48-byte BLS-G1 operator public key.
|
|
525
|
-
*/
|
|
526
|
-
operator: string;
|
|
527
|
-
/**
|
|
528
|
-
* `wire_pending`, `pending`, or `applied`.
|
|
529
|
-
*/
|
|
530
|
-
status: string;
|
|
531
|
-
/**
|
|
532
|
-
* Submitted-at block height, absent for wire-pending rows.
|
|
533
|
-
*/
|
|
534
|
-
submitted_at_height?: bigint;
|
|
535
|
-
/**
|
|
536
|
-
* Effective-at block height, absent for wire-pending rows.
|
|
537
|
-
*/
|
|
538
|
-
effective_at_height?: bigint;
|
|
539
|
-
/**
|
|
540
|
-
* Operator-set resignation nonce.
|
|
541
|
-
*/
|
|
542
|
-
nonce: bigint;
|
|
543
|
-
/**
|
|
544
|
-
* Whether the expedited path was honored.
|
|
545
|
-
*/
|
|
546
|
-
expedited: boolean;
|
|
547
|
-
};
|
|
548
|
-
|
|
549
|
-
/**
|
|
550
|
-
* `lyth_getClusterResignations` response.
|
|
551
|
-
*/
|
|
552
|
-
type ClusterResignationsResponse = {
|
|
553
|
-
/**
|
|
554
|
-
* Rows matching the requested filter.
|
|
555
|
-
*/
|
|
556
|
-
rows: Array<ClusterResignationRow>;
|
|
557
|
-
};
|
|
558
|
-
|
|
559
|
-
/**
|
|
560
|
-
* Parent vertex row returned by `lyth_dagParents`.
|
|
561
|
-
*/
|
|
562
|
-
type DagParent = {
|
|
563
|
-
/**
|
|
564
|
-
* Parent vertex hash.
|
|
565
|
-
*/
|
|
566
|
-
vertexHash: string;
|
|
567
|
-
/**
|
|
568
|
-
* Parent round.
|
|
569
|
-
*/
|
|
570
|
-
round: bigint;
|
|
571
|
-
};
|
|
572
|
-
|
|
573
|
-
/**
|
|
574
|
-
* `lyth_dagParents` response.
|
|
575
|
-
*/
|
|
576
|
-
type DagParentsResponse = {
|
|
577
|
-
/**
|
|
578
|
-
* Response schema version.
|
|
579
|
-
*/
|
|
580
|
-
schemaVersion: number;
|
|
581
|
-
/**
|
|
582
|
-
* Queried round.
|
|
583
|
-
*/
|
|
584
|
-
round: bigint;
|
|
585
|
-
/**
|
|
586
|
-
* Parent rows, or `null` when the round has no retained DAG data.
|
|
587
|
-
*/
|
|
588
|
-
parents: Array<DagParent> | null;
|
|
589
|
-
};
|
|
590
|
-
|
|
591
|
-
/**
|
|
592
|
-
* `lyth_syncStatus` DAG-sync driver snapshot.
|
|
593
|
-
*/
|
|
594
|
-
type DagSyncStatus = {
|
|
595
|
-
/**
|
|
596
|
-
* Driver state: `idle`, `probing`, `catching`, or `synced`.
|
|
597
|
-
*/
|
|
598
|
-
state: string;
|
|
599
|
-
/**
|
|
600
|
-
* Local anchor frontier round.
|
|
601
|
-
*/
|
|
602
|
-
localRound: bigint;
|
|
603
|
-
/**
|
|
604
|
-
* Highest peer committed round observed.
|
|
605
|
-
*/
|
|
606
|
-
peerMaxRound: bigint;
|
|
607
|
-
/**
|
|
608
|
-
* `peerMaxRound - localRound`, saturating at zero.
|
|
609
|
-
*/
|
|
610
|
-
lag: bigint;
|
|
611
|
-
};
|
|
612
|
-
|
|
613
|
-
/**
|
|
614
|
-
* Log row included in `lyth_decodeTx`.
|
|
615
|
-
*/
|
|
616
|
-
type DecodeTxLog = {
|
|
617
|
-
/**
|
|
618
|
-
* Contract address that emitted the log.
|
|
619
|
-
*/
|
|
620
|
-
address: string;
|
|
621
|
-
/**
|
|
622
|
-
* Indexed topics.
|
|
623
|
-
*/
|
|
624
|
-
topics: Array<string>;
|
|
625
|
-
/**
|
|
626
|
-
* ABI-encoded log data.
|
|
627
|
-
*/
|
|
628
|
-
data: string;
|
|
629
|
-
};
|
|
630
|
-
|
|
631
|
-
/**
|
|
632
|
-
* PQ-finality attestation included in `lyth_decodeTx` when available.
|
|
633
|
-
*/
|
|
634
|
-
type DecodeTxPqAttestation = {
|
|
635
|
-
/**
|
|
636
|
-
* Checkpoint height that attests the transaction.
|
|
637
|
-
*/
|
|
638
|
-
checkpointHeight: bigint;
|
|
639
|
-
/**
|
|
640
|
-
* Checkpointed state root.
|
|
641
|
-
*/
|
|
642
|
-
stateRoot: string;
|
|
643
|
-
/**
|
|
644
|
-
* Signer id that produced the attestation.
|
|
645
|
-
*/
|
|
646
|
-
signerId: string;
|
|
647
|
-
/**
|
|
648
|
-
* Scheme-prefixed signer signature.
|
|
649
|
-
*/
|
|
650
|
-
signature: string;
|
|
651
|
-
};
|
|
652
|
-
|
|
653
|
-
/**
|
|
654
|
-
* `lyth_decodeTx` response.
|
|
655
|
-
*/
|
|
656
|
-
type DecodeTxResponse = {
|
|
657
|
-
/**
|
|
658
|
-
* Transaction hash.
|
|
659
|
-
*/
|
|
660
|
-
txHash: string;
|
|
661
|
-
/**
|
|
662
|
-
* Containing block hash.
|
|
663
|
-
*/
|
|
664
|
-
blockHash: string;
|
|
665
|
-
/**
|
|
666
|
-
* Containing block number.
|
|
667
|
-
*/
|
|
668
|
-
blockNumber: bigint;
|
|
669
|
-
/**
|
|
670
|
-
* Transaction index within the block.
|
|
671
|
-
*/
|
|
672
|
-
txIndex: number;
|
|
673
|
-
/**
|
|
674
|
-
* Sender address.
|
|
675
|
-
*/
|
|
676
|
-
from: string;
|
|
677
|
-
/**
|
|
678
|
-
* Recipient address, or `null` for contract creation.
|
|
679
|
-
*/
|
|
680
|
-
to: string | null;
|
|
681
|
-
/**
|
|
682
|
-
* Transferred value as a hex quantity.
|
|
683
|
-
*/
|
|
684
|
-
value: string;
|
|
685
|
-
/**
|
|
686
|
-
* Sender nonce.
|
|
687
|
-
*/
|
|
688
|
-
nonce: bigint;
|
|
689
|
-
/**
|
|
690
|
-
* Gas limit.
|
|
691
|
-
*/
|
|
692
|
-
gasLimit: bigint;
|
|
693
|
-
/**
|
|
694
|
-
* Max fee per gas as a hex quantity.
|
|
695
|
-
*/
|
|
696
|
-
maxFeePerGas: string;
|
|
697
|
-
/**
|
|
698
|
-
* Max priority fee per gas as a hex quantity.
|
|
699
|
-
*/
|
|
700
|
-
maxPriorityFeePerGas: string;
|
|
701
|
-
/**
|
|
702
|
-
* Gas used when the transaction is confirmed.
|
|
703
|
-
*/
|
|
704
|
-
gasUsed: bigint | null;
|
|
705
|
-
/**
|
|
706
|
-
* Opaque decoded calldata descriptor.
|
|
707
|
-
*/
|
|
708
|
-
decodedCalldata: unknown | null;
|
|
709
|
-
/**
|
|
710
|
-
* Optional memo extracted from the transaction.
|
|
711
|
-
*/
|
|
712
|
-
memo: string | null;
|
|
713
|
-
/**
|
|
714
|
-
* DAG round associated with finality, when available.
|
|
715
|
-
*/
|
|
716
|
-
round: bigint | null;
|
|
717
|
-
/**
|
|
718
|
-
* Cluster id associated with finality, when available.
|
|
719
|
-
*/
|
|
720
|
-
clusterId: number | null;
|
|
721
|
-
/**
|
|
722
|
-
* Opaque BLS attestation payload.
|
|
723
|
-
*/
|
|
724
|
-
blsAttestation: unknown | null;
|
|
725
|
-
/**
|
|
726
|
-
* PQ-finality attestation payload.
|
|
727
|
-
*/
|
|
728
|
-
pqAttestation: DecodeTxPqAttestation | null;
|
|
729
|
-
/**
|
|
730
|
-
* Opaque finality proof payload.
|
|
731
|
-
*/
|
|
732
|
-
finalityProof: unknown | null;
|
|
733
|
-
/**
|
|
734
|
-
* Logs emitted by the transaction.
|
|
735
|
-
*/
|
|
736
|
-
logs: Array<DecodeTxLog>;
|
|
737
|
-
/**
|
|
738
|
-
* `success`, `reverted`, `unknown`, or a forward-compatible string.
|
|
739
|
-
*/
|
|
740
|
-
status: string;
|
|
741
|
-
/**
|
|
742
|
-
* Node-supplied execution error code when available.
|
|
743
|
-
*/
|
|
744
|
-
errorCode: string | null;
|
|
745
|
-
};
|
|
746
|
-
|
|
747
|
-
/**
|
|
748
|
-
* `lyth_getDelegationCap` response.
|
|
749
|
-
*/
|
|
750
|
-
type DelegationCapResponse = {
|
|
751
|
-
/**
|
|
752
|
-
* Per-cluster cap in basis points. `u32::MAX` means disabled.
|
|
753
|
-
*/
|
|
754
|
-
capBps: number;
|
|
755
|
-
/**
|
|
756
|
-
* Height of the most recent milestone that changed the cap.
|
|
757
|
-
*/
|
|
758
|
-
lastChangedAtHeight: bigint;
|
|
759
|
-
/**
|
|
760
|
-
* Block height sampled by the node.
|
|
761
|
-
*/
|
|
762
|
-
blockNumber: bigint;
|
|
763
|
-
};
|
|
764
|
-
|
|
765
|
-
/**
|
|
766
|
-
* Per-wallet delegation event row surfaced by `lyth_getDelegationHistory`.
|
|
767
|
-
*/
|
|
768
|
-
type DelegationHistoryRecord = {
|
|
769
|
-
/**
|
|
770
|
-
* Block height the event landed in.
|
|
771
|
-
*/
|
|
772
|
-
blockHeight: bigint;
|
|
773
|
-
/**
|
|
774
|
-
* Tx index within the block.
|
|
775
|
-
*/
|
|
776
|
-
txIndex: number;
|
|
777
|
-
/**
|
|
778
|
-
* Log index within the tx.
|
|
779
|
-
*/
|
|
780
|
-
logIndex: number;
|
|
781
|
-
/**
|
|
782
|
-
* Wallet that performed the delegation move.
|
|
783
|
-
*/
|
|
784
|
-
wallet: string;
|
|
785
|
-
/**
|
|
786
|
-
* Source or only cluster id.
|
|
787
|
-
*/
|
|
788
|
-
cluster: number;
|
|
789
|
-
/**
|
|
790
|
-
* Destination cluster id for redelegations.
|
|
791
|
-
*/
|
|
792
|
-
toCluster: number | null;
|
|
793
|
-
/**
|
|
794
|
-
* Event kind: `delegated`, `undelegated`, or `redelegated`.
|
|
795
|
-
*/
|
|
796
|
-
kind: string;
|
|
797
|
-
/**
|
|
798
|
-
* Weight moved in basis points.
|
|
799
|
-
*/
|
|
800
|
-
weightBps: number;
|
|
801
|
-
/**
|
|
802
|
-
* Wallet total committed weight after the event when known.
|
|
803
|
-
*/
|
|
804
|
-
walletTotalBps: number | null;
|
|
805
|
-
};
|
|
806
|
-
|
|
807
|
-
/**
|
|
808
|
-
* One delegation row in `lyth_getDelegations`.
|
|
809
|
-
*/
|
|
810
|
-
type DelegationRow = {
|
|
811
|
-
/**
|
|
812
|
-
* Cluster id receiving the delegated weight.
|
|
813
|
-
*/
|
|
814
|
-
cluster: number;
|
|
815
|
-
/**
|
|
816
|
-
* Delegated weight in basis points.
|
|
817
|
-
*/
|
|
818
|
-
weightBps: number;
|
|
819
|
-
};
|
|
820
|
-
|
|
821
|
-
/**
|
|
822
|
-
* `lyth_getDelegations` response.
|
|
823
|
-
*/
|
|
824
|
-
type DelegationsResponse = {
|
|
825
|
-
/**
|
|
826
|
-
* Queried wallet address.
|
|
827
|
-
*/
|
|
828
|
-
wallet: string;
|
|
829
|
-
/**
|
|
830
|
-
* Per-cluster delegation rows.
|
|
831
|
-
*/
|
|
832
|
-
rows: Array<DelegationRow>;
|
|
833
|
-
/**
|
|
834
|
-
* Sum of row weights.
|
|
835
|
-
*/
|
|
836
|
-
totalBps: number;
|
|
837
|
-
/**
|
|
838
|
-
* Block selector echoed by the node.
|
|
839
|
-
*/
|
|
840
|
-
block: unknown;
|
|
841
|
-
};
|
|
842
|
-
|
|
843
|
-
/**
|
|
844
|
-
* `lyth_getEncryptionKey` response.
|
|
845
|
-
*/
|
|
846
|
-
type EncryptionKeyResponse = {
|
|
847
|
-
/**
|
|
848
|
-
* KEM algorithm tag.
|
|
849
|
-
*/
|
|
850
|
-
algo: string;
|
|
851
|
-
/**
|
|
852
|
-
* Cluster encryption epoch.
|
|
853
|
-
*/
|
|
854
|
-
epoch: bigint;
|
|
855
|
-
/**
|
|
856
|
-
* ML-KEM-768 encapsulation key.
|
|
857
|
-
*/
|
|
858
|
-
encapsulationKey: string;
|
|
859
|
-
};
|
|
860
|
-
|
|
861
|
-
/**
|
|
862
|
-
* `lyth_getEntityRatchet` response.
|
|
863
|
-
*/
|
|
864
|
-
type EntityRatchetResponse = {
|
|
865
|
-
/**
|
|
866
|
-
* Active foundation-entity cluster count.
|
|
867
|
-
*/
|
|
868
|
-
active: number;
|
|
869
|
-
/**
|
|
870
|
-
* Published ratchet threshold. `u32::MAX` means unset.
|
|
871
|
-
*/
|
|
872
|
-
threshold: number;
|
|
873
|
-
/**
|
|
874
|
-
* Block selector echoed by the node.
|
|
875
|
-
*/
|
|
876
|
-
block: unknown;
|
|
877
|
-
};
|
|
878
|
-
|
|
879
|
-
/**
|
|
880
|
-
* `eth_feeHistory` response.
|
|
881
|
-
*/
|
|
882
|
-
type FeeHistoryResponse = {
|
|
883
|
-
/**
|
|
884
|
-
* Hex height of the first block in the window.
|
|
885
|
-
*/
|
|
886
|
-
oldestBlock: string;
|
|
887
|
-
/**
|
|
888
|
-
* `N+1` base-fee values (one per block, plus the next-block prediction).
|
|
889
|
-
*/
|
|
890
|
-
baseFeePerGas: Array<string>;
|
|
891
|
-
/**
|
|
892
|
-
* `N` `gas_used / gas_limit` ratios.
|
|
893
|
-
*/
|
|
894
|
-
gasUsedRatio: Array<number>;
|
|
895
|
-
/**
|
|
896
|
-
* `N × len(percentiles)` 2D priority-fee approximations. Empty when
|
|
897
|
-
* caller did not request percentiles.
|
|
898
|
-
*/
|
|
899
|
-
reward: Array<Array<string>>;
|
|
900
|
-
};
|
|
901
|
-
|
|
902
|
-
/**
|
|
903
|
-
* Requested block range in `lyth_gapRecords`.
|
|
904
|
-
*/
|
|
905
|
-
type GapRange = {
|
|
906
|
-
/**
|
|
907
|
-
* First block in the requested range.
|
|
908
|
-
*/
|
|
909
|
-
fromBlock: bigint;
|
|
910
|
-
/**
|
|
911
|
-
* Last block in the requested range.
|
|
912
|
-
*/
|
|
913
|
-
toBlock: bigint;
|
|
914
|
-
};
|
|
915
|
-
|
|
916
|
-
/**
|
|
917
|
-
* One retained ingestion/indexing gap.
|
|
918
|
-
*/
|
|
919
|
-
type GapRecord = {
|
|
920
|
-
/**
|
|
921
|
-
* First block in the gap.
|
|
922
|
-
*/
|
|
923
|
-
startBlock: bigint;
|
|
924
|
-
/**
|
|
925
|
-
* Last block in the gap.
|
|
926
|
-
*/
|
|
927
|
-
endBlock: bigint;
|
|
928
|
-
/**
|
|
929
|
-
* Number of blocks in the gap.
|
|
930
|
-
*/
|
|
931
|
-
blockCount: bigint;
|
|
932
|
-
/**
|
|
933
|
-
* Start timestamp in UNIX seconds.
|
|
934
|
-
*/
|
|
935
|
-
startTimestamp: bigint;
|
|
936
|
-
/**
|
|
937
|
-
* End timestamp in UNIX seconds.
|
|
938
|
-
*/
|
|
939
|
-
endTimestamp: bigint;
|
|
940
|
-
/**
|
|
941
|
-
* Duration in seconds.
|
|
942
|
-
*/
|
|
943
|
-
durationSeconds: bigint;
|
|
944
|
-
/**
|
|
945
|
-
* Node-supplied reason label.
|
|
946
|
-
*/
|
|
947
|
-
reason: string;
|
|
948
|
-
};
|
|
949
|
-
|
|
950
|
-
/**
|
|
951
|
-
* `lyth_gapRecords` response.
|
|
952
|
-
*/
|
|
953
|
-
type GapRecordsResponse = {
|
|
954
|
-
/**
|
|
955
|
-
* Response schema version.
|
|
956
|
-
*/
|
|
957
|
-
schemaVersion: number;
|
|
958
|
-
/**
|
|
959
|
-
* Requested range.
|
|
960
|
-
*/
|
|
961
|
-
range: GapRange;
|
|
962
|
-
/**
|
|
963
|
-
* Gap rows in the requested range.
|
|
964
|
-
*/
|
|
965
|
-
gapRecords: Array<GapRecord>;
|
|
966
|
-
};
|
|
967
|
-
|
|
968
|
-
/**
|
|
969
|
-
* `lyth_indexerStatus` envelope. `null` on the wire surfaces as
|
|
970
|
-
* `Option::None` here.
|
|
971
|
-
*/
|
|
972
|
-
type IndexerStatus = {
|
|
973
|
-
/**
|
|
974
|
-
* Highest block fully ingested.
|
|
975
|
-
*/
|
|
976
|
-
currentHeight: bigint;
|
|
977
|
-
/**
|
|
978
|
-
* Highest block observed.
|
|
979
|
-
*/
|
|
980
|
-
latestHeight?: bigint;
|
|
981
|
-
/**
|
|
982
|
-
* Active schema version.
|
|
983
|
-
*/
|
|
984
|
-
schemaVersion: number;
|
|
985
|
-
};
|
|
986
|
-
|
|
987
|
-
/**
|
|
988
|
-
* `lyth_mempoolStatus` aggregate.
|
|
989
|
-
*/
|
|
990
|
-
type MempoolSnapshot = {
|
|
991
|
-
/**
|
|
992
|
-
* Tx count in the Ready bucket.
|
|
993
|
-
*/
|
|
994
|
-
count_ready: bigint;
|
|
995
|
-
/**
|
|
996
|
-
* Tx count in the Pending bucket.
|
|
997
|
-
*/
|
|
998
|
-
count_pending: bigint;
|
|
999
|
-
/**
|
|
1000
|
-
* Mailbox depth gauge.
|
|
1001
|
-
*/
|
|
1002
|
-
mailbox_depth: bigint;
|
|
1003
|
-
/**
|
|
1004
|
-
* Bytes held per tx class.
|
|
1005
|
-
*/
|
|
1006
|
-
bytes_by_class: [bigint, bigint, bigint, bigint, bigint, bigint, bigint];
|
|
1007
|
-
};
|
|
1008
|
-
|
|
1009
|
-
/**
|
|
1010
|
-
* `mesh_decodeTx` response.
|
|
1011
|
-
*/
|
|
1012
|
-
type MeshDecodedTx = {
|
|
1013
|
-
/**
|
|
1014
|
-
* Chain id as a hex quantity.
|
|
1015
|
-
*/
|
|
1016
|
-
chain_id: string;
|
|
1017
|
-
/**
|
|
1018
|
-
* Nonce as a hex quantity.
|
|
1019
|
-
*/
|
|
1020
|
-
nonce: string;
|
|
1021
|
-
/**
|
|
1022
|
-
* Max priority fee per gas as a decimal string.
|
|
1023
|
-
*/
|
|
1024
|
-
max_priority_fee_per_gas: string;
|
|
1025
|
-
/**
|
|
1026
|
-
* Max fee per gas as a decimal string.
|
|
1027
|
-
*/
|
|
1028
|
-
max_fee_per_gas: string;
|
|
1029
|
-
/**
|
|
1030
|
-
* Gas limit as a JSON number.
|
|
1031
|
-
*/
|
|
1032
|
-
gas_limit: bigint;
|
|
1033
|
-
/**
|
|
1034
|
-
* Recipient address, or null for contract creation.
|
|
1035
|
-
*/
|
|
1036
|
-
to: string | null;
|
|
1037
|
-
/**
|
|
1038
|
-
* Value as a decimal string.
|
|
1039
|
-
*/
|
|
1040
|
-
value: string;
|
|
1041
|
-
/**
|
|
1042
|
-
* Input/calldata hex.
|
|
1043
|
-
*/
|
|
1044
|
-
input: string;
|
|
1045
|
-
/**
|
|
1046
|
-
* Present when decoding an unsigned transaction.
|
|
1047
|
-
*/
|
|
1048
|
-
sighash?: string;
|
|
1049
|
-
/**
|
|
1050
|
-
* Present when decoding a signed transaction.
|
|
1051
|
-
*/
|
|
1052
|
-
from?: string;
|
|
1053
|
-
/**
|
|
1054
|
-
* Present when decoding a signed transaction.
|
|
1055
|
-
*/
|
|
1056
|
-
tx_hash?: string;
|
|
1057
|
-
};
|
|
1058
|
-
|
|
1059
|
-
/**
|
|
1060
|
-
* `mesh_combineTx` response.
|
|
1061
|
-
*/
|
|
1062
|
-
type MeshSignedTxResponse = {
|
|
1063
|
-
/**
|
|
1064
|
-
* `0x`-hex bincode signed transaction envelope.
|
|
1065
|
-
*/
|
|
1066
|
-
signed_tx: string;
|
|
1067
|
-
};
|
|
1068
|
-
|
|
1069
|
-
/**
|
|
1070
|
-
* Intent accepted by `mesh_buildUnsignedTx`.
|
|
1071
|
-
*/
|
|
1072
|
-
type MeshTxIntent = {
|
|
1073
|
-
/**
|
|
1074
|
-
* Sender nonce, hex or decimal string.
|
|
1075
|
-
*/
|
|
1076
|
-
nonce: string;
|
|
1077
|
-
/**
|
|
1078
|
-
* EIP-1559 max fee per gas, hex or decimal string.
|
|
1079
|
-
*/
|
|
1080
|
-
max_fee_per_gas: string;
|
|
1081
|
-
/**
|
|
1082
|
-
* EIP-1559 max priority fee per gas, hex or decimal string.
|
|
1083
|
-
*/
|
|
1084
|
-
max_priority_fee_per_gas: string;
|
|
1085
|
-
/**
|
|
1086
|
-
* Gas limit, hex or decimal string.
|
|
1087
|
-
*/
|
|
1088
|
-
gas_limit: string;
|
|
1089
|
-
/**
|
|
1090
|
-
* Recipient address. `None` means contract creation.
|
|
1091
|
-
*/
|
|
1092
|
-
to?: string;
|
|
1093
|
-
/**
|
|
1094
|
-
* Value, hex or decimal string.
|
|
1095
|
-
*/
|
|
1096
|
-
value?: string;
|
|
1097
|
-
/**
|
|
1098
|
-
* Input/calldata hex.
|
|
1099
|
-
*/
|
|
1100
|
-
input?: string;
|
|
1101
|
-
/**
|
|
1102
|
-
* Optional chain id override, hex or decimal string.
|
|
1103
|
-
*/
|
|
1104
|
-
chain_id?: string;
|
|
1105
|
-
};
|
|
1106
|
-
|
|
1107
|
-
/**
|
|
1108
|
-
* `mesh_buildUnsignedTx` response.
|
|
1109
|
-
*/
|
|
1110
|
-
type MeshUnsignedTxResponse = {
|
|
1111
|
-
/**
|
|
1112
|
-
* `0x`-hex bincode unsigned transaction envelope.
|
|
1113
|
-
*/
|
|
1114
|
-
unsigned_tx: string;
|
|
1115
|
-
/**
|
|
1116
|
-
* `0x`-hex signing hash for the wallet.
|
|
1117
|
-
*/
|
|
1118
|
-
sighash: string;
|
|
1119
|
-
};
|
|
1120
|
-
|
|
1121
|
-
/**
|
|
1122
|
-
* `debug_p2pPeers` entry.
|
|
1123
|
-
*/
|
|
1124
|
-
type PeerSummary = {
|
|
1125
|
-
/**
|
|
1126
|
-
* libp2p peer id (base58).
|
|
1127
|
-
*/
|
|
1128
|
-
peerId: string;
|
|
1129
|
-
/**
|
|
1130
|
-
* Declared role.
|
|
1131
|
-
*/
|
|
1132
|
-
role: string;
|
|
1133
|
-
/**
|
|
1134
|
-
* Listen addresses.
|
|
1135
|
-
*/
|
|
1136
|
-
listenAddrs: Array<string>;
|
|
1137
|
-
/**
|
|
1138
|
-
* `agent_version` from libp2p identify.
|
|
1139
|
-
*/
|
|
1140
|
-
agentVersion: string;
|
|
1141
|
-
/**
|
|
1142
|
-
* Reputation score.
|
|
1143
|
-
*/
|
|
1144
|
-
score: number;
|
|
1145
|
-
/**
|
|
1146
|
-
* Whether the peer is in any gossip mesh.
|
|
1147
|
-
*/
|
|
1148
|
-
inMesh: boolean;
|
|
1149
|
-
};
|
|
1150
|
-
|
|
1151
|
-
/**
|
|
1152
|
-
* `lyth_mempoolPending` per-tx entry.
|
|
1153
|
-
*/
|
|
1154
|
-
type PendingTxSummary = {
|
|
1155
|
-
/**
|
|
1156
|
-
* Tx hash.
|
|
1157
|
-
*/
|
|
1158
|
-
txHash: string;
|
|
1159
|
-
/**
|
|
1160
|
-
* Sender nonce of this transaction.
|
|
1161
|
-
*/
|
|
1162
|
-
nonce: bigint;
|
|
1163
|
-
/**
|
|
1164
|
-
* Class index (0..=6).
|
|
1165
|
-
*/
|
|
1166
|
-
class: number;
|
|
1167
|
-
/**
|
|
1168
|
-
* Wire size in bytes.
|
|
1169
|
-
*/
|
|
1170
|
-
wireBytesLen: number;
|
|
1171
|
-
/**
|
|
1172
|
-
* `true` if parked in the ready bucket.
|
|
1173
|
-
*/
|
|
1174
|
-
ready: boolean;
|
|
1175
|
-
};
|
|
1176
|
-
|
|
1177
|
-
/**
|
|
1178
|
-
* `lyth_listActivePrecompiles` entry — OI-0170 / ADR-0015 §5.
|
|
1179
|
-
*/
|
|
1180
|
-
type PrecompileDescriptor = {
|
|
1181
|
-
/**
|
|
1182
|
-
* 20-byte precompile address, `0x`-hex.
|
|
1183
|
-
*/
|
|
1184
|
-
address: string;
|
|
1185
|
-
/**
|
|
1186
|
-
* Stable identifier (e.g. `"agent"`, `"oracle"`, `"delegation"`).
|
|
1187
|
-
*/
|
|
1188
|
-
name: string;
|
|
1189
|
-
/**
|
|
1190
|
-
* Whether milestone gates can toggle this precompile.
|
|
1191
|
-
*/
|
|
1192
|
-
gateable: boolean;
|
|
1193
|
-
/**
|
|
1194
|
-
* Whether the precompile is currently dispatchable.
|
|
1195
|
-
*/
|
|
1196
|
-
enabled: boolean;
|
|
1197
|
-
/**
|
|
1198
|
-
* Stable capability id from the milestone registry.
|
|
1199
|
-
*/
|
|
1200
|
-
capabilityId: string;
|
|
1201
|
-
/**
|
|
1202
|
-
* Height of the milestone that activated this capability, when any.
|
|
1203
|
-
*/
|
|
1204
|
-
activationHeight: bigint | null;
|
|
1205
|
-
};
|
|
1206
|
-
|
|
1207
|
-
/**
|
|
1208
|
-
* `lyth_listProviders` / `lyth_getRegistration` record.
|
|
1209
|
-
*/
|
|
1210
|
-
type RegistryRecord = {
|
|
1211
|
-
/**
|
|
1212
|
-
* libp2p peer id, `0x`-hex 32-byte.
|
|
1213
|
-
*/
|
|
1214
|
-
peerId: string;
|
|
1215
|
-
/**
|
|
1216
|
-
* Capability bitmask.
|
|
1217
|
-
*/
|
|
1218
|
-
capabilities: number;
|
|
1219
|
-
/**
|
|
1220
|
-
* Primary external endpoint URL.
|
|
1221
|
-
*/
|
|
1222
|
-
endpoint: string;
|
|
1223
|
-
/**
|
|
1224
|
-
* Current bond, hex quantity.
|
|
1225
|
-
*/
|
|
1226
|
-
bond: string;
|
|
1227
|
-
/**
|
|
1228
|
-
* Uptime in basis points (0..=10_000).
|
|
1229
|
-
*/
|
|
1230
|
-
uptimeBps: number;
|
|
1231
|
-
};
|
|
1232
|
-
|
|
1233
|
-
/**
|
|
1234
|
-
* One holder row in `lyth_richList`.
|
|
1235
|
-
*/
|
|
1236
|
-
type RichListHolder = {
|
|
1237
|
-
/**
|
|
1238
|
-
* One-based holder rank.
|
|
1239
|
-
*/
|
|
1240
|
-
rank: number;
|
|
1241
|
-
/**
|
|
1242
|
-
* Holder address.
|
|
1243
|
-
*/
|
|
1244
|
-
address: string;
|
|
1245
|
-
/**
|
|
1246
|
-
* Balance as a decimal string.
|
|
1247
|
-
*/
|
|
1248
|
-
balance: string;
|
|
1249
|
-
/**
|
|
1250
|
-
* Block height the balance was last observed at.
|
|
1251
|
-
*/
|
|
1252
|
-
updatedAtBlock: bigint;
|
|
1253
|
-
};
|
|
1254
|
-
|
|
1255
|
-
/**
|
|
1256
|
-
* `lyth_richList` response.
|
|
1257
|
-
*/
|
|
1258
|
-
type RichListResponse = {
|
|
1259
|
-
/**
|
|
1260
|
-
* Response schema version.
|
|
1261
|
-
*/
|
|
1262
|
-
schemaVersion: number;
|
|
1263
|
-
/**
|
|
1264
|
-
* Queried token id.
|
|
1265
|
-
*/
|
|
1266
|
-
tokenId: string;
|
|
1267
|
-
/**
|
|
1268
|
-
* Result limit applied by the node.
|
|
1269
|
-
*/
|
|
1270
|
-
limit: number;
|
|
1271
|
-
/**
|
|
1272
|
-
* Holder rows.
|
|
1273
|
-
*/
|
|
1274
|
-
holders: Array<RichListHolder>;
|
|
1275
|
-
};
|
|
1276
|
-
|
|
1277
|
-
/**
|
|
1278
|
-
* `lyth_currentRound` round shape.
|
|
1279
|
-
*/
|
|
1280
|
-
type RoundInfo = {
|
|
1281
|
-
/**
|
|
1282
|
-
* Latest committed height.
|
|
1283
|
-
*/
|
|
1284
|
-
height: bigint;
|
|
1285
|
-
};
|
|
1286
|
-
|
|
1287
|
-
/**
|
|
1288
|
-
* `lyth_getStorageProof` batch response.
|
|
1289
|
-
*/
|
|
1290
|
-
type StorageProofBatch = {
|
|
1291
|
-
/**
|
|
1292
|
-
* State-root the proofs verify against.
|
|
1293
|
-
*/
|
|
1294
|
-
stateRoot: string;
|
|
1295
|
-
/**
|
|
1296
|
-
* Block height the proofs were generated against.
|
|
1297
|
-
*/
|
|
1298
|
-
blockNumber: bigint;
|
|
1299
|
-
/**
|
|
1300
|
-
* One opaque proof envelope per requested slot.
|
|
1301
|
-
*/
|
|
1302
|
-
proofs: unknown[];
|
|
1303
|
-
};
|
|
1304
|
-
|
|
1305
|
-
/**
|
|
1306
|
-
* `eth_syncing` response when the node is mid-sync. Returns `false`
|
|
1307
|
-
* when the node is caught up — the SDK surfaces that as
|
|
1308
|
-
* `Option::None`.
|
|
1309
|
-
*/
|
|
1310
|
-
type SyncStatus = {
|
|
1311
|
-
/**
|
|
1312
|
-
* First block of the current sync batch.
|
|
1313
|
-
*/
|
|
1314
|
-
startingBlock: string;
|
|
1315
|
-
/**
|
|
1316
|
-
* Last block applied locally.
|
|
1317
|
-
*/
|
|
1318
|
-
currentBlock: string;
|
|
1319
|
-
/**
|
|
1320
|
-
* Highest block advertised by peers.
|
|
1321
|
-
*/
|
|
1322
|
-
highestBlock: string;
|
|
1323
|
-
};
|
|
1324
|
-
|
|
1325
|
-
/**
|
|
1326
|
-
* Per-asset balance row surfaced by `lyth_getTokenBalances`.
|
|
1327
|
-
*/
|
|
1328
|
-
type TokenBalanceRecord = {
|
|
1329
|
-
/**
|
|
1330
|
-
* 32-byte token id, `0x`-hex.
|
|
1331
|
-
*/
|
|
1332
|
-
tokenId: string;
|
|
1333
|
-
/**
|
|
1334
|
-
* Balance as a decimal string.
|
|
1335
|
-
*/
|
|
1336
|
-
balance: string;
|
|
1337
|
-
/**
|
|
1338
|
-
* Block height the balance was last observed at.
|
|
1339
|
-
*/
|
|
1340
|
-
updatedAtBlock: bigint;
|
|
1341
|
-
};
|
|
1342
|
-
|
|
1343
|
-
/**
|
|
1344
|
-
* `lyth_getTpmAttestation` response.
|
|
1345
|
-
*/
|
|
1346
|
-
type TpmAttestationResponse = {
|
|
1347
|
-
/**
|
|
1348
|
-
* 32-byte peer id.
|
|
1349
|
-
*/
|
|
1350
|
-
peerId: string;
|
|
1351
|
-
/**
|
|
1352
|
-
* 32-byte digest over the canonical TPM quote bytes.
|
|
1353
|
-
*/
|
|
1354
|
-
quoteDigest: string;
|
|
1355
|
-
/**
|
|
1356
|
-
* 32-byte EK identifier.
|
|
1357
|
-
*/
|
|
1358
|
-
ekId: string;
|
|
1359
|
-
/**
|
|
1360
|
-
* Block selector echoed by the node.
|
|
1361
|
-
*/
|
|
1362
|
-
block: unknown;
|
|
1363
|
-
};
|
|
1364
|
-
|
|
1365
|
-
/**
|
|
1366
|
-
* Receipt for a confirmed transaction.
|
|
1367
|
-
*/
|
|
1368
|
-
type TransactionReceipt = {
|
|
1369
|
-
/**
|
|
1370
|
-
* Transaction hash.
|
|
1371
|
-
*/
|
|
1372
|
-
tx_hash: string;
|
|
1373
|
-
/**
|
|
1374
|
-
* Block hash that contains the transaction.
|
|
1375
|
-
*/
|
|
1376
|
-
block_hash: string;
|
|
1377
|
-
/**
|
|
1378
|
-
* Block height that contains the transaction.
|
|
1379
|
-
*/
|
|
1380
|
-
block_number: bigint;
|
|
1381
|
-
/**
|
|
1382
|
-
* Transaction index within the block.
|
|
1383
|
-
*/
|
|
1384
|
-
tx_index: number;
|
|
1385
|
-
/**
|
|
1386
|
-
* `1` on success, `0` on revert.
|
|
1387
|
-
*/
|
|
1388
|
-
status: number;
|
|
1389
|
-
/**
|
|
1390
|
-
* Gas consumed by this transaction.
|
|
1391
|
-
*/
|
|
1392
|
-
gas_used: bigint;
|
|
1393
|
-
};
|
|
1394
|
-
|
|
1395
|
-
/**
|
|
1396
|
-
* Ethereum-shaped transaction view returned by `eth_getTransactionByHash`.
|
|
1397
|
-
*/
|
|
1398
|
-
type TransactionView = {
|
|
1399
|
-
/**
|
|
1400
|
-
* Transaction hash.
|
|
1401
|
-
*/
|
|
1402
|
-
hash: string;
|
|
1403
|
-
/**
|
|
1404
|
-
* Block hash that contains the transaction.
|
|
1405
|
-
*/
|
|
1406
|
-
blockHash: string;
|
|
1407
|
-
/**
|
|
1408
|
-
* Block height as a hex quantity.
|
|
1409
|
-
*/
|
|
1410
|
-
blockNumber: string;
|
|
1411
|
-
/**
|
|
1412
|
-
* Transaction index as a hex quantity.
|
|
1413
|
-
*/
|
|
1414
|
-
transactionIndex: string;
|
|
1415
|
-
/**
|
|
1416
|
-
* Sender address.
|
|
1417
|
-
*/
|
|
1418
|
-
from: string;
|
|
1419
|
-
/**
|
|
1420
|
-
* Recipient address, or `null` for contract creation.
|
|
1421
|
-
*/
|
|
1422
|
-
to: string | null;
|
|
1423
|
-
/**
|
|
1424
|
-
* Sender nonce as a hex quantity.
|
|
1425
|
-
*/
|
|
1426
|
-
nonce: string;
|
|
1427
|
-
/**
|
|
1428
|
-
* Transferred value as a hex quantity.
|
|
1429
|
-
*/
|
|
1430
|
-
value: string;
|
|
1431
|
-
/**
|
|
1432
|
-
* Gas limit as a hex quantity.
|
|
1433
|
-
*/
|
|
1434
|
-
gas: string;
|
|
1435
|
-
/**
|
|
1436
|
-
* EIP-1559 max fee per gas as a hex quantity.
|
|
1437
|
-
*/
|
|
1438
|
-
maxFeePerGas: string;
|
|
1439
|
-
/**
|
|
1440
|
-
* EIP-1559 max priority fee per gas as a hex quantity.
|
|
1441
|
-
*/
|
|
1442
|
-
maxPriorityFeePerGas: string;
|
|
1443
|
-
/**
|
|
1444
|
-
* Calldata or deployment bytecode.
|
|
1445
|
-
*/
|
|
1446
|
-
input: string;
|
|
1447
|
-
/**
|
|
1448
|
-
* EIP-2718 transaction type. `mono-core` currently renders `"0x2"`.
|
|
1449
|
-
*/
|
|
1450
|
-
type: string;
|
|
1451
|
-
/**
|
|
1452
|
-
* Chain id as a hex quantity.
|
|
1453
|
-
*/
|
|
1454
|
-
chainId: string;
|
|
1455
|
-
};
|
|
1456
|
-
|
|
1457
|
-
/**
|
|
1458
|
-
* Wire-shape types served by a `mono-core` node.
|
|
1459
|
-
*
|
|
1460
|
-
* Re-exports the `ts-rs`-generated definitions in `./bindings/`. Those
|
|
1461
|
-
* files are the authoritative source — they are written from Rust by
|
|
1462
|
-
* `cargo test --features ts-bindings` and copied into this package via
|
|
1463
|
-
* `pnpm run build:bindings` / `bash scripts/sync-bindings.sh`.
|
|
1464
|
-
*
|
|
1465
|
-
* Quantities (`u64` etc.) surface as `bigint` to preserve full
|
|
1466
|
-
* precision against the chain's 256-bit world. Hashes / addresses /
|
|
1467
|
-
* `0x`-hex byte vectors surface as `string`.
|
|
1468
|
-
*/
|
|
1469
|
-
|
|
1470
|
-
/** `0x`-prefixed hex byte vector. */
|
|
1471
|
-
type Hex = string;
|
|
1472
|
-
/** `0x`-prefixed hex 20-byte address. */
|
|
1473
|
-
type Address = string;
|
|
1474
|
-
/** `0x`-prefixed hex 32-byte hash. */
|
|
1475
|
-
type Hash = string;
|
|
1476
|
-
/** `0x`-prefixed hex unsigned quantity. */
|
|
1477
|
-
type Quantity = string;
|
|
1478
|
-
|
|
1479
|
-
/**
|
|
1480
|
-
* Block selector for `eth_getBlock*`, `eth_call`, etc. — accepts a tag,
|
|
1481
|
-
* a numeric height (encoded by the client as `0x`-hex), a `bigint`, or
|
|
1482
|
-
* a 32-byte hash where the spec allows it.
|
|
1483
|
-
*/
|
|
1484
|
-
type BlockSelector = BlockTag | number | bigint | Hash;
|
|
1485
|
-
/** Encode a `BlockSelector` for a JSON-RPC params array. */
|
|
1486
|
-
declare function encodeBlockSelector(b: BlockSelector): string;
|
|
1487
|
-
|
|
1488
|
-
/**
|
|
1489
|
-
* Chain-registry snapshot and helpers.
|
|
1490
|
-
*
|
|
1491
|
-
* Source of truth:
|
|
1492
|
-
* https://github.com/monolythium/chain-registry
|
|
1493
|
-
*
|
|
1494
|
-
* The SDK vendors a release-time snapshot so callers can bootstrap without
|
|
1495
|
-
* network access to GitHub. Callers that want the newest registry state can
|
|
1496
|
-
* opt into `fetchChainRegistryLatest()`.
|
|
1497
|
-
*/
|
|
1498
|
-
type NetworkSlug = "testnet-69420";
|
|
1499
|
-
interface RpcEndpoint {
|
|
1500
|
-
url: string;
|
|
1501
|
-
provider: string;
|
|
1502
|
-
region?: string;
|
|
1503
|
-
tier: "official" | "community";
|
|
1504
|
-
archive?: boolean;
|
|
1505
|
-
ws_url?: string;
|
|
1506
|
-
notes?: string;
|
|
1507
|
-
}
|
|
1508
|
-
interface P2pSeed {
|
|
1509
|
-
multiaddr: string;
|
|
1510
|
-
region?: string;
|
|
1511
|
-
}
|
|
1512
|
-
interface ExplorerEndpoint {
|
|
1513
|
-
url: string;
|
|
1514
|
-
name: string;
|
|
1515
|
-
kind?: "monoscan" | "etherscan-fork" | "custom";
|
|
1516
|
-
}
|
|
1517
|
-
interface ChainInfo {
|
|
1518
|
-
chain_id: number;
|
|
1519
|
-
network: NetworkSlug | string;
|
|
1520
|
-
display_name?: string;
|
|
1521
|
-
description?: string;
|
|
1522
|
-
genesis_hash: string;
|
|
1523
|
-
binary_sha: string;
|
|
1524
|
-
rpc: RpcEndpoint[];
|
|
1525
|
-
p2p: P2pSeed[];
|
|
1526
|
-
explorer?: ExplorerEndpoint[];
|
|
1527
|
-
}
|
|
1528
|
-
type ChainRegistry = Record<NetworkSlug | string, ChainInfo>;
|
|
1529
|
-
declare const TESTNET_69420: ChainInfo;
|
|
1530
|
-
declare const CHAIN_REGISTRY: ChainRegistry;
|
|
1531
|
-
declare const CHAIN_REGISTRY_RAW_BASE: "https://raw.githubusercontent.com/monolythium/chain-registry/master/chains";
|
|
1532
|
-
declare function getChainInfo(network: NetworkSlug | string): ChainInfo;
|
|
1533
|
-
declare function getRpcEndpoints(network: NetworkSlug | string): readonly RpcEndpoint[];
|
|
1534
|
-
declare function getP2pSeeds(network: NetworkSlug | string): readonly P2pSeed[];
|
|
1535
|
-
interface FetchChainRegistryOptions {
|
|
1536
|
-
fetch?: typeof fetch;
|
|
1537
|
-
rawBaseUrl?: string;
|
|
1538
|
-
}
|
|
1539
|
-
declare function fetchChainInfoLatest(network: NetworkSlug | string, options?: FetchChainRegistryOptions): Promise<ChainInfo>;
|
|
1540
|
-
declare function fetchChainRegistryLatest(networks?: readonly (NetworkSlug | string)[], options?: FetchChainRegistryOptions): Promise<ChainRegistry>;
|
|
1541
|
-
declare function parseChainRegistryToml(input: string): ChainInfo;
|
|
1542
|
-
|
|
1543
|
-
/**
|
|
1544
|
-
* Typed JSON-RPC client for a `mono-core` node.
|
|
1545
|
-
*
|
|
1546
|
-
* Mirrors the Rust SDK's `RpcClient` — every public method maps 1:1 to
|
|
1547
|
-
* a method on the Rust client, returns the same wire-shape value, and
|
|
1548
|
-
* sends the same `lyth_*` / `eth_*` / `debug_*` JSON-RPC method strings
|
|
1549
|
-
* (Law §13.2).
|
|
1550
|
-
*/
|
|
1551
|
-
|
|
1552
|
-
/** Optional per-client configuration. */
|
|
1553
|
-
interface RpcClientOptions {
|
|
1554
|
-
/** Override `fetch`. Useful for tests or non-Node environments. */
|
|
1555
|
-
fetch?: typeof fetch;
|
|
1556
|
-
/** Extra headers to attach to every request. */
|
|
1557
|
-
headers?: Record<string, string>;
|
|
1558
|
-
}
|
|
1559
|
-
interface NetworkClientOptions extends RpcClientOptions {
|
|
1560
|
-
/** Registry snapshot to use instead of the SDK-bundled snapshot. */
|
|
1561
|
-
registry?: ChainRegistry;
|
|
1562
|
-
/** Probe all known endpoints and choose the first one that answers. */
|
|
1563
|
-
probe?: boolean;
|
|
1564
|
-
}
|
|
1565
|
-
interface TxFeedReceipt {
|
|
1566
|
-
status: number;
|
|
1567
|
-
gasUsed: number;
|
|
1568
|
-
logsCount: number;
|
|
1569
|
-
}
|
|
1570
|
-
interface TxFeedTransaction {
|
|
1571
|
-
txHash: string;
|
|
1572
|
-
blockHash: string;
|
|
1573
|
-
blockNumber: number;
|
|
1574
|
-
blockTimestamp: number | null;
|
|
1575
|
-
txIndex: number;
|
|
1576
|
-
from: string;
|
|
1577
|
-
to: string | null;
|
|
1578
|
-
nonce: number;
|
|
1579
|
-
value: string;
|
|
1580
|
-
gasLimit: number;
|
|
1581
|
-
maxFeePerGas: string;
|
|
1582
|
-
maxPriorityFeePerGas: string;
|
|
1583
|
-
input: string;
|
|
1584
|
-
receipt: TxFeedReceipt | null;
|
|
1585
|
-
}
|
|
1586
|
-
interface TxFeedResponse {
|
|
1587
|
-
schemaVersion: number;
|
|
1588
|
-
latestHeight: number;
|
|
1589
|
-
limit: number;
|
|
1590
|
-
nextCursor: string | null;
|
|
1591
|
-
transactions: TxFeedTransaction[];
|
|
1592
|
-
}
|
|
1593
|
-
interface AddressProfileResponse {
|
|
1594
|
-
schemaVersion: number;
|
|
1595
|
-
address: string;
|
|
1596
|
-
account: {
|
|
1597
|
-
nativeBalance: string;
|
|
1598
|
-
nonce: number;
|
|
1599
|
-
codeHash: string;
|
|
1600
|
-
isContract: boolean;
|
|
1601
|
-
};
|
|
1602
|
-
label: {
|
|
1603
|
-
category: string;
|
|
1604
|
-
displayName: string | null;
|
|
1605
|
-
updatedAtBlock: number;
|
|
1606
|
-
} | null;
|
|
1607
|
-
activity: {
|
|
1608
|
-
kind: string;
|
|
1609
|
-
retention: unknown | null;
|
|
1610
|
-
latest: unknown | null;
|
|
1611
|
-
};
|
|
1612
|
-
tokenBalances: Array<{
|
|
1613
|
-
tokenId: string;
|
|
1614
|
-
balance: string;
|
|
1615
|
-
updatedAtBlock: number;
|
|
1616
|
-
}>;
|
|
1617
|
-
}
|
|
1618
|
-
interface AddressFlowResponse {
|
|
1619
|
-
schemaVersion: number;
|
|
1620
|
-
address: string;
|
|
1621
|
-
sampleSize: number;
|
|
1622
|
-
limit: number;
|
|
1623
|
-
totals: {
|
|
1624
|
-
inbound: string;
|
|
1625
|
-
outbound: string;
|
|
1626
|
-
swapVolume: string;
|
|
1627
|
-
stake: string;
|
|
1628
|
-
unstake: string;
|
|
1629
|
-
};
|
|
1630
|
-
topCounterparties: Array<{
|
|
1631
|
-
address: string;
|
|
1632
|
-
eventCount: number;
|
|
1633
|
-
inbound: string;
|
|
1634
|
-
outbound: string;
|
|
1635
|
-
}>;
|
|
1636
|
-
}
|
|
1637
|
-
interface SearchHit {
|
|
1638
|
-
type: string;
|
|
1639
|
-
id: string;
|
|
1640
|
-
route: string;
|
|
1641
|
-
label: string;
|
|
1642
|
-
score: number;
|
|
1643
|
-
meta?: unknown;
|
|
1644
|
-
}
|
|
1645
|
-
interface SearchResponse {
|
|
1646
|
-
schemaVersion: number;
|
|
1647
|
-
query: string;
|
|
1648
|
-
hits: SearchHit[];
|
|
1649
|
-
nextCursor: string | null;
|
|
1650
|
-
}
|
|
1651
|
-
interface ChainStatsResponse {
|
|
1652
|
-
schemaVersion: number;
|
|
1653
|
-
chainId: number;
|
|
1654
|
-
genesisHash: string | null;
|
|
1655
|
-
latestHeight: number;
|
|
1656
|
-
latestBlockHash: string | null;
|
|
1657
|
-
latestTimestamp: number | null;
|
|
1658
|
-
peerCount: number;
|
|
1659
|
-
mempool: {
|
|
1660
|
-
ready: number;
|
|
1661
|
-
pending: number;
|
|
1662
|
-
mailboxDepth: number;
|
|
1663
|
-
};
|
|
1664
|
-
indexer: unknown | null;
|
|
1665
|
-
clusters: {
|
|
1666
|
-
total: number;
|
|
1667
|
-
pageSize: number;
|
|
1668
|
-
};
|
|
1669
|
-
}
|
|
1670
|
-
interface ClobMarketSummary {
|
|
1671
|
-
marketId: string;
|
|
1672
|
-
tradeCount: number;
|
|
1673
|
-
totalVolumeBase: string;
|
|
1674
|
-
lastPrice: string;
|
|
1675
|
-
lastBlockHeight: number;
|
|
1676
|
-
}
|
|
1677
|
-
interface ClobMarketsResponse {
|
|
1678
|
-
schemaVersion: number;
|
|
1679
|
-
limit: number;
|
|
1680
|
-
markets: ClobMarketSummary[];
|
|
1681
|
-
source: string;
|
|
1682
|
-
}
|
|
1683
|
-
interface ClobTrade {
|
|
1684
|
-
blockHeight: number;
|
|
1685
|
-
txIndex: number;
|
|
1686
|
-
logIndex: number;
|
|
1687
|
-
marketId: string;
|
|
1688
|
-
takerOrder: string;
|
|
1689
|
-
makerOrder: string;
|
|
1690
|
-
price: string;
|
|
1691
|
-
amount: string;
|
|
1692
|
-
taker: string;
|
|
1693
|
-
maker: string;
|
|
1694
|
-
}
|
|
1695
|
-
interface ClobTradesResponse {
|
|
1696
|
-
schemaVersion: number;
|
|
1697
|
-
marketId: string;
|
|
1698
|
-
limit: number;
|
|
1699
|
-
nextCursor: string | null;
|
|
1700
|
-
trades: ClobTrade[];
|
|
1701
|
-
}
|
|
1702
|
-
interface ClobOhlcResponse {
|
|
1703
|
-
schemaVersion: number;
|
|
1704
|
-
marketId: string;
|
|
1705
|
-
fromBlock: number;
|
|
1706
|
-
toBlock: number;
|
|
1707
|
-
bucketBlocks: number;
|
|
1708
|
-
candles: Array<{
|
|
1709
|
-
startBlock: number;
|
|
1710
|
-
endBlock: number;
|
|
1711
|
-
open: string;
|
|
1712
|
-
high: string;
|
|
1713
|
-
low: string;
|
|
1714
|
-
close: string;
|
|
1715
|
-
volumeBase: string;
|
|
1716
|
-
tradeCount: number;
|
|
1717
|
-
}>;
|
|
1718
|
-
}
|
|
1719
|
-
interface ClobOrderBookResponse {
|
|
1720
|
-
schemaVersion: number;
|
|
1721
|
-
marketId: string;
|
|
1722
|
-
levels?: number;
|
|
1723
|
-
bids: Array<{
|
|
1724
|
-
price: string;
|
|
1725
|
-
size: string;
|
|
1726
|
-
}>;
|
|
1727
|
-
asks: Array<{
|
|
1728
|
-
price: string;
|
|
1729
|
-
size: string;
|
|
1730
|
-
}>;
|
|
1731
|
-
}
|
|
1732
|
-
/** Public-safe aggregate returned by `lyth_peerSummary`. */
|
|
1733
|
-
interface PeerSummaryAggregate {
|
|
1734
|
-
peerCount: number;
|
|
1735
|
-
inboundCount: number | null;
|
|
1736
|
-
outboundCount: number | null;
|
|
1737
|
-
latencyBands: {
|
|
1738
|
-
lt_50ms: number;
|
|
1739
|
-
lt_200ms: number;
|
|
1740
|
-
lt_1s: number;
|
|
1741
|
-
ge_1s: number;
|
|
1742
|
-
} | null;
|
|
1743
|
-
versionDistribution: Record<string, number>;
|
|
1744
|
-
healthSummary: {
|
|
1745
|
-
synced: number;
|
|
1746
|
-
lagging: number;
|
|
1747
|
-
stale: number;
|
|
1748
|
-
};
|
|
1749
|
-
asOfBlock: number;
|
|
1750
|
-
}
|
|
1751
|
-
/** Live `lyth_listActivePrecompiles` response envelope. */
|
|
1752
|
-
interface PrecompileCatalogueResponse {
|
|
1753
|
-
/** Block height sampled by the node. */
|
|
1754
|
-
blockNumber: bigint;
|
|
1755
|
-
/** Precompile descriptors active or known at the sampled block. */
|
|
1756
|
-
precompiles: PrecompileDescriptor[];
|
|
1757
|
-
}
|
|
1758
|
-
interface OperatorInfoResponse {
|
|
1759
|
-
operatorId: string;
|
|
1760
|
-
moniker: string | null;
|
|
1761
|
-
alias: string | null;
|
|
1762
|
-
chainAddress: string;
|
|
1763
|
-
bonded: boolean;
|
|
1764
|
-
commissionBps: number | null;
|
|
1765
|
-
delegationCount: number | null;
|
|
1766
|
-
bondedAmount: string;
|
|
1767
|
-
activeClusterIds: number[];
|
|
1768
|
-
operatorKeyFingerprint: string | null;
|
|
1769
|
-
blsKeyFingerprint: string | null;
|
|
1770
|
-
lifecycleState: string;
|
|
1771
|
-
capability: Record<string, unknown>;
|
|
1772
|
-
}
|
|
1773
|
-
interface ClusterMemberResponse {
|
|
1774
|
-
operatorId: string;
|
|
1775
|
-
blsPubkey: string;
|
|
1776
|
-
state: string;
|
|
1777
|
-
}
|
|
1778
|
-
interface ClusterStatusResponse {
|
|
1779
|
-
clusterId: number;
|
|
1780
|
-
threshold: number;
|
|
1781
|
-
size: number;
|
|
1782
|
-
live: number;
|
|
1783
|
-
lagging: number;
|
|
1784
|
-
offline: number;
|
|
1785
|
-
maintenance: number;
|
|
1786
|
-
members: ClusterMemberResponse[];
|
|
1787
|
-
epoch: bigint | null;
|
|
1788
|
-
round: bigint | null;
|
|
1789
|
-
quorum: string;
|
|
1790
|
-
reputationScore: number | null;
|
|
1791
|
-
livenessScore: number | null;
|
|
1792
|
-
lastUpdateHeight: bigint;
|
|
1793
|
-
}
|
|
1794
|
-
interface ClusterDirectoryEntryResponse {
|
|
1795
|
-
clusterId: number;
|
|
1796
|
-
size: number;
|
|
1797
|
-
threshold: number;
|
|
1798
|
-
aggregateHealth: string;
|
|
1799
|
-
regionDiversity: string[] | null;
|
|
1800
|
-
active: boolean;
|
|
1801
|
-
}
|
|
1802
|
-
interface ClusterDirectoryPageResponse {
|
|
1803
|
-
page: number;
|
|
1804
|
-
limit: number;
|
|
1805
|
-
totalClusters: number;
|
|
1806
|
-
clusters: ClusterDirectoryEntryResponse[];
|
|
1807
|
-
}
|
|
1808
|
-
type OperatorSurfaceStatus = "available" | "disabled" | "not_implemented" | "not_retained" | "ws_only" | string;
|
|
1809
|
-
interface OperatorSurfaceCapability {
|
|
1810
|
-
status: OperatorSurfaceStatus;
|
|
1811
|
-
tracking?: string;
|
|
1812
|
-
}
|
|
1813
|
-
interface OperatorCapabilitiesResponse {
|
|
1814
|
-
schemaVersion: number;
|
|
1815
|
-
surfaces: Record<string, OperatorSurfaceCapability>;
|
|
1816
|
-
}
|
|
1817
|
-
interface OperatorAuthorityResponse {
|
|
1818
|
-
schemaVersion: number;
|
|
1819
|
-
operatorId: string;
|
|
1820
|
-
authorityIndex: number;
|
|
1821
|
-
blsPubkey: string;
|
|
1822
|
-
active: boolean;
|
|
1823
|
-
}
|
|
1824
|
-
type SigningEntryStatus = "signed" | "missed" | "no_cert" | string;
|
|
1825
|
-
interface OperatorSigningEntry {
|
|
1826
|
-
round: bigint;
|
|
1827
|
-
status: SigningEntryStatus;
|
|
1828
|
-
}
|
|
1829
|
-
interface OperatorSigningActivityResponse {
|
|
1830
|
-
schemaVersion: number;
|
|
1831
|
-
authorityIndex: number;
|
|
1832
|
-
currentRound: bigint;
|
|
1833
|
-
limit: number;
|
|
1834
|
-
entries: OperatorSigningEntry[];
|
|
1835
|
-
}
|
|
1836
|
-
interface AttestationWindow {
|
|
1837
|
-
startRound: bigint;
|
|
1838
|
-
endRound: bigint;
|
|
1839
|
-
kind: string;
|
|
1840
|
-
}
|
|
1841
|
-
interface DutyAbsence {
|
|
1842
|
-
reason: string;
|
|
1843
|
-
}
|
|
1844
|
-
type KeyRotationWindow = {
|
|
1845
|
-
nextRound: bigint;
|
|
1846
|
-
epochLengthRounds: bigint;
|
|
1847
|
-
} | DutyAbsence;
|
|
1848
|
-
interface UpcomingDutyMap {
|
|
1849
|
-
attestation: AttestationWindow;
|
|
1850
|
-
blockProduction: DutyAbsence;
|
|
1851
|
-
sync: DutyAbsence;
|
|
1852
|
-
keyRotation: KeyRotationWindow;
|
|
1853
|
-
}
|
|
1854
|
-
interface UpcomingDutiesResponse {
|
|
1855
|
-
schemaVersion: number;
|
|
1856
|
-
authorityIndex: number;
|
|
1857
|
-
currentRound: bigint;
|
|
1858
|
-
horizonRounds: number;
|
|
1859
|
-
duties: UpcomingDutyMap;
|
|
1860
|
-
}
|
|
1861
|
-
type JailStatusWindow = {
|
|
1862
|
-
jailed: boolean;
|
|
1863
|
-
tombstoned: boolean;
|
|
1864
|
-
jailedUntilHeight: bigint;
|
|
1865
|
-
unjailCount: bigint;
|
|
1866
|
-
} | DutyAbsence;
|
|
1867
|
-
interface OperatorRiskResponse {
|
|
1868
|
-
schemaVersion: number;
|
|
1869
|
-
authorityIndex: number;
|
|
1870
|
-
dataHeight: bigint;
|
|
1871
|
-
windowRounds: number;
|
|
1872
|
-
missedRounds: number;
|
|
1873
|
-
observedRounds: number;
|
|
1874
|
-
missRateBps: number;
|
|
1875
|
-
thresholdBps: number;
|
|
1876
|
-
remainingHeadroomBps: number;
|
|
1877
|
-
jailStatus: JailStatusWindow;
|
|
1878
|
-
reasons: string[];
|
|
1879
|
-
}
|
|
1880
|
-
interface LythUpgradePlanStatus {
|
|
1881
|
-
upgradeId: string;
|
|
1882
|
-
activationHeight: number;
|
|
1883
|
-
activationRound: number | null;
|
|
1884
|
-
requiredBinaryVersion: string;
|
|
1885
|
-
expectedBinaryDigest: string;
|
|
1886
|
-
p2pProtocolVersion: number;
|
|
1887
|
-
requiredFeatures: string[];
|
|
1888
|
-
milestoneFileDigest: string | null;
|
|
1889
|
-
stateMigrationId: string | null;
|
|
1890
|
-
stateMigrationHash: string | null;
|
|
1891
|
-
expectedPreStateRoot: string | null;
|
|
1892
|
-
expectedPostStateRoot: string | null;
|
|
1893
|
-
}
|
|
1894
|
-
interface LythUpgradeStatusResponse {
|
|
1895
|
-
chainId: number;
|
|
1896
|
-
blockNumber: number;
|
|
1897
|
-
configured: boolean;
|
|
1898
|
-
planCount: number;
|
|
1899
|
-
state: "active" | "none" | "pending" | string;
|
|
1900
|
-
active: LythUpgradePlanStatus | null;
|
|
1901
|
-
pendingCount: number;
|
|
1902
|
-
pending: LythUpgradePlanStatus[];
|
|
1903
|
-
}
|
|
1904
|
-
interface RuntimeBuildProvenance {
|
|
1905
|
-
clientName: string;
|
|
1906
|
-
version: string;
|
|
1907
|
-
gitCommit: string;
|
|
1908
|
-
gitDirty: boolean;
|
|
1909
|
-
buildTimestampUtc: number;
|
|
1910
|
-
rustc: string;
|
|
1911
|
-
target: string;
|
|
1912
|
-
profile: string;
|
|
1913
|
-
features: string;
|
|
1914
|
-
p2pProtocolVersion: number;
|
|
1915
|
-
binarySha256: string | null;
|
|
1916
|
-
stateMigrations: string[];
|
|
1917
|
-
}
|
|
1918
|
-
interface RuntimeUpgradeStatus {
|
|
1919
|
-
blockNumber: number;
|
|
1920
|
-
configured: boolean;
|
|
1921
|
-
planCount: number;
|
|
1922
|
-
state: "active" | "none" | "pending" | string;
|
|
1923
|
-
active: LythUpgradePlanStatus | null;
|
|
1924
|
-
pending: LythUpgradePlanStatus[];
|
|
1925
|
-
}
|
|
1926
|
-
interface RuntimeProvenanceResponse {
|
|
1927
|
-
schemaVersion: number;
|
|
1928
|
-
chainId: number;
|
|
1929
|
-
genesisHash: string | null;
|
|
1930
|
-
latestHeight: number;
|
|
1931
|
-
runtime: RuntimeBuildProvenance;
|
|
1932
|
-
upgrade: RuntimeUpgradeStatus | null;
|
|
1933
|
-
}
|
|
1934
|
-
type ServiceProbeStatusLabel = "unknown" | "reachable" | "degraded" | "unreachable" | string;
|
|
1935
|
-
interface ServiceProbeResponse {
|
|
1936
|
-
serviceMask: number;
|
|
1937
|
-
status: ServiceProbeStatusLabel;
|
|
1938
|
-
statusCode: number;
|
|
1939
|
-
lastProbeBlock: number;
|
|
1940
|
-
latencyMs: number;
|
|
1941
|
-
probeDigest: string;
|
|
1942
|
-
reporter: string;
|
|
1943
|
-
}
|
|
1944
|
-
interface ReportServiceProbeRequest {
|
|
1945
|
-
peerId: string;
|
|
1946
|
-
serviceMask: number;
|
|
1947
|
-
status: number;
|
|
1948
|
-
latencyMs: number;
|
|
1949
|
-
probeDigest: string;
|
|
1950
|
-
signedRawTx: string;
|
|
1951
|
-
}
|
|
1952
|
-
interface ReportServiceProbeResponse {
|
|
1953
|
-
txHash: string;
|
|
1954
|
-
peerId: string;
|
|
1955
|
-
serviceMask: number;
|
|
1956
|
-
statusCode: number;
|
|
1957
|
-
}
|
|
1958
|
-
type TxStatusResponse = TxStatusFoundResponse | TxStatusNotFoundResponse;
|
|
1959
|
-
interface TxStatusFoundResponse {
|
|
1960
|
-
status: "found";
|
|
1961
|
-
txHash: string;
|
|
1962
|
-
blockHash: string;
|
|
1963
|
-
blockNumber: number;
|
|
1964
|
-
txIndex: number;
|
|
1965
|
-
}
|
|
1966
|
-
interface TxStatusNotFoundResponse {
|
|
1967
|
-
status: "not_found";
|
|
1968
|
-
txHash: string;
|
|
1969
|
-
latestHeight: number;
|
|
1970
|
-
indexerEnabled: boolean;
|
|
1971
|
-
providerKind: string;
|
|
1972
|
-
}
|
|
1973
|
-
interface VertexAtRound {
|
|
1974
|
-
vertexHash: string;
|
|
1975
|
-
author: number;
|
|
1976
|
-
}
|
|
1977
|
-
interface VerticesAtRoundResponse {
|
|
1978
|
-
schemaVersion: number;
|
|
1979
|
-
round: number;
|
|
1980
|
-
vertices: VertexAtRound[] | null;
|
|
1981
|
-
}
|
|
1982
|
-
type MetricsRangeStatus = "available" | "not_retained" | "unknown" | string;
|
|
1983
|
-
interface MetricsRangeSample {
|
|
1984
|
-
blockNumber: number;
|
|
1985
|
-
value: number;
|
|
1986
|
-
}
|
|
1987
|
-
interface MetricsRangeSeries {
|
|
1988
|
-
selector: string;
|
|
1989
|
-
status: MetricsRangeStatus;
|
|
1990
|
-
unit: string | null;
|
|
1991
|
-
samples: MetricsRangeSample[] | null;
|
|
1992
|
-
}
|
|
1993
|
-
interface MetricsRangeResponse {
|
|
1994
|
-
schemaVersion: number;
|
|
1995
|
-
range: [number, number] | null;
|
|
1996
|
-
tracking: string;
|
|
1997
|
-
series: MetricsRangeSeries[];
|
|
1998
|
-
}
|
|
1999
|
-
type AddressActivityKind = "found" | "not_found" | "indexer_disabled" | "pruned" | "private" | string;
|
|
2000
|
-
declare class RpcClient {
|
|
2001
|
-
#private;
|
|
2002
|
-
readonly endpoint: string;
|
|
2003
|
-
constructor(endpoint: string, options?: RpcClientOptions);
|
|
2004
|
-
/**
|
|
2005
|
-
* Construct a client from the chain-registry network slug.
|
|
2006
|
-
*
|
|
2007
|
-
* Defaults to the SDK-bundled registry snapshot from
|
|
2008
|
-
* `monolythium/chain-registry`. Set `probe: true` to walk the
|
|
2009
|
-
* registry endpoints in order and return the first endpoint whose
|
|
2010
|
-
* `eth_chainId` matches the registry chain id.
|
|
2011
|
-
*/
|
|
2012
|
-
static forNetwork(network?: NetworkSlug | string, options?: NetworkClientOptions): Promise<RpcClient>;
|
|
2013
|
-
/**
|
|
2014
|
-
* Walk a chain-registry entry in order and return the first endpoint
|
|
2015
|
-
* whose `eth_chainId` matches the registry `chain_id`.
|
|
2016
|
-
*/
|
|
2017
|
-
static fromFirstReachable(chain: ChainInfo, options?: RpcClientOptions): Promise<RpcClient>;
|
|
2018
|
-
/**
|
|
2019
|
-
* Send an arbitrary JSON-RPC method. Most callers should prefer the
|
|
2020
|
-
* typed wrappers below; this is the escape hatch for methods the
|
|
2021
|
-
* SDK does not yet wrap.
|
|
2022
|
-
*/
|
|
2023
|
-
call<T>(method: string, params?: unknown): Promise<T>;
|
|
2024
|
-
/** `eth_chainId` — configured chain id. */
|
|
2025
|
-
ethChainId(): Promise<bigint>;
|
|
2026
|
-
/** `eth_blockNumber` — latest committed height. */
|
|
2027
|
-
ethBlockNumber(): Promise<bigint>;
|
|
2028
|
-
/** `eth_getBalance` — balance + Merkle proof envelope. */
|
|
2029
|
-
ethGetBalance(address: string, block?: BlockSelector): Promise<AccountProofResponse>;
|
|
2030
|
-
/** `eth_getStorageAt` — storage word + Merkle proof. */
|
|
2031
|
-
ethGetStorageAt(address: string, slot: string, block?: BlockSelector): Promise<AccountProofResponse>;
|
|
2032
|
-
/** `eth_getTransactionCount` — sender nonce. */
|
|
2033
|
-
ethGetTransactionCount(address: string, block?: BlockSelector): Promise<bigint>;
|
|
2034
|
-
/** `eth_getCode` — deployed bytecode (`0x` for an EOA, `0xfe` for a precompile). */
|
|
2035
|
-
ethGetCode(address: string, block?: BlockSelector): Promise<string>;
|
|
2036
|
-
/** `eth_getBlockByNumber` — fetch a block header by height/tag. */
|
|
2037
|
-
ethGetBlockByNumber(block?: BlockSelector): Promise<BlockHeader | null>;
|
|
2038
|
-
/** `eth_getBlockByHash` — fetch a block header by hash. */
|
|
2039
|
-
ethGetBlockByHash(hash: string): Promise<BlockHeader | null>;
|
|
2040
|
-
/** `eth_getTransactionByHash` — fetch an included transaction by hash. */
|
|
2041
|
-
ethGetTransactionByHash(txHash: string): Promise<TransactionView | null>;
|
|
2042
|
-
/** `eth_getTransactionReceipt` — receipt for a confirmed tx. */
|
|
2043
|
-
ethGetTransactionReceipt(txHash: string): Promise<TransactionReceipt | null>;
|
|
2044
|
-
/** `eth_sendRawTransaction` — submit a signed raw tx. */
|
|
2045
|
-
ethSendRawTransaction(rawTx: string): Promise<string>;
|
|
2046
|
-
/** `eth_call` — dry-run a transaction. */
|
|
2047
|
-
ethCall(request: CallRequest, block?: BlockSelector): Promise<string>;
|
|
2048
|
-
/** `eth_estimateGas` — gas estimate for a dry-run. */
|
|
2049
|
-
ethEstimateGas(request: CallRequest, block?: BlockSelector): Promise<bigint>;
|
|
2050
|
-
/** `eth_gasPrice` — minimum gas price the node will accept. */
|
|
2051
|
-
ethGasPrice(): Promise<bigint>;
|
|
2052
|
-
/** `eth_feeHistory` — base-fee + gas-used history. */
|
|
2053
|
-
ethFeeHistory(blockCount: number, newestBlock?: BlockSelector, rewardPercentiles?: number[]): Promise<FeeHistoryResponse>;
|
|
2054
|
-
/** `eth_syncing` — `null` when caught up. */
|
|
2055
|
-
ethSyncing(): Promise<SyncStatus | null>;
|
|
2056
|
-
/** `net_version` — chain id as a decimal string. */
|
|
2057
|
-
netVersion(): Promise<string>;
|
|
2058
|
-
/** `net_peerCount` — number of connected peers. */
|
|
2059
|
-
netPeerCount(): Promise<bigint>;
|
|
2060
|
-
/** `net_listening` — whether the node accepts inbound peers. */
|
|
2061
|
-
netListening(): Promise<boolean>;
|
|
2062
|
-
/** `web3_clientVersion` — server's client-version string. */
|
|
2063
|
-
web3ClientVersion(): Promise<string>;
|
|
2064
|
-
/** `web3_sha3` — Keccak-256 of `data`. */
|
|
2065
|
-
web3Sha3(data: string): Promise<string>;
|
|
2066
|
-
/** `lyth_listProviders` — paged registry enumeration. */
|
|
2067
|
-
lythListProviders(capabilityMask: number, cursor?: string | null, limit?: number): Promise<RegistryRecord[]>;
|
|
2068
|
-
/** `lyth_getRegistration` — single registry lookup. */
|
|
2069
|
-
lythGetRegistration(peerId: string): Promise<RegistryRecord | null>;
|
|
2070
|
-
/** `lyth_registryStateProof` — Merkle proof for a registry entry. */
|
|
2071
|
-
lythRegistryStateProof(peerId: string): Promise<AccountProofResponse>;
|
|
2072
|
-
/** `lyth_getAccountPolicy` — privacy posture for an account. */
|
|
2073
|
-
lythGetAccountPolicy(address: string): Promise<AccountPolicy>;
|
|
2074
|
-
/** `lyth_getAssetPolicy` — privacy posture for an asset. */
|
|
2075
|
-
lythGetAssetPolicy(tokenId: string): Promise<AssetPolicy>;
|
|
2076
|
-
/** `lyth_getTokenBalances` — indexed per-asset balances for one address. */
|
|
2077
|
-
lythGetTokenBalances(address: string): Promise<TokenBalanceRecord[]>;
|
|
2078
|
-
/** `lyth_getAddressLabel` — indexed display/category label for one address. */
|
|
2079
|
-
lythGetAddressLabel(address: string): Promise<AddressLabelRecord | null>;
|
|
2080
|
-
/** `lyth_getAddressActivity` — indexed per-address activity timeline. */
|
|
2081
|
-
lythGetAddressActivity(address: string, limit?: number, cursor?: string | null): Promise<AddressActivityEntry[]>;
|
|
2082
|
-
/** `lyth_addressActivityKind` — activity index coverage for one address. */
|
|
2083
|
-
lythAddressActivityKind(address: string): Promise<AddressActivityKindResponse>;
|
|
2084
|
-
/** `lyth_decodeTx` — explorer-grade decoded transaction envelope. */
|
|
2085
|
-
lythDecodeTx(txHash: string): Promise<DecodeTxResponse>;
|
|
2086
|
-
/** `lyth_gapRecords` — retained ingestion/indexing gaps for a block range. */
|
|
2087
|
-
lythGapRecords(fromBlock: number | bigint | string, toBlock: number | bigint | string): Promise<GapRecordsResponse>;
|
|
2088
|
-
/** `lyth_dagParents` — parent vertices for a DAG round. */
|
|
2089
|
-
lythDagParents(round: number | bigint | string): Promise<DagParentsResponse>;
|
|
2090
|
-
/** `lyth_richList` — top holders for a token id. */
|
|
2091
|
-
lythRichList(tokenId: string, limit?: number | null): Promise<RichListResponse>;
|
|
2092
|
-
/** `lyth_clobMarket` — live CLOB market metadata for a market id. */
|
|
2093
|
-
lythClobMarket(marketId: string): Promise<ClobMarketResponse>;
|
|
2094
|
-
/** `lyth_clobMarkets` — CLOB markets observed through indexed trades. */
|
|
2095
|
-
lythClobMarkets(limit?: number | null): Promise<ClobMarketsResponse>;
|
|
2096
|
-
/** `lyth_clobTrades` — CLOB fills for one market. */
|
|
2097
|
-
lythClobTrades(marketId: string, limit?: number, cursor?: string | null): Promise<ClobTradesResponse>;
|
|
2098
|
-
/** `lyth_clobOhlc` — CLOB OHLC candles for a market over a block range. */
|
|
2099
|
-
lythClobOhlc(marketId: string, fromBlock?: number | bigint | string | null, toBlock?: number | bigint | string | null, bucketBlocks?: number | bigint | string | null): Promise<ClobOhlcResponse>;
|
|
2100
|
-
/** `lyth_clobOrderBook` — live CLOB depth from canonical state. */
|
|
2101
|
-
lythClobOrderBook(marketId: string, levels?: number | null): Promise<ClobOrderBookResponse>;
|
|
2102
|
-
/** `lyth_txFeed` — paged global transaction feed. */
|
|
2103
|
-
lythTxFeed(limit?: number, cursor?: string | null): Promise<TxFeedResponse>;
|
|
2104
|
-
/** `lyth_addressProfile` — live account + label + activity aggregate. */
|
|
2105
|
-
lythAddressProfile(address: string): Promise<AddressProfileResponse>;
|
|
2106
|
-
/** `lyth_addressFlow` — recent indexed address-flow aggregate. */
|
|
2107
|
-
lythAddressFlow(address: string, limit?: number): Promise<AddressFlowResponse>;
|
|
2108
|
-
/** `lyth_search` — exact live resolver for hashes, addresses, blocks, and clusters. */
|
|
2109
|
-
lythSearch(query: string, limit?: number): Promise<SearchResponse>;
|
|
2110
|
-
/** `lyth_chainStats` — compact live chain/indexer/mempool summary. */
|
|
2111
|
-
lythChainStats(): Promise<ChainStatsResponse>;
|
|
2112
|
-
/** `lyth_mempoolStatus` — aggregate mempool snapshot. */
|
|
2113
|
-
lythMempoolStatus(): Promise<MempoolSnapshot>;
|
|
2114
|
-
/** `lyth_mempoolPending` — pending txs for a sender. */
|
|
2115
|
-
lythMempoolPending(sender: string): Promise<PendingTxSummary[]>;
|
|
2116
|
-
/** `lyth_currentRound` — latest committed height. */
|
|
2117
|
-
lythCurrentRound(): Promise<RoundInfo>;
|
|
2118
|
-
/** `lyth_peerSummary` — public-safe aggregate peer-network diagnostics. */
|
|
2119
|
-
lythPeerSummary(): Promise<PeerSummaryAggregate>;
|
|
2120
|
-
/**
|
|
2121
|
-
* `lyth_listActivePrecompiles` — milestone-gated precompile catalogue
|
|
2122
|
-
* (OI-0170 / ADR-0015 §5).
|
|
2123
|
-
*/
|
|
2124
|
-
lythListActivePrecompiles(block?: BlockSelector): Promise<PrecompileCatalogueResponse>;
|
|
2125
|
-
/** `lyth_capabilities` — address-keyed precompile capability map. */
|
|
2126
|
-
lythCapabilities(block?: BlockSelector): Promise<CapabilitiesResponse>;
|
|
2127
|
-
/**
|
|
2128
|
-
* `lyth_operatorCapabilities` — node-level availability for operator UI
|
|
2129
|
-
* and explorer surfaces.
|
|
2130
|
-
*/
|
|
2131
|
-
lythOperatorCapabilities(): Promise<OperatorCapabilitiesResponse>;
|
|
2132
|
-
/** `lyth_indexerStatus` — indexer status; `null` when disabled. */
|
|
2133
|
-
lythIndexerStatus(): Promise<IndexerStatus | null>;
|
|
2134
|
-
/** `lyth_getStorageProof` — batched Merkle proofs. */
|
|
2135
|
-
lythGetStorageProof(address: string, slots: string[]): Promise<StorageProofBatch>;
|
|
2136
|
-
/** `lyth_getDelegations` — wallet delegation rows at a block. */
|
|
2137
|
-
lythGetDelegations(wallet: string, block?: BlockSelector): Promise<DelegationsResponse>;
|
|
2138
|
-
/** `lyth_getDelegationHistory` — indexed per-wallet delegation event timeline. */
|
|
2139
|
-
lythGetDelegationHistory(wallet: string, limit?: number, cursor?: string | null): Promise<DelegationHistoryRecord[]>;
|
|
2140
|
-
/** `lyth_getClusterDelegators` — delegator addresses for a cluster. */
|
|
2141
|
-
lythGetClusterDelegators(cluster: number, block?: BlockSelector): Promise<ClusterDelegatorsResponse>;
|
|
2142
|
-
/** `lyth_getDelegationCap` — active per-cluster cap at a block. */
|
|
2143
|
-
lythGetDelegationCap(block?: BlockSelector): Promise<DelegationCapResponse>;
|
|
2144
|
-
/** `lyth_getTpmAttestation` — TPM quote digest + EK id for a peer. */
|
|
2145
|
-
lythGetTpmAttestation(peerId: string, block?: BlockSelector): Promise<TpmAttestationResponse>;
|
|
2146
|
-
/** `lyth_getClusterEntity` — entity flag for a cluster. */
|
|
2147
|
-
lythGetClusterEntity(cluster: number, block?: BlockSelector): Promise<ClusterEntityResponse>;
|
|
2148
|
-
/** `lyth_getEntityRatchet` — entity-ratchet snapshot at a block. */
|
|
2149
|
-
lythGetEntityRatchet(block?: BlockSelector): Promise<EntityRatchetResponse>;
|
|
2150
|
-
/** `lyth_operatorInfo` — canonical operator identity envelope. */
|
|
2151
|
-
lythOperatorInfo(operatorId: string): Promise<OperatorInfoResponse>;
|
|
2152
|
-
/** `lyth_getServiceProbe` — latest external reachability report for one public service. */
|
|
2153
|
-
lythGetServiceProbe(peerId: string, serviceMask: number): Promise<ServiceProbeResponse | null>;
|
|
2154
|
-
/** `lyth_reportServiceProbe` — submit a pre-signed public-service probe report. */
|
|
2155
|
-
lythReportServiceProbe(req: ReportServiceProbeRequest): Promise<ReportServiceProbeResponse>;
|
|
2156
|
-
/** `lyth_clusterStatus` — canonical cluster status envelope. */
|
|
2157
|
-
lythClusterStatus(clusterId: number): Promise<ClusterStatusResponse>;
|
|
2158
|
-
/** `lyth_clusterDirectory` — paged public cluster directory. */
|
|
2159
|
-
lythClusterDirectory(page?: number, limit?: number): Promise<ClusterDirectoryPageResponse>;
|
|
2160
|
-
/** `lyth_clusters` — alias for `lyth_clusterDirectory`. */
|
|
2161
|
-
lythClusters(page?: number, limit?: number): Promise<ClusterDirectoryPageResponse>;
|
|
2162
|
-
/**
|
|
2163
|
-
* `lyth_submitPendingChange` — operator-onboarding transport for the
|
|
2164
|
-
* pending-change ledger. Server validates the envelope shape.
|
|
2165
|
-
*/
|
|
2166
|
-
lythSubmitPendingChange(envelope: unknown): Promise<unknown>;
|
|
2167
|
-
/** `lyth_submitEncrypted` — submit a bincode-encoded encrypted envelope hex. */
|
|
2168
|
-
lythSubmitEncrypted(envelopeHex: string): Promise<string>;
|
|
2169
|
-
/** `lyth_getEncryptionKey` — cluster ML-KEM encapsulation key. */
|
|
2170
|
-
lythGetEncryptionKey(): Promise<EncryptionKeyResponse>;
|
|
2171
|
-
/** `lyth_syncStatus` — DAG-sync driver snapshot. */
|
|
2172
|
-
lythSyncStatus(): Promise<DagSyncStatus | null>;
|
|
2173
|
-
/** `lyth_resolveOperatorAuthority` — operator id to authority index. */
|
|
2174
|
-
lythResolveOperatorAuthority(operatorId: string): Promise<OperatorAuthorityResponse>;
|
|
2175
|
-
/** `lyth_signingActivity` — recent per-round signing participation. */
|
|
2176
|
-
lythSigningActivity(authorityIndex: number, limit?: number | null): Promise<OperatorSigningActivityResponse>;
|
|
2177
|
-
/** `lyth_upcomingDuties` — deterministic upcoming duty windows. */
|
|
2178
|
-
lythUpcomingDuties(authorityIndex: number, horizonRounds?: number | null): Promise<UpcomingDutiesResponse>;
|
|
2179
|
-
/** `lyth_operatorRisk` — miss-rate and jail-status window. */
|
|
2180
|
-
lythOperatorRisk(authorityIndex: number, windowRounds?: number | null): Promise<OperatorRiskResponse>;
|
|
2181
|
-
/** `lyth_upgradeStatus` — signed network-upgrade readiness at a height. */
|
|
2182
|
-
lythUpgradeStatus(block?: BlockSelector): Promise<LythUpgradeStatusResponse>;
|
|
2183
|
-
/** `lyth_runtimeProvenance` — public-safe build/runtime provenance. */
|
|
2184
|
-
lythRuntimeProvenance(): Promise<RuntimeProvenanceResponse>;
|
|
2185
|
-
/** `lyth_txStatus` — discriminated transaction lookup outcome. */
|
|
2186
|
-
lythTxStatus(txHash: string): Promise<TxStatusResponse>;
|
|
2187
|
-
/** `lyth_verticesAtRound` — per-vertex authorship observed at a DAG round. */
|
|
2188
|
-
lythVerticesAtRound(round: number | bigint | string): Promise<VerticesAtRoundResponse>;
|
|
2189
|
-
/** `lyth_metricsRange` — retained telemetry series when the node has them. */
|
|
2190
|
-
lythMetricsRange(selectors: string[], range?: readonly [number | bigint | string, number | bigint | string] | null): Promise<MetricsRangeResponse>;
|
|
2191
|
-
/** `lyth_getLatestCheckpoint` — latest PQ-finality checkpoint rows. */
|
|
2192
|
-
lythGetLatestCheckpoint(belowHeight?: number | bigint | string | null): Promise<CheckpointRecord[]>;
|
|
2193
|
-
/** `lyth_getClusterResignations` — in-flight + applied operator resignations. */
|
|
2194
|
-
lythGetClusterResignations(operator?: string | null, status?: "pending" | "applied" | "all" | string | null): Promise<ClusterResignationsResponse>;
|
|
2195
|
-
/** `lyth_getBlsRoundCertificate` — round-advancement BLS aggregate. */
|
|
2196
|
-
lythGetBlsRoundCertificate(round: number | bigint | string): Promise<BlsCertificateResponse | null>;
|
|
2197
|
-
/** `lyth_getLeaderCertificate` — leader-vote BLS aggregate for a block ref. */
|
|
2198
|
-
lythGetLeaderCertificate(round: number | bigint | string, authority: number, digest: string): Promise<BlsCertificateResponse | null>;
|
|
2199
|
-
/** `lyth_getDacCertificate` — data-availability certificate for a block ref. */
|
|
2200
|
-
lythGetDacCertificate(round: number | bigint | string, authority: number, digest: string): Promise<BlsCertificateResponse | null>;
|
|
2201
|
-
/** `lyth_subscribe` — WebSocket-only; returns an RPC error over HTTP. */
|
|
2202
|
-
lythSubscribe(channel: string): Promise<unknown>;
|
|
2203
|
-
/** `lyth_unsubscribe` — counterpart to `lythSubscribe`. */
|
|
2204
|
-
lythUnsubscribe(subId: string): Promise<unknown>;
|
|
2205
|
-
/** `debug_traceTransaction` — revm trace for a confirmed tx. */
|
|
2206
|
-
debugTraceTransaction(txHash: string): Promise<unknown>;
|
|
2207
|
-
/** `debug_traceCall` — revm trace for a dry-run. */
|
|
2208
|
-
debugTraceCall(request: CallRequest, block?: BlockSelector): Promise<unknown>;
|
|
2209
|
-
/** `debug_traceBlockByNumber` — revm traces for an entire block. */
|
|
2210
|
-
debugTraceBlockByNumber(block: BlockSelector): Promise<unknown>;
|
|
2211
|
-
/** `debug_mempoolDump` — full mempool snapshot. */
|
|
2212
|
-
debugMempoolDump(): Promise<MempoolSnapshot>;
|
|
2213
|
-
/** `debug_p2pPeers` — connected libp2p peer list. */
|
|
2214
|
-
debugP2pPeers(): Promise<PeerSummary[]>;
|
|
2215
|
-
/** `debug_stateDiff` — state-diff for a block range. */
|
|
2216
|
-
debugStateDiff(params: unknown): Promise<unknown>;
|
|
2217
|
-
/** `debug_chainReorg` — testnet-only reorg trigger. */
|
|
2218
|
-
debugChainReorg(params: unknown): Promise<unknown>;
|
|
2219
|
-
/** `mesh_buildUnsignedTx` — build an unsigned transaction envelope. */
|
|
2220
|
-
meshBuildUnsignedTx(intent: MeshTxIntent): Promise<MeshUnsignedTxResponse>;
|
|
2221
|
-
/** `mesh_combineTx` — combine an unsigned envelope with a wallet signature. */
|
|
2222
|
-
meshCombineTx(unsignedTx: string, signatureHex: string, algo?: "secp256k1" | "ml_dsa_65" | string, pubkeyHex?: string): Promise<MeshSignedTxResponse>;
|
|
2223
|
-
/** `mesh_decodeTx` — decode a signed or unsigned mesh envelope. */
|
|
2224
|
-
meshDecodeTx(envelopeHex: string, signed?: boolean): Promise<MeshDecodedTx>;
|
|
2225
|
-
/** `mesh_submitTx` — submit a signed mesh envelope. */
|
|
2226
|
-
meshSubmitTx(signedTx: string): Promise<string>;
|
|
2227
|
-
}
|
|
2228
|
-
/** Decode a `0x`-prefixed hex quantity to a `bigint`. */
|
|
2229
|
-
declare function parseQuantityBig(hex: string): bigint;
|
|
2230
|
-
/**
|
|
2231
|
-
* Decode a `0x`-prefixed hex quantity to a JS `number`. Convenience for
|
|
2232
|
-
* small quantities (chain id, block height, gas estimate). Throws if the
|
|
2233
|
-
* value exceeds `Number.MAX_SAFE_INTEGER`.
|
|
2234
|
-
*/
|
|
2235
|
-
declare function parseQuantity(hex: string): number;
|
|
2236
|
-
|
|
2237
|
-
export { type DagSyncStatus as $, type AddressProfileResponse as A, type BlockSelector as B, type ChainStatsResponse as C, CHAIN_REGISTRY as D, CHAIN_REGISTRY_RAW_BASE as E, type CapabilitiesResponse as F, type CapabilityDescriptor as G, type ChainInfo as H, type ChainRegistry as I, type CheckpointRecord as J, type ClobMarketRecord as K, type ClobMarketSummary as L, type ClobTrade as M, type ClusterDelegatorsResponse as N, type OperatorCapabilitiesResponse as O, type ClusterDirectoryEntryResponse as P, type ClusterDirectoryPageResponse as Q, type RuntimeBuildProvenance as R, type SearchResponse as S, type TxFeedResponse as T, type ClusterEntityResponse as U, type ClusterMemberResponse as V, type ClusterResignationRow as W, type ClusterResignationsResponse as X, type ClusterStatusResponse as Y, type DagParent as Z, type DagParentsResponse as _, type RuntimeUpgradeStatus as a, type TransactionView as a$, type DecodeTxLog as a0, type DecodeTxPqAttestation as a1, type DecodeTxResponse as a2, type DelegationCapResponse as a3, type DelegationHistoryRecord as a4, type DelegationRow as a5, type DelegationsResponse as a6, type DutyAbsence as a7, type EncryptionKeyResponse as a8, type EntityRatchetResponse as a9, type OperatorSigningActivityResponse as aA, type OperatorSigningEntry as aB, type OperatorSurfaceCapability as aC, type OperatorSurfaceStatus as aD, type P2pSeed as aE, type PeerSummary as aF, type PeerSummaryAggregate as aG, type PendingTxSummary as aH, type PrecompileCatalogueResponse as aI, type PrecompileDescriptor as aJ, type Quantity as aK, type RegistryRecord as aL, type ReportServiceProbeRequest as aM, type ReportServiceProbeResponse as aN, type RichListHolder as aO, type RichListResponse as aP, type RoundInfo as aQ, type RpcEndpoint as aR, type RuntimeProvenanceResponse as aS, type SearchHit as aT, type ServiceProbeStatusLabel as aU, type SigningEntryStatus as aV, type StorageProofBatch as aW, type SyncStatus as aX, TESTNET_69420 as aY, type TokenBalanceRecord as aZ, type TpmAttestationResponse as a_, type ExplorerEndpoint as aa, type FeeHistoryResponse as ab, type GapRange as ac, type GapRecord as ad, type GapRecordsResponse as ae, type Hash as af, type Hex as ag, type IndexerStatus as ah, type JailStatusWindow as ai, type KeyRotationWindow as aj, type LythUpgradePlanStatus as ak, type LythUpgradeStatusResponse as al, type MempoolSnapshot as am, type MeshDecodedTx as an, type MeshSignedTxResponse as ao, type MeshTxIntent as ap, type MeshUnsignedTxResponse as aq, type MetricsRangeResponse as ar, type MetricsRangeSample as as, type MetricsRangeSeries as at, type MetricsRangeStatus as au, type NetworkClientOptions as av, type NetworkSlug as aw, type OperatorAuthorityResponse as ax, type OperatorInfoResponse as ay, type OperatorRiskResponse as az, type AddressFlowResponse as b, type TxFeedReceipt as b0, type TxFeedTransaction as b1, type TxStatusFoundResponse as b2, type TxStatusNotFoundResponse as b3, type TxStatusResponse as b4, type UpcomingDutiesResponse as b5, type UpcomingDutyMap as b6, type VertexAtRound as b7, type VerticesAtRoundResponse as b8, encodeBlockSelector as b9, fetchChainInfoLatest as ba, fetchChainRegistryLatest as bb, getChainInfo as bc, getP2pSeeds as bd, getRpcEndpoints as be, parseChainRegistryToml as bf, parseQuantity as bg, parseQuantityBig as bh, type ServiceProbeResponse as c, type ClobMarketsResponse as d, type ClobMarketResponse as e, type ClobTradesResponse as f, type ClobOhlcResponse as g, type ClobOrderBookResponse as h, RpcClient as i, type RpcClientOptions as j, type TransactionReceipt as k, type CallRequest as l, type AccountPolicy as m, type AccountProofResponse as n, type Address as o, type AddressActivityArchiveRedirect as p, type AddressActivityEntry as q, type AddressActivityKind as r, type AddressActivityKindResponse as s, type AddressActivityKindRetention as t, type AddressLabelRecord as u, type AssetPolicy as v, type AttestationWindow as w, type BlockHeader as x, type BlockTag as y, type BlsCertificateResponse as z };
|