@xyo-network/xl1-rpc 1.16.22 → 1.16.24
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/engine/rpcMethodHandlersFromViewer.d.ts.map +1 -1
- package/dist/neutral/index.mjs +708 -882
- package/dist/neutral/index.mjs.map +1 -1
- package/dist/neutral/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewer.d.ts +12 -0
- package/dist/neutral/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewer.d.ts.map +1 -0
- package/dist/neutral/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewerMethods.d.ts +12 -0
- package/dist/neutral/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewerMethods.d.ts.map +1 -0
- package/dist/neutral/provider/viewer/JsonRpcAccountBalanceViewer/index.d.ts +3 -0
- package/dist/neutral/provider/viewer/JsonRpcAccountBalanceViewer/index.d.ts.map +1 -0
- package/dist/neutral/provider/viewer/JsonRpcXyoViewer.d.ts +9 -1
- package/dist/neutral/provider/viewer/JsonRpcXyoViewer.d.ts.map +1 -1
- package/dist/neutral/provider/viewer/index.d.ts +1 -0
- package/dist/neutral/provider/viewer/index.d.ts.map +1 -1
- package/dist/neutral/types/AccountBalanceViewerRpc.d.ts +10 -0
- package/dist/neutral/types/AccountBalanceViewerRpc.d.ts.map +1 -0
- package/dist/neutral/types/index.d.ts +1 -0
- package/dist/neutral/types/index.d.ts.map +1 -1
- package/dist/neutral/types/schema/AccountBalanceViewerRpcSchemas.d.ts +132 -0
- package/dist/neutral/types/schema/AccountBalanceViewerRpcSchemas.d.ts.map +1 -0
- package/dist/neutral/types/schema/AllRpcSchemas.d.ts +264 -8
- package/dist/neutral/types/schema/AllRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/DataLakeViewerRpcSchema.d.ts.map +1 -1
- package/dist/neutral/types/schema/RewardsByPositionViewerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/RewardsByStakerViewerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/RewardsByStepViewerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/RewardsTotalViewerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/StepViewerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/TimeSyncViewerRpcSchema.d.ts.map +1 -1
- package/dist/neutral/types/schema/XyoPermissionsRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/XyoRunnerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/XyoSignerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/XyoViewerRpcSchemas.d.ts +136 -8
- package/dist/neutral/types/schema/XyoViewerRpcSchemas.d.ts.map +1 -1
- package/dist/neutral/types/schema/index.d.ts +1 -1
- package/dist/neutral/types/schema/index.d.ts.map +1 -1
- package/dist/node/engine/rpcMethodHandlersFromViewer.d.ts.map +1 -1
- package/dist/node/index-node.mjs +708 -882
- package/dist/node/index-node.mjs.map +1 -1
- package/dist/node/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewer.d.ts +12 -0
- package/dist/node/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewer.d.ts.map +1 -0
- package/dist/node/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewerMethods.d.ts +12 -0
- package/dist/node/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewerMethods.d.ts.map +1 -0
- package/dist/node/provider/viewer/JsonRpcAccountBalanceViewer/index.d.ts +3 -0
- package/dist/node/provider/viewer/JsonRpcAccountBalanceViewer/index.d.ts.map +1 -0
- package/dist/node/provider/viewer/JsonRpcXyoViewer.d.ts +9 -1
- package/dist/node/provider/viewer/JsonRpcXyoViewer.d.ts.map +1 -1
- package/dist/node/provider/viewer/index.d.ts +1 -0
- package/dist/node/provider/viewer/index.d.ts.map +1 -1
- package/dist/node/types/AccountBalanceViewerRpc.d.ts +10 -0
- package/dist/node/types/AccountBalanceViewerRpc.d.ts.map +1 -0
- package/dist/node/types/index.d.ts +1 -0
- package/dist/node/types/index.d.ts.map +1 -1
- package/dist/node/types/schema/AccountBalanceViewerRpcSchemas.d.ts +132 -0
- package/dist/node/types/schema/AccountBalanceViewerRpcSchemas.d.ts.map +1 -0
- package/dist/node/types/schema/AllRpcSchemas.d.ts +264 -8
- package/dist/node/types/schema/AllRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/DataLakeViewerRpcSchema.d.ts.map +1 -1
- package/dist/node/types/schema/RewardsByPositionViewerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/RewardsByStakerViewerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/RewardsByStepViewerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/RewardsTotalViewerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/StepViewerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/TimeSyncViewerRpcSchema.d.ts.map +1 -1
- package/dist/node/types/schema/XyoPermissionsRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/XyoRunnerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/XyoSignerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/XyoViewerRpcSchemas.d.ts +136 -8
- package/dist/node/types/schema/XyoViewerRpcSchemas.d.ts.map +1 -1
- package/dist/node/types/schema/index.d.ts +1 -1
- package/dist/node/types/schema/index.d.ts.map +1 -1
- package/package.json +8 -9
- package/src/engine/rpcMethodHandlersFromViewer.ts +2 -0
- package/src/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewer.ts +23 -0
- package/src/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewerMethods.ts +31 -0
- package/src/provider/viewer/JsonRpcAccountBalanceViewer/index.ts +2 -0
- package/src/provider/viewer/JsonRpcXyoViewer.ts +27 -6
- package/src/provider/viewer/index.ts +1 -0
- package/src/types/AccountBalanceViewerRpc.ts +16 -0
- package/src/types/index.ts +1 -0
- package/src/types/schema/AccountBalanceViewerRpcSchemas.ts +33 -0
- package/src/types/schema/AllRpcSchemas.ts +2 -0
- package/src/types/schema/DataLakeViewerRpcSchema.ts +1 -1
- package/src/types/schema/RewardsByPositionViewerRpcSchemas.ts +1 -1
- package/src/types/schema/RewardsByStakerViewerRpcSchemas.ts +1 -1
- package/src/types/schema/RewardsByStepViewerRpcSchemas.ts +1 -1
- package/src/types/schema/RewardsTotalViewerRpcSchemas.ts +1 -1
- package/src/types/schema/StepViewerRpcSchemas.ts +1 -1
- package/src/types/schema/TimeSyncViewerRpcSchema.ts +1 -1
- package/src/types/schema/XyoPermissionsRpcSchemas.ts +3 -3
- package/src/types/schema/XyoRunnerRpcSchemas.ts +1 -1
- package/src/types/schema/XyoSignerRpcSchemas.ts +1 -4
- package/src/types/schema/XyoViewerRpcSchemas.ts +32 -19
- package/src/types/schema/index.ts +1 -1
- package/dist/neutral/types/schema/common/ArrayBuffer.d.ts +0 -4
- package/dist/neutral/types/schema/common/ArrayBuffer.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/BlockBoundWitness.d.ts +0 -44
- package/dist/neutral/types/schema/common/BlockBoundWitness.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/BoundWitness.d.ts +0 -123
- package/dist/neutral/types/schema/common/BoundWitness.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/Chain.d.ts +0 -4
- package/dist/neutral/types/schema/common/Chain.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/HydratedBlock.d.ts +0 -133
- package/dist/neutral/types/schema/common/HydratedBlock.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/HydratedTransaction.d.ts +0 -210
- package/dist/neutral/types/schema/common/HydratedTransaction.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/Json.d.ts +0 -7
- package/dist/neutral/types/schema/common/Json.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/Permission.d.ts +0 -53
- package/dist/neutral/types/schema/common/Permission.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/RewardsRangeOptions.d.ts +0 -11
- package/dist/neutral/types/schema/common/RewardsRangeOptions.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/Sequence.d.ts +0 -9
- package/dist/neutral/types/schema/common/Sequence.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/Stake.d.ts +0 -62
- package/dist/neutral/types/schema/common/Stake.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/TimeDomain.d.ts +0 -3
- package/dist/neutral/types/schema/common/TimeDomain.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/TransactionBoundWitness.d.ts +0 -75
- package/dist/neutral/types/schema/common/TransactionBoundWitness.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/TransactionFees.d.ts +0 -53
- package/dist/neutral/types/schema/common/TransactionFees.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/TransferPair.d.ts +0 -3
- package/dist/neutral/types/schema/common/TransferPair.d.ts.map +0 -1
- package/dist/neutral/types/schema/common/index.d.ts +0 -16
- package/dist/neutral/types/schema/common/index.d.ts.map +0 -1
- package/dist/node/types/schema/common/ArrayBuffer.d.ts +0 -4
- package/dist/node/types/schema/common/ArrayBuffer.d.ts.map +0 -1
- package/dist/node/types/schema/common/BlockBoundWitness.d.ts +0 -44
- package/dist/node/types/schema/common/BlockBoundWitness.d.ts.map +0 -1
- package/dist/node/types/schema/common/BoundWitness.d.ts +0 -123
- package/dist/node/types/schema/common/BoundWitness.d.ts.map +0 -1
- package/dist/node/types/schema/common/Chain.d.ts +0 -4
- package/dist/node/types/schema/common/Chain.d.ts.map +0 -1
- package/dist/node/types/schema/common/HydratedBlock.d.ts +0 -133
- package/dist/node/types/schema/common/HydratedBlock.d.ts.map +0 -1
- package/dist/node/types/schema/common/HydratedTransaction.d.ts +0 -210
- package/dist/node/types/schema/common/HydratedTransaction.d.ts.map +0 -1
- package/dist/node/types/schema/common/Json.d.ts +0 -7
- package/dist/node/types/schema/common/Json.d.ts.map +0 -1
- package/dist/node/types/schema/common/Permission.d.ts +0 -53
- package/dist/node/types/schema/common/Permission.d.ts.map +0 -1
- package/dist/node/types/schema/common/RewardsRangeOptions.d.ts +0 -11
- package/dist/node/types/schema/common/RewardsRangeOptions.d.ts.map +0 -1
- package/dist/node/types/schema/common/Sequence.d.ts +0 -9
- package/dist/node/types/schema/common/Sequence.d.ts.map +0 -1
- package/dist/node/types/schema/common/Stake.d.ts +0 -62
- package/dist/node/types/schema/common/Stake.d.ts.map +0 -1
- package/dist/node/types/schema/common/TimeDomain.d.ts +0 -3
- package/dist/node/types/schema/common/TimeDomain.d.ts.map +0 -1
- package/dist/node/types/schema/common/TransactionBoundWitness.d.ts +0 -75
- package/dist/node/types/schema/common/TransactionBoundWitness.d.ts.map +0 -1
- package/dist/node/types/schema/common/TransactionFees.d.ts +0 -53
- package/dist/node/types/schema/common/TransactionFees.d.ts.map +0 -1
- package/dist/node/types/schema/common/TransferPair.d.ts +0 -3
- package/dist/node/types/schema/common/TransferPair.d.ts.map +0 -1
- package/dist/node/types/schema/common/index.d.ts +0 -16
- package/dist/node/types/schema/common/index.d.ts.map +0 -1
- package/src/types/schema/common/ArrayBuffer.ts +0 -42
- package/src/types/schema/common/BlockBoundWitness.ts +0 -36
- package/src/types/schema/common/BoundWitness.ts +0 -56
- package/src/types/schema/common/Chain.ts +0 -5
- package/src/types/schema/common/HydratedBlock.ts +0 -32
- package/src/types/schema/common/HydratedTransaction.ts +0 -37
- package/src/types/schema/common/Json.ts +0 -19
- package/src/types/schema/common/Permission.ts +0 -23
- package/src/types/schema/common/RewardsRangeOptions.ts +0 -10
- package/src/types/schema/common/Sequence.ts +0 -15
- package/src/types/schema/common/Stake.ts +0 -43
- package/src/types/schema/common/TimeDomain.ts +0 -7
- package/src/types/schema/common/TransactionBoundWitness.ts +0 -42
- package/src/types/schema/common/TransactionFees.ts +0 -45
- package/src/types/schema/common/TransferPair.ts +0 -6
- package/src/types/schema/common/index.ts +0 -15
package/dist/node/index-node.mjs
CHANGED
|
@@ -45,6 +45,8 @@ var rpcMethodHandlersFromViewer = /* @__PURE__ */ __name((viewer) => {
|
|
|
45
45
|
xyoViewer_networkStakeStepRewardsForStepLevel: /* @__PURE__ */ __name((params) => viewer.networkStakeStepRewardsForStepLevel?.(...params ?? []), "xyoViewer_networkStakeStepRewardsForStepLevel"),
|
|
46
46
|
xyoViewer_accountBalance: /* @__PURE__ */ __name((params) => viewer.accountBalance(...params ?? []), "xyoViewer_accountBalance"),
|
|
47
47
|
xyoViewer_accountBalanceHistory: /* @__PURE__ */ __name((params) => viewer.accountBalanceHistory(...params ?? []), "xyoViewer_accountBalanceHistory"),
|
|
48
|
+
xyoViewer_accountsBalances: /* @__PURE__ */ __name((params) => viewer.accountsBalances(...params ?? []), "xyoViewer_accountsBalances"),
|
|
49
|
+
xyoViewer_accountsBalancesHistory: /* @__PURE__ */ __name((params) => viewer.accountsBalancesHistory(...params ?? []), "xyoViewer_accountsBalancesHistory"),
|
|
48
50
|
xyoViewer_blockByHash: /* @__PURE__ */ __name((params) => viewer.blockByHash(...params ?? []), "xyoViewer_blockByHash"),
|
|
49
51
|
xyoViewer_blockByNumber: /* @__PURE__ */ __name((params) => viewer.blockByNumber(...params ?? []), "xyoViewer_blockByNumber"),
|
|
50
52
|
xyoViewer_blocksByHash: /* @__PURE__ */ __name((params) => viewer.blocksByHash(...params ?? []), "xyoViewer_blocksByHash"),
|
|
@@ -116,6 +118,9 @@ var rpcMethodHandlersFromSigner = /* @__PURE__ */ __name((signer) => {
|
|
|
116
118
|
// src/engine-node/rpcEngineFromConnection.ts
|
|
117
119
|
import { createAsyncMiddleware, JsonRpcEngine } from "@metamask/json-rpc-engine";
|
|
118
120
|
|
|
121
|
+
// src/types/AccountBalanceViewerRpc.ts
|
|
122
|
+
var AccountBalanceViewerRpcNamespace = "accountBalanceViewer";
|
|
123
|
+
|
|
119
124
|
// src/types/DataLakeViewerRpc.ts
|
|
120
125
|
var DataLakeViewerRpcNamespace = "dataLakeViewer";
|
|
121
126
|
|
|
@@ -164,419 +169,160 @@ var NetworkStakingStepRewardsTotalViewerRpcNamespace = "networkStakingStepReward
|
|
|
164
169
|
// src/types/NetworkStakingStepRewardsViewerRpc.ts
|
|
165
170
|
var NetworkStakingStepRewardsViewerRpcNamespace = "networkStakingStepRewardsViewer";
|
|
166
171
|
|
|
172
|
+
// src/types/schema/AccountBalanceViewerRpcSchemas.ts
|
|
173
|
+
import { AddressZod, BigIntToJsonZod, HashZod, JsonToBigIntZod } from "@xylabs/sdk-js";
|
|
174
|
+
import { XL1BlockRangeZod } from "@xyo-network/xl1-protocol";
|
|
175
|
+
import { AccountBalanceHistoryItemZod } from "@xyo-network/xl1-protocol-sdk";
|
|
176
|
+
import * as z from "zod";
|
|
177
|
+
var AccountBalanceViewerRpcSchemas = {
|
|
178
|
+
accountBalanceViewer_accountsBalances: {
|
|
179
|
+
params: {
|
|
180
|
+
to: z.union([
|
|
181
|
+
z.tuple([
|
|
182
|
+
z.array(AddressZod)
|
|
183
|
+
]),
|
|
184
|
+
z.tuple([
|
|
185
|
+
z.array(AddressZod),
|
|
186
|
+
z.union([
|
|
187
|
+
XL1BlockRangeZod,
|
|
188
|
+
HashZod
|
|
189
|
+
])
|
|
190
|
+
])
|
|
191
|
+
]),
|
|
192
|
+
from: z.union([
|
|
193
|
+
z.tuple([
|
|
194
|
+
z.array(AddressZod)
|
|
195
|
+
]),
|
|
196
|
+
z.tuple([
|
|
197
|
+
z.array(AddressZod),
|
|
198
|
+
z.union([
|
|
199
|
+
XL1BlockRangeZod,
|
|
200
|
+
HashZod
|
|
201
|
+
])
|
|
202
|
+
])
|
|
203
|
+
])
|
|
204
|
+
},
|
|
205
|
+
result: {
|
|
206
|
+
to: z.record(AddressZod, BigIntToJsonZod),
|
|
207
|
+
from: z.record(AddressZod, JsonToBigIntZod)
|
|
208
|
+
}
|
|
209
|
+
},
|
|
210
|
+
accountBalanceViewer_accountsBalancesHistory: {
|
|
211
|
+
params: {
|
|
212
|
+
to: z.union([
|
|
213
|
+
z.tuple([
|
|
214
|
+
z.array(AddressZod)
|
|
215
|
+
]),
|
|
216
|
+
z.tuple([
|
|
217
|
+
z.array(AddressZod),
|
|
218
|
+
z.union([
|
|
219
|
+
XL1BlockRangeZod,
|
|
220
|
+
HashZod
|
|
221
|
+
])
|
|
222
|
+
])
|
|
223
|
+
]),
|
|
224
|
+
from: z.union([
|
|
225
|
+
z.tuple([
|
|
226
|
+
z.array(AddressZod)
|
|
227
|
+
]),
|
|
228
|
+
z.tuple([
|
|
229
|
+
z.array(AddressZod),
|
|
230
|
+
z.union([
|
|
231
|
+
XL1BlockRangeZod,
|
|
232
|
+
HashZod
|
|
233
|
+
])
|
|
234
|
+
])
|
|
235
|
+
])
|
|
236
|
+
},
|
|
237
|
+
result: {
|
|
238
|
+
to: z.record(AddressZod, z.array(AccountBalanceHistoryItemZod)),
|
|
239
|
+
from: z.record(AddressZod, z.array(AccountBalanceHistoryItemZod))
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
};
|
|
243
|
+
|
|
167
244
|
// src/types/schema/NetworkStakeViewerRpcSchemas.ts
|
|
168
|
-
import { BigIntToJsonZod, JsonToBigIntZod } from "@xylabs/sdk-js";
|
|
245
|
+
import { BigIntToJsonZod as BigIntToJsonZod2, JsonToBigIntZod as JsonToBigIntZod2 } from "@xylabs/sdk-js";
|
|
169
246
|
import { BlockNumberZod } from "@xyo-network/xl1-protocol";
|
|
170
|
-
import * as
|
|
247
|
+
import * as z2 from "zod";
|
|
171
248
|
var NetworkStakeViewerRpcSchemas = {
|
|
172
249
|
networkStakeViewer_active: {
|
|
173
250
|
params: {
|
|
174
|
-
from:
|
|
251
|
+
from: z2.tuple([
|
|
175
252
|
BlockNumberZod.optional()
|
|
176
253
|
]),
|
|
177
|
-
to:
|
|
254
|
+
to: z2.tuple([
|
|
178
255
|
BlockNumberZod.optional()
|
|
179
256
|
])
|
|
180
257
|
},
|
|
181
258
|
result: {
|
|
182
|
-
from:
|
|
183
|
-
|
|
184
|
-
|
|
259
|
+
from: z2.tuple([
|
|
260
|
+
JsonToBigIntZod2,
|
|
261
|
+
z2.number()
|
|
185
262
|
]),
|
|
186
|
-
to:
|
|
187
|
-
|
|
188
|
-
|
|
263
|
+
to: z2.tuple([
|
|
264
|
+
BigIntToJsonZod2,
|
|
265
|
+
z2.number()
|
|
189
266
|
])
|
|
190
267
|
}
|
|
191
268
|
}
|
|
192
269
|
};
|
|
193
270
|
|
|
194
271
|
// src/types/schema/XyoPermissionsRpcSchemas.ts
|
|
195
|
-
import
|
|
196
|
-
|
|
197
|
-
// src/types/schema/common/ArrayBuffer.ts
|
|
198
|
-
import * as z2 from "zod";
|
|
199
|
-
function base64Encode(u8) {
|
|
200
|
-
if (typeof Buffer !== "undefined" && typeof Buffer.from === "function") {
|
|
201
|
-
return Buffer.from(u8).toString("base64");
|
|
202
|
-
}
|
|
203
|
-
let binary = "";
|
|
204
|
-
const chunk = 32768;
|
|
205
|
-
for (let i = 0; i < u8.length; i += chunk) {
|
|
206
|
-
binary += String.fromCharCode(...u8.subarray(i, i + chunk));
|
|
207
|
-
}
|
|
208
|
-
return btoa(binary);
|
|
209
|
-
}
|
|
210
|
-
__name(base64Encode, "base64Encode");
|
|
211
|
-
function base64Decode(b64) {
|
|
212
|
-
if (typeof Buffer !== "undefined" && typeof Buffer.from === "function") {
|
|
213
|
-
return new Uint8Array(Buffer.from(b64, "base64"));
|
|
214
|
-
}
|
|
215
|
-
const binary = atob(b64);
|
|
216
|
-
const u8 = new Uint8Array(binary.length);
|
|
217
|
-
for (let i = 0; i < binary.length; i++) u8[i] = binary.charCodeAt(i);
|
|
218
|
-
return u8;
|
|
219
|
-
}
|
|
220
|
-
__name(base64Decode, "base64Decode");
|
|
221
|
-
var ArrayBufferToJsonZod = z2.instanceof(ArrayBuffer).transform((x) => {
|
|
222
|
-
const u8 = new Uint8Array(x);
|
|
223
|
-
return base64Encode(u8);
|
|
224
|
-
});
|
|
225
|
-
var JsonToArrayBufferZod = z2.string().transform((x) => {
|
|
226
|
-
const u8 = base64Decode(x);
|
|
227
|
-
return u8.buffer;
|
|
228
|
-
});
|
|
229
|
-
|
|
230
|
-
// src/types/schema/common/BlockBoundWitness.ts
|
|
231
|
-
import { HashZod as HashZod2 } from "@xylabs/sdk-js";
|
|
232
|
-
import { StorageMetaZod as StorageMetaZod2 } from "@xyo-network/payload-model";
|
|
233
|
-
import { XL1BlockNumberZod } from "@xyo-network/xl1-protocol";
|
|
234
|
-
import * as z5 from "zod";
|
|
235
|
-
|
|
236
|
-
// src/types/schema/common/BoundWitness.ts
|
|
237
|
-
import { AddressZod, HashZod, HexZod } from "@xylabs/sdk-js";
|
|
238
|
-
import { BoundWitnessSchema } from "@xyo-network/boundwitness-model";
|
|
239
|
-
import { PayloadZod, SchemaZod, StorageMetaZod } from "@xyo-network/payload-model";
|
|
272
|
+
import { InvokerPermissionZod, PermissionRequestZod, RequestedPermissionZod } from "@xyo-network/xl1-protocol-sdk";
|
|
240
273
|
import * as z3 from "zod";
|
|
241
|
-
var BoundWitnessRequiredFieldsZod = z3.object({
|
|
242
|
-
addresses: z3.array(AddressZod),
|
|
243
|
-
payload_hashes: z3.array(HashZod),
|
|
244
|
-
payload_schemas: z3.array(SchemaZod),
|
|
245
|
-
previous_hashes: z3.array(HashZod.nullable())
|
|
246
|
-
});
|
|
247
|
-
var BoundWitnessMetaZod = z3.object({
|
|
248
|
-
$destination: AddressZod.optional(),
|
|
249
|
-
$sourceQuery: HashZod.optional(),
|
|
250
|
-
$signatures: z3.array(z3.union([
|
|
251
|
-
HexZod,
|
|
252
|
-
z3.null()
|
|
253
|
-
]))
|
|
254
|
-
});
|
|
255
|
-
var BoundWitnessZod = PayloadZod.extend({
|
|
256
|
-
schema: z3.literal(BoundWitnessSchema)
|
|
257
|
-
}).extend(BoundWitnessRequiredFieldsZod.shape).extend(BoundWitnessMetaZod.shape).refine((data) => data.$signatures.length === data.addresses.length, {
|
|
258
|
-
message: "$signatures length must equal addresses length"
|
|
259
|
-
});
|
|
260
|
-
var AnyBoundWitnessZod = BoundWitnessZod.catchall(z3.any());
|
|
261
|
-
var UnsignedBoundWitnessZod = BoundWitnessZod.refine((data) => data.$signatures.includes(null), {
|
|
262
|
-
message: "all $signatures must be null"
|
|
263
|
-
});
|
|
264
|
-
var AnyUnsignedBoundWitnessZod = UnsignedBoundWitnessZod.catchall(z3.any());
|
|
265
|
-
var UnsignedBoundWitnessWithStorageMetaZod = UnsignedBoundWitnessZod.safeExtend(BoundWitnessRequiredFieldsZod.shape).safeExtend(BoundWitnessMetaZod.shape).safeExtend(StorageMetaZod.shape);
|
|
266
|
-
var SignedBoundWitnessZod = BoundWitnessZod.refine((data) => !data.$signatures.includes(null), {
|
|
267
|
-
message: "all $signatures must not be null"
|
|
268
|
-
});
|
|
269
|
-
var SignedBoundWitnessWithStorageMetaZod = UnsignedBoundWitnessWithStorageMetaZod;
|
|
270
|
-
var AnySignedBoundWitnessZod = UnsignedBoundWitnessZod.catchall(z3.any());
|
|
271
|
-
var AnySignedBoundWitnessWithStorageMetaZod = UnsignedBoundWitnessWithStorageMetaZod.catchall(z3.any());
|
|
272
|
-
|
|
273
|
-
// src/types/schema/common/Chain.ts
|
|
274
|
-
import { AddressRegEx, toAddress } from "@xylabs/sdk-js";
|
|
275
|
-
import * as z4 from "zod";
|
|
276
|
-
var ChainZod = z4.string().toLowerCase().regex(AddressRegEx).transform((v) => toAddress(v));
|
|
277
|
-
|
|
278
|
-
// src/types/schema/common/BlockBoundWitness.ts
|
|
279
|
-
var BlockBoundWitnessFieldsZod = z5.object({
|
|
280
|
-
block: XL1BlockNumberZod,
|
|
281
|
-
chain: ChainZod,
|
|
282
|
-
previous: HashZod2.nullable(),
|
|
283
|
-
protocol: z5.number(),
|
|
284
|
-
step_hashes: z5.array(HashZod2).optional()
|
|
285
|
-
});
|
|
286
|
-
var BlockBoundWitnessMetaZod = z5.object({
|
|
287
|
-
$epoch: z5.number()
|
|
288
|
-
});
|
|
289
|
-
var BlockBoundWitnessZod = UnsignedBoundWitnessZod.merge(StorageMetaZod2.partial()).merge(BlockBoundWitnessFieldsZod).merge(BlockBoundWitnessMetaZod);
|
|
290
|
-
var SignedBlockBoundWitnessZod = SignedBoundWitnessZod.merge(StorageMetaZod2.partial()).merge(BlockBoundWitnessFieldsZod).merge(BlockBoundWitnessMetaZod);
|
|
291
|
-
|
|
292
|
-
// src/types/schema/common/HydratedBlock.ts
|
|
293
|
-
import { PayloadZodLoose, WithStorageMetaZod } from "@xyo-network/payload-model";
|
|
294
|
-
import * as z6 from "zod";
|
|
295
|
-
var HydratedBlockZod = z6.tuple([
|
|
296
|
-
BlockBoundWitnessZod,
|
|
297
|
-
z6.array(PayloadZodLoose)
|
|
298
|
-
]);
|
|
299
|
-
var HydratedBlockWithStorageMetaZod = z6.tuple([
|
|
300
|
-
WithStorageMetaZod(BlockBoundWitnessZod),
|
|
301
|
-
z6.array(WithStorageMetaZod(PayloadZodLoose))
|
|
302
|
-
]);
|
|
303
|
-
var SignedHydratedBlockZod = z6.tuple([
|
|
304
|
-
SignedBlockBoundWitnessZod,
|
|
305
|
-
z6.array(PayloadZodLoose)
|
|
306
|
-
]);
|
|
307
|
-
var SignedHydratedBlockToJsonZod = z6.tuple([
|
|
308
|
-
SignedBlockBoundWitnessZod,
|
|
309
|
-
z6.array(PayloadZodLoose)
|
|
310
|
-
]);
|
|
311
|
-
var SignedHydratedBlockWithStorageMetaZod = z6.tuple([
|
|
312
|
-
WithStorageMetaZod(SignedBlockBoundWitnessZod),
|
|
313
|
-
z6.array(WithStorageMetaZod(PayloadZodLoose))
|
|
314
|
-
]);
|
|
315
|
-
|
|
316
|
-
// src/types/schema/common/HydratedTransaction.ts
|
|
317
|
-
import { asAnyPayload, PayloadZodLoose as PayloadZodLoose2 } from "@xyo-network/payload-model";
|
|
318
|
-
import { asSignedHydratedTransaction } from "@xyo-network/xl1-protocol";
|
|
319
|
-
import * as z9 from "zod";
|
|
320
|
-
|
|
321
|
-
// src/types/schema/common/TransactionBoundWitness.ts
|
|
322
|
-
import { StorageMetaZod as StorageMetaZod3 } from "@xyo-network/payload-model";
|
|
323
|
-
import { BlockNumberZod as BlockNumberZod2 } from "@xyo-network/xl1-protocol";
|
|
324
|
-
import * as z8 from "zod";
|
|
325
|
-
|
|
326
|
-
// src/types/schema/common/TransactionFees.ts
|
|
327
|
-
import { BigIntToJsonZod as BigIntToJsonZod2, HexZod as HexZod2, JsonToBigIntZod as JsonToBigIntZod2 } from "@xylabs/sdk-js";
|
|
328
|
-
import { asAttoXL1 } from "@xyo-network/xl1-protocol";
|
|
329
|
-
import * as z7 from "zod";
|
|
330
|
-
var AttoZod = z7.bigint();
|
|
331
|
-
var JsonToAttoZod = JsonToBigIntZod2.transform((v) => asAttoXL1(v));
|
|
332
|
-
var AttoToJsonZod = BigIntToJsonZod2;
|
|
333
|
-
var TransactionFeesHexZod = z7.object({
|
|
334
|
-
base: HexZod2,
|
|
335
|
-
gasLimit: HexZod2,
|
|
336
|
-
gasPrice: HexZod2,
|
|
337
|
-
priority: HexZod2
|
|
338
|
-
});
|
|
339
|
-
var TransactionFeesBigIntZod = z7.object({
|
|
340
|
-
base: AttoZod,
|
|
341
|
-
gasLimit: AttoZod,
|
|
342
|
-
gasPrice: AttoZod,
|
|
343
|
-
priority: AttoZod
|
|
344
|
-
});
|
|
345
|
-
var TransactionFeesJsonToBigIntZod = TransactionFeesHexZod.transform((val) => ({
|
|
346
|
-
base: JsonToBigIntZod2.parse(val.base),
|
|
347
|
-
gasLimit: JsonToBigIntZod2.parse(val.gasLimit),
|
|
348
|
-
gasPrice: JsonToBigIntZod2.parse(val.gasPrice),
|
|
349
|
-
priority: JsonToBigIntZod2.parse(val.priority)
|
|
350
|
-
}));
|
|
351
|
-
var TransactionFeesBigIntToJsonZod = TransactionFeesBigIntZod.transform((val) => ({
|
|
352
|
-
base: BigIntToJsonZod2.parse(val.base),
|
|
353
|
-
gasLimit: BigIntToJsonZod2.parse(val.gasLimit),
|
|
354
|
-
gasPrice: BigIntToJsonZod2.parse(val.gasPrice),
|
|
355
|
-
priority: BigIntToJsonZod2.parse(val.priority)
|
|
356
|
-
}));
|
|
357
|
-
|
|
358
|
-
// src/types/schema/common/TransactionBoundWitness.ts
|
|
359
|
-
var BlockStartZod = z8.object({
|
|
360
|
-
nbf: BlockNumberZod2
|
|
361
|
-
});
|
|
362
|
-
var BlockEndZod = z8.object({
|
|
363
|
-
exp: BlockNumberZod2
|
|
364
|
-
});
|
|
365
|
-
var BlockDurationZod = z8.object({
|
|
366
|
-
nbf: BlockNumberZod2,
|
|
367
|
-
exp: BlockNumberZod2
|
|
368
|
-
});
|
|
369
|
-
var BlockScriptsZod = z8.object({
|
|
370
|
-
script: z8.array(z8.string()).optional()
|
|
371
|
-
});
|
|
372
|
-
var WithTransactionFeesZod = z8.object({
|
|
373
|
-
fees: TransactionFeesHexZod
|
|
374
|
-
});
|
|
375
|
-
var TransactionBoundWitnessFields = z8.object({
|
|
376
|
-
chain: ChainZod,
|
|
377
|
-
from: ChainZod
|
|
378
|
-
});
|
|
379
|
-
var TransactionBoundWitnessZod = UnsignedBoundWitnessZod.merge(StorageMetaZod3.partial()).merge(BlockDurationZod).merge(WithTransactionFeesZod).merge(TransactionBoundWitnessFields).merge(BlockScriptsZod);
|
|
380
|
-
var SignedTransactionBoundWitnessZod = SignedBoundWitnessZod.merge(StorageMetaZod3.partial()).merge(BlockDurationZod).merge(WithTransactionFeesZod).merge(TransactionBoundWitnessFields).merge(BlockScriptsZod.partial());
|
|
381
|
-
|
|
382
|
-
// src/types/schema/common/HydratedTransaction.ts
|
|
383
|
-
var HydratedTransactionZod = z9.tuple([
|
|
384
|
-
TransactionBoundWitnessZod,
|
|
385
|
-
z9.array(PayloadZodLoose2)
|
|
386
|
-
]);
|
|
387
|
-
var UnsignedHydratedTransactionZod = z9.tuple([
|
|
388
|
-
TransactionBoundWitnessZod,
|
|
389
|
-
z9.array(PayloadZodLoose2)
|
|
390
|
-
]);
|
|
391
|
-
var SignedHydratedTransactionZod = z9.tuple([
|
|
392
|
-
SignedTransactionBoundWitnessZod,
|
|
393
|
-
z9.array(PayloadZodLoose2)
|
|
394
|
-
]);
|
|
395
|
-
var SignedHydratedTransactionToJsonZod = SignedHydratedTransactionZod.transform(([tx, payloads]) => asSignedHydratedTransaction([
|
|
396
|
-
tx,
|
|
397
|
-
payloads.map((payload) => payload)
|
|
398
|
-
]));
|
|
399
|
-
var JsonToSignedHydratedTransactionZod = SignedHydratedTransactionZod.transform(([tx, payloads]) => [
|
|
400
|
-
asSignedHydratedTransaction(tx),
|
|
401
|
-
payloads.map((p) => asAnyPayload(p))
|
|
402
|
-
]);
|
|
403
|
-
|
|
404
|
-
// src/types/schema/common/Json.ts
|
|
405
|
-
import * as z10 from "zod";
|
|
406
|
-
var JsonValueZod = z10.lazy(() => z10.union([
|
|
407
|
-
z10.string(),
|
|
408
|
-
z10.number(),
|
|
409
|
-
z10.boolean(),
|
|
410
|
-
z10.null(),
|
|
411
|
-
z10.array(JsonValueZod),
|
|
412
|
-
z10.record(z10.string(), JsonValueZod)
|
|
413
|
-
]));
|
|
414
|
-
var JsonObjectZod = z10.record(z10.string(), JsonValueZod);
|
|
415
|
-
|
|
416
|
-
// src/types/schema/common/Permission.ts
|
|
417
|
-
import { z as z11 } from "zod";
|
|
418
|
-
var CaveatTypesZod = z11.enum([
|
|
419
|
-
"chain",
|
|
420
|
-
"expiration",
|
|
421
|
-
"filteredResponse",
|
|
422
|
-
"rateLimit",
|
|
423
|
-
"restrictReturnedAccounts"
|
|
424
|
-
]);
|
|
425
|
-
var CaveatsZod = z11.object({
|
|
426
|
-
type: CaveatTypesZod,
|
|
427
|
-
value: z11.json()
|
|
428
|
-
});
|
|
429
|
-
var PermissionZod = z11.object({
|
|
430
|
-
parentCapability: z11.string(),
|
|
431
|
-
caveats: CaveatsZod.array().optional(),
|
|
432
|
-
invoker: z11.string()
|
|
433
|
-
});
|
|
434
|
-
var InvokerPermissionZod = PermissionZod.extend({
|
|
435
|
-
date: z11.number().optional()
|
|
436
|
-
});
|
|
437
|
-
var PermissionRequestZod = z11.record(z11.string(), z11.record(z11.string(), z11.any()));
|
|
438
|
-
var RequestedPermissionZod = z11.object({
|
|
439
|
-
parentCapability: z11.string(),
|
|
440
|
-
date: z11.number().optional()
|
|
441
|
-
});
|
|
442
|
-
|
|
443
|
-
// src/types/schema/common/RewardsRangeOptions.ts
|
|
444
|
-
import { AddressZod as AddressZod2 } from "@xylabs/sdk-js";
|
|
445
|
-
import { BlockRangeZod, StepIdentityZod } from "@xyo-network/xl1-protocol";
|
|
446
|
-
import { z as z12 } from "zod";
|
|
447
|
-
var RewardsRangeOptionsZod = z12.object({
|
|
448
|
-
positions: z12.array(z12.number()).optional(),
|
|
449
|
-
range: BlockRangeZod.optional(),
|
|
450
|
-
steps: z12.array(StepIdentityZod).optional(),
|
|
451
|
-
stakers: z12.array(AddressZod2).optional()
|
|
452
|
-
});
|
|
453
|
-
|
|
454
|
-
// src/types/schema/common/Sequence.ts
|
|
455
|
-
import { HexRegExMinMax, toHex } from "@xylabs/sdk-js";
|
|
456
|
-
import { SequenceConstants } from "@xyo-network/payload-model";
|
|
457
|
-
import * as z13 from "zod";
|
|
458
|
-
var LocalSequenceRegex = new RegExp(HexRegExMinMax(SequenceConstants.localSequenceBytes, SequenceConstants.localSequenceBytes));
|
|
459
|
-
var LocalSequenceToStringZod = z13.string().regex(LocalSequenceRegex);
|
|
460
|
-
var LocalSequenceFromStringZod = z13.string().regex(LocalSequenceRegex).transform((v) => toHex(v));
|
|
461
|
-
var QualifiedSequenceRegex = new RegExp(HexRegExMinMax(SequenceConstants.qualifiedSequenceBytes, SequenceConstants.qualifiedSequenceBytes));
|
|
462
|
-
var QualifiedSequenceToStringZod = z13.string().regex(QualifiedSequenceRegex);
|
|
463
|
-
var QualifiedSequenceFromStringZod = z13.string().regex(QualifiedSequenceRegex).transform((v) => toHex(v));
|
|
464
|
-
var SequenceToStringZod = z13.union([
|
|
465
|
-
LocalSequenceToStringZod,
|
|
466
|
-
QualifiedSequenceToStringZod
|
|
467
|
-
]);
|
|
468
|
-
var SequenceFromStringZod = z13.union([
|
|
469
|
-
LocalSequenceFromStringZod,
|
|
470
|
-
QualifiedSequenceFromStringZod
|
|
471
|
-
]);
|
|
472
|
-
|
|
473
|
-
// src/types/schema/common/Stake.ts
|
|
474
|
-
import { AddressZod as AddressZod3, HexZod as HexZod3 } from "@xylabs/sdk-js";
|
|
475
|
-
import * as z14 from "zod";
|
|
476
|
-
var StakeZod = z14.object({
|
|
477
|
-
amount: AttoZod,
|
|
478
|
-
// the block number when the stake was added
|
|
479
|
-
addBlock: z14.number(),
|
|
480
|
-
// the unique id for the stake item
|
|
481
|
-
id: z14.number(),
|
|
482
|
-
// the block number when the stake was removed (set to 0 if not removed)
|
|
483
|
-
removeBlock: z14.number(),
|
|
484
|
-
// the address that is being staked
|
|
485
|
-
staked: AddressZod3,
|
|
486
|
-
// the address that owns the stake
|
|
487
|
-
staker: AddressZod3,
|
|
488
|
-
// the block number when the stake was withdrawn (set to 0 if not withdrawn)
|
|
489
|
-
withdrawBlock: z14.number()
|
|
490
|
-
});
|
|
491
|
-
var StakeToJsonZod = StakeZod.transform((val) => ({
|
|
492
|
-
addBlock: val.addBlock,
|
|
493
|
-
amount: AttoToJsonZod.parse(val.amount),
|
|
494
|
-
id: val.id,
|
|
495
|
-
removeBlock: val.removeBlock,
|
|
496
|
-
staked: AddressZod3.parse(val.staked),
|
|
497
|
-
staker: AddressZod3.parse(val.staker),
|
|
498
|
-
withdrawBlock: val.withdrawBlock
|
|
499
|
-
}));
|
|
500
|
-
var JsonToStakeZod = StakeZod.extend({
|
|
501
|
-
amount: HexZod3
|
|
502
|
-
}).transform((val) => ({
|
|
503
|
-
addBlock: val.addBlock,
|
|
504
|
-
amount: JsonToAttoZod.parse(val.amount),
|
|
505
|
-
id: val.id,
|
|
506
|
-
removeBlock: val.removeBlock,
|
|
507
|
-
staked: val.staked,
|
|
508
|
-
staker: val.staker,
|
|
509
|
-
withdrawBlock: val.withdrawBlock
|
|
510
|
-
}));
|
|
511
|
-
|
|
512
|
-
// src/types/schema/common/TimeDomain.ts
|
|
513
|
-
import * as z15 from "zod";
|
|
514
|
-
var TimeDomainZod = z15.union([
|
|
515
|
-
z15.literal("xl1"),
|
|
516
|
-
z15.literal("epoch"),
|
|
517
|
-
z15.literal("ethereum")
|
|
518
|
-
]);
|
|
519
|
-
|
|
520
|
-
// src/types/schema/common/TransferPair.ts
|
|
521
|
-
import { AddressZod as AddressZod4 } from "@xylabs/sdk-js";
|
|
522
|
-
import z16 from "zod";
|
|
523
|
-
var TransferPairZod = z16.tuple([
|
|
524
|
-
AddressZod4,
|
|
525
|
-
AddressZod4
|
|
526
|
-
]);
|
|
527
|
-
|
|
528
|
-
// src/types/schema/XyoPermissionsRpcSchemas.ts
|
|
529
274
|
var XyoPermissionsRpcSchemas = {
|
|
530
275
|
xyoPermissions_getPermissions: {
|
|
531
276
|
params: {
|
|
532
|
-
to:
|
|
533
|
-
from:
|
|
277
|
+
to: z3.array(z3.any()).length(0),
|
|
278
|
+
from: z3.array(z3.any()).length(0)
|
|
534
279
|
},
|
|
535
280
|
result: {
|
|
536
|
-
to:
|
|
537
|
-
from:
|
|
281
|
+
to: z3.array(InvokerPermissionZod),
|
|
282
|
+
from: z3.array(InvokerPermissionZod)
|
|
538
283
|
}
|
|
539
284
|
},
|
|
540
285
|
xyoPermissions_requestPermissions: {
|
|
541
286
|
params: {
|
|
542
|
-
to:
|
|
543
|
-
|
|
287
|
+
to: z3.tuple([
|
|
288
|
+
z3.array(PermissionRequestZod)
|
|
544
289
|
]),
|
|
545
|
-
from:
|
|
546
|
-
|
|
290
|
+
from: z3.tuple([
|
|
291
|
+
z3.array(PermissionRequestZod)
|
|
547
292
|
])
|
|
548
293
|
},
|
|
549
294
|
result: {
|
|
550
|
-
to:
|
|
551
|
-
from:
|
|
295
|
+
to: z3.array(RequestedPermissionZod),
|
|
296
|
+
from: z3.array(RequestedPermissionZod)
|
|
552
297
|
}
|
|
553
298
|
},
|
|
554
299
|
xyoPermissions_revokePermissions: {
|
|
555
300
|
params: {
|
|
556
|
-
to:
|
|
557
|
-
|
|
301
|
+
to: z3.tuple([
|
|
302
|
+
z3.array(PermissionRequestZod)
|
|
558
303
|
]),
|
|
559
|
-
from:
|
|
560
|
-
|
|
304
|
+
from: z3.tuple([
|
|
305
|
+
z3.array(PermissionRequestZod)
|
|
561
306
|
])
|
|
562
307
|
},
|
|
563
308
|
result: {
|
|
564
|
-
to:
|
|
565
|
-
from:
|
|
309
|
+
to: z3.array(RequestedPermissionZod),
|
|
310
|
+
from: z3.array(RequestedPermissionZod)
|
|
566
311
|
}
|
|
567
312
|
}
|
|
568
313
|
};
|
|
569
314
|
|
|
570
315
|
// src/types/schema/XyoRunnerRpcSchemas.ts
|
|
571
316
|
import { HashToJsonZod, JsonToHashZod } from "@xylabs/sdk-js";
|
|
572
|
-
import
|
|
317
|
+
import { SignedHydratedTransactionZod } from "@xyo-network/xl1-protocol-sdk";
|
|
318
|
+
import * as z4 from "zod";
|
|
573
319
|
var XyoRunnerRpcSchemas = {
|
|
574
320
|
xyoRunner_broadcastTransaction: {
|
|
575
321
|
params: {
|
|
576
|
-
to:
|
|
322
|
+
to: z4.tuple([
|
|
577
323
|
SignedHydratedTransactionZod
|
|
578
324
|
]),
|
|
579
|
-
from:
|
|
325
|
+
from: z4.tuple([
|
|
580
326
|
SignedHydratedTransactionZod
|
|
581
327
|
])
|
|
582
328
|
},
|
|
@@ -588,32 +334,33 @@ var XyoRunnerRpcSchemas = {
|
|
|
588
334
|
};
|
|
589
335
|
|
|
590
336
|
// src/types/schema/XyoSignerRpcSchemas.ts
|
|
591
|
-
import { AddressZod as
|
|
337
|
+
import { AddressZod as AddressZod2 } from "@xylabs/sdk-js";
|
|
592
338
|
import { asHydratedTransactionWithStorageMeta } from "@xyo-network/xl1-protocol";
|
|
593
|
-
import {
|
|
339
|
+
import { SignedHydratedTransactionZod as SignedHydratedTransactionZod2, UnsignedHydratedTransactionZod } from "@xyo-network/xl1-protocol-sdk";
|
|
340
|
+
import { z as z5 } from "zod";
|
|
594
341
|
var XyoSignerRpcSchemas = {
|
|
595
342
|
xyoSigner_address: {
|
|
596
343
|
params: {
|
|
597
|
-
to:
|
|
598
|
-
from:
|
|
344
|
+
to: z5.array(z5.any()).length(0).optional(),
|
|
345
|
+
from: z5.array(z5.any()).length(0).optional()
|
|
599
346
|
},
|
|
600
347
|
result: {
|
|
601
|
-
to:
|
|
602
|
-
from:
|
|
348
|
+
to: AddressZod2,
|
|
349
|
+
from: AddressZod2
|
|
603
350
|
}
|
|
604
351
|
},
|
|
605
352
|
xyoSigner_signTransaction: {
|
|
606
353
|
params: {
|
|
607
|
-
to:
|
|
354
|
+
to: z5.tuple([
|
|
608
355
|
UnsignedHydratedTransactionZod
|
|
609
356
|
]),
|
|
610
|
-
from:
|
|
357
|
+
from: z5.tuple([
|
|
611
358
|
UnsignedHydratedTransactionZod
|
|
612
359
|
])
|
|
613
360
|
},
|
|
614
361
|
result: {
|
|
615
|
-
to:
|
|
616
|
-
from:
|
|
362
|
+
to: SignedHydratedTransactionZod2,
|
|
363
|
+
from: SignedHydratedTransactionZod2.transform((data) => asHydratedTransactionWithStorageMeta(data, {
|
|
617
364
|
required: true
|
|
618
365
|
}))
|
|
619
366
|
}
|
|
@@ -621,18 +368,18 @@ var XyoSignerRpcSchemas = {
|
|
|
621
368
|
};
|
|
622
369
|
|
|
623
370
|
// src/types/schema/XyoViewerRpcSchemas.ts
|
|
624
|
-
import { AddressZod as
|
|
625
|
-
import {
|
|
626
|
-
import {
|
|
627
|
-
import * as
|
|
371
|
+
import { AddressZod as AddressZod3, BigIntToJsonZod as BigIntToJsonZod3, HashToJsonZod as HashToJsonZod2, HashZod as HashZod2, JsonToBigIntZod as JsonToBigIntZod3, JsonToHashZod as JsonToHashZod2 } from "@xylabs/sdk-js";
|
|
372
|
+
import { BlockNumberZod as BlockNumberZod2, BlockRangeZod, StepIdentityZod, XL1BlockNumberZod, XL1BlockRangeZod as XL1BlockRangeZod2 } from "@xyo-network/xl1-protocol";
|
|
373
|
+
import { AccountBalanceHistoryItemZod as AccountBalanceHistoryItemZod2, JsonToStakeZod, SignedHydratedBlockZod, SignedHydratedTransactionZod as SignedHydratedTransactionZod3, StakeToJsonZod, TransferPairZod } from "@xyo-network/xl1-protocol-sdk";
|
|
374
|
+
import * as z6 from "zod";
|
|
628
375
|
var XyoViewerRpcSchemas = {
|
|
629
376
|
xyoViewer_networkStakeStepRewardClaimedByAddress: {
|
|
630
377
|
params: {
|
|
631
|
-
to:
|
|
632
|
-
|
|
378
|
+
to: z6.tuple([
|
|
379
|
+
AddressZod3
|
|
633
380
|
]),
|
|
634
|
-
from:
|
|
635
|
-
|
|
381
|
+
from: z6.tuple([
|
|
382
|
+
AddressZod3
|
|
636
383
|
])
|
|
637
384
|
},
|
|
638
385
|
result: {
|
|
@@ -642,51 +389,51 @@ var XyoViewerRpcSchemas = {
|
|
|
642
389
|
},
|
|
643
390
|
xyoViewer_networkStakeStepRewardAddressReward: {
|
|
644
391
|
params: {
|
|
645
|
-
to:
|
|
646
|
-
|
|
647
|
-
|
|
392
|
+
to: z6.tuple([
|
|
393
|
+
StepIdentityZod,
|
|
394
|
+
AddressZod3
|
|
648
395
|
]),
|
|
649
|
-
from:
|
|
650
|
-
|
|
651
|
-
|
|
396
|
+
from: z6.tuple([
|
|
397
|
+
StepIdentityZod,
|
|
398
|
+
AddressZod3
|
|
652
399
|
])
|
|
653
400
|
},
|
|
654
401
|
result: {
|
|
655
|
-
to:
|
|
656
|
-
from:
|
|
402
|
+
to: z6.record(AddressZod3, BigIntToJsonZod3),
|
|
403
|
+
from: z6.record(AddressZod3, JsonToBigIntZod3)
|
|
657
404
|
}
|
|
658
405
|
},
|
|
659
406
|
xyoViewer_networkStakeStepRewardAddressHistory: {
|
|
660
407
|
params: {
|
|
661
|
-
to:
|
|
662
|
-
|
|
408
|
+
to: z6.tuple([
|
|
409
|
+
AddressZod3
|
|
663
410
|
]),
|
|
664
|
-
from:
|
|
665
|
-
|
|
411
|
+
from: z6.tuple([
|
|
412
|
+
AddressZod3
|
|
666
413
|
])
|
|
667
414
|
},
|
|
668
415
|
result: {
|
|
669
|
-
to:
|
|
670
|
-
from:
|
|
416
|
+
to: z6.record(AddressZod3, BigIntToJsonZod3),
|
|
417
|
+
from: z6.record(AddressZod3, JsonToBigIntZod3)
|
|
671
418
|
}
|
|
672
419
|
},
|
|
673
420
|
xyoViewer_networkStakeStepRewardAddressShare: {
|
|
674
421
|
params: {
|
|
675
|
-
to:
|
|
676
|
-
|
|
677
|
-
|
|
422
|
+
to: z6.tuple([
|
|
423
|
+
StepIdentityZod,
|
|
424
|
+
AddressZod3
|
|
678
425
|
]),
|
|
679
|
-
from:
|
|
680
|
-
|
|
681
|
-
|
|
426
|
+
from: z6.tuple([
|
|
427
|
+
StepIdentityZod,
|
|
428
|
+
AddressZod3
|
|
682
429
|
])
|
|
683
430
|
},
|
|
684
431
|
result: {
|
|
685
|
-
to:
|
|
432
|
+
to: z6.tuple([
|
|
686
433
|
BigIntToJsonZod3,
|
|
687
434
|
BigIntToJsonZod3
|
|
688
435
|
]),
|
|
689
|
-
from:
|
|
436
|
+
from: z6.tuple([
|
|
690
437
|
JsonToBigIntZod3,
|
|
691
438
|
JsonToBigIntZod3
|
|
692
439
|
])
|
|
@@ -694,13 +441,13 @@ var XyoViewerRpcSchemas = {
|
|
|
694
441
|
},
|
|
695
442
|
xyoViewer_networkStakeStepRewardWeightForAddress: {
|
|
696
443
|
params: {
|
|
697
|
-
to:
|
|
698
|
-
|
|
699
|
-
|
|
444
|
+
to: z6.tuple([
|
|
445
|
+
StepIdentityZod,
|
|
446
|
+
AddressZod3
|
|
700
447
|
]),
|
|
701
|
-
from:
|
|
702
|
-
|
|
703
|
-
|
|
448
|
+
from: z6.tuple([
|
|
449
|
+
StepIdentityZod,
|
|
450
|
+
AddressZod3
|
|
704
451
|
])
|
|
705
452
|
},
|
|
706
453
|
result: {
|
|
@@ -710,11 +457,11 @@ var XyoViewerRpcSchemas = {
|
|
|
710
457
|
},
|
|
711
458
|
xyoViewer_networkStakeStepRewardUnclaimedByAddress: {
|
|
712
459
|
params: {
|
|
713
|
-
to:
|
|
714
|
-
|
|
460
|
+
to: z6.tuple([
|
|
461
|
+
AddressZod3
|
|
715
462
|
]),
|
|
716
|
-
from:
|
|
717
|
-
|
|
463
|
+
from: z6.tuple([
|
|
464
|
+
AddressZod3
|
|
718
465
|
])
|
|
719
466
|
},
|
|
720
467
|
result: {
|
|
@@ -724,27 +471,27 @@ var XyoViewerRpcSchemas = {
|
|
|
724
471
|
},
|
|
725
472
|
xyoViewer_networkStakeStepRewardPoolRewards: {
|
|
726
473
|
params: {
|
|
727
|
-
to:
|
|
728
|
-
|
|
474
|
+
to: z6.tuple([
|
|
475
|
+
StepIdentityZod
|
|
729
476
|
]),
|
|
730
|
-
from:
|
|
731
|
-
|
|
477
|
+
from: z6.tuple([
|
|
478
|
+
StepIdentityZod
|
|
732
479
|
])
|
|
733
480
|
},
|
|
734
481
|
result: {
|
|
735
|
-
to:
|
|
736
|
-
from:
|
|
482
|
+
to: z6.record(AddressZod3, BigIntToJsonZod3),
|
|
483
|
+
from: z6.record(AddressZod3, JsonToBigIntZod3)
|
|
737
484
|
}
|
|
738
485
|
},
|
|
739
486
|
xyoViewer_networkStakeStepRewardPositionWeight: {
|
|
740
487
|
params: {
|
|
741
|
-
to:
|
|
742
|
-
|
|
743
|
-
|
|
488
|
+
to: z6.tuple([
|
|
489
|
+
StepIdentityZod,
|
|
490
|
+
z6.number()
|
|
744
491
|
]),
|
|
745
|
-
from:
|
|
746
|
-
|
|
747
|
-
|
|
492
|
+
from: z6.tuple([
|
|
493
|
+
StepIdentityZod,
|
|
494
|
+
z6.number()
|
|
748
495
|
])
|
|
749
496
|
},
|
|
750
497
|
result: {
|
|
@@ -754,13 +501,13 @@ var XyoViewerRpcSchemas = {
|
|
|
754
501
|
},
|
|
755
502
|
xyoViewer_networkStakeStepRewardPotentialPositionLoss: {
|
|
756
503
|
params: {
|
|
757
|
-
to:
|
|
758
|
-
|
|
759
|
-
|
|
504
|
+
to: z6.tuple([
|
|
505
|
+
StepIdentityZod,
|
|
506
|
+
z6.number()
|
|
760
507
|
]),
|
|
761
|
-
from:
|
|
762
|
-
|
|
763
|
-
|
|
508
|
+
from: z6.tuple([
|
|
509
|
+
StepIdentityZod,
|
|
510
|
+
z6.number()
|
|
764
511
|
])
|
|
765
512
|
},
|
|
766
513
|
result: {
|
|
@@ -770,11 +517,11 @@ var XyoViewerRpcSchemas = {
|
|
|
770
517
|
},
|
|
771
518
|
xyoViewer_networkStakeStepRewardForStep: {
|
|
772
519
|
params: {
|
|
773
|
-
to:
|
|
774
|
-
|
|
520
|
+
to: z6.tuple([
|
|
521
|
+
StepIdentityZod
|
|
775
522
|
]),
|
|
776
|
-
from:
|
|
777
|
-
|
|
523
|
+
from: z6.tuple([
|
|
524
|
+
StepIdentityZod
|
|
778
525
|
])
|
|
779
526
|
},
|
|
780
527
|
result: {
|
|
@@ -784,11 +531,11 @@ var XyoViewerRpcSchemas = {
|
|
|
784
531
|
},
|
|
785
532
|
xyoViewer_networkStakeStepRewardRandomizer: {
|
|
786
533
|
params: {
|
|
787
|
-
to:
|
|
788
|
-
|
|
534
|
+
to: z6.tuple([
|
|
535
|
+
StepIdentityZod
|
|
789
536
|
]),
|
|
790
|
-
from:
|
|
791
|
-
|
|
537
|
+
from: z6.tuple([
|
|
538
|
+
StepIdentityZod
|
|
792
539
|
])
|
|
793
540
|
},
|
|
794
541
|
result: {
|
|
@@ -798,49 +545,49 @@ var XyoViewerRpcSchemas = {
|
|
|
798
545
|
},
|
|
799
546
|
xyoViewer_networkStakeStepRewardStakerCount: {
|
|
800
547
|
params: {
|
|
801
|
-
to:
|
|
802
|
-
|
|
548
|
+
to: z6.tuple([
|
|
549
|
+
StepIdentityZod
|
|
803
550
|
]),
|
|
804
|
-
from:
|
|
805
|
-
|
|
551
|
+
from: z6.tuple([
|
|
552
|
+
StepIdentityZod
|
|
806
553
|
])
|
|
807
554
|
},
|
|
808
555
|
result: {
|
|
809
|
-
to:
|
|
810
|
-
from:
|
|
556
|
+
to: z6.number(),
|
|
557
|
+
from: z6.number()
|
|
811
558
|
}
|
|
812
559
|
},
|
|
813
560
|
xyoViewer_networkStakeStepRewardPoolShares: {
|
|
814
561
|
params: {
|
|
815
|
-
to:
|
|
816
|
-
|
|
562
|
+
to: z6.tuple([
|
|
563
|
+
StepIdentityZod
|
|
817
564
|
]),
|
|
818
|
-
from:
|
|
819
|
-
|
|
565
|
+
from: z6.tuple([
|
|
566
|
+
StepIdentityZod
|
|
820
567
|
])
|
|
821
568
|
},
|
|
822
569
|
result: {
|
|
823
|
-
to:
|
|
824
|
-
from:
|
|
570
|
+
to: z6.record(AddressZod3, BigIntToJsonZod3),
|
|
571
|
+
from: z6.record(AddressZod3, JsonToBigIntZod3)
|
|
825
572
|
}
|
|
826
573
|
},
|
|
827
574
|
xyoViewer_networkStakeStepRewardForStepForPosition: {
|
|
828
575
|
params: {
|
|
829
|
-
to:
|
|
830
|
-
|
|
831
|
-
|
|
576
|
+
to: z6.tuple([
|
|
577
|
+
StepIdentityZod,
|
|
578
|
+
z6.number()
|
|
832
579
|
]),
|
|
833
|
-
from:
|
|
834
|
-
|
|
835
|
-
|
|
580
|
+
from: z6.tuple([
|
|
581
|
+
StepIdentityZod,
|
|
582
|
+
z6.number()
|
|
836
583
|
])
|
|
837
584
|
},
|
|
838
585
|
result: {
|
|
839
|
-
to:
|
|
586
|
+
to: z6.tuple([
|
|
840
587
|
BigIntToJsonZod3,
|
|
841
588
|
BigIntToJsonZod3
|
|
842
589
|
]),
|
|
843
|
-
from:
|
|
590
|
+
from: z6.tuple([
|
|
844
591
|
JsonToBigIntZod3,
|
|
845
592
|
JsonToBigIntZod3
|
|
846
593
|
])
|
|
@@ -848,27 +595,27 @@ var XyoViewerRpcSchemas = {
|
|
|
848
595
|
},
|
|
849
596
|
xyoViewer_networkStakeStepRewardForPosition: {
|
|
850
597
|
params: {
|
|
851
|
-
to:
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
598
|
+
to: z6.tuple([
|
|
599
|
+
z6.number(),
|
|
600
|
+
z6.tuple([
|
|
601
|
+
z6.number(),
|
|
602
|
+
z6.number()
|
|
856
603
|
])
|
|
857
604
|
]),
|
|
858
|
-
from:
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
605
|
+
from: z6.tuple([
|
|
606
|
+
z6.number(),
|
|
607
|
+
z6.tuple([
|
|
608
|
+
z6.number(),
|
|
609
|
+
z6.number()
|
|
863
610
|
])
|
|
864
611
|
])
|
|
865
612
|
},
|
|
866
613
|
result: {
|
|
867
|
-
to:
|
|
614
|
+
to: z6.tuple([
|
|
868
615
|
BigIntToJsonZod3,
|
|
869
616
|
BigIntToJsonZod3
|
|
870
617
|
]),
|
|
871
|
-
from:
|
|
618
|
+
from: z6.tuple([
|
|
872
619
|
JsonToBigIntZod3,
|
|
873
620
|
JsonToBigIntZod3
|
|
874
621
|
])
|
|
@@ -876,16 +623,16 @@ var XyoViewerRpcSchemas = {
|
|
|
876
623
|
},
|
|
877
624
|
xyoViewer_networkStakeStepRewardsForRange: {
|
|
878
625
|
params: {
|
|
879
|
-
to:
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
626
|
+
to: z6.tuple([
|
|
627
|
+
z6.tuple([
|
|
628
|
+
z6.number(),
|
|
629
|
+
z6.number()
|
|
883
630
|
])
|
|
884
631
|
]),
|
|
885
|
-
from:
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
632
|
+
from: z6.tuple([
|
|
633
|
+
z6.tuple([
|
|
634
|
+
z6.number(),
|
|
635
|
+
z6.number()
|
|
889
636
|
])
|
|
890
637
|
])
|
|
891
638
|
},
|
|
@@ -896,18 +643,18 @@ var XyoViewerRpcSchemas = {
|
|
|
896
643
|
},
|
|
897
644
|
xyoViewer_networkStakeStepRewardsForStepLevel: {
|
|
898
645
|
params: {
|
|
899
|
-
to:
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
646
|
+
to: z6.tuple([
|
|
647
|
+
z6.number(),
|
|
648
|
+
z6.tuple([
|
|
649
|
+
z6.number(),
|
|
650
|
+
z6.number()
|
|
904
651
|
])
|
|
905
652
|
]),
|
|
906
|
-
from:
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
653
|
+
from: z6.tuple([
|
|
654
|
+
z6.number(),
|
|
655
|
+
z6.tuple([
|
|
656
|
+
z6.number(),
|
|
657
|
+
z6.number()
|
|
911
658
|
])
|
|
912
659
|
])
|
|
913
660
|
},
|
|
@@ -918,27 +665,27 @@ var XyoViewerRpcSchemas = {
|
|
|
918
665
|
},
|
|
919
666
|
xyoViewer_networkStakeStepRewardsForPosition: {
|
|
920
667
|
params: {
|
|
921
|
-
to:
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
668
|
+
to: z6.tuple([
|
|
669
|
+
z6.number(),
|
|
670
|
+
z6.tuple([
|
|
671
|
+
z6.number(),
|
|
672
|
+
z6.number()
|
|
926
673
|
])
|
|
927
674
|
]),
|
|
928
|
-
from:
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
675
|
+
from: z6.tuple([
|
|
676
|
+
z6.number(),
|
|
677
|
+
z6.tuple([
|
|
678
|
+
z6.number(),
|
|
679
|
+
z6.number()
|
|
933
680
|
])
|
|
934
681
|
])
|
|
935
682
|
},
|
|
936
683
|
result: {
|
|
937
|
-
to:
|
|
684
|
+
to: z6.record(z6.string(), z6.tuple([
|
|
938
685
|
BigIntToJsonZod3,
|
|
939
686
|
BigIntToJsonZod3
|
|
940
687
|
])),
|
|
941
|
-
from:
|
|
688
|
+
from: z6.record(z6.string(), z6.tuple([
|
|
942
689
|
JsonToBigIntZod3,
|
|
943
690
|
JsonToBigIntZod3
|
|
944
691
|
]))
|
|
@@ -946,11 +693,29 @@ var XyoViewerRpcSchemas = {
|
|
|
946
693
|
},
|
|
947
694
|
xyoViewer_accountBalance: {
|
|
948
695
|
params: {
|
|
949
|
-
to:
|
|
950
|
-
|
|
696
|
+
to: z6.union([
|
|
697
|
+
z6.tuple([
|
|
698
|
+
AddressZod3
|
|
699
|
+
]),
|
|
700
|
+
z6.tuple([
|
|
701
|
+
AddressZod3,
|
|
702
|
+
z6.union([
|
|
703
|
+
XL1BlockRangeZod2,
|
|
704
|
+
HashZod2
|
|
705
|
+
])
|
|
706
|
+
])
|
|
951
707
|
]),
|
|
952
|
-
from:
|
|
953
|
-
|
|
708
|
+
from: z6.union([
|
|
709
|
+
z6.tuple([
|
|
710
|
+
AddressZod3
|
|
711
|
+
]),
|
|
712
|
+
z6.tuple([
|
|
713
|
+
AddressZod3,
|
|
714
|
+
z6.union([
|
|
715
|
+
XL1BlockRangeZod2,
|
|
716
|
+
HashZod2
|
|
717
|
+
])
|
|
718
|
+
])
|
|
954
719
|
])
|
|
955
720
|
},
|
|
956
721
|
result: {
|
|
@@ -960,50 +725,106 @@ var XyoViewerRpcSchemas = {
|
|
|
960
725
|
},
|
|
961
726
|
xyoViewer_accountBalanceHistory: {
|
|
962
727
|
params: {
|
|
963
|
-
to:
|
|
964
|
-
|
|
965
|
-
|
|
728
|
+
to: z6.union([
|
|
729
|
+
z6.tuple([
|
|
730
|
+
AddressZod3
|
|
966
731
|
]),
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
732
|
+
z6.tuple([
|
|
733
|
+
AddressZod3,
|
|
734
|
+
z6.union([
|
|
735
|
+
XL1BlockRangeZod2,
|
|
736
|
+
HashZod2
|
|
972
737
|
])
|
|
973
738
|
])
|
|
974
739
|
]),
|
|
975
|
-
from:
|
|
976
|
-
|
|
977
|
-
|
|
740
|
+
from: z6.union([
|
|
741
|
+
z6.tuple([
|
|
742
|
+
AddressZod3
|
|
978
743
|
]),
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
744
|
+
z6.tuple([
|
|
745
|
+
AddressZod3,
|
|
746
|
+
z6.union([
|
|
747
|
+
XL1BlockRangeZod2,
|
|
748
|
+
HashZod2
|
|
984
749
|
])
|
|
985
750
|
])
|
|
986
751
|
])
|
|
987
752
|
},
|
|
988
753
|
result: {
|
|
989
|
-
to:
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
754
|
+
to: z6.array(AccountBalanceHistoryItemZod2),
|
|
755
|
+
from: z6.array(AccountBalanceHistoryItemZod2)
|
|
756
|
+
}
|
|
757
|
+
},
|
|
758
|
+
xyoViewer_accountsBalances: {
|
|
759
|
+
params: {
|
|
760
|
+
to: z6.union([
|
|
761
|
+
z6.tuple([
|
|
762
|
+
z6.array(AddressZod3)
|
|
763
|
+
]),
|
|
764
|
+
z6.tuple([
|
|
765
|
+
z6.array(AddressZod3),
|
|
766
|
+
z6.union([
|
|
767
|
+
XL1BlockRangeZod2,
|
|
768
|
+
HashZod2
|
|
769
|
+
])
|
|
770
|
+
])
|
|
771
|
+
]),
|
|
772
|
+
from: z6.union([
|
|
773
|
+
z6.tuple([
|
|
774
|
+
z6.array(AddressZod3)
|
|
775
|
+
]),
|
|
776
|
+
z6.tuple([
|
|
777
|
+
z6.array(AddressZod3),
|
|
778
|
+
z6.union([
|
|
779
|
+
XL1BlockRangeZod2,
|
|
780
|
+
HashZod2
|
|
781
|
+
])
|
|
782
|
+
])
|
|
783
|
+
])
|
|
784
|
+
},
|
|
785
|
+
result: {
|
|
786
|
+
to: z6.record(AddressZod3, BigIntToJsonZod3),
|
|
787
|
+
from: z6.record(AddressZod3, JsonToBigIntZod3)
|
|
788
|
+
}
|
|
789
|
+
},
|
|
790
|
+
xyoViewer_accountsBalancesHistory: {
|
|
791
|
+
params: {
|
|
792
|
+
to: z6.union([
|
|
793
|
+
z6.tuple([
|
|
794
|
+
z6.array(AddressZod3)
|
|
795
|
+
]),
|
|
796
|
+
z6.tuple([
|
|
797
|
+
z6.array(AddressZod3),
|
|
798
|
+
z6.union([
|
|
799
|
+
XL1BlockRangeZod2,
|
|
800
|
+
HashZod2
|
|
801
|
+
])
|
|
802
|
+
])
|
|
803
|
+
]),
|
|
804
|
+
from: z6.union([
|
|
805
|
+
z6.tuple([
|
|
806
|
+
z6.array(AddressZod3)
|
|
807
|
+
]),
|
|
808
|
+
z6.tuple([
|
|
809
|
+
z6.array(AddressZod3),
|
|
810
|
+
z6.union([
|
|
811
|
+
XL1BlockRangeZod2,
|
|
812
|
+
HashZod2
|
|
813
|
+
])
|
|
814
|
+
])
|
|
815
|
+
])
|
|
816
|
+
},
|
|
817
|
+
result: {
|
|
818
|
+
to: z6.record(AddressZod3, AccountBalanceHistoryItemZod2),
|
|
819
|
+
from: z6.record(AddressZod3, AccountBalanceHistoryItemZod2)
|
|
999
820
|
}
|
|
1000
821
|
},
|
|
1001
822
|
xyoViewer_transferPairBalance: {
|
|
1002
823
|
params: {
|
|
1003
|
-
to:
|
|
824
|
+
to: z6.tuple([
|
|
1004
825
|
TransferPairZod
|
|
1005
826
|
]),
|
|
1006
|
-
from:
|
|
827
|
+
from: z6.tuple([
|
|
1007
828
|
TransferPairZod
|
|
1008
829
|
])
|
|
1009
830
|
},
|
|
@@ -1014,33 +835,25 @@ var XyoViewerRpcSchemas = {
|
|
|
1014
835
|
},
|
|
1015
836
|
xyoViewer_transferPairBalanceHistory: {
|
|
1016
837
|
params: {
|
|
1017
|
-
to:
|
|
838
|
+
to: z6.tuple([
|
|
1018
839
|
TransferPairZod
|
|
1019
840
|
]),
|
|
1020
|
-
from:
|
|
841
|
+
from: z6.tuple([
|
|
1021
842
|
TransferPairZod
|
|
1022
843
|
])
|
|
1023
844
|
},
|
|
1024
845
|
result: {
|
|
1025
|
-
to:
|
|
1026
|
-
|
|
1027
|
-
WithHashMetaZod(TransactionBoundWitnessZod).nullable(),
|
|
1028
|
-
WithHashMetaZod(TransferZod)
|
|
1029
|
-
])),
|
|
1030
|
-
from: z20.array(z20.tuple([
|
|
1031
|
-
WithHashMetaZod(BlockBoundWitnessZod),
|
|
1032
|
-
WithHashMetaZod(TransactionBoundWitnessZod).nullable(),
|
|
1033
|
-
WithHashMetaZod(TransferZod)
|
|
1034
|
-
]))
|
|
846
|
+
to: z6.array(AccountBalanceHistoryItemZod2),
|
|
847
|
+
from: z6.array(AccountBalanceHistoryItemZod2)
|
|
1035
848
|
}
|
|
1036
849
|
},
|
|
1037
850
|
xyoViewer_transferBalance: {
|
|
1038
851
|
params: {
|
|
1039
|
-
to:
|
|
1040
|
-
|
|
852
|
+
to: z6.tuple([
|
|
853
|
+
AddressZod3
|
|
1041
854
|
]),
|
|
1042
|
-
from:
|
|
1043
|
-
|
|
855
|
+
from: z6.tuple([
|
|
856
|
+
AddressZod3
|
|
1044
857
|
])
|
|
1045
858
|
},
|
|
1046
859
|
result: {
|
|
@@ -1050,34 +863,26 @@ var XyoViewerRpcSchemas = {
|
|
|
1050
863
|
},
|
|
1051
864
|
xyoViewer_transferBalanceHistory: {
|
|
1052
865
|
params: {
|
|
1053
|
-
to:
|
|
1054
|
-
|
|
1055
|
-
|
|
866
|
+
to: z6.tuple([
|
|
867
|
+
AddressZod3,
|
|
868
|
+
BlockRangeZod.optional()
|
|
1056
869
|
]),
|
|
1057
|
-
from:
|
|
1058
|
-
|
|
1059
|
-
|
|
870
|
+
from: z6.tuple([
|
|
871
|
+
AddressZod3,
|
|
872
|
+
BlockRangeZod.optional()
|
|
1060
873
|
])
|
|
1061
874
|
},
|
|
1062
875
|
result: {
|
|
1063
|
-
to:
|
|
1064
|
-
|
|
1065
|
-
WithHashMetaZod(TransactionBoundWitnessZod).nullable(),
|
|
1066
|
-
WithHashMetaZod(TransferZod)
|
|
1067
|
-
])),
|
|
1068
|
-
from: z20.array(z20.tuple([
|
|
1069
|
-
WithHashMetaZod(BlockBoundWitnessZod),
|
|
1070
|
-
WithHashMetaZod(TransactionBoundWitnessZod).nullable(),
|
|
1071
|
-
WithHashMetaZod(TransferZod)
|
|
1072
|
-
]))
|
|
876
|
+
to: z6.array(AccountBalanceHistoryItemZod2),
|
|
877
|
+
from: z6.array(AccountBalanceHistoryItemZod2)
|
|
1073
878
|
}
|
|
1074
879
|
},
|
|
1075
880
|
xyoViewer_blockByHash: {
|
|
1076
881
|
params: {
|
|
1077
|
-
to:
|
|
882
|
+
to: z6.tuple([
|
|
1078
883
|
HashToJsonZod2
|
|
1079
884
|
]),
|
|
1080
|
-
from:
|
|
885
|
+
from: z6.tuple([
|
|
1081
886
|
JsonToHashZod2
|
|
1082
887
|
])
|
|
1083
888
|
},
|
|
@@ -1088,11 +893,11 @@ var XyoViewerRpcSchemas = {
|
|
|
1088
893
|
},
|
|
1089
894
|
xyoViewer_blockByNumber: {
|
|
1090
895
|
params: {
|
|
1091
|
-
to:
|
|
1092
|
-
|
|
896
|
+
to: z6.tuple([
|
|
897
|
+
z6.number()
|
|
1093
898
|
]),
|
|
1094
|
-
from:
|
|
1095
|
-
|
|
899
|
+
from: z6.tuple([
|
|
900
|
+
z6.number()
|
|
1096
901
|
])
|
|
1097
902
|
},
|
|
1098
903
|
result: {
|
|
@@ -1102,48 +907,48 @@ var XyoViewerRpcSchemas = {
|
|
|
1102
907
|
},
|
|
1103
908
|
xyoViewer_blocksByHash: {
|
|
1104
909
|
params: {
|
|
1105
|
-
to:
|
|
1106
|
-
|
|
1107
|
-
|
|
910
|
+
to: z6.tuple([
|
|
911
|
+
HashZod2,
|
|
912
|
+
z6.number().optional()
|
|
1108
913
|
]),
|
|
1109
|
-
from:
|
|
1110
|
-
|
|
1111
|
-
|
|
914
|
+
from: z6.tuple([
|
|
915
|
+
HashZod2,
|
|
916
|
+
z6.number().optional()
|
|
1112
917
|
])
|
|
1113
918
|
},
|
|
1114
919
|
result: {
|
|
1115
|
-
to:
|
|
1116
|
-
from:
|
|
920
|
+
to: z6.array(SignedHydratedBlockZod),
|
|
921
|
+
from: z6.array(SignedHydratedBlockZod)
|
|
1117
922
|
}
|
|
1118
923
|
},
|
|
1119
924
|
xyoViewer_chainId: {
|
|
1120
925
|
params: {
|
|
1121
|
-
to:
|
|
1122
|
-
from:
|
|
926
|
+
to: z6.array(z6.any()).length(0).optional(),
|
|
927
|
+
from: z6.array(z6.any()).length(0).optional()
|
|
1123
928
|
},
|
|
1124
929
|
result: {
|
|
1125
|
-
to:
|
|
1126
|
-
from:
|
|
930
|
+
to: AddressZod3,
|
|
931
|
+
from: AddressZod3
|
|
1127
932
|
}
|
|
1128
933
|
},
|
|
1129
934
|
xyoViewer_chainIdAtBlock: {
|
|
1130
935
|
params: {
|
|
1131
|
-
to:
|
|
1132
|
-
|
|
936
|
+
to: z6.tuple([
|
|
937
|
+
BlockNumberZod2
|
|
1133
938
|
]),
|
|
1134
|
-
from:
|
|
1135
|
-
|
|
939
|
+
from: z6.tuple([
|
|
940
|
+
BlockNumberZod2
|
|
1136
941
|
])
|
|
1137
942
|
},
|
|
1138
943
|
result: {
|
|
1139
|
-
to:
|
|
1140
|
-
from:
|
|
944
|
+
to: AddressZod3,
|
|
945
|
+
from: AddressZod3
|
|
1141
946
|
}
|
|
1142
947
|
},
|
|
1143
948
|
xyoViewer_currentBlock: {
|
|
1144
949
|
params: {
|
|
1145
|
-
to:
|
|
1146
|
-
from:
|
|
950
|
+
to: z6.array(z6.any()).length(0).optional(),
|
|
951
|
+
from: z6.array(z6.any()).length(0).optional()
|
|
1147
952
|
},
|
|
1148
953
|
result: {
|
|
1149
954
|
to: SignedHydratedBlockZod,
|
|
@@ -1152,43 +957,43 @@ var XyoViewerRpcSchemas = {
|
|
|
1152
957
|
},
|
|
1153
958
|
xyoViewer_currentBlockHash: {
|
|
1154
959
|
params: {
|
|
1155
|
-
to:
|
|
1156
|
-
from:
|
|
960
|
+
to: z6.array(z6.any()).length(0).optional(),
|
|
961
|
+
from: z6.array(z6.any()).length(0).optional()
|
|
1157
962
|
},
|
|
1158
963
|
result: {
|
|
1159
|
-
to:
|
|
1160
|
-
from:
|
|
964
|
+
to: HashZod2,
|
|
965
|
+
from: HashZod2
|
|
1161
966
|
}
|
|
1162
967
|
},
|
|
1163
968
|
xyoViewer_currentBlockNumber: {
|
|
1164
969
|
params: {
|
|
1165
|
-
to:
|
|
1166
|
-
from:
|
|
970
|
+
to: z6.array(z6.any()).length(0).optional(),
|
|
971
|
+
from: z6.array(z6.any()).length(0).optional()
|
|
1167
972
|
},
|
|
1168
973
|
result: {
|
|
1169
|
-
to:
|
|
1170
|
-
from:
|
|
974
|
+
to: XL1BlockNumberZod,
|
|
975
|
+
from: XL1BlockNumberZod
|
|
1171
976
|
}
|
|
1172
977
|
},
|
|
1173
978
|
xyoViewer_forkHistory: {
|
|
1174
979
|
params: {
|
|
1175
|
-
to:
|
|
1176
|
-
from:
|
|
980
|
+
to: z6.array(z6.any()).length(0).optional(),
|
|
981
|
+
from: z6.array(z6.any()).length(0).optional()
|
|
1177
982
|
},
|
|
1178
983
|
result: {
|
|
1179
|
-
to:
|
|
1180
|
-
from:
|
|
984
|
+
to: z6.record(z6.number(), AddressZod3),
|
|
985
|
+
from: z6.record(z6.number(), AddressZod3)
|
|
1181
986
|
}
|
|
1182
987
|
},
|
|
1183
988
|
xyoViewer_stakeByStaker: {
|
|
1184
989
|
params: {
|
|
1185
|
-
to:
|
|
1186
|
-
|
|
1187
|
-
|
|
990
|
+
to: z6.tuple([
|
|
991
|
+
AddressZod3,
|
|
992
|
+
z6.number()
|
|
1188
993
|
]),
|
|
1189
|
-
from:
|
|
1190
|
-
|
|
1191
|
-
|
|
994
|
+
from: z6.tuple([
|
|
995
|
+
AddressZod3,
|
|
996
|
+
z6.number()
|
|
1192
997
|
])
|
|
1193
998
|
},
|
|
1194
999
|
result: {
|
|
@@ -1198,11 +1003,11 @@ var XyoViewerRpcSchemas = {
|
|
|
1198
1003
|
},
|
|
1199
1004
|
xyoViewer_stakeById: {
|
|
1200
1005
|
params: {
|
|
1201
|
-
to:
|
|
1202
|
-
|
|
1006
|
+
to: z6.tuple([
|
|
1007
|
+
z6.number()
|
|
1203
1008
|
]),
|
|
1204
|
-
from:
|
|
1205
|
-
|
|
1009
|
+
from: z6.tuple([
|
|
1010
|
+
z6.number()
|
|
1206
1011
|
])
|
|
1207
1012
|
},
|
|
1208
1013
|
result: {
|
|
@@ -1212,82 +1017,83 @@ var XyoViewerRpcSchemas = {
|
|
|
1212
1017
|
},
|
|
1213
1018
|
xyoViewer_stakesByStaker: {
|
|
1214
1019
|
params: {
|
|
1215
|
-
to:
|
|
1216
|
-
|
|
1020
|
+
to: z6.tuple([
|
|
1021
|
+
AddressZod3
|
|
1217
1022
|
]),
|
|
1218
|
-
from:
|
|
1219
|
-
|
|
1023
|
+
from: z6.tuple([
|
|
1024
|
+
AddressZod3
|
|
1220
1025
|
])
|
|
1221
1026
|
},
|
|
1222
1027
|
result: {
|
|
1223
|
-
to:
|
|
1224
|
-
from:
|
|
1028
|
+
to: z6.array(StakeToJsonZod),
|
|
1029
|
+
from: z6.array(JsonToStakeZod)
|
|
1225
1030
|
}
|
|
1226
1031
|
},
|
|
1227
1032
|
xyoViewer_stakesByStaked: {
|
|
1228
1033
|
params: {
|
|
1229
|
-
to:
|
|
1230
|
-
|
|
1034
|
+
to: z6.tuple([
|
|
1035
|
+
AddressZod3
|
|
1231
1036
|
]),
|
|
1232
|
-
from:
|
|
1233
|
-
|
|
1037
|
+
from: z6.tuple([
|
|
1038
|
+
AddressZod3
|
|
1234
1039
|
])
|
|
1235
1040
|
},
|
|
1236
1041
|
result: {
|
|
1237
|
-
to:
|
|
1238
|
-
from:
|
|
1042
|
+
to: z6.array(StakeToJsonZod),
|
|
1043
|
+
from: z6.array(JsonToStakeZod)
|
|
1239
1044
|
}
|
|
1240
1045
|
},
|
|
1241
1046
|
xyoViewer_transactionByBlockHashAndIndex: {
|
|
1242
1047
|
params: {
|
|
1243
|
-
to:
|
|
1244
|
-
|
|
1245
|
-
|
|
1048
|
+
to: z6.tuple([
|
|
1049
|
+
HashZod2,
|
|
1050
|
+
z6.number()
|
|
1246
1051
|
]),
|
|
1247
|
-
from:
|
|
1248
|
-
|
|
1249
|
-
|
|
1052
|
+
from: z6.tuple([
|
|
1053
|
+
HashZod2,
|
|
1054
|
+
z6.number()
|
|
1250
1055
|
])
|
|
1251
1056
|
},
|
|
1252
1057
|
result: {
|
|
1253
|
-
to:
|
|
1254
|
-
from:
|
|
1058
|
+
to: SignedHydratedTransactionZod3.nullable(),
|
|
1059
|
+
from: SignedHydratedTransactionZod3.nullable()
|
|
1255
1060
|
}
|
|
1256
1061
|
},
|
|
1257
1062
|
xyoViewer_transactionByBlockNumberAndIndex: {
|
|
1258
1063
|
params: {
|
|
1259
|
-
to:
|
|
1260
|
-
|
|
1261
|
-
|
|
1064
|
+
to: z6.tuple([
|
|
1065
|
+
z6.number(),
|
|
1066
|
+
z6.number()
|
|
1262
1067
|
]),
|
|
1263
|
-
from:
|
|
1264
|
-
|
|
1265
|
-
|
|
1068
|
+
from: z6.tuple([
|
|
1069
|
+
z6.number(),
|
|
1070
|
+
z6.number()
|
|
1266
1071
|
])
|
|
1267
1072
|
},
|
|
1268
1073
|
result: {
|
|
1269
|
-
to:
|
|
1270
|
-
from:
|
|
1074
|
+
to: SignedHydratedTransactionZod3.nullable(),
|
|
1075
|
+
from: SignedHydratedTransactionZod3.nullable()
|
|
1271
1076
|
}
|
|
1272
1077
|
},
|
|
1273
1078
|
xyoViewer_transactionByHash: {
|
|
1274
1079
|
params: {
|
|
1275
|
-
to:
|
|
1276
|
-
|
|
1080
|
+
to: z6.tuple([
|
|
1081
|
+
HashZod2
|
|
1277
1082
|
]),
|
|
1278
|
-
from:
|
|
1279
|
-
|
|
1083
|
+
from: z6.tuple([
|
|
1084
|
+
HashZod2
|
|
1280
1085
|
])
|
|
1281
1086
|
},
|
|
1282
1087
|
result: {
|
|
1283
|
-
to:
|
|
1284
|
-
from:
|
|
1088
|
+
to: SignedHydratedTransactionZod3.nullable(),
|
|
1089
|
+
from: SignedHydratedTransactionZod3.nullable()
|
|
1285
1090
|
}
|
|
1286
1091
|
}
|
|
1287
1092
|
};
|
|
1288
1093
|
|
|
1289
1094
|
// src/types/schema/AllRpcSchemas.ts
|
|
1290
1095
|
var AllRpcSchemas = {
|
|
1096
|
+
...AccountBalanceViewerRpcSchemas,
|
|
1291
1097
|
...XyoRunnerRpcSchemas,
|
|
1292
1098
|
...XyoSignerRpcSchemas,
|
|
1293
1099
|
...XyoViewerRpcSchemas,
|
|
@@ -1296,390 +1102,395 @@ var AllRpcSchemas = {
|
|
|
1296
1102
|
};
|
|
1297
1103
|
|
|
1298
1104
|
// src/types/schema/createRequestSchema.ts
|
|
1299
|
-
import * as
|
|
1300
|
-
var createRequestSchema = /* @__PURE__ */ __name((methodName, paramsSchema =
|
|
1301
|
-
id:
|
|
1302
|
-
|
|
1303
|
-
|
|
1105
|
+
import * as z7 from "zod";
|
|
1106
|
+
var createRequestSchema = /* @__PURE__ */ __name((methodName, paramsSchema = z7.undefined()) => z7.object({
|
|
1107
|
+
id: z7.union([
|
|
1108
|
+
z7.string(),
|
|
1109
|
+
z7.number()
|
|
1304
1110
|
]),
|
|
1305
|
-
jsonrpc:
|
|
1306
|
-
method:
|
|
1111
|
+
jsonrpc: z7.literal(jsonrpc),
|
|
1112
|
+
method: z7.literal(methodName),
|
|
1307
1113
|
params: paramsSchema
|
|
1308
1114
|
}), "createRequestSchema");
|
|
1309
1115
|
|
|
1310
1116
|
// src/types/schema/createResponseSchema.ts
|
|
1311
|
-
import * as
|
|
1312
|
-
var createResponseSchema = /* @__PURE__ */ __name((resultSchema =
|
|
1313
|
-
id:
|
|
1314
|
-
|
|
1315
|
-
|
|
1117
|
+
import * as z8 from "zod";
|
|
1118
|
+
var createResponseSchema = /* @__PURE__ */ __name((resultSchema = z8.undefined()) => z8.object({
|
|
1119
|
+
id: z8.union([
|
|
1120
|
+
z8.string(),
|
|
1121
|
+
z8.number()
|
|
1316
1122
|
]),
|
|
1317
|
-
jsonrpc:
|
|
1123
|
+
jsonrpc: z8.literal(jsonrpc),
|
|
1318
1124
|
result: resultSchema
|
|
1319
1125
|
}), "createResponseSchema");
|
|
1320
1126
|
|
|
1321
1127
|
// src/types/schema/DataLakeViewerRpcSchema.ts
|
|
1322
|
-
import { HashZod as
|
|
1323
|
-
import { PayloadZod
|
|
1324
|
-
import
|
|
1128
|
+
import { HashZod as HashZod3 } from "@xylabs/sdk-js";
|
|
1129
|
+
import { PayloadZod } from "@xyo-network/payload-model";
|
|
1130
|
+
import { ArrayBufferToJsonZod, JsonToArrayBufferZod } from "@xyo-network/xl1-protocol-sdk";
|
|
1131
|
+
import * as z9 from "zod";
|
|
1325
1132
|
var DataLakeViewerRpcSchemas = {
|
|
1326
1133
|
dataLakeViewer_get: {
|
|
1327
1134
|
params: {
|
|
1328
|
-
to:
|
|
1329
|
-
|
|
1135
|
+
to: z9.tuple([
|
|
1136
|
+
HashZod3
|
|
1330
1137
|
]),
|
|
1331
|
-
from:
|
|
1332
|
-
|
|
1138
|
+
from: z9.tuple([
|
|
1139
|
+
HashZod3
|
|
1333
1140
|
])
|
|
1334
1141
|
},
|
|
1335
1142
|
result: {
|
|
1336
|
-
to:
|
|
1337
|
-
|
|
1143
|
+
to: z9.union([
|
|
1144
|
+
PayloadZod,
|
|
1338
1145
|
ArrayBufferToJsonZod
|
|
1339
1146
|
]).optional(),
|
|
1340
|
-
from:
|
|
1341
|
-
|
|
1147
|
+
from: z9.union([
|
|
1148
|
+
PayloadZod,
|
|
1342
1149
|
JsonToArrayBufferZod
|
|
1343
1150
|
]).optional()
|
|
1344
1151
|
}
|
|
1345
1152
|
},
|
|
1346
1153
|
dataLakeViewer_getMany: {
|
|
1347
1154
|
params: {
|
|
1348
|
-
to:
|
|
1349
|
-
|
|
1155
|
+
to: z9.tuple([
|
|
1156
|
+
z9.array(HashZod3)
|
|
1350
1157
|
]),
|
|
1351
|
-
from:
|
|
1352
|
-
|
|
1158
|
+
from: z9.tuple([
|
|
1159
|
+
z9.array(HashZod3)
|
|
1353
1160
|
])
|
|
1354
1161
|
},
|
|
1355
1162
|
result: {
|
|
1356
|
-
to:
|
|
1357
|
-
|
|
1163
|
+
to: z9.array(z9.union([
|
|
1164
|
+
PayloadZod,
|
|
1358
1165
|
ArrayBufferToJsonZod
|
|
1359
1166
|
])),
|
|
1360
|
-
from:
|
|
1361
|
-
|
|
1167
|
+
from: z9.array(z9.union([
|
|
1168
|
+
PayloadZod,
|
|
1362
1169
|
JsonToArrayBufferZod
|
|
1363
1170
|
]))
|
|
1364
1171
|
}
|
|
1365
1172
|
},
|
|
1366
1173
|
dataLakeViewer_has: {
|
|
1367
1174
|
params: {
|
|
1368
|
-
to:
|
|
1369
|
-
|
|
1175
|
+
to: z9.tuple([
|
|
1176
|
+
HashZod3
|
|
1370
1177
|
]),
|
|
1371
|
-
from:
|
|
1372
|
-
|
|
1178
|
+
from: z9.tuple([
|
|
1179
|
+
HashZod3
|
|
1373
1180
|
])
|
|
1374
1181
|
},
|
|
1375
1182
|
result: {
|
|
1376
|
-
to:
|
|
1377
|
-
from:
|
|
1183
|
+
to: z9.boolean(),
|
|
1184
|
+
from: z9.boolean()
|
|
1378
1185
|
}
|
|
1379
1186
|
}
|
|
1380
1187
|
};
|
|
1381
1188
|
|
|
1382
1189
|
// src/types/schema/RewardsByPositionViewerRpcSchemas.ts
|
|
1383
1190
|
import { BigIntToJsonZod as BigIntToJsonZod4, JsonToBigIntZod as JsonToBigIntZod4 } from "@xylabs/sdk-js";
|
|
1384
|
-
import { asAttoXL1
|
|
1385
|
-
import
|
|
1191
|
+
import { asAttoXL1 } from "@xyo-network/xl1-protocol";
|
|
1192
|
+
import { RewardsRangeOptionsZod } from "@xyo-network/xl1-protocol-sdk";
|
|
1193
|
+
import z10 from "zod";
|
|
1386
1194
|
var NetworkStakingStepRewardsByPositionViewerRpcSchemas = {
|
|
1387
1195
|
networkStakingStepRewardsByPositionViewer_bonus: {
|
|
1388
1196
|
params: {
|
|
1389
|
-
from:
|
|
1197
|
+
from: z10.tuple([
|
|
1390
1198
|
RewardsRangeOptionsZod.optional()
|
|
1391
1199
|
]),
|
|
1392
|
-
to:
|
|
1200
|
+
to: z10.tuple([
|
|
1393
1201
|
RewardsRangeOptionsZod.optional()
|
|
1394
1202
|
])
|
|
1395
1203
|
},
|
|
1396
1204
|
result: {
|
|
1397
|
-
from:
|
|
1398
|
-
to:
|
|
1205
|
+
from: z10.record(z10.number(), JsonToBigIntZod4.transform((val) => asAttoXL1(val))),
|
|
1206
|
+
to: z10.record(z10.number(), BigIntToJsonZod4)
|
|
1399
1207
|
}
|
|
1400
1208
|
},
|
|
1401
1209
|
networkStakingStepRewardsByPositionViewer_claimed: {
|
|
1402
1210
|
params: {
|
|
1403
|
-
from:
|
|
1211
|
+
from: z10.tuple([
|
|
1404
1212
|
RewardsRangeOptionsZod.optional()
|
|
1405
1213
|
]),
|
|
1406
|
-
to:
|
|
1214
|
+
to: z10.tuple([
|
|
1407
1215
|
RewardsRangeOptionsZod.optional()
|
|
1408
1216
|
])
|
|
1409
1217
|
},
|
|
1410
1218
|
result: {
|
|
1411
|
-
from:
|
|
1412
|
-
to:
|
|
1219
|
+
from: z10.record(z10.number(), BigIntToJsonZod4.transform((val) => asAttoXL1(val))),
|
|
1220
|
+
to: z10.record(z10.number(), JsonToBigIntZod4)
|
|
1413
1221
|
}
|
|
1414
1222
|
},
|
|
1415
1223
|
networkStakingStepRewardsByPositionViewer_earned: {
|
|
1416
1224
|
params: {
|
|
1417
|
-
from:
|
|
1225
|
+
from: z10.tuple([
|
|
1418
1226
|
RewardsRangeOptionsZod.optional()
|
|
1419
1227
|
]),
|
|
1420
|
-
to:
|
|
1228
|
+
to: z10.tuple([
|
|
1421
1229
|
RewardsRangeOptionsZod.optional()
|
|
1422
1230
|
])
|
|
1423
1231
|
},
|
|
1424
1232
|
result: {
|
|
1425
|
-
from:
|
|
1426
|
-
to:
|
|
1233
|
+
from: z10.record(z10.number(), BigIntToJsonZod4.transform((val) => asAttoXL1(val))),
|
|
1234
|
+
to: z10.record(z10.number(), JsonToBigIntZod4)
|
|
1427
1235
|
}
|
|
1428
1236
|
},
|
|
1429
1237
|
networkStakingStepRewardsByPositionViewer_total: {
|
|
1430
1238
|
params: {
|
|
1431
|
-
from:
|
|
1239
|
+
from: z10.tuple([
|
|
1432
1240
|
RewardsRangeOptionsZod.optional()
|
|
1433
1241
|
]),
|
|
1434
|
-
to:
|
|
1242
|
+
to: z10.tuple([
|
|
1435
1243
|
RewardsRangeOptionsZod.optional()
|
|
1436
1244
|
])
|
|
1437
1245
|
},
|
|
1438
1246
|
result: {
|
|
1439
|
-
from:
|
|
1440
|
-
to:
|
|
1247
|
+
from: z10.record(z10.number(), BigIntToJsonZod4.transform((val) => asAttoXL1(val))),
|
|
1248
|
+
to: z10.record(z10.number(), JsonToBigIntZod4)
|
|
1441
1249
|
}
|
|
1442
1250
|
},
|
|
1443
1251
|
networkStakingStepRewardsByPositionViewer_unclaimed: {
|
|
1444
1252
|
params: {
|
|
1445
|
-
from:
|
|
1253
|
+
from: z10.tuple([
|
|
1446
1254
|
RewardsRangeOptionsZod.optional()
|
|
1447
1255
|
]),
|
|
1448
|
-
to:
|
|
1256
|
+
to: z10.tuple([
|
|
1449
1257
|
RewardsRangeOptionsZod.optional()
|
|
1450
1258
|
])
|
|
1451
1259
|
},
|
|
1452
1260
|
result: {
|
|
1453
|
-
from:
|
|
1454
|
-
to:
|
|
1261
|
+
from: z10.record(z10.number(), BigIntToJsonZod4.transform((val) => asAttoXL1(val))),
|
|
1262
|
+
to: z10.record(z10.number(), JsonToBigIntZod4)
|
|
1455
1263
|
}
|
|
1456
1264
|
}
|
|
1457
1265
|
};
|
|
1458
1266
|
|
|
1459
1267
|
// src/types/schema/RewardsByStakerViewerRpcSchemas.ts
|
|
1460
|
-
import { AddressZod as
|
|
1461
|
-
import
|
|
1268
|
+
import { AddressZod as AddressZod4, BigIntToJsonZod as BigIntToJsonZod5, JsonToBigIntZod as JsonToBigIntZod5 } from "@xylabs/sdk-js";
|
|
1269
|
+
import { RewardsRangeOptionsZod as RewardsRangeOptionsZod2 } from "@xyo-network/xl1-protocol-sdk";
|
|
1270
|
+
import z11 from "zod";
|
|
1462
1271
|
var NetworkStakingStepRewardsByStakerViewerRpcSchemas = {
|
|
1463
1272
|
networkStakingStepRewardsByStakerViewer_bonus: {
|
|
1464
1273
|
params: {
|
|
1465
|
-
from:
|
|
1466
|
-
|
|
1274
|
+
from: z11.tuple([
|
|
1275
|
+
RewardsRangeOptionsZod2.optional()
|
|
1467
1276
|
]),
|
|
1468
|
-
to:
|
|
1469
|
-
|
|
1277
|
+
to: z11.tuple([
|
|
1278
|
+
RewardsRangeOptionsZod2.optional()
|
|
1470
1279
|
])
|
|
1471
1280
|
},
|
|
1472
1281
|
result: {
|
|
1473
|
-
from:
|
|
1474
|
-
to:
|
|
1282
|
+
from: z11.record(AddressZod4, BigIntToJsonZod5),
|
|
1283
|
+
to: z11.record(AddressZod4, JsonToBigIntZod5)
|
|
1475
1284
|
}
|
|
1476
1285
|
},
|
|
1477
1286
|
networkStakingStepRewardsByStakerViewer_claimed: {
|
|
1478
1287
|
params: {
|
|
1479
|
-
from:
|
|
1480
|
-
|
|
1288
|
+
from: z11.tuple([
|
|
1289
|
+
RewardsRangeOptionsZod2.optional()
|
|
1481
1290
|
]),
|
|
1482
|
-
to:
|
|
1483
|
-
|
|
1291
|
+
to: z11.tuple([
|
|
1292
|
+
RewardsRangeOptionsZod2.optional()
|
|
1484
1293
|
])
|
|
1485
1294
|
},
|
|
1486
1295
|
result: {
|
|
1487
|
-
from:
|
|
1488
|
-
to:
|
|
1296
|
+
from: z11.record(AddressZod4, BigIntToJsonZod5),
|
|
1297
|
+
to: z11.record(AddressZod4, JsonToBigIntZod5)
|
|
1489
1298
|
}
|
|
1490
1299
|
},
|
|
1491
1300
|
networkStakingStepRewardsByStakerViewer_earned: {
|
|
1492
1301
|
params: {
|
|
1493
|
-
from:
|
|
1494
|
-
|
|
1302
|
+
from: z11.tuple([
|
|
1303
|
+
RewardsRangeOptionsZod2.optional()
|
|
1495
1304
|
]),
|
|
1496
|
-
to:
|
|
1497
|
-
|
|
1305
|
+
to: z11.tuple([
|
|
1306
|
+
RewardsRangeOptionsZod2.optional()
|
|
1498
1307
|
])
|
|
1499
1308
|
},
|
|
1500
1309
|
result: {
|
|
1501
|
-
from:
|
|
1502
|
-
to:
|
|
1310
|
+
from: z11.record(AddressZod4, BigIntToJsonZod5),
|
|
1311
|
+
to: z11.record(AddressZod4, JsonToBigIntZod5)
|
|
1503
1312
|
}
|
|
1504
1313
|
},
|
|
1505
1314
|
networkStakingStepRewardsByStakerViewer_total: {
|
|
1506
1315
|
params: {
|
|
1507
|
-
from:
|
|
1508
|
-
|
|
1316
|
+
from: z11.tuple([
|
|
1317
|
+
RewardsRangeOptionsZod2.optional()
|
|
1509
1318
|
]),
|
|
1510
|
-
to:
|
|
1511
|
-
|
|
1319
|
+
to: z11.tuple([
|
|
1320
|
+
RewardsRangeOptionsZod2.optional()
|
|
1512
1321
|
])
|
|
1513
1322
|
},
|
|
1514
1323
|
result: {
|
|
1515
|
-
from:
|
|
1516
|
-
to:
|
|
1324
|
+
from: z11.record(AddressZod4, BigIntToJsonZod5),
|
|
1325
|
+
to: z11.record(AddressZod4, JsonToBigIntZod5)
|
|
1517
1326
|
}
|
|
1518
1327
|
},
|
|
1519
1328
|
networkStakingStepRewardsByStakerViewer_unclaimed: {
|
|
1520
1329
|
params: {
|
|
1521
|
-
from:
|
|
1522
|
-
|
|
1330
|
+
from: z11.tuple([
|
|
1331
|
+
RewardsRangeOptionsZod2.optional()
|
|
1523
1332
|
]),
|
|
1524
|
-
to:
|
|
1525
|
-
|
|
1333
|
+
to: z11.tuple([
|
|
1334
|
+
RewardsRangeOptionsZod2.optional()
|
|
1526
1335
|
])
|
|
1527
1336
|
},
|
|
1528
1337
|
result: {
|
|
1529
|
-
from:
|
|
1530
|
-
to:
|
|
1338
|
+
from: z11.record(AddressZod4, BigIntToJsonZod5),
|
|
1339
|
+
to: z11.record(AddressZod4, JsonToBigIntZod5)
|
|
1531
1340
|
}
|
|
1532
1341
|
}
|
|
1533
1342
|
};
|
|
1534
1343
|
|
|
1535
1344
|
// src/types/schema/RewardsByStepViewerRpcSchemas.ts
|
|
1536
|
-
import { AddressZod as
|
|
1537
|
-
import
|
|
1345
|
+
import { AddressZod as AddressZod5, BigIntToJsonZod as BigIntToJsonZod6, JsonToBigIntZod as JsonToBigIntZod6 } from "@xylabs/sdk-js";
|
|
1346
|
+
import { RewardsRangeOptionsZod as RewardsRangeOptionsZod3 } from "@xyo-network/xl1-protocol-sdk";
|
|
1347
|
+
import z12 from "zod";
|
|
1538
1348
|
var NetworkStakingStepRewardsByStepViewerRpcSchemas = {
|
|
1539
1349
|
networkStakingStepRewardsByStepViewer_bonus: {
|
|
1540
1350
|
params: {
|
|
1541
|
-
from:
|
|
1542
|
-
|
|
1351
|
+
from: z12.tuple([
|
|
1352
|
+
RewardsRangeOptionsZod3.optional()
|
|
1543
1353
|
]),
|
|
1544
|
-
to:
|
|
1545
|
-
|
|
1354
|
+
to: z12.tuple([
|
|
1355
|
+
RewardsRangeOptionsZod3.optional()
|
|
1546
1356
|
])
|
|
1547
1357
|
},
|
|
1548
1358
|
result: {
|
|
1549
|
-
from:
|
|
1550
|
-
to:
|
|
1359
|
+
from: z12.record(AddressZod5, BigIntToJsonZod6),
|
|
1360
|
+
to: z12.record(AddressZod5, JsonToBigIntZod6)
|
|
1551
1361
|
}
|
|
1552
1362
|
},
|
|
1553
1363
|
networkStakingStepRewardsByStepViewer_claimed: {
|
|
1554
1364
|
params: {
|
|
1555
|
-
from:
|
|
1556
|
-
|
|
1365
|
+
from: z12.tuple([
|
|
1366
|
+
RewardsRangeOptionsZod3.optional()
|
|
1557
1367
|
]),
|
|
1558
|
-
to:
|
|
1559
|
-
|
|
1368
|
+
to: z12.tuple([
|
|
1369
|
+
RewardsRangeOptionsZod3.optional()
|
|
1560
1370
|
])
|
|
1561
1371
|
},
|
|
1562
1372
|
result: {
|
|
1563
|
-
from:
|
|
1564
|
-
to:
|
|
1373
|
+
from: z12.record(AddressZod5, BigIntToJsonZod6),
|
|
1374
|
+
to: z12.record(AddressZod5, JsonToBigIntZod6)
|
|
1565
1375
|
}
|
|
1566
1376
|
},
|
|
1567
1377
|
networkStakingStepRewardsByStepViewer_earned: {
|
|
1568
1378
|
params: {
|
|
1569
|
-
from:
|
|
1570
|
-
|
|
1379
|
+
from: z12.tuple([
|
|
1380
|
+
RewardsRangeOptionsZod3.optional()
|
|
1571
1381
|
]),
|
|
1572
|
-
to:
|
|
1573
|
-
|
|
1382
|
+
to: z12.tuple([
|
|
1383
|
+
RewardsRangeOptionsZod3.optional()
|
|
1574
1384
|
])
|
|
1575
1385
|
},
|
|
1576
1386
|
result: {
|
|
1577
|
-
from:
|
|
1578
|
-
to:
|
|
1387
|
+
from: z12.record(AddressZod5, BigIntToJsonZod6),
|
|
1388
|
+
to: z12.record(AddressZod5, JsonToBigIntZod6)
|
|
1579
1389
|
}
|
|
1580
1390
|
},
|
|
1581
1391
|
networkStakingStepRewardsByStepViewer_total: {
|
|
1582
1392
|
params: {
|
|
1583
|
-
from:
|
|
1584
|
-
|
|
1393
|
+
from: z12.tuple([
|
|
1394
|
+
RewardsRangeOptionsZod3.optional()
|
|
1585
1395
|
]),
|
|
1586
|
-
to:
|
|
1587
|
-
|
|
1396
|
+
to: z12.tuple([
|
|
1397
|
+
RewardsRangeOptionsZod3.optional()
|
|
1588
1398
|
])
|
|
1589
1399
|
},
|
|
1590
1400
|
result: {
|
|
1591
|
-
from:
|
|
1592
|
-
to:
|
|
1401
|
+
from: z12.record(AddressZod5, BigIntToJsonZod6),
|
|
1402
|
+
to: z12.record(AddressZod5, JsonToBigIntZod6)
|
|
1593
1403
|
}
|
|
1594
1404
|
},
|
|
1595
1405
|
networkStakingStepRewardsByStepViewer_unclaimed: {
|
|
1596
1406
|
params: {
|
|
1597
|
-
from:
|
|
1598
|
-
|
|
1407
|
+
from: z12.tuple([
|
|
1408
|
+
RewardsRangeOptionsZod3.optional()
|
|
1599
1409
|
]),
|
|
1600
|
-
to:
|
|
1601
|
-
|
|
1410
|
+
to: z12.tuple([
|
|
1411
|
+
RewardsRangeOptionsZod3.optional()
|
|
1602
1412
|
])
|
|
1603
1413
|
},
|
|
1604
1414
|
result: {
|
|
1605
|
-
from:
|
|
1606
|
-
to:
|
|
1415
|
+
from: z12.record(AddressZod5, BigIntToJsonZod6),
|
|
1416
|
+
to: z12.record(AddressZod5, JsonToBigIntZod6)
|
|
1607
1417
|
}
|
|
1608
1418
|
}
|
|
1609
1419
|
};
|
|
1610
1420
|
|
|
1611
1421
|
// src/types/schema/RewardsTotalViewerRpcSchemas.ts
|
|
1612
1422
|
import { BigIntToJsonZod as BigIntToJsonZod7, JsonToBigIntZod as JsonToBigIntZod7 } from "@xylabs/sdk-js";
|
|
1613
|
-
import { asAttoXL1 as
|
|
1614
|
-
import
|
|
1423
|
+
import { asAttoXL1 as asAttoXL12 } from "@xyo-network/xl1-protocol";
|
|
1424
|
+
import { RewardsRangeOptionsZod as RewardsRangeOptionsZod4 } from "@xyo-network/xl1-protocol-sdk";
|
|
1425
|
+
import * as z13 from "zod";
|
|
1615
1426
|
var NetworkStakingStepRewardsTotalViewerRpcSchemas = {
|
|
1616
1427
|
networkStakingStepRewardsTotalViewer_bonus: {
|
|
1617
1428
|
params: {
|
|
1618
|
-
from:
|
|
1619
|
-
|
|
1429
|
+
from: z13.tuple([
|
|
1430
|
+
RewardsRangeOptionsZod4.optional()
|
|
1620
1431
|
]),
|
|
1621
|
-
to:
|
|
1622
|
-
|
|
1432
|
+
to: z13.tuple([
|
|
1433
|
+
RewardsRangeOptionsZod4.optional()
|
|
1623
1434
|
])
|
|
1624
1435
|
},
|
|
1625
1436
|
result: {
|
|
1626
|
-
from: JsonToBigIntZod7.transform((val) =>
|
|
1437
|
+
from: JsonToBigIntZod7.transform((val) => asAttoXL12(val)),
|
|
1627
1438
|
to: BigIntToJsonZod7
|
|
1628
1439
|
}
|
|
1629
1440
|
},
|
|
1630
1441
|
networkStakingStepRewardsTotalViewer_claimed: {
|
|
1631
1442
|
params: {
|
|
1632
|
-
from:
|
|
1633
|
-
|
|
1443
|
+
from: z13.tuple([
|
|
1444
|
+
RewardsRangeOptionsZod4.optional()
|
|
1634
1445
|
]),
|
|
1635
|
-
to:
|
|
1636
|
-
|
|
1446
|
+
to: z13.tuple([
|
|
1447
|
+
RewardsRangeOptionsZod4.optional()
|
|
1637
1448
|
])
|
|
1638
1449
|
},
|
|
1639
1450
|
result: {
|
|
1640
|
-
from: JsonToBigIntZod7.transform((val) =>
|
|
1451
|
+
from: JsonToBigIntZod7.transform((val) => asAttoXL12(val)),
|
|
1641
1452
|
to: BigIntToJsonZod7
|
|
1642
1453
|
}
|
|
1643
1454
|
},
|
|
1644
1455
|
networkStakingStepRewardsTotalViewer_earned: {
|
|
1645
1456
|
params: {
|
|
1646
|
-
from:
|
|
1647
|
-
|
|
1457
|
+
from: z13.tuple([
|
|
1458
|
+
RewardsRangeOptionsZod4.optional()
|
|
1648
1459
|
]),
|
|
1649
|
-
to:
|
|
1650
|
-
|
|
1460
|
+
to: z13.tuple([
|
|
1461
|
+
RewardsRangeOptionsZod4.optional()
|
|
1651
1462
|
])
|
|
1652
1463
|
},
|
|
1653
1464
|
result: {
|
|
1654
|
-
from: JsonToBigIntZod7.transform((val) =>
|
|
1465
|
+
from: JsonToBigIntZod7.transform((val) => asAttoXL12(val)),
|
|
1655
1466
|
to: BigIntToJsonZod7
|
|
1656
1467
|
}
|
|
1657
1468
|
},
|
|
1658
1469
|
networkStakingStepRewardsTotalViewer_total: {
|
|
1659
1470
|
params: {
|
|
1660
|
-
from:
|
|
1661
|
-
|
|
1471
|
+
from: z13.tuple([
|
|
1472
|
+
RewardsRangeOptionsZod4.optional()
|
|
1662
1473
|
]),
|
|
1663
|
-
to:
|
|
1664
|
-
|
|
1474
|
+
to: z13.tuple([
|
|
1475
|
+
RewardsRangeOptionsZod4.optional()
|
|
1665
1476
|
])
|
|
1666
1477
|
},
|
|
1667
1478
|
result: {
|
|
1668
|
-
from: JsonToBigIntZod7.transform((val) =>
|
|
1479
|
+
from: JsonToBigIntZod7.transform((val) => asAttoXL12(val)),
|
|
1669
1480
|
to: BigIntToJsonZod7
|
|
1670
1481
|
}
|
|
1671
1482
|
},
|
|
1672
1483
|
networkStakingStepRewardsTotalViewer_unclaimed: {
|
|
1673
1484
|
params: {
|
|
1674
|
-
from:
|
|
1675
|
-
|
|
1485
|
+
from: z13.tuple([
|
|
1486
|
+
RewardsRangeOptionsZod4.optional()
|
|
1676
1487
|
]),
|
|
1677
|
-
to:
|
|
1678
|
-
|
|
1488
|
+
to: z13.tuple([
|
|
1489
|
+
RewardsRangeOptionsZod4.optional()
|
|
1679
1490
|
])
|
|
1680
1491
|
},
|
|
1681
1492
|
result: {
|
|
1682
|
-
from: JsonToBigIntZod7.transform((val) =>
|
|
1493
|
+
from: JsonToBigIntZod7.transform((val) => asAttoXL12(val)),
|
|
1683
1494
|
to: BigIntToJsonZod7
|
|
1684
1495
|
}
|
|
1685
1496
|
}
|
|
@@ -1690,70 +1501,71 @@ var NetworkStakingStepRewardsViewerRpcSchemas = {};
|
|
|
1690
1501
|
|
|
1691
1502
|
// src/types/schema/TimeSyncViewerRpcSchema.ts
|
|
1692
1503
|
import { TimePayloadZod } from "@xyo-network/xl1-protocol";
|
|
1693
|
-
import
|
|
1504
|
+
import { TimeDomainZod } from "@xyo-network/xl1-protocol-sdk";
|
|
1505
|
+
import * as z14 from "zod";
|
|
1694
1506
|
var TimeSyncViewerRpcSchemas = {
|
|
1695
1507
|
timeSyncViewer_convertTime: {
|
|
1696
1508
|
params: {
|
|
1697
|
-
from:
|
|
1509
|
+
from: z14.tuple([
|
|
1698
1510
|
TimeDomainZod,
|
|
1699
1511
|
TimeDomainZod,
|
|
1700
|
-
|
|
1512
|
+
z14.number()
|
|
1701
1513
|
]),
|
|
1702
|
-
to:
|
|
1514
|
+
to: z14.tuple([
|
|
1703
1515
|
TimeDomainZod,
|
|
1704
1516
|
TimeDomainZod,
|
|
1705
|
-
|
|
1517
|
+
z14.number()
|
|
1706
1518
|
])
|
|
1707
1519
|
},
|
|
1708
1520
|
result: {
|
|
1709
|
-
from:
|
|
1710
|
-
to:
|
|
1521
|
+
from: z14.number(),
|
|
1522
|
+
to: z14.number()
|
|
1711
1523
|
}
|
|
1712
1524
|
},
|
|
1713
1525
|
timeSyncViewer_currentTime: {
|
|
1714
1526
|
params: {
|
|
1715
|
-
from:
|
|
1527
|
+
from: z14.tuple([
|
|
1716
1528
|
TimeDomainZod
|
|
1717
1529
|
]),
|
|
1718
|
-
to:
|
|
1530
|
+
to: z14.tuple([
|
|
1719
1531
|
TimeDomainZod
|
|
1720
1532
|
])
|
|
1721
1533
|
},
|
|
1722
1534
|
result: {
|
|
1723
|
-
from:
|
|
1535
|
+
from: z14.tuple([
|
|
1724
1536
|
TimeDomainZod,
|
|
1725
|
-
|
|
1537
|
+
z14.number()
|
|
1726
1538
|
]),
|
|
1727
|
-
to:
|
|
1539
|
+
to: z14.tuple([
|
|
1728
1540
|
TimeDomainZod,
|
|
1729
|
-
|
|
1541
|
+
z14.number()
|
|
1730
1542
|
])
|
|
1731
1543
|
}
|
|
1732
1544
|
},
|
|
1733
1545
|
timeSyncViewer_currentTimeAndHash: {
|
|
1734
1546
|
params: {
|
|
1735
|
-
from:
|
|
1547
|
+
from: z14.tuple([
|
|
1736
1548
|
TimeDomainZod
|
|
1737
1549
|
]),
|
|
1738
|
-
to:
|
|
1550
|
+
to: z14.tuple([
|
|
1739
1551
|
TimeDomainZod
|
|
1740
1552
|
])
|
|
1741
1553
|
},
|
|
1742
1554
|
result: {
|
|
1743
|
-
from:
|
|
1744
|
-
|
|
1745
|
-
|
|
1555
|
+
from: z14.tuple([
|
|
1556
|
+
z14.number(),
|
|
1557
|
+
z14.nullable(z14.string())
|
|
1746
1558
|
]),
|
|
1747
|
-
to:
|
|
1748
|
-
|
|
1749
|
-
|
|
1559
|
+
to: z14.tuple([
|
|
1560
|
+
z14.number(),
|
|
1561
|
+
z14.nullable(z14.string())
|
|
1750
1562
|
])
|
|
1751
1563
|
}
|
|
1752
1564
|
},
|
|
1753
1565
|
timeSyncViewer_currentTimePayload: {
|
|
1754
1566
|
params: {
|
|
1755
|
-
from:
|
|
1756
|
-
to:
|
|
1567
|
+
from: z14.tuple([]),
|
|
1568
|
+
to: z14.tuple([])
|
|
1757
1569
|
},
|
|
1758
1570
|
result: {
|
|
1759
1571
|
from: TimePayloadZod,
|
|
@@ -1948,6 +1760,56 @@ var NodeXyoRunner = class {
|
|
|
1948
1760
|
}, "getPendingArchivist");
|
|
1949
1761
|
};
|
|
1950
1762
|
|
|
1763
|
+
// src/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewer.ts
|
|
1764
|
+
import { asAttoXL1 as asAttoXL13 } from "@xyo-network/xl1-protocol";
|
|
1765
|
+
|
|
1766
|
+
// src/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewerMethods.ts
|
|
1767
|
+
var JsonRpcAccountBalanceViewerMethods = class {
|
|
1768
|
+
static {
|
|
1769
|
+
__name(this, "JsonRpcAccountBalanceViewerMethods");
|
|
1770
|
+
}
|
|
1771
|
+
transport;
|
|
1772
|
+
constructor(transport) {
|
|
1773
|
+
this.transport = transport;
|
|
1774
|
+
}
|
|
1775
|
+
async accountsBalances(address, headOrRange) {
|
|
1776
|
+
return await this.transport.sendRequest("accountBalanceViewer_accountsBalances", headOrRange ? [
|
|
1777
|
+
address,
|
|
1778
|
+
headOrRange
|
|
1779
|
+
] : [
|
|
1780
|
+
address
|
|
1781
|
+
]);
|
|
1782
|
+
}
|
|
1783
|
+
async accountsBalancesHistory(address, headOrRange) {
|
|
1784
|
+
return await this.transport.sendRequest("accountBalanceViewer_accountsBalancesHistory", headOrRange ? [
|
|
1785
|
+
address,
|
|
1786
|
+
headOrRange
|
|
1787
|
+
] : [
|
|
1788
|
+
address
|
|
1789
|
+
]);
|
|
1790
|
+
}
|
|
1791
|
+
};
|
|
1792
|
+
|
|
1793
|
+
// src/provider/viewer/JsonRpcAccountBalanceViewer/JsonRpcAccountBalanceViewer.ts
|
|
1794
|
+
var JsonRpcAccountBalanceViewer = class extends JsonRpcAccountBalanceViewerMethods {
|
|
1795
|
+
static {
|
|
1796
|
+
__name(this, "JsonRpcAccountBalanceViewer");
|
|
1797
|
+
}
|
|
1798
|
+
constructor(transport) {
|
|
1799
|
+
super(transport);
|
|
1800
|
+
}
|
|
1801
|
+
async accountBalance(address, headOrRange) {
|
|
1802
|
+
return (await this.accountsBalances([
|
|
1803
|
+
address
|
|
1804
|
+
], headOrRange))[address] ?? asAttoXL13(0);
|
|
1805
|
+
}
|
|
1806
|
+
async accountBalanceHistory(address, headOrRange) {
|
|
1807
|
+
return (await this.accountsBalancesHistory([
|
|
1808
|
+
address
|
|
1809
|
+
], headOrRange))[address] ?? [];
|
|
1810
|
+
}
|
|
1811
|
+
};
|
|
1812
|
+
|
|
1951
1813
|
// src/provider/viewer/JsonRpcViewer.ts
|
|
1952
1814
|
var JsonRpcViewer = class {
|
|
1953
1815
|
static {
|
|
@@ -2059,8 +1921,7 @@ var JsonRpcTimeSyncViewer = class extends JsonRpcTimeSyncViewerMethods {
|
|
|
2059
1921
|
};
|
|
2060
1922
|
|
|
2061
1923
|
// src/provider/viewer/JsonRpcXyoViewer.ts
|
|
2062
|
-
import { isHash } from "@xylabs/sdk-js";
|
|
2063
|
-
import { isDefined } from "@xylabs/sdk-js";
|
|
1924
|
+
import { isDefined, isHash } from "@xylabs/sdk-js";
|
|
2064
1925
|
import { asAttoXL1 as asAttoXL14, asHydratedBlock } from "@xyo-network/xl1-protocol";
|
|
2065
1926
|
var JsonRpcXyoViewer = class {
|
|
2066
1927
|
static {
|
|
@@ -2075,10 +1936,22 @@ var JsonRpcXyoViewer = class {
|
|
|
2075
1936
|
get networkStakeViewer() {
|
|
2076
1937
|
return this.providers?.networkStakeViewer;
|
|
2077
1938
|
}
|
|
2078
|
-
async accountBalance(address) {
|
|
2079
|
-
|
|
1939
|
+
async accountBalance(address, headOrRange) {
|
|
1940
|
+
if (isDefined(headOrRange)) {
|
|
1941
|
+
if (isHash(headOrRange)) {
|
|
1942
|
+
return await this.transport.sendRequest("xyoViewer_accountBalance", [
|
|
1943
|
+
address,
|
|
1944
|
+
headOrRange
|
|
1945
|
+
]);
|
|
1946
|
+
}
|
|
1947
|
+
return await this.transport.sendRequest("xyoViewer_accountBalance", [
|
|
1948
|
+
address,
|
|
1949
|
+
headOrRange
|
|
1950
|
+
]);
|
|
1951
|
+
}
|
|
1952
|
+
return await this.transport.sendRequest("xyoViewer_accountBalance", [
|
|
2080
1953
|
address
|
|
2081
|
-
])
|
|
1954
|
+
]);
|
|
2082
1955
|
}
|
|
2083
1956
|
async accountBalanceHistory(address, headOrRange) {
|
|
2084
1957
|
if (isDefined(headOrRange)) {
|
|
@@ -2097,6 +1970,12 @@ var JsonRpcXyoViewer = class {
|
|
|
2097
1970
|
address
|
|
2098
1971
|
]);
|
|
2099
1972
|
}
|
|
1973
|
+
accountsBalances(address, headOrRange) {
|
|
1974
|
+
throw new Error("Method not implemented.");
|
|
1975
|
+
}
|
|
1976
|
+
accountsBalancesHistory(address, headOrRange) {
|
|
1977
|
+
throw new Error("Method not implemented.");
|
|
1978
|
+
}
|
|
2100
1979
|
async blockByHash(hash) {
|
|
2101
1980
|
return asHydratedBlock(await this.transport.sendRequest("xyoViewer_blockByHash", [
|
|
2102
1981
|
hash
|
|
@@ -2416,32 +2295,15 @@ var RpcXyoSigner = class {
|
|
|
2416
2295
|
}
|
|
2417
2296
|
};
|
|
2418
2297
|
export {
|
|
2298
|
+
AccountBalanceViewerRpcNamespace,
|
|
2299
|
+
AccountBalanceViewerRpcSchemas,
|
|
2419
2300
|
AllRpcSchemas,
|
|
2420
|
-
AnyBoundWitnessZod,
|
|
2421
|
-
AnySignedBoundWitnessWithStorageMetaZod,
|
|
2422
|
-
AnySignedBoundWitnessZod,
|
|
2423
|
-
AnyUnsignedBoundWitnessZod,
|
|
2424
|
-
ArrayBufferToJsonZod,
|
|
2425
|
-
AttoToJsonZod,
|
|
2426
|
-
AttoZod,
|
|
2427
|
-
BlockBoundWitnessZod,
|
|
2428
|
-
BlockDurationZod,
|
|
2429
|
-
BlockEndZod,
|
|
2430
|
-
BlockScriptsZod,
|
|
2431
|
-
BlockStartZod,
|
|
2432
|
-
BoundWitnessZod,
|
|
2433
|
-
CaveatTypesZod,
|
|
2434
|
-
CaveatsZod,
|
|
2435
|
-
ChainZod,
|
|
2436
2301
|
DataLakeViewerRpcNamespace,
|
|
2437
2302
|
DataLakeViewerRpcSchemas,
|
|
2438
2303
|
HttpRpcTransport,
|
|
2439
2304
|
HttpRpcXyoConnection,
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
HydratedTransactionZod,
|
|
2443
|
-
InvokerPermissionZod,
|
|
2444
|
-
JsonObjectZod,
|
|
2305
|
+
JsonRpcAccountBalanceViewer,
|
|
2306
|
+
JsonRpcAccountBalanceViewerMethods,
|
|
2445
2307
|
JsonRpcDataLakeViewer,
|
|
2446
2308
|
JsonRpcDataLakeViewerMethods,
|
|
2447
2309
|
JsonRpcErrorCodes,
|
|
@@ -2454,12 +2316,6 @@ export {
|
|
|
2454
2316
|
JsonRpcViewer,
|
|
2455
2317
|
JsonRpcXyoRunner,
|
|
2456
2318
|
JsonRpcXyoViewer,
|
|
2457
|
-
JsonToArrayBufferZod,
|
|
2458
|
-
JsonToAttoZod,
|
|
2459
|
-
JsonToSignedHydratedTransactionZod,
|
|
2460
|
-
JsonToStakeZod,
|
|
2461
|
-
LocalSequenceFromStringZod,
|
|
2462
|
-
LocalSequenceToStringZod,
|
|
2463
2319
|
MemoryRpcTransport,
|
|
2464
2320
|
NetworkStakeViewerRpcNamespace,
|
|
2465
2321
|
NetworkStakeViewerRpcSchemas,
|
|
@@ -2474,40 +2330,10 @@ export {
|
|
|
2474
2330
|
NetworkStakingStepRewardsViewerRpcNamespace,
|
|
2475
2331
|
NetworkStakingStepRewardsViewerRpcSchemas,
|
|
2476
2332
|
NodeXyoRunner,
|
|
2477
|
-
PermissionRequestZod,
|
|
2478
|
-
PermissionZod,
|
|
2479
|
-
QualifiedSequenceFromStringZod,
|
|
2480
|
-
QualifiedSequenceToStringZod,
|
|
2481
|
-
RequestedPermissionZod,
|
|
2482
|
-
RewardsRangeOptionsZod,
|
|
2483
2333
|
RpcXyoPermissions,
|
|
2484
2334
|
RpcXyoSigner,
|
|
2485
|
-
SequenceFromStringZod,
|
|
2486
|
-
SequenceToStringZod,
|
|
2487
|
-
SignedBlockBoundWitnessZod,
|
|
2488
|
-
SignedBoundWitnessWithStorageMetaZod,
|
|
2489
|
-
SignedBoundWitnessZod,
|
|
2490
|
-
SignedHydratedBlockToJsonZod,
|
|
2491
|
-
SignedHydratedBlockWithStorageMetaZod,
|
|
2492
|
-
SignedHydratedBlockZod,
|
|
2493
|
-
SignedHydratedTransactionToJsonZod,
|
|
2494
|
-
SignedHydratedTransactionZod,
|
|
2495
|
-
SignedTransactionBoundWitnessZod,
|
|
2496
|
-
StakeToJsonZod,
|
|
2497
|
-
StakeZod,
|
|
2498
|
-
TimeDomainZod,
|
|
2499
2335
|
TimeSyncViewerRpcNamespace,
|
|
2500
2336
|
TimeSyncViewerRpcSchemas,
|
|
2501
|
-
TransactionBoundWitnessZod,
|
|
2502
|
-
TransactionFeesBigIntToJsonZod,
|
|
2503
|
-
TransactionFeesBigIntZod,
|
|
2504
|
-
TransactionFeesHexZod,
|
|
2505
|
-
TransactionFeesJsonToBigIntZod,
|
|
2506
|
-
TransferPairZod,
|
|
2507
|
-
UnsignedBoundWitnessWithStorageMetaZod,
|
|
2508
|
-
UnsignedBoundWitnessZod,
|
|
2509
|
-
UnsignedHydratedTransactionZod,
|
|
2510
|
-
WithTransactionFeesZod,
|
|
2511
2337
|
XyoBaseConnection,
|
|
2512
2338
|
XyoPermissionsRpcSchemas,
|
|
2513
2339
|
XyoRunnerRpcSchemas,
|