@xyo-network/xl1-rpc 1.16.5 → 1.16.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/neutral/index.mjs +521 -550
- package/dist/neutral/index.mjs.map +1 -1
- package/dist/neutral/provider/viewer/JsonRpcXyoViewer.d.ts +4 -2
- package/dist/neutral/provider/viewer/JsonRpcXyoViewer.d.ts.map +1 -1
- package/dist/neutral/types/schema/AllRpcSchemas.d.ts +338 -769
- package/dist/neutral/types/schema/AllRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/NetworkStakeViewerRpcSchemas.d.ts +2 -2
- package/dist/neutral/types/schema/NetworkStakeViewerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/RewardsByPositionViewerRpcSchemas.d.ts +10 -10
- package/dist/neutral/types/schema/RewardsByStakerViewerRpcSchemas.d.ts +10 -10
- package/dist/neutral/types/schema/RewardsByStepViewerRpcSchemas.d.ts +10 -10
- package/dist/neutral/types/schema/RewardsTotalViewerRpcSchemas.d.ts +10 -10
- package/dist/neutral/types/schema/XyoRunnerRpcSchemas.d.ts +22 -46
- package/dist/neutral/types/schema/XyoRunnerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/XyoSignerRpcSchemas.d.ts +54 -107
- package/dist/neutral/types/schema/XyoSignerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/XyoViewerRpcSchemas.d.ts +260 -614
- package/dist/neutral/types/schema/XyoViewerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/common/BlockBoundWitness.d.ts +10 -118
- package/dist/neutral/types/schema/common/BlockBoundWitness.d.ts.map +1 -1
- package/dist/neutral/types/schema/common/BoundWitness.d.ts +38 -68
- package/dist/neutral/types/schema/common/BoundWitness.d.ts.map +1 -1
- package/dist/neutral/types/schema/common/HydratedBlock.d.ts +51 -143
- package/dist/neutral/types/schema/common/HydratedBlock.d.ts.map +1 -1
- package/dist/neutral/types/schema/common/HydratedTransaction.d.ts +75 -145
- package/dist/neutral/types/schema/common/HydratedTransaction.d.ts.map +1 -1
- package/dist/neutral/types/schema/common/RewardsRangeOptions.d.ts +1 -1
- package/dist/neutral/types/schema/common/RewardsRangeOptions.d.ts.map +1 -1
- package/dist/neutral/types/schema/common/StepIdentity.d.ts +3 -0
- package/dist/neutral/types/schema/common/StepIdentity.d.ts.map +1 -1
- package/dist/neutral/types/schema/common/TransactionBoundWitness.d.ts +18 -46
- package/dist/neutral/types/schema/common/TransactionBoundWitness.d.ts.map +1 -1
- package/dist/neutral/types/schema/common/Transfer.d.ts +0 -31
- package/dist/neutral/types/schema/common/Transfer.d.ts.map +1 -1
- package/dist/neutral/types/schema/common/index.d.ts +0 -2
- package/dist/neutral/types/schema/common/index.d.ts.map +1 -1
- package/dist/node/index-node.mjs +521 -550
- package/dist/node/index-node.mjs.map +1 -1
- package/dist/node/provider/viewer/JsonRpcXyoViewer.d.ts +4 -2
- package/dist/node/provider/viewer/JsonRpcXyoViewer.d.ts.map +1 -1
- package/dist/node/types/schema/AllRpcSchemas.d.ts +338 -769
- package/dist/node/types/schema/AllRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/NetworkStakeViewerRpcSchemas.d.ts +2 -2
- package/dist/node/types/schema/NetworkStakeViewerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/RewardsByPositionViewerRpcSchemas.d.ts +10 -10
- package/dist/node/types/schema/RewardsByStakerViewerRpcSchemas.d.ts +10 -10
- package/dist/node/types/schema/RewardsByStepViewerRpcSchemas.d.ts +10 -10
- package/dist/node/types/schema/RewardsTotalViewerRpcSchemas.d.ts +10 -10
- package/dist/node/types/schema/XyoRunnerRpcSchemas.d.ts +22 -46
- package/dist/node/types/schema/XyoRunnerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/XyoSignerRpcSchemas.d.ts +54 -107
- package/dist/node/types/schema/XyoSignerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/XyoViewerRpcSchemas.d.ts +260 -614
- package/dist/node/types/schema/XyoViewerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/common/BlockBoundWitness.d.ts +10 -118
- package/dist/node/types/schema/common/BlockBoundWitness.d.ts.map +1 -1
- package/dist/node/types/schema/common/BoundWitness.d.ts +38 -68
- package/dist/node/types/schema/common/BoundWitness.d.ts.map +1 -1
- package/dist/node/types/schema/common/HydratedBlock.d.ts +51 -143
- package/dist/node/types/schema/common/HydratedBlock.d.ts.map +1 -1
- package/dist/node/types/schema/common/HydratedTransaction.d.ts +75 -145
- package/dist/node/types/schema/common/HydratedTransaction.d.ts.map +1 -1
- package/dist/node/types/schema/common/RewardsRangeOptions.d.ts +1 -1
- package/dist/node/types/schema/common/RewardsRangeOptions.d.ts.map +1 -1
- package/dist/node/types/schema/common/StepIdentity.d.ts +3 -0
- package/dist/node/types/schema/common/StepIdentity.d.ts.map +1 -1
- package/dist/node/types/schema/common/TransactionBoundWitness.d.ts +18 -46
- package/dist/node/types/schema/common/TransactionBoundWitness.d.ts.map +1 -1
- package/dist/node/types/schema/common/Transfer.d.ts +0 -31
- package/dist/node/types/schema/common/Transfer.d.ts.map +1 -1
- package/dist/node/types/schema/common/index.d.ts +0 -2
- package/dist/node/types/schema/common/index.d.ts.map +1 -1
- package/package.json +21 -21
- package/src/provider/viewer/JsonRpcXyoViewer.ts +21 -5
- package/src/types/schema/NetworkStakeViewerRpcSchemas.ts +1 -1
- package/src/types/schema/XyoViewerRpcSchemas.ts +13 -14
- package/src/types/schema/common/BlockBoundWitness.ts +2 -18
- package/src/types/schema/common/BoundWitness.ts +3 -2
- package/src/types/schema/common/HydratedBlock.ts +6 -6
- package/src/types/schema/common/HydratedTransaction.ts +1 -2
- package/src/types/schema/common/RewardsRangeOptions.ts +1 -1
- package/src/types/schema/common/StepIdentity.ts +3 -0
- package/src/types/schema/common/TransactionBoundWitness.ts +1 -1
- package/src/types/schema/common/Transfer.ts +1 -2
- package/src/types/schema/common/index.ts +0 -2
- package/src/types/schema/common/spec/Payload.spec.ts +2 -3
- package/dist/neutral/types/schema/common/BlockRange.d.ts +0 -3
- package/dist/neutral/types/schema/common/BlockRange.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/Payload.d.ts +0 -81
- package/dist/neutral/types/schema/common/Payload.d.ts.map +0 -1
- package/dist/node/types/schema/common/BlockRange.d.ts +0 -3
- package/dist/node/types/schema/common/BlockRange.d.ts.map +0 -1
- package/dist/node/types/schema/common/Payload.d.ts +0 -81
- package/dist/node/types/schema/common/Payload.d.ts.map +0 -1
- package/src/types/schema/common/BlockRange.ts +0 -6
- package/src/types/schema/common/Payload.ts +0 -23
package/dist/neutral/index.mjs
CHANGED
|
@@ -166,16 +166,42 @@ var NetworkStakingStepRewardsTotalViewerRpcNamespace = "networkStakingStepReward
|
|
|
166
166
|
var NetworkStakingStepRewardsViewerRpcNamespace = "networkStakingStepRewardsViewer";
|
|
167
167
|
|
|
168
168
|
// src/types/schema/NetworkStakeViewerRpcSchemas.ts
|
|
169
|
-
import { BigIntToJsonZod
|
|
170
|
-
import
|
|
169
|
+
import { BigIntToJsonZod, JsonToBigIntZod } from "@xylabs/hex";
|
|
170
|
+
import { BlockNumberZod } from "@xyo-network/xl1-protocol";
|
|
171
|
+
import * as z from "zod";
|
|
172
|
+
var NetworkStakeViewerRpcSchemas = {
|
|
173
|
+
networkStakeViewer_active: {
|
|
174
|
+
params: {
|
|
175
|
+
from: z.tuple([
|
|
176
|
+
BlockNumberZod.optional()
|
|
177
|
+
]),
|
|
178
|
+
to: z.tuple([
|
|
179
|
+
BlockNumberZod.optional()
|
|
180
|
+
])
|
|
181
|
+
},
|
|
182
|
+
result: {
|
|
183
|
+
from: z.tuple([
|
|
184
|
+
JsonToBigIntZod,
|
|
185
|
+
z.number()
|
|
186
|
+
]),
|
|
187
|
+
to: z.tuple([
|
|
188
|
+
BigIntToJsonZod,
|
|
189
|
+
z.number()
|
|
190
|
+
])
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
};
|
|
194
|
+
|
|
195
|
+
// src/types/schema/XyoPermissionsRpcSchemas.ts
|
|
196
|
+
import * as z19 from "zod";
|
|
171
197
|
|
|
172
198
|
// src/types/schema/common/Address.ts
|
|
173
199
|
import { AddressRegEx, toAddress } from "@xylabs/hex";
|
|
174
|
-
import * as
|
|
175
|
-
var AddressZod =
|
|
200
|
+
import * as z2 from "zod";
|
|
201
|
+
var AddressZod = z2.string().toLowerCase().regex(AddressRegEx).transform((v) => toAddress(v));
|
|
176
202
|
|
|
177
203
|
// src/types/schema/common/ArrayBuffer.ts
|
|
178
|
-
import * as
|
|
204
|
+
import * as z3 from "zod";
|
|
179
205
|
function base64Encode(u8) {
|
|
180
206
|
if (typeof Buffer !== "undefined" && typeof Buffer.from === "function") {
|
|
181
207
|
return Buffer.from(u8).toString("base64");
|
|
@@ -198,43 +224,26 @@ function base64Decode(b64) {
|
|
|
198
224
|
return u8;
|
|
199
225
|
}
|
|
200
226
|
__name(base64Decode, "base64Decode");
|
|
201
|
-
var ArrayBufferToJsonZod =
|
|
227
|
+
var ArrayBufferToJsonZod = z3.instanceof(ArrayBuffer).transform((x) => {
|
|
202
228
|
const u8 = new Uint8Array(x);
|
|
203
229
|
return base64Encode(u8);
|
|
204
230
|
});
|
|
205
|
-
var JsonToArrayBufferZod =
|
|
231
|
+
var JsonToArrayBufferZod = z3.string().transform((x) => {
|
|
206
232
|
const u8 = base64Decode(x);
|
|
207
233
|
return u8.buffer;
|
|
208
234
|
});
|
|
209
235
|
|
|
210
236
|
// src/types/schema/common/BlockBoundWitness.ts
|
|
211
237
|
import { HashZod as HashZod2 } from "@xylabs/hex";
|
|
212
|
-
import { StorageMetaZod as
|
|
213
|
-
import {
|
|
238
|
+
import { StorageMetaZod as StorageMetaZod2 } from "@xyo-network/payload-model";
|
|
239
|
+
import { XL1BlockNumberZod } from "@xyo-network/xl1-protocol";
|
|
214
240
|
import * as z6 from "zod";
|
|
215
241
|
|
|
216
242
|
// src/types/schema/common/BoundWitness.ts
|
|
217
243
|
import { HashZod, HexZod } from "@xylabs/hex";
|
|
218
244
|
import { BoundWitnessSchema } from "@xyo-network/boundwitness-model";
|
|
219
|
-
import {
|
|
245
|
+
import { PayloadZod, SchemaZod, StorageMetaZod } from "@xyo-network/payload-model";
|
|
220
246
|
import * as z4 from "zod";
|
|
221
|
-
|
|
222
|
-
// src/types/schema/common/Payload.ts
|
|
223
|
-
import { StorageMetaZod } from "@xyo-network/payload-model";
|
|
224
|
-
import * as z3 from "zod";
|
|
225
|
-
var SchemaZod = z3.string();
|
|
226
|
-
var PayloadZod = z3.object({
|
|
227
|
-
schema: SchemaZod
|
|
228
|
-
}).catchall(z3.any());
|
|
229
|
-
var PayloadWithStorageMetaZod = PayloadZod.extend(StorageMetaZod.shape);
|
|
230
|
-
var AnyPayloadZod = PayloadZod.catchall(z3.json());
|
|
231
|
-
var AnyPayloadWithStorageMetaZod = AnyPayloadZod.extend(StorageMetaZod.shape);
|
|
232
|
-
function WithStorageMetaZod(valueZod) {
|
|
233
|
-
return StorageMetaZod.extend(valueZod.shape);
|
|
234
|
-
}
|
|
235
|
-
__name(WithStorageMetaZod, "WithStorageMetaZod");
|
|
236
|
-
|
|
237
|
-
// src/types/schema/common/BoundWitness.ts
|
|
238
247
|
var BoundWitnessRequiredFieldsZod = z4.object({
|
|
239
248
|
addresses: z4.array(AddressZod),
|
|
240
249
|
payload_hashes: z4.array(HashZod),
|
|
@@ -259,7 +268,7 @@ var UnsignedBoundWitnessZod = BoundWitnessZod.refine((data) => data.$signatures.
|
|
|
259
268
|
message: "all $signatures must be null"
|
|
260
269
|
});
|
|
261
270
|
var AnyUnsignedBoundWitnessZod = UnsignedBoundWitnessZod.catchall(z4.any());
|
|
262
|
-
var UnsignedBoundWitnessWithStorageMetaZod = UnsignedBoundWitnessZod.safeExtend(BoundWitnessRequiredFieldsZod.shape).safeExtend(BoundWitnessMetaZod.shape).safeExtend(
|
|
271
|
+
var UnsignedBoundWitnessWithStorageMetaZod = UnsignedBoundWitnessZod.safeExtend(BoundWitnessRequiredFieldsZod.shape).safeExtend(BoundWitnessMetaZod.shape).safeExtend(StorageMetaZod.shape);
|
|
263
272
|
var SignedBoundWitnessZod = BoundWitnessZod.refine((data) => !data.$signatures.includes(null), {
|
|
264
273
|
message: "all $signatures must not be null"
|
|
265
274
|
});
|
|
@@ -273,8 +282,6 @@ import * as z5 from "zod";
|
|
|
273
282
|
var ChainZod = z5.string().toLowerCase().regex(AddressRegEx2).transform((v) => toAddress2(v));
|
|
274
283
|
|
|
275
284
|
// src/types/schema/common/BlockBoundWitness.ts
|
|
276
|
-
var BlockNumberZod = z6.number().int().nonnegative();
|
|
277
|
-
var XL1BlockNumberZod = BlockNumberZod.transform(asXL1BlockNumber);
|
|
278
285
|
var BlockBoundWitnessFieldsZod = z6.object({
|
|
279
286
|
block: XL1BlockNumberZod,
|
|
280
287
|
chain: ChainZod,
|
|
@@ -285,118 +292,111 @@ var BlockBoundWitnessFieldsZod = z6.object({
|
|
|
285
292
|
var BlockBoundWitnessMetaZod = z6.object({
|
|
286
293
|
$epoch: z6.number()
|
|
287
294
|
});
|
|
288
|
-
var BlockBoundWitnessZod = UnsignedBoundWitnessZod.merge(
|
|
289
|
-
var
|
|
290
|
-
var SignedBlockBoundWitnessZod = SignedBoundWitnessZod.merge(StorageMetaZod3.partial()).merge(BlockBoundWitnessFieldsZod).merge(BlockBoundWitnessMetaZod);
|
|
291
|
-
var SignedBlockBoundWitnessWithStorageMetaZod = SignedBoundWitnessWithStorageMetaZod.merge(StorageMetaZod3.partial()).merge(BlockBoundWitnessFieldsZod).merge(BlockBoundWitnessMetaZod);
|
|
292
|
-
|
|
293
|
-
// src/types/schema/common/BlockRange.ts
|
|
294
|
-
import { z as z7 } from "zod";
|
|
295
|
-
var BlockRangeZod = z7.tuple([
|
|
296
|
-
z7.number().optional(),
|
|
297
|
-
z7.number().optional()
|
|
298
|
-
]);
|
|
295
|
+
var BlockBoundWitnessZod = UnsignedBoundWitnessZod.merge(StorageMetaZod2.partial()).merge(BlockBoundWitnessFieldsZod).merge(BlockBoundWitnessMetaZod);
|
|
296
|
+
var SignedBlockBoundWitnessZod = SignedBoundWitnessZod.merge(StorageMetaZod2.partial()).merge(BlockBoundWitnessFieldsZod).merge(BlockBoundWitnessMetaZod);
|
|
299
297
|
|
|
300
298
|
// src/types/schema/common/HydratedBlock.ts
|
|
301
|
-
import
|
|
302
|
-
|
|
299
|
+
import { PayloadZod as PayloadZod2, WithStorageMetaZod } from "@xyo-network/payload-model";
|
|
300
|
+
import * as z7 from "zod";
|
|
301
|
+
var HydratedBlockZod = z7.tuple([
|
|
303
302
|
BlockBoundWitnessZod,
|
|
304
|
-
|
|
303
|
+
z7.array(PayloadZod2)
|
|
305
304
|
]);
|
|
306
|
-
var HydratedBlockWithStorageMetaZod =
|
|
307
|
-
|
|
308
|
-
|
|
305
|
+
var HydratedBlockWithStorageMetaZod = z7.tuple([
|
|
306
|
+
WithStorageMetaZod(BlockBoundWitnessZod),
|
|
307
|
+
z7.array(WithStorageMetaZod(PayloadZod2))
|
|
309
308
|
]);
|
|
310
|
-
var SignedHydratedBlockZod =
|
|
309
|
+
var SignedHydratedBlockZod = z7.tuple([
|
|
311
310
|
SignedBlockBoundWitnessZod,
|
|
312
|
-
|
|
311
|
+
z7.array(PayloadZod2)
|
|
313
312
|
]);
|
|
314
|
-
var SignedHydratedBlockToJsonZod =
|
|
313
|
+
var SignedHydratedBlockToJsonZod = z7.tuple([
|
|
315
314
|
SignedBlockBoundWitnessZod,
|
|
316
|
-
|
|
315
|
+
z7.array(PayloadZod2)
|
|
317
316
|
]);
|
|
318
|
-
var SignedHydratedBlockWithStorageMetaZod =
|
|
319
|
-
|
|
320
|
-
|
|
317
|
+
var SignedHydratedBlockWithStorageMetaZod = z7.tuple([
|
|
318
|
+
WithStorageMetaZod(SignedBlockBoundWitnessZod),
|
|
319
|
+
z7.array(WithStorageMetaZod(PayloadZod2))
|
|
321
320
|
]);
|
|
322
321
|
|
|
323
322
|
// src/types/schema/common/HydratedTransaction.ts
|
|
324
|
-
import { asAnyPayload } from "@xyo-network/payload-model";
|
|
323
|
+
import { asAnyPayload, PayloadZod as PayloadZod3 } from "@xyo-network/payload-model";
|
|
325
324
|
import { asSignedHydratedTransaction } from "@xyo-network/xl1-protocol";
|
|
326
|
-
import * as
|
|
325
|
+
import * as z10 from "zod";
|
|
327
326
|
|
|
328
327
|
// src/types/schema/common/TransactionBoundWitness.ts
|
|
329
|
-
import { StorageMetaZod as
|
|
330
|
-
import
|
|
328
|
+
import { StorageMetaZod as StorageMetaZod3 } from "@xyo-network/payload-model";
|
|
329
|
+
import { BlockNumberZod as BlockNumberZod2 } from "@xyo-network/xl1-protocol";
|
|
330
|
+
import * as z9 from "zod";
|
|
331
331
|
|
|
332
332
|
// src/types/schema/common/TransactionFees.ts
|
|
333
|
-
import { BigIntToJsonZod, HexZod as HexZod2, JsonToBigIntZod } from "@xylabs/hex";
|
|
333
|
+
import { BigIntToJsonZod as BigIntToJsonZod2, HexZod as HexZod2, JsonToBigIntZod as JsonToBigIntZod2 } from "@xylabs/hex";
|
|
334
334
|
import { asAttoXL1 } from "@xyo-network/xl1-protocol";
|
|
335
|
-
import * as
|
|
336
|
-
var AttoZod =
|
|
337
|
-
var JsonToAttoZod =
|
|
338
|
-
var AttoToJsonZod =
|
|
339
|
-
var TransactionFeesHexZod =
|
|
335
|
+
import * as z8 from "zod";
|
|
336
|
+
var AttoZod = z8.bigint();
|
|
337
|
+
var JsonToAttoZod = JsonToBigIntZod2.transform((v) => asAttoXL1(v));
|
|
338
|
+
var AttoToJsonZod = BigIntToJsonZod2;
|
|
339
|
+
var TransactionFeesHexZod = z8.object({
|
|
340
340
|
base: HexZod2,
|
|
341
341
|
gasLimit: HexZod2,
|
|
342
342
|
gasPrice: HexZod2,
|
|
343
343
|
priority: HexZod2
|
|
344
344
|
});
|
|
345
|
-
var TransactionFeesBigIntZod =
|
|
345
|
+
var TransactionFeesBigIntZod = z8.object({
|
|
346
346
|
base: AttoZod,
|
|
347
347
|
gasLimit: AttoZod,
|
|
348
348
|
gasPrice: AttoZod,
|
|
349
349
|
priority: AttoZod
|
|
350
350
|
});
|
|
351
351
|
var TransactionFeesJsonToBigIntZod = TransactionFeesHexZod.transform((val) => ({
|
|
352
|
-
base:
|
|
353
|
-
gasLimit:
|
|
354
|
-
gasPrice:
|
|
355
|
-
priority:
|
|
352
|
+
base: JsonToBigIntZod2.parse(val.base),
|
|
353
|
+
gasLimit: JsonToBigIntZod2.parse(val.gasLimit),
|
|
354
|
+
gasPrice: JsonToBigIntZod2.parse(val.gasPrice),
|
|
355
|
+
priority: JsonToBigIntZod2.parse(val.priority)
|
|
356
356
|
}));
|
|
357
357
|
var TransactionFeesBigIntToJsonZod = TransactionFeesBigIntZod.transform((val) => ({
|
|
358
|
-
base:
|
|
359
|
-
gasLimit:
|
|
360
|
-
gasPrice:
|
|
361
|
-
priority:
|
|
358
|
+
base: BigIntToJsonZod2.parse(val.base),
|
|
359
|
+
gasLimit: BigIntToJsonZod2.parse(val.gasLimit),
|
|
360
|
+
gasPrice: BigIntToJsonZod2.parse(val.gasPrice),
|
|
361
|
+
priority: BigIntToJsonZod2.parse(val.priority)
|
|
362
362
|
}));
|
|
363
363
|
|
|
364
364
|
// src/types/schema/common/TransactionBoundWitness.ts
|
|
365
|
-
var BlockStartZod =
|
|
366
|
-
nbf:
|
|
365
|
+
var BlockStartZod = z9.object({
|
|
366
|
+
nbf: BlockNumberZod2
|
|
367
367
|
});
|
|
368
|
-
var BlockEndZod =
|
|
369
|
-
exp:
|
|
368
|
+
var BlockEndZod = z9.object({
|
|
369
|
+
exp: BlockNumberZod2
|
|
370
370
|
});
|
|
371
|
-
var BlockDurationZod =
|
|
372
|
-
nbf:
|
|
373
|
-
exp:
|
|
371
|
+
var BlockDurationZod = z9.object({
|
|
372
|
+
nbf: BlockNumberZod2,
|
|
373
|
+
exp: BlockNumberZod2
|
|
374
374
|
});
|
|
375
|
-
var BlockScriptsZod =
|
|
376
|
-
script:
|
|
375
|
+
var BlockScriptsZod = z9.object({
|
|
376
|
+
script: z9.array(z9.string()).optional()
|
|
377
377
|
});
|
|
378
|
-
var WithTransactionFeesZod =
|
|
378
|
+
var WithTransactionFeesZod = z9.object({
|
|
379
379
|
fees: TransactionFeesHexZod
|
|
380
380
|
});
|
|
381
|
-
var TransactionBoundWitnessFields =
|
|
381
|
+
var TransactionBoundWitnessFields = z9.object({
|
|
382
382
|
chain: ChainZod,
|
|
383
383
|
from: ChainZod
|
|
384
384
|
});
|
|
385
|
-
var TransactionBoundWitnessZod = UnsignedBoundWitnessZod.merge(
|
|
386
|
-
var SignedTransactionBoundWitnessZod = SignedBoundWitnessZod.merge(
|
|
385
|
+
var TransactionBoundWitnessZod = UnsignedBoundWitnessZod.merge(StorageMetaZod3.partial()).merge(BlockDurationZod).merge(WithTransactionFeesZod).merge(TransactionBoundWitnessFields).merge(BlockScriptsZod);
|
|
386
|
+
var SignedTransactionBoundWitnessZod = SignedBoundWitnessZod.merge(StorageMetaZod3.partial()).merge(BlockDurationZod).merge(WithTransactionFeesZod).merge(TransactionBoundWitnessFields).merge(BlockScriptsZod.partial());
|
|
387
387
|
|
|
388
388
|
// src/types/schema/common/HydratedTransaction.ts
|
|
389
|
-
var HydratedTransactionZod =
|
|
389
|
+
var HydratedTransactionZod = z10.tuple([
|
|
390
390
|
TransactionBoundWitnessZod,
|
|
391
|
-
|
|
391
|
+
z10.array(PayloadZod3)
|
|
392
392
|
]);
|
|
393
|
-
var UnsignedHydratedTransactionZod =
|
|
393
|
+
var UnsignedHydratedTransactionZod = z10.tuple([
|
|
394
394
|
TransactionBoundWitnessZod,
|
|
395
|
-
|
|
395
|
+
z10.array(PayloadZod3)
|
|
396
396
|
]);
|
|
397
|
-
var SignedHydratedTransactionZod =
|
|
397
|
+
var SignedHydratedTransactionZod = z10.tuple([
|
|
398
398
|
SignedTransactionBoundWitnessZod,
|
|
399
|
-
|
|
399
|
+
z10.array(PayloadZod3)
|
|
400
400
|
]);
|
|
401
401
|
var SignedHydratedTransactionToJsonZod = SignedHydratedTransactionZod.transform(([tx, payloads]) => asSignedHydratedTransaction([
|
|
402
402
|
tx,
|
|
@@ -408,98 +408,99 @@ var JsonToSignedHydratedTransactionZod = SignedHydratedTransactionZod.transform(
|
|
|
408
408
|
]);
|
|
409
409
|
|
|
410
410
|
// src/types/schema/common/Json.ts
|
|
411
|
-
import * as
|
|
412
|
-
var JsonValueZod =
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
411
|
+
import * as z11 from "zod";
|
|
412
|
+
var JsonValueZod = z11.lazy(() => z11.union([
|
|
413
|
+
z11.string(),
|
|
414
|
+
z11.number(),
|
|
415
|
+
z11.boolean(),
|
|
416
|
+
z11.null(),
|
|
417
|
+
z11.array(JsonValueZod),
|
|
418
|
+
z11.record(z11.string(), JsonValueZod)
|
|
419
419
|
]));
|
|
420
|
-
var JsonObjectZod =
|
|
420
|
+
var JsonObjectZod = z11.record(z11.string(), JsonValueZod);
|
|
421
421
|
|
|
422
422
|
// src/types/schema/common/Permission.ts
|
|
423
|
-
import { z as
|
|
424
|
-
var CaveatTypesZod =
|
|
423
|
+
import { z as z12 } from "zod";
|
|
424
|
+
var CaveatTypesZod = z12.enum([
|
|
425
425
|
"chain",
|
|
426
426
|
"expiration",
|
|
427
427
|
"filteredResponse",
|
|
428
428
|
"rateLimit",
|
|
429
429
|
"restrictReturnedAccounts"
|
|
430
430
|
]);
|
|
431
|
-
var CaveatsZod =
|
|
431
|
+
var CaveatsZod = z12.object({
|
|
432
432
|
type: CaveatTypesZod,
|
|
433
|
-
value:
|
|
433
|
+
value: z12.json()
|
|
434
434
|
});
|
|
435
|
-
var PermissionZod =
|
|
436
|
-
parentCapability:
|
|
435
|
+
var PermissionZod = z12.object({
|
|
436
|
+
parentCapability: z12.string(),
|
|
437
437
|
caveats: CaveatsZod.array().optional(),
|
|
438
|
-
invoker:
|
|
438
|
+
invoker: z12.string()
|
|
439
439
|
});
|
|
440
440
|
var InvokerPermissionZod = PermissionZod.extend({
|
|
441
|
-
date:
|
|
441
|
+
date: z12.number().optional()
|
|
442
442
|
});
|
|
443
|
-
var PermissionRequestZod =
|
|
444
|
-
var RequestedPermissionZod =
|
|
445
|
-
parentCapability:
|
|
446
|
-
date:
|
|
443
|
+
var PermissionRequestZod = z12.record(z12.string(), z12.record(z12.string(), z12.any()));
|
|
444
|
+
var RequestedPermissionZod = z12.object({
|
|
445
|
+
parentCapability: z12.string(),
|
|
446
|
+
date: z12.number().optional()
|
|
447
447
|
});
|
|
448
448
|
|
|
449
449
|
// src/types/schema/common/RewardsRangeOptions.ts
|
|
450
|
-
import {
|
|
450
|
+
import { BlockRangeZod } from "@xyo-network/xl1-protocol";
|
|
451
|
+
import { z as z14 } from "zod";
|
|
451
452
|
|
|
452
453
|
// src/types/schema/common/StepIdentity.ts
|
|
453
|
-
import * as
|
|
454
|
-
var StepIdentityZod =
|
|
455
|
-
block:
|
|
456
|
-
step:
|
|
454
|
+
import * as z13 from "zod";
|
|
455
|
+
var StepIdentityZod = z13.object({
|
|
456
|
+
block: z13.number(),
|
|
457
|
+
step: z13.number()
|
|
457
458
|
});
|
|
458
459
|
|
|
459
460
|
// src/types/schema/common/RewardsRangeOptions.ts
|
|
460
|
-
var RewardsRangeOptionsZod =
|
|
461
|
-
positions:
|
|
461
|
+
var RewardsRangeOptionsZod = z14.object({
|
|
462
|
+
positions: z14.array(z14.number()).optional(),
|
|
462
463
|
range: BlockRangeZod.optional(),
|
|
463
|
-
steps:
|
|
464
|
-
stakers:
|
|
464
|
+
steps: z14.array(StepIdentityZod).optional(),
|
|
465
|
+
stakers: z14.array(AddressZod).optional()
|
|
465
466
|
});
|
|
466
467
|
|
|
467
468
|
// src/types/schema/common/Sequence.ts
|
|
468
469
|
import { HexRegExMinMax, toHex } from "@xylabs/hex";
|
|
469
470
|
import { SequenceConstants } from "@xyo-network/payload-model";
|
|
470
|
-
import * as
|
|
471
|
+
import * as z15 from "zod";
|
|
471
472
|
var LocalSequenceRegex = new RegExp(HexRegExMinMax(SequenceConstants.localSequenceBytes, SequenceConstants.localSequenceBytes));
|
|
472
|
-
var LocalSequenceToStringZod =
|
|
473
|
-
var LocalSequenceFromStringZod =
|
|
473
|
+
var LocalSequenceToStringZod = z15.string().regex(LocalSequenceRegex);
|
|
474
|
+
var LocalSequenceFromStringZod = z15.string().regex(LocalSequenceRegex).transform((v) => toHex(v));
|
|
474
475
|
var QualifiedSequenceRegex = new RegExp(HexRegExMinMax(SequenceConstants.qualifiedSequenceBytes, SequenceConstants.qualifiedSequenceBytes));
|
|
475
|
-
var QualifiedSequenceToStringZod =
|
|
476
|
-
var QualifiedSequenceFromStringZod =
|
|
477
|
-
var SequenceToStringZod =
|
|
476
|
+
var QualifiedSequenceToStringZod = z15.string().regex(QualifiedSequenceRegex);
|
|
477
|
+
var QualifiedSequenceFromStringZod = z15.string().regex(QualifiedSequenceRegex).transform((v) => toHex(v));
|
|
478
|
+
var SequenceToStringZod = z15.union([
|
|
478
479
|
LocalSequenceToStringZod,
|
|
479
480
|
QualifiedSequenceToStringZod
|
|
480
481
|
]);
|
|
481
|
-
var SequenceFromStringZod =
|
|
482
|
+
var SequenceFromStringZod = z15.union([
|
|
482
483
|
LocalSequenceFromStringZod,
|
|
483
484
|
QualifiedSequenceFromStringZod
|
|
484
485
|
]);
|
|
485
486
|
|
|
486
487
|
// src/types/schema/common/Stake.ts
|
|
487
488
|
import { HexZod as HexZod3 } from "@xylabs/hex";
|
|
488
|
-
import * as
|
|
489
|
-
var StakeZod =
|
|
489
|
+
import * as z16 from "zod";
|
|
490
|
+
var StakeZod = z16.object({
|
|
490
491
|
amount: AttoZod,
|
|
491
492
|
// the block number when the stake was added
|
|
492
|
-
addBlock:
|
|
493
|
+
addBlock: z16.number(),
|
|
493
494
|
// the unique id for the stake item
|
|
494
|
-
id:
|
|
495
|
+
id: z16.number(),
|
|
495
496
|
// the block number when the stake was removed (set to 0 if not removed)
|
|
496
|
-
removeBlock:
|
|
497
|
+
removeBlock: z16.number(),
|
|
497
498
|
// the address that is being staked
|
|
498
499
|
staked: AddressZod,
|
|
499
500
|
// the address that owns the stake
|
|
500
501
|
staker: AddressZod,
|
|
501
502
|
// the block number when the stake was withdrawn (set to 0 if not withdrawn)
|
|
502
|
-
withdrawBlock:
|
|
503
|
+
withdrawBlock: z16.number()
|
|
503
504
|
});
|
|
504
505
|
var StakeToJsonZod = StakeZod.transform((val) => ({
|
|
505
506
|
addBlock: val.addBlock,
|
|
@@ -524,103 +525,77 @@ var JsonToStakeZod = StakeZod.extend({
|
|
|
524
525
|
|
|
525
526
|
// src/types/schema/common/Transfer.ts
|
|
526
527
|
import { HexZod as HexZod4 } from "@xylabs/hex";
|
|
527
|
-
import { PayloadZodStrictOfSchema
|
|
528
|
+
import { PayloadZodStrictOfSchema } from "@xyo-network/payload-model";
|
|
528
529
|
import { TransferSchema } from "@xyo-network/xl1-protocol";
|
|
529
|
-
import
|
|
530
|
-
var TransferFieldsZod =
|
|
531
|
-
$opCodes:
|
|
532
|
-
context:
|
|
533
|
-
epoch:
|
|
530
|
+
import z17 from "zod";
|
|
531
|
+
var TransferFieldsZod = z17.object({
|
|
532
|
+
$opCodes: z17.array(z17.string()).optional(),
|
|
533
|
+
context: z17.record(z17.string(), z17.json()).optional(),
|
|
534
|
+
epoch: z17.number(),
|
|
534
535
|
from: AddressZod,
|
|
535
|
-
transfers:
|
|
536
|
+
transfers: z17.record(AddressZod, HexZod4)
|
|
536
537
|
});
|
|
537
538
|
var TransferZod = PayloadZodStrictOfSchema(TransferSchema).extend(TransferFieldsZod.shape);
|
|
538
|
-
var TransferZodWithStorageMeta = TransferZod.extend(StorageMetaZod5.shape);
|
|
539
539
|
|
|
540
540
|
// src/types/schema/common/TransferPair.ts
|
|
541
|
-
import
|
|
542
|
-
var TransferPairZod =
|
|
541
|
+
import z18 from "zod";
|
|
542
|
+
var TransferPairZod = z18.tuple([
|
|
543
543
|
AddressZod,
|
|
544
544
|
AddressZod
|
|
545
545
|
]);
|
|
546
546
|
|
|
547
|
-
// src/types/schema/NetworkStakeViewerRpcSchemas.ts
|
|
548
|
-
var NetworkStakeViewerRpcSchemas = {
|
|
549
|
-
networkStakeViewer_active: {
|
|
550
|
-
params: {
|
|
551
|
-
from: z20.tuple([
|
|
552
|
-
BlockNumberZod.optional()
|
|
553
|
-
]),
|
|
554
|
-
to: z20.tuple([
|
|
555
|
-
BlockNumberZod.optional()
|
|
556
|
-
])
|
|
557
|
-
},
|
|
558
|
-
result: {
|
|
559
|
-
from: z20.tuple([
|
|
560
|
-
JsonToBigIntZod2,
|
|
561
|
-
z20.number()
|
|
562
|
-
]),
|
|
563
|
-
to: z20.tuple([
|
|
564
|
-
BigIntToJsonZod2,
|
|
565
|
-
z20.number()
|
|
566
|
-
])
|
|
567
|
-
}
|
|
568
|
-
}
|
|
569
|
-
};
|
|
570
|
-
|
|
571
547
|
// src/types/schema/XyoPermissionsRpcSchemas.ts
|
|
572
|
-
import * as z21 from "zod";
|
|
573
548
|
var XyoPermissionsRpcSchemas = {
|
|
574
549
|
xyoPermissions_getPermissions: {
|
|
575
550
|
params: {
|
|
576
|
-
to:
|
|
577
|
-
from:
|
|
551
|
+
to: z19.array(z19.any()).length(0),
|
|
552
|
+
from: z19.array(z19.any()).length(0)
|
|
578
553
|
},
|
|
579
554
|
result: {
|
|
580
|
-
to:
|
|
581
|
-
from:
|
|
555
|
+
to: z19.array(InvokerPermissionZod),
|
|
556
|
+
from: z19.array(InvokerPermissionZod)
|
|
582
557
|
}
|
|
583
558
|
},
|
|
584
559
|
xyoPermissions_requestPermissions: {
|
|
585
560
|
params: {
|
|
586
|
-
to:
|
|
587
|
-
|
|
561
|
+
to: z19.tuple([
|
|
562
|
+
z19.array(PermissionRequestZod)
|
|
588
563
|
]),
|
|
589
|
-
from:
|
|
590
|
-
|
|
564
|
+
from: z19.tuple([
|
|
565
|
+
z19.array(PermissionRequestZod)
|
|
591
566
|
])
|
|
592
567
|
},
|
|
593
568
|
result: {
|
|
594
|
-
to:
|
|
595
|
-
from:
|
|
569
|
+
to: z19.array(RequestedPermissionZod),
|
|
570
|
+
from: z19.array(RequestedPermissionZod)
|
|
596
571
|
}
|
|
597
572
|
},
|
|
598
573
|
xyoPermissions_revokePermissions: {
|
|
599
574
|
params: {
|
|
600
|
-
to:
|
|
601
|
-
|
|
575
|
+
to: z19.tuple([
|
|
576
|
+
z19.array(PermissionRequestZod)
|
|
602
577
|
]),
|
|
603
|
-
from:
|
|
604
|
-
|
|
578
|
+
from: z19.tuple([
|
|
579
|
+
z19.array(PermissionRequestZod)
|
|
605
580
|
])
|
|
606
581
|
},
|
|
607
582
|
result: {
|
|
608
|
-
to:
|
|
609
|
-
from:
|
|
583
|
+
to: z19.array(RequestedPermissionZod),
|
|
584
|
+
from: z19.array(RequestedPermissionZod)
|
|
610
585
|
}
|
|
611
586
|
}
|
|
612
587
|
};
|
|
613
588
|
|
|
614
589
|
// src/types/schema/XyoRunnerRpcSchemas.ts
|
|
615
590
|
import { HashToJsonZod, JsonToHashZod } from "@xylabs/hex";
|
|
616
|
-
import * as
|
|
591
|
+
import * as z20 from "zod";
|
|
617
592
|
var XyoRunnerRpcSchemas = {
|
|
618
593
|
xyoRunner_broadcastTransaction: {
|
|
619
594
|
params: {
|
|
620
|
-
to:
|
|
595
|
+
to: z20.tuple([
|
|
621
596
|
SignedHydratedTransactionZod
|
|
622
597
|
]),
|
|
623
|
-
from:
|
|
598
|
+
from: z20.tuple([
|
|
624
599
|
SignedHydratedTransactionZod
|
|
625
600
|
])
|
|
626
601
|
},
|
|
@@ -633,12 +608,12 @@ var XyoRunnerRpcSchemas = {
|
|
|
633
608
|
|
|
634
609
|
// src/types/schema/XyoSignerRpcSchemas.ts
|
|
635
610
|
import { asHydratedTransactionWithStorageMeta } from "@xyo-network/xl1-protocol";
|
|
636
|
-
import { z as
|
|
611
|
+
import { z as z21 } from "zod";
|
|
637
612
|
var XyoSignerRpcSchemas = {
|
|
638
613
|
xyoSigner_address: {
|
|
639
614
|
params: {
|
|
640
|
-
to:
|
|
641
|
-
from:
|
|
615
|
+
to: z21.array(z21.any()).length(0).optional(),
|
|
616
|
+
from: z21.array(z21.any()).length(0).optional()
|
|
642
617
|
},
|
|
643
618
|
result: {
|
|
644
619
|
to: AddressZod,
|
|
@@ -647,10 +622,10 @@ var XyoSignerRpcSchemas = {
|
|
|
647
622
|
},
|
|
648
623
|
xyoSigner_signTransaction: {
|
|
649
624
|
params: {
|
|
650
|
-
to:
|
|
625
|
+
to: z21.tuple([
|
|
651
626
|
UnsignedHydratedTransactionZod
|
|
652
627
|
]),
|
|
653
|
-
from:
|
|
628
|
+
from: z21.tuple([
|
|
654
629
|
UnsignedHydratedTransactionZod
|
|
655
630
|
])
|
|
656
631
|
},
|
|
@@ -665,14 +640,16 @@ var XyoSignerRpcSchemas = {
|
|
|
665
640
|
|
|
666
641
|
// src/types/schema/XyoViewerRpcSchemas.ts
|
|
667
642
|
import { BigIntToJsonZod as BigIntToJsonZod3, HashToJsonZod as HashToJsonZod2, HashZod as HashZod3, JsonToBigIntZod as JsonToBigIntZod3, JsonToHashZod as JsonToHashZod2 } from "@xylabs/hex";
|
|
668
|
-
import
|
|
643
|
+
import { PayloadZod as PayloadZod4, WithHashMetaZod } from "@xyo-network/payload-model";
|
|
644
|
+
import { BlockNumberZod as BlockNumberZod3, BlockRangeZod as BlockRangeZod2, StepIdentityZod as StepIdentityZod2, XL1BlockRangeZod } from "@xyo-network/xl1-protocol";
|
|
645
|
+
import * as z22 from "zod";
|
|
669
646
|
var XyoViewerRpcSchemas = {
|
|
670
647
|
xyoViewer_networkStakeStepRewardClaimedByAddress: {
|
|
671
648
|
params: {
|
|
672
|
-
to:
|
|
649
|
+
to: z22.tuple([
|
|
673
650
|
AddressZod
|
|
674
651
|
]),
|
|
675
|
-
from:
|
|
652
|
+
from: z22.tuple([
|
|
676
653
|
AddressZod
|
|
677
654
|
])
|
|
678
655
|
},
|
|
@@ -683,51 +660,51 @@ var XyoViewerRpcSchemas = {
|
|
|
683
660
|
},
|
|
684
661
|
xyoViewer_networkStakeStepRewardAddressReward: {
|
|
685
662
|
params: {
|
|
686
|
-
to:
|
|
687
|
-
|
|
663
|
+
to: z22.tuple([
|
|
664
|
+
StepIdentityZod2,
|
|
688
665
|
AddressZod
|
|
689
666
|
]),
|
|
690
|
-
from:
|
|
691
|
-
|
|
667
|
+
from: z22.tuple([
|
|
668
|
+
StepIdentityZod2,
|
|
692
669
|
AddressZod
|
|
693
670
|
])
|
|
694
671
|
},
|
|
695
672
|
result: {
|
|
696
|
-
to:
|
|
697
|
-
from:
|
|
673
|
+
to: z22.record(AddressZod, BigIntToJsonZod3),
|
|
674
|
+
from: z22.record(AddressZod, JsonToBigIntZod3)
|
|
698
675
|
}
|
|
699
676
|
},
|
|
700
677
|
xyoViewer_networkStakeStepRewardAddressHistory: {
|
|
701
678
|
params: {
|
|
702
|
-
to:
|
|
679
|
+
to: z22.tuple([
|
|
703
680
|
AddressZod
|
|
704
681
|
]),
|
|
705
|
-
from:
|
|
682
|
+
from: z22.tuple([
|
|
706
683
|
AddressZod
|
|
707
684
|
])
|
|
708
685
|
},
|
|
709
686
|
result: {
|
|
710
|
-
to:
|
|
711
|
-
from:
|
|
687
|
+
to: z22.record(AddressZod, BigIntToJsonZod3),
|
|
688
|
+
from: z22.record(AddressZod, JsonToBigIntZod3)
|
|
712
689
|
}
|
|
713
690
|
},
|
|
714
691
|
xyoViewer_networkStakeStepRewardAddressShare: {
|
|
715
692
|
params: {
|
|
716
|
-
to:
|
|
717
|
-
|
|
693
|
+
to: z22.tuple([
|
|
694
|
+
StepIdentityZod2,
|
|
718
695
|
AddressZod
|
|
719
696
|
]),
|
|
720
|
-
from:
|
|
721
|
-
|
|
697
|
+
from: z22.tuple([
|
|
698
|
+
StepIdentityZod2,
|
|
722
699
|
AddressZod
|
|
723
700
|
])
|
|
724
701
|
},
|
|
725
702
|
result: {
|
|
726
|
-
to:
|
|
703
|
+
to: z22.tuple([
|
|
727
704
|
BigIntToJsonZod3,
|
|
728
705
|
BigIntToJsonZod3
|
|
729
706
|
]),
|
|
730
|
-
from:
|
|
707
|
+
from: z22.tuple([
|
|
731
708
|
JsonToBigIntZod3,
|
|
732
709
|
JsonToBigIntZod3
|
|
733
710
|
])
|
|
@@ -735,12 +712,12 @@ var XyoViewerRpcSchemas = {
|
|
|
735
712
|
},
|
|
736
713
|
xyoViewer_networkStakeStepRewardWeightForAddress: {
|
|
737
714
|
params: {
|
|
738
|
-
to:
|
|
739
|
-
|
|
715
|
+
to: z22.tuple([
|
|
716
|
+
StepIdentityZod2,
|
|
740
717
|
AddressZod
|
|
741
718
|
]),
|
|
742
|
-
from:
|
|
743
|
-
|
|
719
|
+
from: z22.tuple([
|
|
720
|
+
StepIdentityZod2,
|
|
744
721
|
AddressZod
|
|
745
722
|
])
|
|
746
723
|
},
|
|
@@ -751,10 +728,10 @@ var XyoViewerRpcSchemas = {
|
|
|
751
728
|
},
|
|
752
729
|
xyoViewer_networkStakeStepRewardUnclaimedByAddress: {
|
|
753
730
|
params: {
|
|
754
|
-
to:
|
|
731
|
+
to: z22.tuple([
|
|
755
732
|
AddressZod
|
|
756
733
|
]),
|
|
757
|
-
from:
|
|
734
|
+
from: z22.tuple([
|
|
758
735
|
AddressZod
|
|
759
736
|
])
|
|
760
737
|
},
|
|
@@ -765,27 +742,27 @@ var XyoViewerRpcSchemas = {
|
|
|
765
742
|
},
|
|
766
743
|
xyoViewer_networkStakeStepRewardPoolRewards: {
|
|
767
744
|
params: {
|
|
768
|
-
to:
|
|
769
|
-
|
|
745
|
+
to: z22.tuple([
|
|
746
|
+
StepIdentityZod2
|
|
770
747
|
]),
|
|
771
|
-
from:
|
|
772
|
-
|
|
748
|
+
from: z22.tuple([
|
|
749
|
+
StepIdentityZod2
|
|
773
750
|
])
|
|
774
751
|
},
|
|
775
752
|
result: {
|
|
776
|
-
to:
|
|
777
|
-
from:
|
|
753
|
+
to: z22.record(AddressZod, BigIntToJsonZod3),
|
|
754
|
+
from: z22.record(AddressZod, JsonToBigIntZod3)
|
|
778
755
|
}
|
|
779
756
|
},
|
|
780
757
|
xyoViewer_networkStakeStepRewardPositionWeight: {
|
|
781
758
|
params: {
|
|
782
|
-
to:
|
|
783
|
-
|
|
784
|
-
|
|
759
|
+
to: z22.tuple([
|
|
760
|
+
StepIdentityZod2,
|
|
761
|
+
z22.number()
|
|
785
762
|
]),
|
|
786
|
-
from:
|
|
787
|
-
|
|
788
|
-
|
|
763
|
+
from: z22.tuple([
|
|
764
|
+
StepIdentityZod2,
|
|
765
|
+
z22.number()
|
|
789
766
|
])
|
|
790
767
|
},
|
|
791
768
|
result: {
|
|
@@ -795,13 +772,13 @@ var XyoViewerRpcSchemas = {
|
|
|
795
772
|
},
|
|
796
773
|
xyoViewer_networkStakeStepRewardPotentialPositionLoss: {
|
|
797
774
|
params: {
|
|
798
|
-
to:
|
|
799
|
-
|
|
800
|
-
|
|
775
|
+
to: z22.tuple([
|
|
776
|
+
StepIdentityZod2,
|
|
777
|
+
z22.number()
|
|
801
778
|
]),
|
|
802
|
-
from:
|
|
803
|
-
|
|
804
|
-
|
|
779
|
+
from: z22.tuple([
|
|
780
|
+
StepIdentityZod2,
|
|
781
|
+
z22.number()
|
|
805
782
|
])
|
|
806
783
|
},
|
|
807
784
|
result: {
|
|
@@ -811,11 +788,11 @@ var XyoViewerRpcSchemas = {
|
|
|
811
788
|
},
|
|
812
789
|
xyoViewer_networkStakeStepRewardForStep: {
|
|
813
790
|
params: {
|
|
814
|
-
to:
|
|
815
|
-
|
|
791
|
+
to: z22.tuple([
|
|
792
|
+
StepIdentityZod2
|
|
816
793
|
]),
|
|
817
|
-
from:
|
|
818
|
-
|
|
794
|
+
from: z22.tuple([
|
|
795
|
+
StepIdentityZod2
|
|
819
796
|
])
|
|
820
797
|
},
|
|
821
798
|
result: {
|
|
@@ -825,11 +802,11 @@ var XyoViewerRpcSchemas = {
|
|
|
825
802
|
},
|
|
826
803
|
xyoViewer_networkStakeStepRewardRandomizer: {
|
|
827
804
|
params: {
|
|
828
|
-
to:
|
|
829
|
-
|
|
805
|
+
to: z22.tuple([
|
|
806
|
+
StepIdentityZod2
|
|
830
807
|
]),
|
|
831
|
-
from:
|
|
832
|
-
|
|
808
|
+
from: z22.tuple([
|
|
809
|
+
StepIdentityZod2
|
|
833
810
|
])
|
|
834
811
|
},
|
|
835
812
|
result: {
|
|
@@ -839,49 +816,49 @@ var XyoViewerRpcSchemas = {
|
|
|
839
816
|
},
|
|
840
817
|
xyoViewer_networkStakeStepRewardStakerCount: {
|
|
841
818
|
params: {
|
|
842
|
-
to:
|
|
843
|
-
|
|
819
|
+
to: z22.tuple([
|
|
820
|
+
StepIdentityZod2
|
|
844
821
|
]),
|
|
845
|
-
from:
|
|
846
|
-
|
|
822
|
+
from: z22.tuple([
|
|
823
|
+
StepIdentityZod2
|
|
847
824
|
])
|
|
848
825
|
},
|
|
849
826
|
result: {
|
|
850
|
-
to:
|
|
851
|
-
from:
|
|
827
|
+
to: z22.number(),
|
|
828
|
+
from: z22.number()
|
|
852
829
|
}
|
|
853
830
|
},
|
|
854
831
|
xyoViewer_networkStakeStepRewardPoolShares: {
|
|
855
832
|
params: {
|
|
856
|
-
to:
|
|
857
|
-
|
|
833
|
+
to: z22.tuple([
|
|
834
|
+
StepIdentityZod2
|
|
858
835
|
]),
|
|
859
|
-
from:
|
|
860
|
-
|
|
836
|
+
from: z22.tuple([
|
|
837
|
+
StepIdentityZod2
|
|
861
838
|
])
|
|
862
839
|
},
|
|
863
840
|
result: {
|
|
864
|
-
to:
|
|
865
|
-
from:
|
|
841
|
+
to: z22.record(AddressZod, BigIntToJsonZod3),
|
|
842
|
+
from: z22.record(AddressZod, JsonToBigIntZod3)
|
|
866
843
|
}
|
|
867
844
|
},
|
|
868
845
|
xyoViewer_networkStakeStepRewardForStepForPosition: {
|
|
869
846
|
params: {
|
|
870
|
-
to:
|
|
871
|
-
|
|
872
|
-
|
|
847
|
+
to: z22.tuple([
|
|
848
|
+
StepIdentityZod2,
|
|
849
|
+
z22.number()
|
|
873
850
|
]),
|
|
874
|
-
from:
|
|
875
|
-
|
|
876
|
-
|
|
851
|
+
from: z22.tuple([
|
|
852
|
+
StepIdentityZod2,
|
|
853
|
+
z22.number()
|
|
877
854
|
])
|
|
878
855
|
},
|
|
879
856
|
result: {
|
|
880
|
-
to:
|
|
857
|
+
to: z22.tuple([
|
|
881
858
|
BigIntToJsonZod3,
|
|
882
859
|
BigIntToJsonZod3
|
|
883
860
|
]),
|
|
884
|
-
from:
|
|
861
|
+
from: z22.tuple([
|
|
885
862
|
JsonToBigIntZod3,
|
|
886
863
|
JsonToBigIntZod3
|
|
887
864
|
])
|
|
@@ -889,27 +866,27 @@ var XyoViewerRpcSchemas = {
|
|
|
889
866
|
},
|
|
890
867
|
xyoViewer_networkStakeStepRewardForPosition: {
|
|
891
868
|
params: {
|
|
892
|
-
to:
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
869
|
+
to: z22.tuple([
|
|
870
|
+
z22.number(),
|
|
871
|
+
z22.tuple([
|
|
872
|
+
z22.number(),
|
|
873
|
+
z22.number()
|
|
897
874
|
])
|
|
898
875
|
]),
|
|
899
|
-
from:
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
876
|
+
from: z22.tuple([
|
|
877
|
+
z22.number(),
|
|
878
|
+
z22.tuple([
|
|
879
|
+
z22.number(),
|
|
880
|
+
z22.number()
|
|
904
881
|
])
|
|
905
882
|
])
|
|
906
883
|
},
|
|
907
884
|
result: {
|
|
908
|
-
to:
|
|
885
|
+
to: z22.tuple([
|
|
909
886
|
BigIntToJsonZod3,
|
|
910
887
|
BigIntToJsonZod3
|
|
911
888
|
]),
|
|
912
|
-
from:
|
|
889
|
+
from: z22.tuple([
|
|
913
890
|
JsonToBigIntZod3,
|
|
914
891
|
JsonToBigIntZod3
|
|
915
892
|
])
|
|
@@ -917,16 +894,16 @@ var XyoViewerRpcSchemas = {
|
|
|
917
894
|
},
|
|
918
895
|
xyoViewer_networkStakeStepRewardsForRange: {
|
|
919
896
|
params: {
|
|
920
|
-
to:
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
897
|
+
to: z22.tuple([
|
|
898
|
+
z22.tuple([
|
|
899
|
+
z22.number(),
|
|
900
|
+
z22.number()
|
|
924
901
|
])
|
|
925
902
|
]),
|
|
926
|
-
from:
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
903
|
+
from: z22.tuple([
|
|
904
|
+
z22.tuple([
|
|
905
|
+
z22.number(),
|
|
906
|
+
z22.number()
|
|
930
907
|
])
|
|
931
908
|
])
|
|
932
909
|
},
|
|
@@ -937,18 +914,18 @@ var XyoViewerRpcSchemas = {
|
|
|
937
914
|
},
|
|
938
915
|
xyoViewer_networkStakeStepRewardsForStepLevel: {
|
|
939
916
|
params: {
|
|
940
|
-
to:
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
917
|
+
to: z22.tuple([
|
|
918
|
+
z22.number(),
|
|
919
|
+
z22.tuple([
|
|
920
|
+
z22.number(),
|
|
921
|
+
z22.number()
|
|
945
922
|
])
|
|
946
923
|
]),
|
|
947
|
-
from:
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
924
|
+
from: z22.tuple([
|
|
925
|
+
z22.number(),
|
|
926
|
+
z22.tuple([
|
|
927
|
+
z22.number(),
|
|
928
|
+
z22.number()
|
|
952
929
|
])
|
|
953
930
|
])
|
|
954
931
|
},
|
|
@@ -959,27 +936,27 @@ var XyoViewerRpcSchemas = {
|
|
|
959
936
|
},
|
|
960
937
|
xyoViewer_networkStakeStepRewardsForPosition: {
|
|
961
938
|
params: {
|
|
962
|
-
to:
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
939
|
+
to: z22.tuple([
|
|
940
|
+
z22.number(),
|
|
941
|
+
z22.tuple([
|
|
942
|
+
z22.number(),
|
|
943
|
+
z22.number()
|
|
967
944
|
])
|
|
968
945
|
]),
|
|
969
|
-
from:
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
946
|
+
from: z22.tuple([
|
|
947
|
+
z22.number(),
|
|
948
|
+
z22.tuple([
|
|
949
|
+
z22.number(),
|
|
950
|
+
z22.number()
|
|
974
951
|
])
|
|
975
952
|
])
|
|
976
953
|
},
|
|
977
954
|
result: {
|
|
978
|
-
to:
|
|
955
|
+
to: z22.record(z22.string(), z22.tuple([
|
|
979
956
|
BigIntToJsonZod3,
|
|
980
957
|
BigIntToJsonZod3
|
|
981
958
|
])),
|
|
982
|
-
from:
|
|
959
|
+
from: z22.record(z22.string(), z22.tuple([
|
|
983
960
|
JsonToBigIntZod3,
|
|
984
961
|
JsonToBigIntZod3
|
|
985
962
|
]))
|
|
@@ -987,10 +964,10 @@ var XyoViewerRpcSchemas = {
|
|
|
987
964
|
},
|
|
988
965
|
xyoViewer_accountBalance: {
|
|
989
966
|
params: {
|
|
990
|
-
to:
|
|
967
|
+
to: z22.tuple([
|
|
991
968
|
AddressZod
|
|
992
969
|
]),
|
|
993
|
-
from:
|
|
970
|
+
from: z22.tuple([
|
|
994
971
|
AddressZod
|
|
995
972
|
])
|
|
996
973
|
},
|
|
@@ -1001,34 +978,40 @@ var XyoViewerRpcSchemas = {
|
|
|
1001
978
|
},
|
|
1002
979
|
xyoViewer_accountBalanceHistory: {
|
|
1003
980
|
params: {
|
|
1004
|
-
to:
|
|
981
|
+
to: z22.tuple([
|
|
1005
982
|
AddressZod,
|
|
1006
|
-
|
|
983
|
+
z22.union([
|
|
984
|
+
XL1BlockRangeZod,
|
|
985
|
+
HashZod3
|
|
986
|
+
]).optional()
|
|
1007
987
|
]),
|
|
1008
|
-
from:
|
|
988
|
+
from: z22.tuple([
|
|
1009
989
|
AddressZod,
|
|
1010
|
-
|
|
990
|
+
z22.union([
|
|
991
|
+
XL1BlockRangeZod,
|
|
992
|
+
HashZod3
|
|
993
|
+
]).optional()
|
|
1011
994
|
])
|
|
1012
995
|
},
|
|
1013
996
|
result: {
|
|
1014
|
-
to:
|
|
1015
|
-
BlockBoundWitnessZod,
|
|
1016
|
-
TransactionBoundWitnessZod.nullable(),
|
|
1017
|
-
|
|
997
|
+
to: z22.array(z22.tuple([
|
|
998
|
+
WithHashMetaZod(BlockBoundWitnessZod),
|
|
999
|
+
WithHashMetaZod(TransactionBoundWitnessZod).nullable(),
|
|
1000
|
+
WithHashMetaZod(TransferZod)
|
|
1018
1001
|
])),
|
|
1019
|
-
from:
|
|
1020
|
-
BlockBoundWitnessZod,
|
|
1021
|
-
TransactionBoundWitnessZod.nullable(),
|
|
1022
|
-
|
|
1002
|
+
from: z22.array(z22.tuple([
|
|
1003
|
+
WithHashMetaZod(BlockBoundWitnessZod),
|
|
1004
|
+
WithHashMetaZod(TransactionBoundWitnessZod).nullable(),
|
|
1005
|
+
WithHashMetaZod(TransferZod)
|
|
1023
1006
|
]))
|
|
1024
1007
|
}
|
|
1025
1008
|
},
|
|
1026
1009
|
xyoViewer_transferPairBalance: {
|
|
1027
1010
|
params: {
|
|
1028
|
-
to:
|
|
1011
|
+
to: z22.tuple([
|
|
1029
1012
|
TransferPairZod
|
|
1030
1013
|
]),
|
|
1031
|
-
from:
|
|
1014
|
+
from: z22.tuple([
|
|
1032
1015
|
TransferPairZod
|
|
1033
1016
|
])
|
|
1034
1017
|
},
|
|
@@ -1039,38 +1022,32 @@ var XyoViewerRpcSchemas = {
|
|
|
1039
1022
|
},
|
|
1040
1023
|
xyoViewer_transferPairBalanceHistory: {
|
|
1041
1024
|
params: {
|
|
1042
|
-
to:
|
|
1025
|
+
to: z22.tuple([
|
|
1043
1026
|
TransferPairZod
|
|
1044
1027
|
]),
|
|
1045
|
-
from:
|
|
1028
|
+
from: z22.tuple([
|
|
1046
1029
|
TransferPairZod
|
|
1047
1030
|
])
|
|
1048
1031
|
},
|
|
1049
1032
|
result: {
|
|
1050
|
-
to:
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
z24.null()
|
|
1055
|
-
]),
|
|
1056
|
-
PayloadZod
|
|
1033
|
+
to: z22.array(z22.tuple([
|
|
1034
|
+
WithHashMetaZod(BlockBoundWitnessZod),
|
|
1035
|
+
WithHashMetaZod(TransactionBoundWitnessZod).nullable(),
|
|
1036
|
+
WithHashMetaZod(PayloadZod4)
|
|
1057
1037
|
])),
|
|
1058
|
-
from:
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
z24.null()
|
|
1063
|
-
]),
|
|
1064
|
-
PayloadZod
|
|
1038
|
+
from: z22.array(z22.tuple([
|
|
1039
|
+
WithHashMetaZod(BlockBoundWitnessZod),
|
|
1040
|
+
WithHashMetaZod(TransactionBoundWitnessZod).nullable(),
|
|
1041
|
+
WithHashMetaZod(PayloadZod4)
|
|
1065
1042
|
]))
|
|
1066
1043
|
}
|
|
1067
1044
|
},
|
|
1068
1045
|
xyoViewer_transferBalance: {
|
|
1069
1046
|
params: {
|
|
1070
|
-
to:
|
|
1047
|
+
to: z22.tuple([
|
|
1071
1048
|
AddressZod
|
|
1072
1049
|
]),
|
|
1073
|
-
from:
|
|
1050
|
+
from: z22.tuple([
|
|
1074
1051
|
AddressZod
|
|
1075
1052
|
])
|
|
1076
1053
|
},
|
|
@@ -1081,40 +1058,34 @@ var XyoViewerRpcSchemas = {
|
|
|
1081
1058
|
},
|
|
1082
1059
|
xyoViewer_transferBalanceHistory: {
|
|
1083
1060
|
params: {
|
|
1084
|
-
to:
|
|
1061
|
+
to: z22.tuple([
|
|
1085
1062
|
AddressZod,
|
|
1086
|
-
|
|
1063
|
+
BlockRangeZod2.optional()
|
|
1087
1064
|
]),
|
|
1088
|
-
from:
|
|
1065
|
+
from: z22.tuple([
|
|
1089
1066
|
AddressZod,
|
|
1090
|
-
|
|
1067
|
+
BlockRangeZod2.optional()
|
|
1091
1068
|
])
|
|
1092
1069
|
},
|
|
1093
1070
|
result: {
|
|
1094
|
-
to:
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
z24.null()
|
|
1099
|
-
]),
|
|
1100
|
-
PayloadZod
|
|
1071
|
+
to: z22.array(z22.tuple([
|
|
1072
|
+
WithHashMetaZod(BlockBoundWitnessZod),
|
|
1073
|
+
WithHashMetaZod(TransactionBoundWitnessZod).nullable(),
|
|
1074
|
+
WithHashMetaZod(PayloadZod4)
|
|
1101
1075
|
])),
|
|
1102
|
-
from:
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
z24.null()
|
|
1107
|
-
]),
|
|
1108
|
-
PayloadZod
|
|
1076
|
+
from: z22.array(z22.tuple([
|
|
1077
|
+
WithHashMetaZod(BlockBoundWitnessZod),
|
|
1078
|
+
WithHashMetaZod(TransactionBoundWitnessZod).nullable(),
|
|
1079
|
+
WithHashMetaZod(PayloadZod4)
|
|
1109
1080
|
]))
|
|
1110
1081
|
}
|
|
1111
1082
|
},
|
|
1112
1083
|
xyoViewer_blockByHash: {
|
|
1113
1084
|
params: {
|
|
1114
|
-
to:
|
|
1085
|
+
to: z22.tuple([
|
|
1115
1086
|
HashToJsonZod2
|
|
1116
1087
|
]),
|
|
1117
|
-
from:
|
|
1088
|
+
from: z22.tuple([
|
|
1118
1089
|
JsonToHashZod2
|
|
1119
1090
|
])
|
|
1120
1091
|
},
|
|
@@ -1125,11 +1096,11 @@ var XyoViewerRpcSchemas = {
|
|
|
1125
1096
|
},
|
|
1126
1097
|
xyoViewer_blockByNumber: {
|
|
1127
1098
|
params: {
|
|
1128
|
-
to:
|
|
1129
|
-
|
|
1099
|
+
to: z22.tuple([
|
|
1100
|
+
z22.number()
|
|
1130
1101
|
]),
|
|
1131
|
-
from:
|
|
1132
|
-
|
|
1102
|
+
from: z22.tuple([
|
|
1103
|
+
z22.number()
|
|
1133
1104
|
])
|
|
1134
1105
|
},
|
|
1135
1106
|
result: {
|
|
@@ -1139,24 +1110,24 @@ var XyoViewerRpcSchemas = {
|
|
|
1139
1110
|
},
|
|
1140
1111
|
xyoViewer_blocksByHash: {
|
|
1141
1112
|
params: {
|
|
1142
|
-
to:
|
|
1113
|
+
to: z22.tuple([
|
|
1143
1114
|
HashZod3,
|
|
1144
|
-
|
|
1115
|
+
z22.number().optional()
|
|
1145
1116
|
]),
|
|
1146
|
-
from:
|
|
1117
|
+
from: z22.tuple([
|
|
1147
1118
|
HashZod3,
|
|
1148
|
-
|
|
1119
|
+
z22.number().optional()
|
|
1149
1120
|
])
|
|
1150
1121
|
},
|
|
1151
1122
|
result: {
|
|
1152
|
-
to:
|
|
1153
|
-
from:
|
|
1123
|
+
to: z22.array(SignedHydratedBlockZod),
|
|
1124
|
+
from: z22.array(SignedHydratedBlockZod)
|
|
1154
1125
|
}
|
|
1155
1126
|
},
|
|
1156
1127
|
xyoViewer_chainId: {
|
|
1157
1128
|
params: {
|
|
1158
|
-
to:
|
|
1159
|
-
from:
|
|
1129
|
+
to: z22.array(z22.any()).length(0).optional(),
|
|
1130
|
+
from: z22.array(z22.any()).length(0).optional()
|
|
1160
1131
|
},
|
|
1161
1132
|
result: {
|
|
1162
1133
|
to: AddressZod,
|
|
@@ -1165,11 +1136,11 @@ var XyoViewerRpcSchemas = {
|
|
|
1165
1136
|
},
|
|
1166
1137
|
xyoViewer_chainIdAtBlock: {
|
|
1167
1138
|
params: {
|
|
1168
|
-
to:
|
|
1169
|
-
|
|
1139
|
+
to: z22.tuple([
|
|
1140
|
+
BlockNumberZod3
|
|
1170
1141
|
]),
|
|
1171
|
-
from:
|
|
1172
|
-
|
|
1142
|
+
from: z22.tuple([
|
|
1143
|
+
BlockNumberZod3
|
|
1173
1144
|
])
|
|
1174
1145
|
},
|
|
1175
1146
|
result: {
|
|
@@ -1179,8 +1150,8 @@ var XyoViewerRpcSchemas = {
|
|
|
1179
1150
|
},
|
|
1180
1151
|
xyoViewer_currentBlock: {
|
|
1181
1152
|
params: {
|
|
1182
|
-
to:
|
|
1183
|
-
from:
|
|
1153
|
+
to: z22.array(z22.any()).length(0).optional(),
|
|
1154
|
+
from: z22.array(z22.any()).length(0).optional()
|
|
1184
1155
|
},
|
|
1185
1156
|
result: {
|
|
1186
1157
|
to: SignedHydratedBlockZod,
|
|
@@ -1189,8 +1160,8 @@ var XyoViewerRpcSchemas = {
|
|
|
1189
1160
|
},
|
|
1190
1161
|
xyoViewer_currentBlockHash: {
|
|
1191
1162
|
params: {
|
|
1192
|
-
to:
|
|
1193
|
-
from:
|
|
1163
|
+
to: z22.array(z22.any()).length(0).optional(),
|
|
1164
|
+
from: z22.array(z22.any()).length(0).optional()
|
|
1194
1165
|
},
|
|
1195
1166
|
result: {
|
|
1196
1167
|
to: HashZod3,
|
|
@@ -1199,33 +1170,33 @@ var XyoViewerRpcSchemas = {
|
|
|
1199
1170
|
},
|
|
1200
1171
|
xyoViewer_currentBlockNumber: {
|
|
1201
1172
|
params: {
|
|
1202
|
-
to:
|
|
1203
|
-
from:
|
|
1173
|
+
to: z22.array(z22.any()).length(0).optional(),
|
|
1174
|
+
from: z22.array(z22.any()).length(0).optional()
|
|
1204
1175
|
},
|
|
1205
1176
|
result: {
|
|
1206
|
-
to:
|
|
1207
|
-
from:
|
|
1177
|
+
to: BlockNumberZod3,
|
|
1178
|
+
from: BlockNumberZod3
|
|
1208
1179
|
}
|
|
1209
1180
|
},
|
|
1210
1181
|
xyoViewer_forkHistory: {
|
|
1211
1182
|
params: {
|
|
1212
|
-
to:
|
|
1213
|
-
from:
|
|
1183
|
+
to: z22.array(z22.any()).length(0).optional(),
|
|
1184
|
+
from: z22.array(z22.any()).length(0).optional()
|
|
1214
1185
|
},
|
|
1215
1186
|
result: {
|
|
1216
|
-
to:
|
|
1217
|
-
from:
|
|
1187
|
+
to: z22.record(z22.number(), AddressZod),
|
|
1188
|
+
from: z22.record(z22.number(), AddressZod)
|
|
1218
1189
|
}
|
|
1219
1190
|
},
|
|
1220
1191
|
xyoViewer_stakeByStaker: {
|
|
1221
1192
|
params: {
|
|
1222
|
-
to:
|
|
1193
|
+
to: z22.tuple([
|
|
1223
1194
|
AddressZod,
|
|
1224
|
-
|
|
1195
|
+
z22.number()
|
|
1225
1196
|
]),
|
|
1226
|
-
from:
|
|
1197
|
+
from: z22.tuple([
|
|
1227
1198
|
AddressZod,
|
|
1228
|
-
|
|
1199
|
+
z22.number()
|
|
1229
1200
|
])
|
|
1230
1201
|
},
|
|
1231
1202
|
result: {
|
|
@@ -1235,11 +1206,11 @@ var XyoViewerRpcSchemas = {
|
|
|
1235
1206
|
},
|
|
1236
1207
|
xyoViewer_stakeById: {
|
|
1237
1208
|
params: {
|
|
1238
|
-
to:
|
|
1239
|
-
|
|
1209
|
+
to: z22.tuple([
|
|
1210
|
+
z22.number()
|
|
1240
1211
|
]),
|
|
1241
|
-
from:
|
|
1242
|
-
|
|
1212
|
+
from: z22.tuple([
|
|
1213
|
+
z22.number()
|
|
1243
1214
|
])
|
|
1244
1215
|
},
|
|
1245
1216
|
result: {
|
|
@@ -1249,55 +1220,55 @@ var XyoViewerRpcSchemas = {
|
|
|
1249
1220
|
},
|
|
1250
1221
|
xyoViewer_stakedByStaker: {
|
|
1251
1222
|
params: {
|
|
1252
|
-
to:
|
|
1223
|
+
to: z22.tuple([
|
|
1253
1224
|
AddressZod
|
|
1254
1225
|
]),
|
|
1255
|
-
from:
|
|
1226
|
+
from: z22.tuple([
|
|
1256
1227
|
AddressZod
|
|
1257
1228
|
])
|
|
1258
1229
|
},
|
|
1259
1230
|
result: {
|
|
1260
|
-
to:
|
|
1261
|
-
from:
|
|
1231
|
+
to: z22.array(AddressZod),
|
|
1232
|
+
from: z22.array(AddressZod)
|
|
1262
1233
|
}
|
|
1263
1234
|
},
|
|
1264
1235
|
xyoViewer_stakesByStaker: {
|
|
1265
1236
|
params: {
|
|
1266
|
-
to:
|
|
1237
|
+
to: z22.tuple([
|
|
1267
1238
|
AddressZod
|
|
1268
1239
|
]),
|
|
1269
|
-
from:
|
|
1240
|
+
from: z22.tuple([
|
|
1270
1241
|
AddressZod
|
|
1271
1242
|
])
|
|
1272
1243
|
},
|
|
1273
1244
|
result: {
|
|
1274
|
-
to:
|
|
1275
|
-
from:
|
|
1245
|
+
to: z22.array(StakeToJsonZod),
|
|
1246
|
+
from: z22.array(JsonToStakeZod)
|
|
1276
1247
|
}
|
|
1277
1248
|
},
|
|
1278
1249
|
xyoViewer_stakesByStaked: {
|
|
1279
1250
|
params: {
|
|
1280
|
-
to:
|
|
1251
|
+
to: z22.tuple([
|
|
1281
1252
|
AddressZod
|
|
1282
1253
|
]),
|
|
1283
|
-
from:
|
|
1254
|
+
from: z22.tuple([
|
|
1284
1255
|
AddressZod
|
|
1285
1256
|
])
|
|
1286
1257
|
},
|
|
1287
1258
|
result: {
|
|
1288
|
-
to:
|
|
1289
|
-
from:
|
|
1259
|
+
to: z22.array(StakeToJsonZod),
|
|
1260
|
+
from: z22.array(JsonToStakeZod)
|
|
1290
1261
|
}
|
|
1291
1262
|
},
|
|
1292
1263
|
xyoViewer_transactionByBlockHashAndIndex: {
|
|
1293
1264
|
params: {
|
|
1294
|
-
to:
|
|
1265
|
+
to: z22.tuple([
|
|
1295
1266
|
HashZod3,
|
|
1296
|
-
|
|
1267
|
+
z22.number()
|
|
1297
1268
|
]),
|
|
1298
|
-
from:
|
|
1269
|
+
from: z22.tuple([
|
|
1299
1270
|
HashZod3,
|
|
1300
|
-
|
|
1271
|
+
z22.number()
|
|
1301
1272
|
])
|
|
1302
1273
|
},
|
|
1303
1274
|
result: {
|
|
@@ -1307,13 +1278,13 @@ var XyoViewerRpcSchemas = {
|
|
|
1307
1278
|
},
|
|
1308
1279
|
xyoViewer_transactionByBlockNumberAndIndex: {
|
|
1309
1280
|
params: {
|
|
1310
|
-
to:
|
|
1311
|
-
|
|
1312
|
-
|
|
1281
|
+
to: z22.tuple([
|
|
1282
|
+
z22.number(),
|
|
1283
|
+
z22.number()
|
|
1313
1284
|
]),
|
|
1314
|
-
from:
|
|
1315
|
-
|
|
1316
|
-
|
|
1285
|
+
from: z22.tuple([
|
|
1286
|
+
z22.number(),
|
|
1287
|
+
z22.number()
|
|
1317
1288
|
])
|
|
1318
1289
|
},
|
|
1319
1290
|
result: {
|
|
@@ -1323,10 +1294,10 @@ var XyoViewerRpcSchemas = {
|
|
|
1323
1294
|
},
|
|
1324
1295
|
xyoViewer_transactionByHash: {
|
|
1325
1296
|
params: {
|
|
1326
|
-
to:
|
|
1297
|
+
to: z22.tuple([
|
|
1327
1298
|
HashZod3
|
|
1328
1299
|
]),
|
|
1329
|
-
from:
|
|
1300
|
+
from: z22.tuple([
|
|
1330
1301
|
HashZod3
|
|
1331
1302
|
])
|
|
1332
1303
|
},
|
|
@@ -1347,85 +1318,85 @@ var AllRpcSchemas = {
|
|
|
1347
1318
|
};
|
|
1348
1319
|
|
|
1349
1320
|
// src/types/schema/createRequestSchema.ts
|
|
1350
|
-
import * as
|
|
1351
|
-
var createRequestSchema = /* @__PURE__ */ __name((methodName, paramsSchema =
|
|
1352
|
-
id:
|
|
1353
|
-
|
|
1354
|
-
|
|
1321
|
+
import * as z23 from "zod";
|
|
1322
|
+
var createRequestSchema = /* @__PURE__ */ __name((methodName, paramsSchema = z23.undefined()) => z23.object({
|
|
1323
|
+
id: z23.union([
|
|
1324
|
+
z23.string(),
|
|
1325
|
+
z23.number()
|
|
1355
1326
|
]),
|
|
1356
|
-
jsonrpc:
|
|
1357
|
-
method:
|
|
1327
|
+
jsonrpc: z23.literal(jsonrpc),
|
|
1328
|
+
method: z23.literal(methodName),
|
|
1358
1329
|
params: paramsSchema
|
|
1359
1330
|
}), "createRequestSchema");
|
|
1360
1331
|
|
|
1361
1332
|
// src/types/schema/createResponseSchema.ts
|
|
1362
|
-
import * as
|
|
1363
|
-
var createResponseSchema = /* @__PURE__ */ __name((resultSchema =
|
|
1364
|
-
id:
|
|
1365
|
-
|
|
1366
|
-
|
|
1333
|
+
import * as z24 from "zod";
|
|
1334
|
+
var createResponseSchema = /* @__PURE__ */ __name((resultSchema = z24.undefined()) => z24.object({
|
|
1335
|
+
id: z24.union([
|
|
1336
|
+
z24.string(),
|
|
1337
|
+
z24.number()
|
|
1367
1338
|
]),
|
|
1368
|
-
jsonrpc:
|
|
1339
|
+
jsonrpc: z24.literal(jsonrpc),
|
|
1369
1340
|
result: resultSchema
|
|
1370
1341
|
}), "createResponseSchema");
|
|
1371
1342
|
|
|
1372
1343
|
// src/types/schema/DataLakeViewerRpcSchema.ts
|
|
1373
1344
|
import { HashZod as HashZod4 } from "@xylabs/hex";
|
|
1374
|
-
import { PayloadZod as
|
|
1375
|
-
import * as
|
|
1345
|
+
import { PayloadZod as PayloadZod5 } from "@xyo-network/payload-model";
|
|
1346
|
+
import * as z25 from "zod";
|
|
1376
1347
|
var DataLakeViewerRpcSchemas = {
|
|
1377
1348
|
dataLakeViewer_get: {
|
|
1378
1349
|
params: {
|
|
1379
|
-
to:
|
|
1350
|
+
to: z25.tuple([
|
|
1380
1351
|
HashZod4
|
|
1381
1352
|
]),
|
|
1382
|
-
from:
|
|
1353
|
+
from: z25.tuple([
|
|
1383
1354
|
HashZod4
|
|
1384
1355
|
])
|
|
1385
1356
|
},
|
|
1386
1357
|
result: {
|
|
1387
|
-
to:
|
|
1388
|
-
|
|
1358
|
+
to: z25.union([
|
|
1359
|
+
PayloadZod5,
|
|
1389
1360
|
ArrayBufferToJsonZod
|
|
1390
1361
|
]).optional(),
|
|
1391
|
-
from:
|
|
1392
|
-
|
|
1362
|
+
from: z25.union([
|
|
1363
|
+
PayloadZod5,
|
|
1393
1364
|
JsonToArrayBufferZod
|
|
1394
1365
|
]).optional()
|
|
1395
1366
|
}
|
|
1396
1367
|
},
|
|
1397
1368
|
dataLakeViewer_getMany: {
|
|
1398
1369
|
params: {
|
|
1399
|
-
to:
|
|
1400
|
-
|
|
1370
|
+
to: z25.tuple([
|
|
1371
|
+
z25.array(HashZod4)
|
|
1401
1372
|
]),
|
|
1402
|
-
from:
|
|
1403
|
-
|
|
1373
|
+
from: z25.tuple([
|
|
1374
|
+
z25.array(HashZod4)
|
|
1404
1375
|
])
|
|
1405
1376
|
},
|
|
1406
1377
|
result: {
|
|
1407
|
-
to:
|
|
1408
|
-
|
|
1378
|
+
to: z25.array(z25.union([
|
|
1379
|
+
PayloadZod5,
|
|
1409
1380
|
ArrayBufferToJsonZod
|
|
1410
1381
|
])),
|
|
1411
|
-
from:
|
|
1412
|
-
|
|
1382
|
+
from: z25.array(z25.union([
|
|
1383
|
+
PayloadZod5,
|
|
1413
1384
|
JsonToArrayBufferZod
|
|
1414
1385
|
]))
|
|
1415
1386
|
}
|
|
1416
1387
|
},
|
|
1417
1388
|
dataLakeViewer_has: {
|
|
1418
1389
|
params: {
|
|
1419
|
-
to:
|
|
1390
|
+
to: z25.tuple([
|
|
1420
1391
|
HashZod4
|
|
1421
1392
|
]),
|
|
1422
|
-
from:
|
|
1393
|
+
from: z25.tuple([
|
|
1423
1394
|
HashZod4
|
|
1424
1395
|
])
|
|
1425
1396
|
},
|
|
1426
1397
|
result: {
|
|
1427
|
-
to:
|
|
1428
|
-
from:
|
|
1398
|
+
to: z25.boolean(),
|
|
1399
|
+
from: z25.boolean()
|
|
1429
1400
|
}
|
|
1430
1401
|
}
|
|
1431
1402
|
};
|
|
@@ -1433,228 +1404,228 @@ var DataLakeViewerRpcSchemas = {
|
|
|
1433
1404
|
// src/types/schema/RewardsByPositionViewerRpcSchemas.ts
|
|
1434
1405
|
import { BigIntToJsonZod as BigIntToJsonZod4, JsonToBigIntZod as JsonToBigIntZod4 } from "@xylabs/hex";
|
|
1435
1406
|
import { asAttoXL1 as asAttoXL12 } from "@xyo-network/xl1-protocol";
|
|
1436
|
-
import
|
|
1407
|
+
import z26 from "zod";
|
|
1437
1408
|
var NetworkStakingStepRewardsByPositionViewerRpcSchemas = {
|
|
1438
1409
|
networkStakingStepRewardsByPositionViewer_bonus: {
|
|
1439
1410
|
params: {
|
|
1440
|
-
from:
|
|
1411
|
+
from: z26.tuple([
|
|
1441
1412
|
RewardsRangeOptionsZod.optional()
|
|
1442
1413
|
]),
|
|
1443
|
-
to:
|
|
1414
|
+
to: z26.tuple([
|
|
1444
1415
|
RewardsRangeOptionsZod.optional()
|
|
1445
1416
|
])
|
|
1446
1417
|
},
|
|
1447
1418
|
result: {
|
|
1448
|
-
from:
|
|
1449
|
-
to:
|
|
1419
|
+
from: z26.record(z26.number(), JsonToBigIntZod4.transform((val) => asAttoXL12(val))),
|
|
1420
|
+
to: z26.record(z26.number(), BigIntToJsonZod4)
|
|
1450
1421
|
}
|
|
1451
1422
|
},
|
|
1452
1423
|
networkStakingStepRewardsByPositionViewer_claimed: {
|
|
1453
1424
|
params: {
|
|
1454
|
-
from:
|
|
1425
|
+
from: z26.tuple([
|
|
1455
1426
|
RewardsRangeOptionsZod.optional()
|
|
1456
1427
|
]),
|
|
1457
|
-
to:
|
|
1428
|
+
to: z26.tuple([
|
|
1458
1429
|
RewardsRangeOptionsZod.optional()
|
|
1459
1430
|
])
|
|
1460
1431
|
},
|
|
1461
1432
|
result: {
|
|
1462
|
-
from:
|
|
1463
|
-
to:
|
|
1433
|
+
from: z26.record(z26.number(), BigIntToJsonZod4.transform((val) => asAttoXL12(val))),
|
|
1434
|
+
to: z26.record(z26.number(), JsonToBigIntZod4)
|
|
1464
1435
|
}
|
|
1465
1436
|
},
|
|
1466
1437
|
networkStakingStepRewardsByPositionViewer_earned: {
|
|
1467
1438
|
params: {
|
|
1468
|
-
from:
|
|
1439
|
+
from: z26.tuple([
|
|
1469
1440
|
RewardsRangeOptionsZod.optional()
|
|
1470
1441
|
]),
|
|
1471
|
-
to:
|
|
1442
|
+
to: z26.tuple([
|
|
1472
1443
|
RewardsRangeOptionsZod.optional()
|
|
1473
1444
|
])
|
|
1474
1445
|
},
|
|
1475
1446
|
result: {
|
|
1476
|
-
from:
|
|
1477
|
-
to:
|
|
1447
|
+
from: z26.record(z26.number(), BigIntToJsonZod4.transform((val) => asAttoXL12(val))),
|
|
1448
|
+
to: z26.record(z26.number(), JsonToBigIntZod4)
|
|
1478
1449
|
}
|
|
1479
1450
|
},
|
|
1480
1451
|
networkStakingStepRewardsByPositionViewer_total: {
|
|
1481
1452
|
params: {
|
|
1482
|
-
from:
|
|
1453
|
+
from: z26.tuple([
|
|
1483
1454
|
RewardsRangeOptionsZod.optional()
|
|
1484
1455
|
]),
|
|
1485
|
-
to:
|
|
1456
|
+
to: z26.tuple([
|
|
1486
1457
|
RewardsRangeOptionsZod.optional()
|
|
1487
1458
|
])
|
|
1488
1459
|
},
|
|
1489
1460
|
result: {
|
|
1490
|
-
from:
|
|
1491
|
-
to:
|
|
1461
|
+
from: z26.record(z26.number(), BigIntToJsonZod4.transform((val) => asAttoXL12(val))),
|
|
1462
|
+
to: z26.record(z26.number(), JsonToBigIntZod4)
|
|
1492
1463
|
}
|
|
1493
1464
|
},
|
|
1494
1465
|
networkStakingStepRewardsByPositionViewer_unclaimed: {
|
|
1495
1466
|
params: {
|
|
1496
|
-
from:
|
|
1467
|
+
from: z26.tuple([
|
|
1497
1468
|
RewardsRangeOptionsZod.optional()
|
|
1498
1469
|
]),
|
|
1499
|
-
to:
|
|
1470
|
+
to: z26.tuple([
|
|
1500
1471
|
RewardsRangeOptionsZod.optional()
|
|
1501
1472
|
])
|
|
1502
1473
|
},
|
|
1503
1474
|
result: {
|
|
1504
|
-
from:
|
|
1505
|
-
to:
|
|
1475
|
+
from: z26.record(z26.number(), BigIntToJsonZod4.transform((val) => asAttoXL12(val))),
|
|
1476
|
+
to: z26.record(z26.number(), JsonToBigIntZod4)
|
|
1506
1477
|
}
|
|
1507
1478
|
}
|
|
1508
1479
|
};
|
|
1509
1480
|
|
|
1510
1481
|
// src/types/schema/RewardsByStakerViewerRpcSchemas.ts
|
|
1511
1482
|
import { BigIntToJsonZod as BigIntToJsonZod5, JsonToBigIntZod as JsonToBigIntZod5 } from "@xylabs/hex";
|
|
1512
|
-
import
|
|
1483
|
+
import z27 from "zod";
|
|
1513
1484
|
var NetworkStakingStepRewardsByStakerViewerRpcSchemas = {
|
|
1514
1485
|
networkStakingStepRewardsByStakerViewer_bonus: {
|
|
1515
1486
|
params: {
|
|
1516
|
-
from:
|
|
1487
|
+
from: z27.tuple([
|
|
1517
1488
|
RewardsRangeOptionsZod.optional()
|
|
1518
1489
|
]),
|
|
1519
|
-
to:
|
|
1490
|
+
to: z27.tuple([
|
|
1520
1491
|
RewardsRangeOptionsZod.optional()
|
|
1521
1492
|
])
|
|
1522
1493
|
},
|
|
1523
1494
|
result: {
|
|
1524
|
-
from:
|
|
1525
|
-
to:
|
|
1495
|
+
from: z27.record(AddressZod, BigIntToJsonZod5),
|
|
1496
|
+
to: z27.record(AddressZod, JsonToBigIntZod5)
|
|
1526
1497
|
}
|
|
1527
1498
|
},
|
|
1528
1499
|
networkStakingStepRewardsByStakerViewer_claimed: {
|
|
1529
1500
|
params: {
|
|
1530
|
-
from:
|
|
1501
|
+
from: z27.tuple([
|
|
1531
1502
|
RewardsRangeOptionsZod.optional()
|
|
1532
1503
|
]),
|
|
1533
|
-
to:
|
|
1504
|
+
to: z27.tuple([
|
|
1534
1505
|
RewardsRangeOptionsZod.optional()
|
|
1535
1506
|
])
|
|
1536
1507
|
},
|
|
1537
1508
|
result: {
|
|
1538
|
-
from:
|
|
1539
|
-
to:
|
|
1509
|
+
from: z27.record(AddressZod, BigIntToJsonZod5),
|
|
1510
|
+
to: z27.record(AddressZod, JsonToBigIntZod5)
|
|
1540
1511
|
}
|
|
1541
1512
|
},
|
|
1542
1513
|
networkStakingStepRewardsByStakerViewer_earned: {
|
|
1543
1514
|
params: {
|
|
1544
|
-
from:
|
|
1515
|
+
from: z27.tuple([
|
|
1545
1516
|
RewardsRangeOptionsZod.optional()
|
|
1546
1517
|
]),
|
|
1547
|
-
to:
|
|
1518
|
+
to: z27.tuple([
|
|
1548
1519
|
RewardsRangeOptionsZod.optional()
|
|
1549
1520
|
])
|
|
1550
1521
|
},
|
|
1551
1522
|
result: {
|
|
1552
|
-
from:
|
|
1553
|
-
to:
|
|
1523
|
+
from: z27.record(AddressZod, BigIntToJsonZod5),
|
|
1524
|
+
to: z27.record(AddressZod, JsonToBigIntZod5)
|
|
1554
1525
|
}
|
|
1555
1526
|
},
|
|
1556
1527
|
networkStakingStepRewardsByStakerViewer_total: {
|
|
1557
1528
|
params: {
|
|
1558
|
-
from:
|
|
1529
|
+
from: z27.tuple([
|
|
1559
1530
|
RewardsRangeOptionsZod.optional()
|
|
1560
1531
|
]),
|
|
1561
|
-
to:
|
|
1532
|
+
to: z27.tuple([
|
|
1562
1533
|
RewardsRangeOptionsZod.optional()
|
|
1563
1534
|
])
|
|
1564
1535
|
},
|
|
1565
1536
|
result: {
|
|
1566
|
-
from:
|
|
1567
|
-
to:
|
|
1537
|
+
from: z27.record(AddressZod, BigIntToJsonZod5),
|
|
1538
|
+
to: z27.record(AddressZod, JsonToBigIntZod5)
|
|
1568
1539
|
}
|
|
1569
1540
|
},
|
|
1570
1541
|
networkStakingStepRewardsByStakerViewer_unclaimed: {
|
|
1571
1542
|
params: {
|
|
1572
|
-
from:
|
|
1543
|
+
from: z27.tuple([
|
|
1573
1544
|
RewardsRangeOptionsZod.optional()
|
|
1574
1545
|
]),
|
|
1575
|
-
to:
|
|
1546
|
+
to: z27.tuple([
|
|
1576
1547
|
RewardsRangeOptionsZod.optional()
|
|
1577
1548
|
])
|
|
1578
1549
|
},
|
|
1579
1550
|
result: {
|
|
1580
|
-
from:
|
|
1581
|
-
to:
|
|
1551
|
+
from: z27.record(AddressZod, BigIntToJsonZod5),
|
|
1552
|
+
to: z27.record(AddressZod, JsonToBigIntZod5)
|
|
1582
1553
|
}
|
|
1583
1554
|
}
|
|
1584
1555
|
};
|
|
1585
1556
|
|
|
1586
1557
|
// src/types/schema/RewardsByStepViewerRpcSchemas.ts
|
|
1587
1558
|
import { BigIntToJsonZod as BigIntToJsonZod6, JsonToBigIntZod as JsonToBigIntZod6 } from "@xylabs/hex";
|
|
1588
|
-
import
|
|
1559
|
+
import z28 from "zod";
|
|
1589
1560
|
var NetworkStakingStepRewardsByStepViewerRpcSchemas = {
|
|
1590
1561
|
networkStakingStepRewardsByStepViewer_bonus: {
|
|
1591
1562
|
params: {
|
|
1592
|
-
from:
|
|
1563
|
+
from: z28.tuple([
|
|
1593
1564
|
RewardsRangeOptionsZod.optional()
|
|
1594
1565
|
]),
|
|
1595
|
-
to:
|
|
1566
|
+
to: z28.tuple([
|
|
1596
1567
|
RewardsRangeOptionsZod.optional()
|
|
1597
1568
|
])
|
|
1598
1569
|
},
|
|
1599
1570
|
result: {
|
|
1600
|
-
from:
|
|
1601
|
-
to:
|
|
1571
|
+
from: z28.record(AddressZod, BigIntToJsonZod6),
|
|
1572
|
+
to: z28.record(AddressZod, JsonToBigIntZod6)
|
|
1602
1573
|
}
|
|
1603
1574
|
},
|
|
1604
1575
|
networkStakingStepRewardsByStepViewer_claimed: {
|
|
1605
1576
|
params: {
|
|
1606
|
-
from:
|
|
1577
|
+
from: z28.tuple([
|
|
1607
1578
|
RewardsRangeOptionsZod.optional()
|
|
1608
1579
|
]),
|
|
1609
|
-
to:
|
|
1580
|
+
to: z28.tuple([
|
|
1610
1581
|
RewardsRangeOptionsZod.optional()
|
|
1611
1582
|
])
|
|
1612
1583
|
},
|
|
1613
1584
|
result: {
|
|
1614
|
-
from:
|
|
1615
|
-
to:
|
|
1585
|
+
from: z28.record(AddressZod, BigIntToJsonZod6),
|
|
1586
|
+
to: z28.record(AddressZod, JsonToBigIntZod6)
|
|
1616
1587
|
}
|
|
1617
1588
|
},
|
|
1618
1589
|
networkStakingStepRewardsByStepViewer_earned: {
|
|
1619
1590
|
params: {
|
|
1620
|
-
from:
|
|
1591
|
+
from: z28.tuple([
|
|
1621
1592
|
RewardsRangeOptionsZod.optional()
|
|
1622
1593
|
]),
|
|
1623
|
-
to:
|
|
1594
|
+
to: z28.tuple([
|
|
1624
1595
|
RewardsRangeOptionsZod.optional()
|
|
1625
1596
|
])
|
|
1626
1597
|
},
|
|
1627
1598
|
result: {
|
|
1628
|
-
from:
|
|
1629
|
-
to:
|
|
1599
|
+
from: z28.record(AddressZod, BigIntToJsonZod6),
|
|
1600
|
+
to: z28.record(AddressZod, JsonToBigIntZod6)
|
|
1630
1601
|
}
|
|
1631
1602
|
},
|
|
1632
1603
|
networkStakingStepRewardsByStepViewer_total: {
|
|
1633
1604
|
params: {
|
|
1634
|
-
from:
|
|
1605
|
+
from: z28.tuple([
|
|
1635
1606
|
RewardsRangeOptionsZod.optional()
|
|
1636
1607
|
]),
|
|
1637
|
-
to:
|
|
1608
|
+
to: z28.tuple([
|
|
1638
1609
|
RewardsRangeOptionsZod.optional()
|
|
1639
1610
|
])
|
|
1640
1611
|
},
|
|
1641
1612
|
result: {
|
|
1642
|
-
from:
|
|
1643
|
-
to:
|
|
1613
|
+
from: z28.record(AddressZod, BigIntToJsonZod6),
|
|
1614
|
+
to: z28.record(AddressZod, JsonToBigIntZod6)
|
|
1644
1615
|
}
|
|
1645
1616
|
},
|
|
1646
1617
|
networkStakingStepRewardsByStepViewer_unclaimed: {
|
|
1647
1618
|
params: {
|
|
1648
|
-
from:
|
|
1619
|
+
from: z28.tuple([
|
|
1649
1620
|
RewardsRangeOptionsZod.optional()
|
|
1650
1621
|
]),
|
|
1651
|
-
to:
|
|
1622
|
+
to: z28.tuple([
|
|
1652
1623
|
RewardsRangeOptionsZod.optional()
|
|
1653
1624
|
])
|
|
1654
1625
|
},
|
|
1655
1626
|
result: {
|
|
1656
|
-
from:
|
|
1657
|
-
to:
|
|
1627
|
+
from: z28.record(AddressZod, BigIntToJsonZod6),
|
|
1628
|
+
to: z28.record(AddressZod, JsonToBigIntZod6)
|
|
1658
1629
|
}
|
|
1659
1630
|
}
|
|
1660
1631
|
};
|
|
@@ -1662,14 +1633,14 @@ var NetworkStakingStepRewardsByStepViewerRpcSchemas = {
|
|
|
1662
1633
|
// src/types/schema/RewardsTotalViewerRpcSchemas.ts
|
|
1663
1634
|
import { BigIntToJsonZod as BigIntToJsonZod7, JsonToBigIntZod as JsonToBigIntZod7 } from "@xylabs/hex";
|
|
1664
1635
|
import { asAttoXL1 as asAttoXL13 } from "@xyo-network/xl1-protocol";
|
|
1665
|
-
import * as
|
|
1636
|
+
import * as z29 from "zod";
|
|
1666
1637
|
var NetworkStakingStepRewardsTotalViewerRpcSchemas = {
|
|
1667
1638
|
networkStakingStepRewardsTotalViewer_bonus: {
|
|
1668
1639
|
params: {
|
|
1669
|
-
from:
|
|
1640
|
+
from: z29.tuple([
|
|
1670
1641
|
RewardsRangeOptionsZod.optional()
|
|
1671
1642
|
]),
|
|
1672
|
-
to:
|
|
1643
|
+
to: z29.tuple([
|
|
1673
1644
|
RewardsRangeOptionsZod.optional()
|
|
1674
1645
|
])
|
|
1675
1646
|
},
|
|
@@ -1680,10 +1651,10 @@ var NetworkStakingStepRewardsTotalViewerRpcSchemas = {
|
|
|
1680
1651
|
},
|
|
1681
1652
|
networkStakingStepRewardsTotalViewer_claimed: {
|
|
1682
1653
|
params: {
|
|
1683
|
-
from:
|
|
1654
|
+
from: z29.tuple([
|
|
1684
1655
|
RewardsRangeOptionsZod.optional()
|
|
1685
1656
|
]),
|
|
1686
|
-
to:
|
|
1657
|
+
to: z29.tuple([
|
|
1687
1658
|
RewardsRangeOptionsZod.optional()
|
|
1688
1659
|
])
|
|
1689
1660
|
},
|
|
@@ -1694,10 +1665,10 @@ var NetworkStakingStepRewardsTotalViewerRpcSchemas = {
|
|
|
1694
1665
|
},
|
|
1695
1666
|
networkStakingStepRewardsTotalViewer_earned: {
|
|
1696
1667
|
params: {
|
|
1697
|
-
from:
|
|
1668
|
+
from: z29.tuple([
|
|
1698
1669
|
RewardsRangeOptionsZod.optional()
|
|
1699
1670
|
]),
|
|
1700
|
-
to:
|
|
1671
|
+
to: z29.tuple([
|
|
1701
1672
|
RewardsRangeOptionsZod.optional()
|
|
1702
1673
|
])
|
|
1703
1674
|
},
|
|
@@ -1708,10 +1679,10 @@ var NetworkStakingStepRewardsTotalViewerRpcSchemas = {
|
|
|
1708
1679
|
},
|
|
1709
1680
|
networkStakingStepRewardsTotalViewer_total: {
|
|
1710
1681
|
params: {
|
|
1711
|
-
from:
|
|
1682
|
+
from: z29.tuple([
|
|
1712
1683
|
RewardsRangeOptionsZod.optional()
|
|
1713
1684
|
]),
|
|
1714
|
-
to:
|
|
1685
|
+
to: z29.tuple([
|
|
1715
1686
|
RewardsRangeOptionsZod.optional()
|
|
1716
1687
|
])
|
|
1717
1688
|
},
|
|
@@ -1722,10 +1693,10 @@ var NetworkStakingStepRewardsTotalViewerRpcSchemas = {
|
|
|
1722
1693
|
},
|
|
1723
1694
|
networkStakingStepRewardsTotalViewer_unclaimed: {
|
|
1724
1695
|
params: {
|
|
1725
|
-
from:
|
|
1696
|
+
from: z29.tuple([
|
|
1726
1697
|
RewardsRangeOptionsZod.optional()
|
|
1727
1698
|
]),
|
|
1728
|
-
to:
|
|
1699
|
+
to: z29.tuple([
|
|
1729
1700
|
RewardsRangeOptionsZod.optional()
|
|
1730
1701
|
])
|
|
1731
1702
|
},
|
|
@@ -1765,11 +1736,11 @@ var HttpRpcTransport = class {
|
|
|
1765
1736
|
body.params = schemas[method].params.to.parse(params);
|
|
1766
1737
|
}
|
|
1767
1738
|
const res = await new AxiosJson().post(url, body);
|
|
1768
|
-
const
|
|
1769
|
-
if (isUndefinedOrNull(
|
|
1770
|
-
throw new Error(
|
|
1739
|
+
const json = res.data;
|
|
1740
|
+
if (isUndefinedOrNull(json) || json.error) {
|
|
1741
|
+
throw new Error(json.error.message);
|
|
1771
1742
|
}
|
|
1772
|
-
return schemas[method].result.from.parse(
|
|
1743
|
+
return schemas[method].result.from.parse(json.result);
|
|
1773
1744
|
} catch (ex) {
|
|
1774
1745
|
let message = isError(ex) ? ex.message : String(ex);
|
|
1775
1746
|
if (isAxiosError(ex)) {
|
|
@@ -1949,8 +1920,8 @@ var JsonRpcNetworkStakeViewer = class extends JsonRpcNetworkStakeViewerMethods {
|
|
|
1949
1920
|
};
|
|
1950
1921
|
|
|
1951
1922
|
// src/provider/viewer/JsonRpcXyoViewer.ts
|
|
1952
|
-
import {
|
|
1953
|
-
import { asAttoXL1 as asAttoXL14, asHydratedBlock } from "@xyo-network/xl1-protocol";
|
|
1923
|
+
import { asHash, isHash } from "@xylabs/hex";
|
|
1924
|
+
import { asAttoXL1 as asAttoXL14, asHydratedBlock, asXL1BlockRange, isRange } from "@xyo-network/xl1-protocol";
|
|
1954
1925
|
var JsonRpcXyoViewer = class {
|
|
1955
1926
|
static {
|
|
1956
1927
|
__name(this, "JsonRpcXyoViewer");
|
|
@@ -1969,12 +1940,24 @@ var JsonRpcXyoViewer = class {
|
|
|
1969
1940
|
address
|
|
1970
1941
|
]));
|
|
1971
1942
|
}
|
|
1972
|
-
async accountBalanceHistory(address,
|
|
1973
|
-
|
|
1943
|
+
async accountBalanceHistory(address, headOrRange) {
|
|
1944
|
+
const head = asHash(headOrRange);
|
|
1945
|
+
const range = asXL1BlockRange(headOrRange);
|
|
1946
|
+
if (isHash(head)) {
|
|
1947
|
+
return await this.transport.sendRequest("xyoViewer_accountBalanceHistory", [
|
|
1948
|
+
address,
|
|
1949
|
+
head
|
|
1950
|
+
]);
|
|
1951
|
+
}
|
|
1952
|
+
if (isRange(range)) {
|
|
1953
|
+
return await this.transport.sendRequest("xyoViewer_accountBalanceHistory", [
|
|
1954
|
+
address,
|
|
1955
|
+
range
|
|
1956
|
+
]);
|
|
1957
|
+
}
|
|
1958
|
+
return await this.transport.sendRequest("xyoViewer_accountBalanceHistory", [
|
|
1974
1959
|
address,
|
|
1975
1960
|
range
|
|
1976
|
-
] : [
|
|
1977
|
-
address
|
|
1978
1961
|
]);
|
|
1979
1962
|
}
|
|
1980
1963
|
async blockByHash(hash) {
|
|
@@ -2304,20 +2287,15 @@ export {
|
|
|
2304
2287
|
AddressZod,
|
|
2305
2288
|
AllRpcSchemas,
|
|
2306
2289
|
AnyBoundWitnessZod,
|
|
2307
|
-
AnyPayloadWithStorageMetaZod,
|
|
2308
|
-
AnyPayloadZod,
|
|
2309
2290
|
AnySignedBoundWitnessWithStorageMetaZod,
|
|
2310
2291
|
AnySignedBoundWitnessZod,
|
|
2311
2292
|
AnyUnsignedBoundWitnessZod,
|
|
2312
2293
|
ArrayBufferToJsonZod,
|
|
2313
2294
|
AttoToJsonZod,
|
|
2314
2295
|
AttoZod,
|
|
2315
|
-
BlockBoundWitnessWithStorageMetaZod,
|
|
2316
2296
|
BlockBoundWitnessZod,
|
|
2317
2297
|
BlockDurationZod,
|
|
2318
2298
|
BlockEndZod,
|
|
2319
|
-
BlockNumberZod,
|
|
2320
|
-
BlockRangeZod,
|
|
2321
2299
|
BlockScriptsZod,
|
|
2322
2300
|
BlockStartZod,
|
|
2323
2301
|
BoundWitnessZod,
|
|
@@ -2362,8 +2340,6 @@ export {
|
|
|
2362
2340
|
NetworkStakingStepRewardsViewerRpcNamespace,
|
|
2363
2341
|
NetworkStakingStepRewardsViewerRpcSchemas,
|
|
2364
2342
|
NodeXyoRunner,
|
|
2365
|
-
PayloadWithStorageMetaZod,
|
|
2366
|
-
PayloadZod,
|
|
2367
2343
|
PermissionRequestZod,
|
|
2368
2344
|
PermissionZod,
|
|
2369
2345
|
QualifiedSequenceFromStringZod,
|
|
@@ -2372,10 +2348,8 @@ export {
|
|
|
2372
2348
|
RewardsRangeOptionsZod,
|
|
2373
2349
|
RpcXyoPermissions,
|
|
2374
2350
|
RpcXyoSigner,
|
|
2375
|
-
SchemaZod,
|
|
2376
2351
|
SequenceFromStringZod,
|
|
2377
2352
|
SequenceToStringZod,
|
|
2378
|
-
SignedBlockBoundWitnessWithStorageMetaZod,
|
|
2379
2353
|
SignedBlockBoundWitnessZod,
|
|
2380
2354
|
SignedBoundWitnessWithStorageMetaZod,
|
|
2381
2355
|
SignedBoundWitnessZod,
|
|
@@ -2396,13 +2370,10 @@ export {
|
|
|
2396
2370
|
TransferFieldsZod,
|
|
2397
2371
|
TransferPairZod,
|
|
2398
2372
|
TransferZod,
|
|
2399
|
-
TransferZodWithStorageMeta,
|
|
2400
2373
|
UnsignedBoundWitnessWithStorageMetaZod,
|
|
2401
2374
|
UnsignedBoundWitnessZod,
|
|
2402
2375
|
UnsignedHydratedTransactionZod,
|
|
2403
|
-
WithStorageMetaZod,
|
|
2404
2376
|
WithTransactionFeesZod,
|
|
2405
|
-
XL1BlockNumberZod,
|
|
2406
2377
|
XyoBaseConnection,
|
|
2407
2378
|
XyoPermissionsRpcSchemas,
|
|
2408
2379
|
XyoRunnerRpcSchemas,
|