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