@dedot/chaintypes 0.0.1-alpha.8 → 0.0.1-alpha.80

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.
Files changed (298) hide show
  1. package/README.md +3 -1
  2. package/aleph/consts.d.ts +675 -532
  3. package/aleph/errors.d.ts +1053 -821
  4. package/aleph/events.d.ts +1144 -940
  5. package/aleph/index.d.ts +19 -11
  6. package/aleph/json-rpc.d.ts +85 -0
  7. package/aleph/query.d.ts +1572 -1270
  8. package/aleph/runtime.d.ts +595 -409
  9. package/aleph/tx.d.ts +3439 -2205
  10. package/aleph/types.d.ts +3756 -5365
  11. package/astar/consts.d.ts +694 -678
  12. package/astar/errors.d.ts +1468 -1316
  13. package/astar/events.d.ts +1745 -1630
  14. package/astar/index.d.ts +19 -11
  15. package/astar/json-rpc.d.ts +82 -0
  16. package/astar/query.d.ts +1761 -1473
  17. package/astar/runtime.d.ts +769 -261
  18. package/astar/tx.d.ts +4423 -4809
  19. package/astar/types.d.ts +6088 -12266
  20. package/index.d.ts +1 -0
  21. package/index.ts +11 -0
  22. package/kusama/consts.d.ts +1577 -1426
  23. package/kusama/errors.d.ts +3151 -2493
  24. package/kusama/events.d.ts +3323 -2704
  25. package/kusama/index.d.ts +19 -11
  26. package/kusama/json-rpc.d.ts +103 -0
  27. package/kusama/query.d.ts +4228 -3250
  28. package/kusama/runtime.d.ts +1195 -843
  29. package/kusama/tx.d.ts +9039 -6013
  30. package/kusama/types.d.ts +10866 -15400
  31. package/kusamaAssetHub/consts.d.ts +758 -631
  32. package/kusamaAssetHub/errors.d.ts +1493 -1163
  33. package/kusamaAssetHub/events.d.ts +2369 -2040
  34. package/kusamaAssetHub/index.d.ts +19 -11
  35. package/kusamaAssetHub/json-rpc.d.ts +89 -0
  36. package/kusamaAssetHub/query.d.ts +1661 -1300
  37. package/kusamaAssetHub/runtime.d.ts +554 -401
  38. package/kusamaAssetHub/tx.d.ts +6191 -4216
  39. package/kusamaAssetHub/types.d.ts +6551 -10138
  40. package/moonbeam/consts.d.ts +1022 -960
  41. package/moonbeam/errors.d.ts +1938 -1796
  42. package/moonbeam/events.d.ts +2832 -2685
  43. package/moonbeam/index.d.ts +19 -11
  44. package/moonbeam/json-rpc.d.ts +137 -0
  45. package/moonbeam/query.d.ts +2396 -2026
  46. package/moonbeam/runtime.d.ts +686 -505
  47. package/moonbeam/tx.d.ts +6368 -5204
  48. package/moonbeam/types.d.ts +7782 -12033
  49. package/package.json +8 -16
  50. package/polkadot/consts.d.ts +1312 -1159
  51. package/polkadot/errors.d.ts +2574 -2019
  52. package/polkadot/events.d.ts +2591 -2069
  53. package/polkadot/index.d.ts +19 -11
  54. package/polkadot/json-rpc.d.ts +103 -0
  55. package/polkadot/query.d.ts +3692 -2810
  56. package/polkadot/runtime.d.ts +1195 -843
  57. package/polkadot/tx.d.ts +7705 -5008
  58. package/polkadot/types.d.ts +9490 -13326
  59. package/polkadotAssetHub/consts.d.ts +723 -523
  60. package/polkadotAssetHub/errors.d.ts +1464 -924
  61. package/polkadotAssetHub/events.d.ts +2346 -1671
  62. package/polkadotAssetHub/index.d.ts +19 -11
  63. package/polkadotAssetHub/json-rpc.d.ts +89 -0
  64. package/polkadotAssetHub/query.d.ts +1639 -1221
  65. package/polkadotAssetHub/runtime.d.ts +557 -358
  66. package/polkadotAssetHub/tx.d.ts +6120 -3491
  67. package/polkadotAssetHub/types.d.ts +6474 -8899
  68. package/rococo/consts.d.ts +1423 -0
  69. package/rococo/errors.d.ts +2783 -0
  70. package/rococo/events.d.ts +3361 -0
  71. package/rococo/index.d.ts +27 -0
  72. package/rococo/json-rpc.d.ts +103 -0
  73. package/rococo/query.d.ts +3535 -0
  74. package/rococo/runtime.d.ts +1217 -0
  75. package/rococo/tx.d.ts +10657 -0
  76. package/rococo/types.d.ts +14776 -0
  77. package/rococoAssetHub/consts.d.ts +820 -657
  78. package/rococoAssetHub/errors.d.ts +1567 -1230
  79. package/rococoAssetHub/events.d.ts +2382 -2040
  80. package/rococoAssetHub/index.d.ts +19 -11
  81. package/rococoAssetHub/json-rpc.d.ts +89 -0
  82. package/rococoAssetHub/query.d.ts +1694 -1268
  83. package/rococoAssetHub/runtime.d.ts +578 -427
  84. package/rococoAssetHub/tx.d.ts +9171 -4306
  85. package/rococoAssetHub/types.d.ts +12252 -10796
  86. package/substrate/consts.d.ts +2222 -1970
  87. package/substrate/errors.d.ts +4022 -3336
  88. package/substrate/events.d.ts +4924 -4271
  89. package/substrate/index.d.ts +19 -11
  90. package/substrate/json-rpc.d.ts +101 -0
  91. package/substrate/query.d.ts +4082 -3349
  92. package/substrate/runtime.d.ts +970 -707
  93. package/substrate/tx.d.ts +12500 -8799
  94. package/substrate/types.d.ts +12809 -19761
  95. package/westendAssetHub/consts.d.ts +786 -657
  96. package/westendAssetHub/errors.d.ts +1522 -1230
  97. package/westendAssetHub/events.d.ts +2345 -2040
  98. package/westendAssetHub/index.d.ts +19 -11
  99. package/westendAssetHub/json-rpc.d.ts +89 -0
  100. package/westendAssetHub/query.d.ts +1655 -1268
  101. package/westendAssetHub/runtime.d.ts +651 -455
  102. package/westendAssetHub/tx.d.ts +8983 -4306
  103. package/westendAssetHub/types.d.ts +12027 -10797
  104. package/aleph/consts.js +0 -2
  105. package/aleph/errors.js +0 -2
  106. package/aleph/events.js +0 -2
  107. package/aleph/index.js +0 -3
  108. package/aleph/query.js +0 -2
  109. package/aleph/rpc.d.ts +0 -575
  110. package/aleph/rpc.js +0 -2
  111. package/aleph/runtime.js +0 -2
  112. package/aleph/tx.js +0 -2
  113. package/aleph/types.js +0 -2
  114. package/astar/consts.js +0 -2
  115. package/astar/errors.js +0 -2
  116. package/astar/events.js +0 -2
  117. package/astar/index.js +0 -3
  118. package/astar/query.js +0 -2
  119. package/astar/rpc.d.ts +0 -775
  120. package/astar/rpc.js +0 -2
  121. package/astar/runtime.js +0 -2
  122. package/astar/tx.js +0 -2
  123. package/astar/types.js +0 -2
  124. package/cjs/aleph/consts.js +0 -3
  125. package/cjs/aleph/errors.js +0 -3
  126. package/cjs/aleph/events.js +0 -3
  127. package/cjs/aleph/index.js +0 -19
  128. package/cjs/aleph/query.js +0 -3
  129. package/cjs/aleph/rpc.js +0 -3
  130. package/cjs/aleph/runtime.js +0 -3
  131. package/cjs/aleph/tx.js +0 -3
  132. package/cjs/aleph/types.js +0 -3
  133. package/cjs/astar/consts.js +0 -3
  134. package/cjs/astar/errors.js +0 -3
  135. package/cjs/astar/events.js +0 -3
  136. package/cjs/astar/index.js +0 -19
  137. package/cjs/astar/query.js +0 -3
  138. package/cjs/astar/rpc.js +0 -3
  139. package/cjs/astar/runtime.js +0 -3
  140. package/cjs/astar/tx.js +0 -3
  141. package/cjs/astar/types.js +0 -3
  142. package/cjs/index.js +0 -2
  143. package/cjs/kusama/consts.js +0 -3
  144. package/cjs/kusama/errors.js +0 -3
  145. package/cjs/kusama/events.js +0 -3
  146. package/cjs/kusama/index.js +0 -19
  147. package/cjs/kusama/query.js +0 -3
  148. package/cjs/kusama/rpc.js +0 -3
  149. package/cjs/kusama/runtime.js +0 -3
  150. package/cjs/kusama/tx.js +0 -3
  151. package/cjs/kusama/types.js +0 -3
  152. package/cjs/kusamaAssetHub/consts.js +0 -3
  153. package/cjs/kusamaAssetHub/errors.js +0 -3
  154. package/cjs/kusamaAssetHub/events.js +0 -3
  155. package/cjs/kusamaAssetHub/index.js +0 -19
  156. package/cjs/kusamaAssetHub/query.js +0 -3
  157. package/cjs/kusamaAssetHub/rpc.js +0 -3
  158. package/cjs/kusamaAssetHub/runtime.js +0 -3
  159. package/cjs/kusamaAssetHub/tx.js +0 -3
  160. package/cjs/kusamaAssetHub/types.js +0 -3
  161. package/cjs/moonbeam/consts.js +0 -3
  162. package/cjs/moonbeam/errors.js +0 -3
  163. package/cjs/moonbeam/events.js +0 -3
  164. package/cjs/moonbeam/index.js +0 -19
  165. package/cjs/moonbeam/query.js +0 -3
  166. package/cjs/moonbeam/rpc.js +0 -3
  167. package/cjs/moonbeam/runtime.js +0 -3
  168. package/cjs/moonbeam/tx.js +0 -3
  169. package/cjs/moonbeam/types.js +0 -3
  170. package/cjs/package.json +0 -1
  171. package/cjs/packageInfo.js +0 -5
  172. package/cjs/polkadot/consts.js +0 -3
  173. package/cjs/polkadot/errors.js +0 -3
  174. package/cjs/polkadot/events.js +0 -3
  175. package/cjs/polkadot/index.js +0 -19
  176. package/cjs/polkadot/query.js +0 -3
  177. package/cjs/polkadot/rpc.js +0 -3
  178. package/cjs/polkadot/runtime.js +0 -3
  179. package/cjs/polkadot/tx.js +0 -3
  180. package/cjs/polkadot/types.js +0 -3
  181. package/cjs/polkadotAssetHub/consts.js +0 -3
  182. package/cjs/polkadotAssetHub/errors.js +0 -3
  183. package/cjs/polkadotAssetHub/events.js +0 -3
  184. package/cjs/polkadotAssetHub/index.js +0 -19
  185. package/cjs/polkadotAssetHub/query.js +0 -3
  186. package/cjs/polkadotAssetHub/rpc.js +0 -3
  187. package/cjs/polkadotAssetHub/runtime.js +0 -3
  188. package/cjs/polkadotAssetHub/tx.js +0 -3
  189. package/cjs/polkadotAssetHub/types.js +0 -3
  190. package/cjs/rococoAssetHub/consts.js +0 -3
  191. package/cjs/rococoAssetHub/errors.js +0 -3
  192. package/cjs/rococoAssetHub/events.js +0 -3
  193. package/cjs/rococoAssetHub/index.js +0 -19
  194. package/cjs/rococoAssetHub/query.js +0 -3
  195. package/cjs/rococoAssetHub/rpc.js +0 -3
  196. package/cjs/rococoAssetHub/runtime.js +0 -3
  197. package/cjs/rococoAssetHub/tx.js +0 -3
  198. package/cjs/rococoAssetHub/types.js +0 -3
  199. package/cjs/substrate/consts.js +0 -3
  200. package/cjs/substrate/errors.js +0 -3
  201. package/cjs/substrate/events.js +0 -3
  202. package/cjs/substrate/index.js +0 -19
  203. package/cjs/substrate/query.js +0 -3
  204. package/cjs/substrate/rpc.js +0 -3
  205. package/cjs/substrate/runtime.js +0 -3
  206. package/cjs/substrate/tx.js +0 -3
  207. package/cjs/substrate/types.js +0 -3
  208. package/cjs/westendAssetHub/consts.js +0 -3
  209. package/cjs/westendAssetHub/errors.js +0 -3
  210. package/cjs/westendAssetHub/events.js +0 -3
  211. package/cjs/westendAssetHub/index.js +0 -19
  212. package/cjs/westendAssetHub/query.js +0 -3
  213. package/cjs/westendAssetHub/rpc.js +0 -3
  214. package/cjs/westendAssetHub/runtime.js +0 -3
  215. package/cjs/westendAssetHub/tx.js +0 -3
  216. package/cjs/westendAssetHub/types.js +0 -3
  217. package/kusama/consts.js +0 -2
  218. package/kusama/errors.js +0 -2
  219. package/kusama/events.js +0 -2
  220. package/kusama/index.js +0 -3
  221. package/kusama/query.js +0 -2
  222. package/kusama/rpc.d.ts +0 -726
  223. package/kusama/rpc.js +0 -2
  224. package/kusama/runtime.js +0 -2
  225. package/kusama/tx.js +0 -2
  226. package/kusama/types.js +0 -2
  227. package/kusamaAssetHub/consts.js +0 -2
  228. package/kusamaAssetHub/errors.js +0 -2
  229. package/kusamaAssetHub/events.js +0 -2
  230. package/kusamaAssetHub/index.js +0 -3
  231. package/kusamaAssetHub/query.js +0 -2
  232. package/kusamaAssetHub/rpc.d.ts +0 -590
  233. package/kusamaAssetHub/rpc.js +0 -2
  234. package/kusamaAssetHub/runtime.js +0 -2
  235. package/kusamaAssetHub/tx.js +0 -2
  236. package/kusamaAssetHub/types.js +0 -2
  237. package/moonbeam/consts.js +0 -2
  238. package/moonbeam/errors.js +0 -2
  239. package/moonbeam/events.js +0 -2
  240. package/moonbeam/index.js +0 -3
  241. package/moonbeam/query.js +0 -2
  242. package/moonbeam/rpc.d.ts +0 -809
  243. package/moonbeam/rpc.js +0 -2
  244. package/moonbeam/runtime.js +0 -2
  245. package/moonbeam/tx.js +0 -2
  246. package/moonbeam/types.js +0 -2
  247. package/packageInfo.d.ts +0 -4
  248. package/packageInfo.js +0 -2
  249. package/polkadot/consts.js +0 -2
  250. package/polkadot/errors.js +0 -2
  251. package/polkadot/events.js +0 -2
  252. package/polkadot/index.js +0 -3
  253. package/polkadot/query.js +0 -2
  254. package/polkadot/rpc.d.ts +0 -726
  255. package/polkadot/rpc.js +0 -2
  256. package/polkadot/runtime.js +0 -2
  257. package/polkadot/tx.js +0 -2
  258. package/polkadot/types.js +0 -2
  259. package/polkadotAssetHub/consts.js +0 -2
  260. package/polkadotAssetHub/errors.js +0 -2
  261. package/polkadotAssetHub/events.js +0 -2
  262. package/polkadotAssetHub/index.js +0 -3
  263. package/polkadotAssetHub/query.js +0 -2
  264. package/polkadotAssetHub/rpc.d.ts +0 -590
  265. package/polkadotAssetHub/rpc.js +0 -2
  266. package/polkadotAssetHub/runtime.js +0 -2
  267. package/polkadotAssetHub/tx.js +0 -2
  268. package/polkadotAssetHub/types.js +0 -2
  269. package/rococoAssetHub/consts.js +0 -2
  270. package/rococoAssetHub/errors.js +0 -2
  271. package/rococoAssetHub/events.js +0 -2
  272. package/rococoAssetHub/index.js +0 -3
  273. package/rococoAssetHub/query.js +0 -2
  274. package/rococoAssetHub/rpc.d.ts +0 -590
  275. package/rococoAssetHub/rpc.js +0 -2
  276. package/rococoAssetHub/runtime.js +0 -2
  277. package/rococoAssetHub/tx.js +0 -2
  278. package/rococoAssetHub/types.js +0 -2
  279. package/substrate/consts.js +0 -2
  280. package/substrate/errors.js +0 -2
  281. package/substrate/events.js +0 -2
  282. package/substrate/index.js +0 -3
  283. package/substrate/query.js +0 -2
  284. package/substrate/rpc.d.ts +0 -718
  285. package/substrate/rpc.js +0 -2
  286. package/substrate/runtime.js +0 -2
  287. package/substrate/tx.js +0 -2
  288. package/substrate/types.js +0 -2
  289. package/westendAssetHub/consts.js +0 -2
  290. package/westendAssetHub/errors.js +0 -2
  291. package/westendAssetHub/events.js +0 -2
  292. package/westendAssetHub/index.js +0 -3
  293. package/westendAssetHub/query.js +0 -2
  294. package/westendAssetHub/rpc.d.ts +0 -590
  295. package/westendAssetHub/rpc.js +0 -2
  296. package/westendAssetHub/runtime.js +0 -2
  297. package/westendAssetHub/tx.js +0 -2
  298. package/westendAssetHub/types.js +0 -2
@@ -0,0 +1,1217 @@
1
+ // Generated by @dedot/codegen
2
+
3
+ import type { GenericRuntimeApis, GenericRuntimeApiMethod, RpcVersion } from 'dedot/types';
4
+ import type {
5
+ RuntimeVersion,
6
+ Header,
7
+ Result,
8
+ DispatchError,
9
+ UncheckedExtrinsicLike,
10
+ UncheckedExtrinsic,
11
+ H256,
12
+ BitSequence,
13
+ Bytes,
14
+ BytesLike,
15
+ AccountId32Like,
16
+ } from 'dedot/codecs';
17
+ import type {
18
+ SpRuntimeBlock,
19
+ SpRuntimeExtrinsicInclusionMode,
20
+ XcmVersionedAssetId,
21
+ XcmFeePaymentRuntimeApiError,
22
+ SpWeightsWeightV2Weight,
23
+ XcmVersionedXcm,
24
+ XcmVersionedAssets,
25
+ XcmVersionedLocation,
26
+ SpCoreOpaqueMetadata,
27
+ SpRuntimeTransactionValidityTransactionValidityError,
28
+ SpInherentsInherentData,
29
+ SpInherentsCheckInherentsResult,
30
+ SpRuntimeTransactionValidityValidTransaction,
31
+ SpRuntimeTransactionValidityTransactionSource,
32
+ PolkadotPrimitivesV7ValidatorAppPublic,
33
+ PolkadotPrimitivesV7ValidatorIndex,
34
+ PolkadotPrimitivesV7GroupRotationInfo,
35
+ PolkadotPrimitivesV7CoreState,
36
+ PolkadotPrimitivesV7PersistedValidationData,
37
+ PolkadotParachainPrimitivesPrimitivesId,
38
+ PolkadotPrimitivesV7OccupiedCoreAssumption,
39
+ PolkadotParachainPrimitivesPrimitivesValidationCodeHash,
40
+ PolkadotPrimitivesV7CandidateCommitments,
41
+ PolkadotParachainPrimitivesPrimitivesValidationCode,
42
+ PolkadotPrimitivesV7CommittedCandidateReceipt,
43
+ PolkadotPrimitivesV7CandidateEvent,
44
+ PolkadotCorePrimitivesInboundDownwardMessage,
45
+ PolkadotCorePrimitivesInboundHrmpMessage,
46
+ PolkadotPrimitivesV7ScrapedOnChainVotes,
47
+ PolkadotPrimitivesV7SessionInfo,
48
+ PolkadotPrimitivesV7PvfCheckStatement,
49
+ PolkadotPrimitivesV7ValidatorAppSignature,
50
+ PolkadotCorePrimitivesCandidateHash,
51
+ PolkadotPrimitivesV7DisputeState,
52
+ PolkadotPrimitivesV7ExecutorParams,
53
+ PolkadotPrimitivesV7SlashingPendingSlashes,
54
+ PolkadotPrimitivesV7SlashingOpaqueKeyOwnershipProof,
55
+ PolkadotPrimitivesV7SlashingDisputeProof,
56
+ PolkadotPrimitivesV7AsyncBackingBackingState,
57
+ PolkadotPrimitivesV7AsyncBackingAsyncBackingParams,
58
+ PolkadotPrimitivesV7ApprovalVotingParams,
59
+ PolkadotPrimitivesV7CoreIndex,
60
+ SpConsensusBeefyValidatorSet,
61
+ SpConsensusBeefyEquivocationProof,
62
+ SpConsensusBeefyOpaqueKeyOwnershipProof,
63
+ SpConsensusBeefyEcdsaCryptoPublic,
64
+ SpMmrPrimitivesError,
65
+ SpMmrPrimitivesEncodableOpaqueLeaf,
66
+ SpMmrPrimitivesProof,
67
+ SpConsensusGrandpaAppPublic,
68
+ SpConsensusGrandpaEquivocationProof,
69
+ SpConsensusGrandpaOpaqueKeyOwnershipProof,
70
+ SpConsensusBabeBabeConfiguration,
71
+ SpConsensusSlotsSlot,
72
+ SpConsensusBabeEpoch,
73
+ SpConsensusBabeOpaqueKeyOwnershipProof,
74
+ SpConsensusBabeAppPublic,
75
+ SpConsensusSlotsEquivocationProof,
76
+ SpAuthorityDiscoveryAppPublic,
77
+ SpCoreCryptoKeyTypeId,
78
+ PalletTransactionPaymentRuntimeDispatchInfo,
79
+ PalletTransactionPaymentFeeDetails,
80
+ SpConsensusBeefyMmrBeefyAuthoritySet,
81
+ } from './types';
82
+
83
+ export interface RuntimeApis<Rv extends RpcVersion> extends GenericRuntimeApis<Rv> {
84
+ /**
85
+ * @runtimeapi: Core - 0xdf6acb689907609b
86
+ **/
87
+ core: {
88
+ /**
89
+ * Returns the version of the runtime.
90
+ *
91
+ * @callname: Core_version
92
+ **/
93
+ version: GenericRuntimeApiMethod<Rv, () => Promise<RuntimeVersion>>;
94
+
95
+ /**
96
+ * Execute the given block.
97
+ *
98
+ * @callname: Core_execute_block
99
+ * @param {SpRuntimeBlock} block
100
+ **/
101
+ executeBlock: GenericRuntimeApiMethod<Rv, (block: SpRuntimeBlock) => Promise<[]>>;
102
+
103
+ /**
104
+ * Initialize a block with the given header and return the runtime executive mode.
105
+ *
106
+ * @callname: Core_initialize_block
107
+ * @param {Header} header
108
+ **/
109
+ initializeBlock: GenericRuntimeApiMethod<Rv, (header: Header) => Promise<SpRuntimeExtrinsicInclusionMode>>;
110
+
111
+ /**
112
+ * Generic runtime api call
113
+ **/
114
+ [method: string]: GenericRuntimeApiMethod<Rv>;
115
+ };
116
+ /**
117
+ * @runtimeapi: XcmPaymentApi - 0x6ff52ee858e6c5bd
118
+ **/
119
+ xcmPaymentApi: {
120
+ /**
121
+ * Returns a list of acceptable payment assets.
122
+ *
123
+ * # Arguments
124
+ *
125
+ * * `xcm_version`: Version.
126
+ *
127
+ * @callname: XcmPaymentApi_query_acceptable_payment_assets
128
+ * @param {number} xcm_version
129
+ **/
130
+ queryAcceptablePaymentAssets: GenericRuntimeApiMethod<
131
+ Rv,
132
+ (xcmVersion: number) => Promise<Result<Array<XcmVersionedAssetId>, XcmFeePaymentRuntimeApiError>>
133
+ >;
134
+
135
+ /**
136
+ * Returns a weight needed to execute a XCM.
137
+ *
138
+ * # Arguments
139
+ *
140
+ * * `message`: `VersionedXcm`.
141
+ *
142
+ * @callname: XcmPaymentApi_query_xcm_weight
143
+ * @param {XcmVersionedXcm} message
144
+ **/
145
+ queryXcmWeight: GenericRuntimeApiMethod<
146
+ Rv,
147
+ (message: XcmVersionedXcm) => Promise<Result<SpWeightsWeightV2Weight, XcmFeePaymentRuntimeApiError>>
148
+ >;
149
+
150
+ /**
151
+ * Converts a weight into a fee for the specified `AssetId`.
152
+ *
153
+ * # Arguments
154
+ *
155
+ * * `weight`: convertible `Weight`.
156
+ * * `asset`: `VersionedAssetId`.
157
+ *
158
+ * @callname: XcmPaymentApi_query_weight_to_asset_fee
159
+ * @param {SpWeightsWeightV2Weight} weight
160
+ * @param {XcmVersionedAssetId} asset
161
+ **/
162
+ queryWeightToAssetFee: GenericRuntimeApiMethod<
163
+ Rv,
164
+ (
165
+ weight: SpWeightsWeightV2Weight,
166
+ asset: XcmVersionedAssetId,
167
+ ) => Promise<Result<bigint, XcmFeePaymentRuntimeApiError>>
168
+ >;
169
+
170
+ /**
171
+ * Get delivery fees for sending a specific `message` to a `destination`.
172
+ * These always come in a specific asset, defined by the chain.
173
+ *
174
+ * # Arguments
175
+ * * `message`: The message that'll be sent, necessary because most delivery fees are based on the
176
+ * size of the message.
177
+ * * `destination`: The destination to send the message to. Different destinations may use
178
+ * different senders that charge different fees.
179
+ *
180
+ * @callname: XcmPaymentApi_query_delivery_fees
181
+ * @param {XcmVersionedLocation} destination
182
+ * @param {XcmVersionedXcm} message
183
+ **/
184
+ queryDeliveryFees: GenericRuntimeApiMethod<
185
+ Rv,
186
+ (
187
+ destination: XcmVersionedLocation,
188
+ message: XcmVersionedXcm,
189
+ ) => Promise<Result<XcmVersionedAssets, XcmFeePaymentRuntimeApiError>>
190
+ >;
191
+
192
+ /**
193
+ * Generic runtime api call
194
+ **/
195
+ [method: string]: GenericRuntimeApiMethod<Rv>;
196
+ };
197
+ /**
198
+ * @runtimeapi: Metadata - 0x37e397fc7c91f5e4
199
+ **/
200
+ metadata: {
201
+ /**
202
+ * Returns the metadata of a runtime.
203
+ *
204
+ * @callname: Metadata_metadata
205
+ **/
206
+ metadata: GenericRuntimeApiMethod<Rv, () => Promise<SpCoreOpaqueMetadata>>;
207
+
208
+ /**
209
+ * Returns the metadata at a given version.
210
+ *
211
+ * If the given `version` isn't supported, this will return `None`.
212
+ * Use [`Self::metadata_versions`] to find out about supported metadata version of the runtime.
213
+ *
214
+ * @callname: Metadata_metadata_at_version
215
+ * @param {number} version
216
+ **/
217
+ metadataAtVersion: GenericRuntimeApiMethod<Rv, (version: number) => Promise<SpCoreOpaqueMetadata | undefined>>;
218
+
219
+ /**
220
+ * Returns the supported metadata versions.
221
+ *
222
+ * This can be used to call `metadata_at_version`.
223
+ *
224
+ * @callname: Metadata_metadata_versions
225
+ **/
226
+ metadataVersions: GenericRuntimeApiMethod<Rv, () => Promise<Array<number>>>;
227
+
228
+ /**
229
+ * Generic runtime api call
230
+ **/
231
+ [method: string]: GenericRuntimeApiMethod<Rv>;
232
+ };
233
+ /**
234
+ * @runtimeapi: BlockBuilder - 0x40fe3ad401f8959a
235
+ **/
236
+ blockBuilder: {
237
+ /**
238
+ * Apply the given extrinsic.
239
+ *
240
+ * Returns an inclusion outcome which specifies if this extrinsic is included in
241
+ * this block or not.
242
+ *
243
+ * @callname: BlockBuilder_apply_extrinsic
244
+ * @param {UncheckedExtrinsicLike} extrinsic
245
+ **/
246
+ applyExtrinsic: GenericRuntimeApiMethod<
247
+ Rv,
248
+ (
249
+ extrinsic: UncheckedExtrinsicLike,
250
+ ) => Promise<Result<Result<[], DispatchError>, SpRuntimeTransactionValidityTransactionValidityError>>
251
+ >;
252
+
253
+ /**
254
+ * Finish the current block.
255
+ *
256
+ * @callname: BlockBuilder_finalize_block
257
+ **/
258
+ finalizeBlock: GenericRuntimeApiMethod<Rv, () => Promise<Header>>;
259
+
260
+ /**
261
+ * Generate inherent extrinsics. The inherent data will vary from chain to chain.
262
+ *
263
+ * @callname: BlockBuilder_inherent_extrinsics
264
+ * @param {SpInherentsInherentData} inherent
265
+ **/
266
+ inherentExtrinsics: GenericRuntimeApiMethod<
267
+ Rv,
268
+ (inherent: SpInherentsInherentData) => Promise<Array<UncheckedExtrinsic>>
269
+ >;
270
+
271
+ /**
272
+ * Check that the inherents are valid. The inherent data will vary from chain to chain.
273
+ *
274
+ * @callname: BlockBuilder_check_inherents
275
+ * @param {SpRuntimeBlock} block
276
+ * @param {SpInherentsInherentData} data
277
+ **/
278
+ checkInherents: GenericRuntimeApiMethod<
279
+ Rv,
280
+ (block: SpRuntimeBlock, data: SpInherentsInherentData) => Promise<SpInherentsCheckInherentsResult>
281
+ >;
282
+
283
+ /**
284
+ * Generic runtime api call
285
+ **/
286
+ [method: string]: GenericRuntimeApiMethod<Rv>;
287
+ };
288
+ /**
289
+ * @runtimeapi: TaggedTransactionQueue - 0xd2bc9897eed08f15
290
+ **/
291
+ taggedTransactionQueue: {
292
+ /**
293
+ * Validate the transaction.
294
+ *
295
+ * This method is invoked by the transaction pool to learn details about given transaction.
296
+ * The implementation should make sure to verify the correctness of the transaction
297
+ * against current state. The given `block_hash` corresponds to the hash of the block
298
+ * that is used as current state.
299
+ *
300
+ * Note that this call may be performed by the pool multiple times and transactions
301
+ * might be verified in any possible order.
302
+ *
303
+ * @callname: TaggedTransactionQueue_validate_transaction
304
+ * @param {SpRuntimeTransactionValidityTransactionSource} source
305
+ * @param {UncheckedExtrinsicLike} tx
306
+ * @param {H256} block_hash
307
+ **/
308
+ validateTransaction: GenericRuntimeApiMethod<
309
+ Rv,
310
+ (
311
+ source: SpRuntimeTransactionValidityTransactionSource,
312
+ tx: UncheckedExtrinsicLike,
313
+ blockHash: H256,
314
+ ) => Promise<
315
+ Result<SpRuntimeTransactionValidityValidTransaction, SpRuntimeTransactionValidityTransactionValidityError>
316
+ >
317
+ >;
318
+
319
+ /**
320
+ * Generic runtime api call
321
+ **/
322
+ [method: string]: GenericRuntimeApiMethod<Rv>;
323
+ };
324
+ /**
325
+ * @runtimeapi: OffchainWorkerApi - 0xf78b278be53f454c
326
+ **/
327
+ offchainWorkerApi: {
328
+ /**
329
+ * Starts the off-chain task for given block header.
330
+ *
331
+ * @callname: OffchainWorkerApi_offchain_worker
332
+ * @param {Header} header
333
+ **/
334
+ offchainWorker: GenericRuntimeApiMethod<Rv, (header: Header) => Promise<[]>>;
335
+
336
+ /**
337
+ * Generic runtime api call
338
+ **/
339
+ [method: string]: GenericRuntimeApiMethod<Rv>;
340
+ };
341
+ /**
342
+ * @runtimeapi: ParachainHost - 0xaf2c0297a23e6d3d
343
+ **/
344
+ parachainHost: {
345
+ /**
346
+ * Get the current validators.
347
+ *
348
+ * @callname: ParachainHost_validators
349
+ **/
350
+ validators: GenericRuntimeApiMethod<Rv, () => Promise<Array<PolkadotPrimitivesV7ValidatorAppPublic>>>;
351
+
352
+ /**
353
+ * Returns the validator groups and rotation info localized based on the hypothetical child
354
+ * of a block whose state this is invoked on. Note that `now` in the `GroupRotationInfo`
355
+ * should be the successor of the number of the block.
356
+ *
357
+ * @callname: ParachainHost_validator_groups
358
+ **/
359
+ validatorGroups: GenericRuntimeApiMethod<
360
+ Rv,
361
+ () => Promise<[Array<Array<PolkadotPrimitivesV7ValidatorIndex>>, PolkadotPrimitivesV7GroupRotationInfo]>
362
+ >;
363
+
364
+ /**
365
+ * Yields information on all availability cores as relevant to the child block.
366
+ * Cores are either free or occupied. Free cores can have paras assigned to them.
367
+ *
368
+ * @callname: ParachainHost_availability_cores
369
+ **/
370
+ availabilityCores: GenericRuntimeApiMethod<Rv, () => Promise<Array<PolkadotPrimitivesV7CoreState>>>;
371
+
372
+ /**
373
+ * Yields the persisted validation data for the given `ParaId` along with an assumption that
374
+ * should be used if the para currently occupies a core.
375
+ *
376
+ * Returns `None` if either the para is not registered or the assumption is `Freed`
377
+ * and the para already occupies a core.
378
+ *
379
+ * @callname: ParachainHost_persisted_validation_data
380
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
381
+ * @param {PolkadotPrimitivesV7OccupiedCoreAssumption} assumption
382
+ **/
383
+ persistedValidationData: GenericRuntimeApiMethod<
384
+ Rv,
385
+ (
386
+ paraId: PolkadotParachainPrimitivesPrimitivesId,
387
+ assumption: PolkadotPrimitivesV7OccupiedCoreAssumption,
388
+ ) => Promise<PolkadotPrimitivesV7PersistedValidationData | undefined>
389
+ >;
390
+
391
+ /**
392
+ * Returns the persisted validation data for the given `ParaId` along with the corresponding
393
+ * validation code hash. Instead of accepting assumption about the para, matches the validation
394
+ * data hash against an expected one and yields `None` if they're not equal.
395
+ *
396
+ * @callname: ParachainHost_assumed_validation_data
397
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
398
+ * @param {H256} expected_persisted_validation_data_hash
399
+ **/
400
+ assumedValidationData: GenericRuntimeApiMethod<
401
+ Rv,
402
+ (
403
+ paraId: PolkadotParachainPrimitivesPrimitivesId,
404
+ expectedPersistedValidationDataHash: H256,
405
+ ) => Promise<
406
+ | [PolkadotPrimitivesV7PersistedValidationData, PolkadotParachainPrimitivesPrimitivesValidationCodeHash]
407
+ | undefined
408
+ >
409
+ >;
410
+
411
+ /**
412
+ * Checks if the given validation outputs pass the acceptance criteria.
413
+ *
414
+ * @callname: ParachainHost_check_validation_outputs
415
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
416
+ * @param {PolkadotPrimitivesV7CandidateCommitments} outputs
417
+ **/
418
+ checkValidationOutputs: GenericRuntimeApiMethod<
419
+ Rv,
420
+ (
421
+ paraId: PolkadotParachainPrimitivesPrimitivesId,
422
+ outputs: PolkadotPrimitivesV7CandidateCommitments,
423
+ ) => Promise<boolean>
424
+ >;
425
+
426
+ /**
427
+ * Returns the session index expected at a child of the block.
428
+ *
429
+ * This can be used to instantiate a `SigningContext`.
430
+ *
431
+ * @callname: ParachainHost_session_index_for_child
432
+ **/
433
+ sessionIndexForChild: GenericRuntimeApiMethod<Rv, () => Promise<number>>;
434
+
435
+ /**
436
+ * Fetch the validation code used by a para, making the given `OccupiedCoreAssumption`.
437
+ *
438
+ * Returns `None` if either the para is not registered or the assumption is `Freed`
439
+ * and the para already occupies a core.
440
+ *
441
+ * @callname: ParachainHost_validation_code
442
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
443
+ * @param {PolkadotPrimitivesV7OccupiedCoreAssumption} assumption
444
+ **/
445
+ validationCode: GenericRuntimeApiMethod<
446
+ Rv,
447
+ (
448
+ paraId: PolkadotParachainPrimitivesPrimitivesId,
449
+ assumption: PolkadotPrimitivesV7OccupiedCoreAssumption,
450
+ ) => Promise<PolkadotParachainPrimitivesPrimitivesValidationCode | undefined>
451
+ >;
452
+
453
+ /**
454
+ * Get the receipt of a candidate pending availability. This returns `Some` for any paras
455
+ * assigned to occupied cores in `availability_cores` and `None` otherwise.
456
+ *
457
+ * @callname: ParachainHost_candidate_pending_availability
458
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
459
+ **/
460
+ candidatePendingAvailability: GenericRuntimeApiMethod<
461
+ Rv,
462
+ (
463
+ paraId: PolkadotParachainPrimitivesPrimitivesId,
464
+ ) => Promise<PolkadotPrimitivesV7CommittedCandidateReceipt | undefined>
465
+ >;
466
+
467
+ /**
468
+ * Get a vector of events concerning candidates that occurred within a block.
469
+ *
470
+ * @callname: ParachainHost_candidate_events
471
+ **/
472
+ candidateEvents: GenericRuntimeApiMethod<Rv, () => Promise<Array<PolkadotPrimitivesV7CandidateEvent>>>;
473
+
474
+ /**
475
+ * Get all the pending inbound messages in the downward message queue for a para.
476
+ *
477
+ * @callname: ParachainHost_dmq_contents
478
+ * @param {PolkadotParachainPrimitivesPrimitivesId} recipient
479
+ **/
480
+ dmqContents: GenericRuntimeApiMethod<
481
+ Rv,
482
+ (
483
+ recipient: PolkadotParachainPrimitivesPrimitivesId,
484
+ ) => Promise<Array<PolkadotCorePrimitivesInboundDownwardMessage>>
485
+ >;
486
+
487
+ /**
488
+ * Get the contents of all channels addressed to the given recipient. Channels that have no
489
+ * messages in them are also included.
490
+ *
491
+ * @callname: ParachainHost_inbound_hrmp_channels_contents
492
+ * @param {PolkadotParachainPrimitivesPrimitivesId} recipient
493
+ **/
494
+ inboundHrmpChannelsContents: GenericRuntimeApiMethod<
495
+ Rv,
496
+ (
497
+ recipient: PolkadotParachainPrimitivesPrimitivesId,
498
+ ) => Promise<Array<[PolkadotParachainPrimitivesPrimitivesId, Array<PolkadotCorePrimitivesInboundHrmpMessage>]>>
499
+ >;
500
+
501
+ /**
502
+ * Get the validation code from its hash.
503
+ *
504
+ * @callname: ParachainHost_validation_code_by_hash
505
+ * @param {PolkadotParachainPrimitivesPrimitivesValidationCodeHash} hash
506
+ **/
507
+ validationCodeByHash: GenericRuntimeApiMethod<
508
+ Rv,
509
+ (
510
+ hash: PolkadotParachainPrimitivesPrimitivesValidationCodeHash,
511
+ ) => Promise<PolkadotParachainPrimitivesPrimitivesValidationCode | undefined>
512
+ >;
513
+
514
+ /**
515
+ * Scrape dispute relevant from on-chain, backing votes and resolved disputes.
516
+ *
517
+ * @callname: ParachainHost_on_chain_votes
518
+ **/
519
+ onChainVotes: GenericRuntimeApiMethod<Rv, () => Promise<PolkadotPrimitivesV7ScrapedOnChainVotes | undefined>>;
520
+
521
+ /**
522
+ * Get the session info for the given session, if stored.
523
+ *
524
+ * NOTE: This function is only available since parachain host version 2.
525
+ *
526
+ * @callname: ParachainHost_session_info
527
+ * @param {number} index
528
+ **/
529
+ sessionInfo: GenericRuntimeApiMethod<Rv, (index: number) => Promise<PolkadotPrimitivesV7SessionInfo | undefined>>;
530
+
531
+ /**
532
+ * Submits a PVF pre-checking statement into the transaction pool.
533
+ *
534
+ * NOTE: This function is only available since parachain host version 2.
535
+ *
536
+ * @callname: ParachainHost_submit_pvf_check_statement
537
+ * @param {PolkadotPrimitivesV7PvfCheckStatement} stmt
538
+ * @param {PolkadotPrimitivesV7ValidatorAppSignature} signature
539
+ **/
540
+ submitPvfCheckStatement: GenericRuntimeApiMethod<
541
+ Rv,
542
+ (stmt: PolkadotPrimitivesV7PvfCheckStatement, signature: PolkadotPrimitivesV7ValidatorAppSignature) => Promise<[]>
543
+ >;
544
+
545
+ /**
546
+ * Returns code hashes of PVFs that require pre-checking by validators in the active set.
547
+ *
548
+ * NOTE: This function is only available since parachain host version 2.
549
+ *
550
+ * @callname: ParachainHost_pvfs_require_precheck
551
+ **/
552
+ pvfsRequirePrecheck: GenericRuntimeApiMethod<
553
+ Rv,
554
+ () => Promise<Array<PolkadotParachainPrimitivesPrimitivesValidationCodeHash>>
555
+ >;
556
+
557
+ /**
558
+ * Fetch the hash of the validation code used by a para, making the given `OccupiedCoreAssumption`.
559
+ *
560
+ * NOTE: This function is only available since parachain host version 2.
561
+ *
562
+ * @callname: ParachainHost_validation_code_hash
563
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
564
+ * @param {PolkadotPrimitivesV7OccupiedCoreAssumption} assumption
565
+ **/
566
+ validationCodeHash: GenericRuntimeApiMethod<
567
+ Rv,
568
+ (
569
+ paraId: PolkadotParachainPrimitivesPrimitivesId,
570
+ assumption: PolkadotPrimitivesV7OccupiedCoreAssumption,
571
+ ) => Promise<PolkadotParachainPrimitivesPrimitivesValidationCodeHash | undefined>
572
+ >;
573
+
574
+ /**
575
+ * Returns all onchain disputes.
576
+ *
577
+ * @callname: ParachainHost_disputes
578
+ **/
579
+ disputes: GenericRuntimeApiMethod<
580
+ Rv,
581
+ () => Promise<Array<[number, PolkadotCorePrimitivesCandidateHash, PolkadotPrimitivesV7DisputeState]>>
582
+ >;
583
+
584
+ /**
585
+ * Returns execution parameters for the session.
586
+ *
587
+ * @callname: ParachainHost_session_executor_params
588
+ * @param {number} session_index
589
+ **/
590
+ sessionExecutorParams: GenericRuntimeApiMethod<
591
+ Rv,
592
+ (sessionIndex: number) => Promise<PolkadotPrimitivesV7ExecutorParams | undefined>
593
+ >;
594
+
595
+ /**
596
+ * Returns a list of validators that lost a past session dispute and need to be slashed.
597
+ * NOTE: This function is only available since parachain host version 5.
598
+ *
599
+ * @callname: ParachainHost_unapplied_slashes
600
+ **/
601
+ unappliedSlashes: GenericRuntimeApiMethod<
602
+ Rv,
603
+ () => Promise<Array<[number, PolkadotCorePrimitivesCandidateHash, PolkadotPrimitivesV7SlashingPendingSlashes]>>
604
+ >;
605
+
606
+ /**
607
+ * Returns a merkle proof of a validator session key.
608
+ * NOTE: This function is only available since parachain host version 5.
609
+ *
610
+ * @callname: ParachainHost_key_ownership_proof
611
+ * @param {PolkadotPrimitivesV7ValidatorAppPublic} validator_id
612
+ **/
613
+ keyOwnershipProof: GenericRuntimeApiMethod<
614
+ Rv,
615
+ (
616
+ validatorId: PolkadotPrimitivesV7ValidatorAppPublic,
617
+ ) => Promise<PolkadotPrimitivesV7SlashingOpaqueKeyOwnershipProof | undefined>
618
+ >;
619
+
620
+ /**
621
+ * Submit an unsigned extrinsic to slash validators who lost a dispute about
622
+ * a candidate of a past session.
623
+ * NOTE: This function is only available since parachain host version 5.
624
+ *
625
+ * @callname: ParachainHost_submit_report_dispute_lost
626
+ * @param {PolkadotPrimitivesV7SlashingDisputeProof} dispute_proof
627
+ * @param {PolkadotPrimitivesV7SlashingOpaqueKeyOwnershipProof} key_ownership_proof
628
+ **/
629
+ submitReportDisputeLost: GenericRuntimeApiMethod<
630
+ Rv,
631
+ (
632
+ disputeProof: PolkadotPrimitivesV7SlashingDisputeProof,
633
+ keyOwnershipProof: PolkadotPrimitivesV7SlashingOpaqueKeyOwnershipProof,
634
+ ) => Promise<[] | undefined>
635
+ >;
636
+
637
+ /**
638
+ * Get the minimum number of backing votes for a parachain candidate.
639
+ * This is a staging method! Do not use on production runtimes!
640
+ *
641
+ * @callname: ParachainHost_minimum_backing_votes
642
+ **/
643
+ minimumBackingVotes: GenericRuntimeApiMethod<Rv, () => Promise<number>>;
644
+
645
+ /**
646
+ * Returns the state of parachain backing for a given para.
647
+ *
648
+ * @callname: ParachainHost_para_backing_state
649
+ * @param {PolkadotParachainPrimitivesPrimitivesId} _
650
+ **/
651
+ paraBackingState: GenericRuntimeApiMethod<
652
+ Rv,
653
+ (
654
+ undefined: PolkadotParachainPrimitivesPrimitivesId,
655
+ ) => Promise<PolkadotPrimitivesV7AsyncBackingBackingState | undefined>
656
+ >;
657
+
658
+ /**
659
+ * Returns candidate's acceptance limitations for asynchronous backing for a relay parent.
660
+ *
661
+ * @callname: ParachainHost_async_backing_params
662
+ **/
663
+ asyncBackingParams: GenericRuntimeApiMethod<Rv, () => Promise<PolkadotPrimitivesV7AsyncBackingAsyncBackingParams>>;
664
+
665
+ /**
666
+ * Returns a list of all disabled validators at the given block.
667
+ *
668
+ * @callname: ParachainHost_disabled_validators
669
+ **/
670
+ disabledValidators: GenericRuntimeApiMethod<Rv, () => Promise<Array<PolkadotPrimitivesV7ValidatorIndex>>>;
671
+
672
+ /**
673
+ * Get node features.
674
+ * This is a staging method! Do not use on production runtimes!
675
+ *
676
+ * @callname: ParachainHost_node_features
677
+ **/
678
+ nodeFeatures: GenericRuntimeApiMethod<Rv, () => Promise<BitSequence>>;
679
+
680
+ /**
681
+ * Approval voting configuration parameters
682
+ *
683
+ * @callname: ParachainHost_approval_voting_params
684
+ **/
685
+ approvalVotingParams: GenericRuntimeApiMethod<Rv, () => Promise<PolkadotPrimitivesV7ApprovalVotingParams>>;
686
+
687
+ /**
688
+ * Claim queue
689
+ *
690
+ * @callname: ParachainHost_claim_queue
691
+ **/
692
+ claimQueue: GenericRuntimeApiMethod<
693
+ Rv,
694
+ () => Promise<Array<[PolkadotPrimitivesV7CoreIndex, Array<PolkadotParachainPrimitivesPrimitivesId>]>>
695
+ >;
696
+
697
+ /**
698
+ * Elastic scaling support
699
+ *
700
+ * @callname: ParachainHost_candidates_pending_availability
701
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
702
+ **/
703
+ candidatesPendingAvailability: GenericRuntimeApiMethod<
704
+ Rv,
705
+ (paraId: PolkadotParachainPrimitivesPrimitivesId) => Promise<Array<PolkadotPrimitivesV7CommittedCandidateReceipt>>
706
+ >;
707
+
708
+ /**
709
+ * Generic runtime api call
710
+ **/
711
+ [method: string]: GenericRuntimeApiMethod<Rv>;
712
+ };
713
+ /**
714
+ * @runtimeapi: BeefyApi - 0x49eaaf1b548a0cb0
715
+ **/
716
+ beefyApi: {
717
+ /**
718
+ * Return the block number where BEEFY consensus is enabled/started
719
+ *
720
+ * @callname: BeefyApi_beefy_genesis
721
+ **/
722
+ beefyGenesis: GenericRuntimeApiMethod<Rv, () => Promise<number | undefined>>;
723
+
724
+ /**
725
+ * Return the current active BEEFY validator set
726
+ *
727
+ * @callname: BeefyApi_validator_set
728
+ **/
729
+ validatorSet: GenericRuntimeApiMethod<Rv, () => Promise<SpConsensusBeefyValidatorSet | undefined>>;
730
+
731
+ /**
732
+ * Submits an unsigned extrinsic to report an equivocation. The caller
733
+ * must provide the equivocation proof and a key ownership proof
734
+ * (should be obtained using `generate_key_ownership_proof`). The
735
+ * extrinsic will be unsigned and should only be accepted for local
736
+ * authorship (not to be broadcast to the network). This method returns
737
+ * `None` when creation of the extrinsic fails, e.g. if equivocation
738
+ * reporting is disabled for the given runtime (i.e. this method is
739
+ * hardcoded to return `None`). Only useful in an offchain context.
740
+ *
741
+ * @callname: BeefyApi_submit_report_equivocation_unsigned_extrinsic
742
+ * @param {SpConsensusBeefyEquivocationProof} equivocation_proof
743
+ * @param {SpConsensusBeefyOpaqueKeyOwnershipProof} key_owner_proof
744
+ **/
745
+ submitReportEquivocationUnsignedExtrinsic: GenericRuntimeApiMethod<
746
+ Rv,
747
+ (
748
+ equivocationProof: SpConsensusBeefyEquivocationProof,
749
+ keyOwnerProof: SpConsensusBeefyOpaqueKeyOwnershipProof,
750
+ ) => Promise<[] | undefined>
751
+ >;
752
+
753
+ /**
754
+ * Generates a proof of key ownership for the given authority in the
755
+ * given set. An example usage of this module is coupled with the
756
+ * session historical module to prove that a given authority key is
757
+ * tied to a given staking identity during a specific session. Proofs
758
+ * of key ownership are necessary for submitting equivocation reports.
759
+ * NOTE: even though the API takes a `set_id` as parameter the current
760
+ * implementations ignores this parameter and instead relies on this
761
+ * method being called at the correct block height, i.e. any point at
762
+ * which the given set id is live on-chain. Future implementations will
763
+ * instead use indexed data through an offchain worker, not requiring
764
+ * older states to be available.
765
+ *
766
+ * @callname: BeefyApi_generate_key_ownership_proof
767
+ * @param {bigint} set_id
768
+ * @param {SpConsensusBeefyEcdsaCryptoPublic} authority_id
769
+ **/
770
+ generateKeyOwnershipProof: GenericRuntimeApiMethod<
771
+ Rv,
772
+ (
773
+ setId: bigint,
774
+ authorityId: SpConsensusBeefyEcdsaCryptoPublic,
775
+ ) => Promise<SpConsensusBeefyOpaqueKeyOwnershipProof | undefined>
776
+ >;
777
+
778
+ /**
779
+ * Generic runtime api call
780
+ **/
781
+ [method: string]: GenericRuntimeApiMethod<Rv>;
782
+ };
783
+ /**
784
+ * @runtimeapi: MmrApi - 0x91d5df18b0d2cf58
785
+ **/
786
+ mmrApi: {
787
+ /**
788
+ * Return the on-chain MMR root hash.
789
+ *
790
+ * @callname: MmrApi_mmr_root
791
+ **/
792
+ mmrRoot: GenericRuntimeApiMethod<Rv, () => Promise<Result<H256, SpMmrPrimitivesError>>>;
793
+
794
+ /**
795
+ * Return the number of MMR blocks in the chain.
796
+ *
797
+ * @callname: MmrApi_mmr_leaf_count
798
+ **/
799
+ mmrLeafCount: GenericRuntimeApiMethod<Rv, () => Promise<Result<bigint, SpMmrPrimitivesError>>>;
800
+
801
+ /**
802
+ * Generate MMR proof for a series of block numbers. If `best_known_block_number = Some(n)`,
803
+ * use historical MMR state at given block height `n`. Else, use current MMR state.
804
+ *
805
+ * @callname: MmrApi_generate_proof
806
+ * @param {Array<number>} block_numbers
807
+ * @param {number | undefined} best_known_block_number
808
+ **/
809
+ generateProof: GenericRuntimeApiMethod<
810
+ Rv,
811
+ (
812
+ blockNumbers: Array<number>,
813
+ bestKnownBlockNumber?: number | undefined,
814
+ ) => Promise<Result<[Array<SpMmrPrimitivesEncodableOpaqueLeaf>, SpMmrPrimitivesProof], SpMmrPrimitivesError>>
815
+ >;
816
+
817
+ /**
818
+ * Verify MMR proof against on-chain MMR for a batch of leaves.
819
+ *
820
+ * Note this function will use on-chain MMR root hash and check if the proof matches the hash.
821
+ * Note, the leaves should be sorted such that corresponding leaves and leaf indices have the
822
+ * same position in both the `leaves` vector and the `leaf_indices` vector contained in the [Proof]
823
+ *
824
+ * @callname: MmrApi_verify_proof
825
+ * @param {Array<SpMmrPrimitivesEncodableOpaqueLeaf>} leaves
826
+ * @param {SpMmrPrimitivesProof} proof
827
+ **/
828
+ verifyProof: GenericRuntimeApiMethod<
829
+ Rv,
830
+ (
831
+ leaves: Array<SpMmrPrimitivesEncodableOpaqueLeaf>,
832
+ proof: SpMmrPrimitivesProof,
833
+ ) => Promise<Result<[], SpMmrPrimitivesError>>
834
+ >;
835
+
836
+ /**
837
+ * Verify MMR proof against given root hash for a batch of leaves.
838
+ *
839
+ * Note this function does not require any on-chain storage - the
840
+ * proof is verified against given MMR root hash.
841
+ *
842
+ * Note, the leaves should be sorted such that corresponding leaves and leaf indices have the
843
+ * same position in both the `leaves` vector and the `leaf_indices` vector contained in the [Proof]
844
+ *
845
+ * @callname: MmrApi_verify_proof_stateless
846
+ * @param {H256} root
847
+ * @param {Array<SpMmrPrimitivesEncodableOpaqueLeaf>} leaves
848
+ * @param {SpMmrPrimitivesProof} proof
849
+ **/
850
+ verifyProofStateless: GenericRuntimeApiMethod<
851
+ Rv,
852
+ (
853
+ root: H256,
854
+ leaves: Array<SpMmrPrimitivesEncodableOpaqueLeaf>,
855
+ proof: SpMmrPrimitivesProof,
856
+ ) => Promise<Result<[], SpMmrPrimitivesError>>
857
+ >;
858
+
859
+ /**
860
+ * Generic runtime api call
861
+ **/
862
+ [method: string]: GenericRuntimeApiMethod<Rv>;
863
+ };
864
+ /**
865
+ * @runtimeapi: GrandpaApi - 0xed99c5acb25eedf5
866
+ **/
867
+ grandpaApi: {
868
+ /**
869
+ * Get the current GRANDPA authorities and weights. This should not change except
870
+ * for when changes are scheduled and the corresponding delay has passed.
871
+ *
872
+ * When called at block B, it will return the set of authorities that should be
873
+ * used to finalize descendants of this block (B+1, B+2, ...). The block B itself
874
+ * is finalized by the authorities from block B-1.
875
+ *
876
+ * @callname: GrandpaApi_grandpa_authorities
877
+ **/
878
+ grandpaAuthorities: GenericRuntimeApiMethod<Rv, () => Promise<Array<[SpConsensusGrandpaAppPublic, bigint]>>>;
879
+
880
+ /**
881
+ * Submits an unsigned extrinsic to report an equivocation. The caller
882
+ * must provide the equivocation proof and a key ownership proof
883
+ * (should be obtained using `generate_key_ownership_proof`). The
884
+ * extrinsic will be unsigned and should only be accepted for local
885
+ * authorship (not to be broadcast to the network). This method returns
886
+ * `None` when creation of the extrinsic fails, e.g. if equivocation
887
+ * reporting is disabled for the given runtime (i.e. this method is
888
+ * hardcoded to return `None`). Only useful in an offchain context.
889
+ *
890
+ * @callname: GrandpaApi_submit_report_equivocation_unsigned_extrinsic
891
+ * @param {SpConsensusGrandpaEquivocationProof} equivocation_proof
892
+ * @param {SpConsensusGrandpaOpaqueKeyOwnershipProof} key_owner_proof
893
+ **/
894
+ submitReportEquivocationUnsignedExtrinsic: GenericRuntimeApiMethod<
895
+ Rv,
896
+ (
897
+ equivocationProof: SpConsensusGrandpaEquivocationProof,
898
+ keyOwnerProof: SpConsensusGrandpaOpaqueKeyOwnershipProof,
899
+ ) => Promise<[] | undefined>
900
+ >;
901
+
902
+ /**
903
+ * Generates a proof of key ownership for the given authority in the
904
+ * given set. An example usage of this module is coupled with the
905
+ * session historical module to prove that a given authority key is
906
+ * tied to a given staking identity during a specific session. Proofs
907
+ * of key ownership are necessary for submitting equivocation reports.
908
+ * NOTE: even though the API takes a `set_id` as parameter the current
909
+ * implementations ignore this parameter and instead rely on this
910
+ * method being called at the correct block height, i.e. any point at
911
+ * which the given set id is live on-chain. Future implementations will
912
+ * instead use indexed data through an offchain worker, not requiring
913
+ * older states to be available.
914
+ *
915
+ * @callname: GrandpaApi_generate_key_ownership_proof
916
+ * @param {bigint} set_id
917
+ * @param {SpConsensusGrandpaAppPublic} authority_id
918
+ **/
919
+ generateKeyOwnershipProof: GenericRuntimeApiMethod<
920
+ Rv,
921
+ (
922
+ setId: bigint,
923
+ authorityId: SpConsensusGrandpaAppPublic,
924
+ ) => Promise<SpConsensusGrandpaOpaqueKeyOwnershipProof | undefined>
925
+ >;
926
+
927
+ /**
928
+ * Get current GRANDPA authority set id.
929
+ *
930
+ * @callname: GrandpaApi_current_set_id
931
+ **/
932
+ currentSetId: GenericRuntimeApiMethod<Rv, () => Promise<bigint>>;
933
+
934
+ /**
935
+ * Generic runtime api call
936
+ **/
937
+ [method: string]: GenericRuntimeApiMethod<Rv>;
938
+ };
939
+ /**
940
+ * @runtimeapi: BabeApi - 0xcbca25e39f142387
941
+ **/
942
+ babeApi: {
943
+ /**
944
+ * Return the configuration for BABE.
945
+ *
946
+ * @callname: BabeApi_configuration
947
+ **/
948
+ configuration: GenericRuntimeApiMethod<Rv, () => Promise<SpConsensusBabeBabeConfiguration>>;
949
+
950
+ /**
951
+ * Returns the slot that started the current epoch.
952
+ *
953
+ * @callname: BabeApi_current_epoch_start
954
+ **/
955
+ currentEpochStart: GenericRuntimeApiMethod<Rv, () => Promise<SpConsensusSlotsSlot>>;
956
+
957
+ /**
958
+ * Returns information regarding the current epoch.
959
+ *
960
+ * @callname: BabeApi_current_epoch
961
+ **/
962
+ currentEpoch: GenericRuntimeApiMethod<Rv, () => Promise<SpConsensusBabeEpoch>>;
963
+
964
+ /**
965
+ * Returns information regarding the next epoch (which was already
966
+ * previously announced).
967
+ *
968
+ * @callname: BabeApi_next_epoch
969
+ **/
970
+ nextEpoch: GenericRuntimeApiMethod<Rv, () => Promise<SpConsensusBabeEpoch>>;
971
+
972
+ /**
973
+ * Generates a proof of key ownership for the given authority in the
974
+ * current epoch. An example usage of this module is coupled with the
975
+ * session historical module to prove that a given authority key is
976
+ * tied to a given staking identity during a specific session. Proofs
977
+ * of key ownership are necessary for submitting equivocation reports.
978
+ * NOTE: even though the API takes a `slot` as parameter the current
979
+ * implementations ignores this parameter and instead relies on this
980
+ * method being called at the correct block height, i.e. any point at
981
+ * which the epoch for the given slot is live on-chain. Future
982
+ * implementations will instead use indexed data through an offchain
983
+ * worker, not requiring older states to be available.
984
+ *
985
+ * @callname: BabeApi_generate_key_ownership_proof
986
+ * @param {SpConsensusSlotsSlot} slot
987
+ * @param {SpConsensusBabeAppPublic} authority_id
988
+ **/
989
+ generateKeyOwnershipProof: GenericRuntimeApiMethod<
990
+ Rv,
991
+ (
992
+ slot: SpConsensusSlotsSlot,
993
+ authorityId: SpConsensusBabeAppPublic,
994
+ ) => Promise<SpConsensusBabeOpaqueKeyOwnershipProof | undefined>
995
+ >;
996
+
997
+ /**
998
+ * Submits an unsigned extrinsic to report an equivocation. The caller
999
+ * must provide the equivocation proof and a key ownership proof
1000
+ * (should be obtained using `generate_key_ownership_proof`). The
1001
+ * extrinsic will be unsigned and should only be accepted for local
1002
+ * authorship (not to be broadcast to the network). This method returns
1003
+ * `None` when creation of the extrinsic fails, e.g. if equivocation
1004
+ * reporting is disabled for the given runtime (i.e. this method is
1005
+ * hardcoded to return `None`). Only useful in an offchain context.
1006
+ *
1007
+ * @callname: BabeApi_submit_report_equivocation_unsigned_extrinsic
1008
+ * @param {SpConsensusSlotsEquivocationProof} equivocation_proof
1009
+ * @param {SpConsensusBabeOpaqueKeyOwnershipProof} key_owner_proof
1010
+ **/
1011
+ submitReportEquivocationUnsignedExtrinsic: GenericRuntimeApiMethod<
1012
+ Rv,
1013
+ (
1014
+ equivocationProof: SpConsensusSlotsEquivocationProof,
1015
+ keyOwnerProof: SpConsensusBabeOpaqueKeyOwnershipProof,
1016
+ ) => Promise<[] | undefined>
1017
+ >;
1018
+
1019
+ /**
1020
+ * Generic runtime api call
1021
+ **/
1022
+ [method: string]: GenericRuntimeApiMethod<Rv>;
1023
+ };
1024
+ /**
1025
+ * @runtimeapi: AuthorityDiscoveryApi - 0x687ad44ad37f03c2
1026
+ **/
1027
+ authorityDiscoveryApi: {
1028
+ /**
1029
+ * Retrieve authority identifiers of the current and next authority set.
1030
+ *
1031
+ * @callname: AuthorityDiscoveryApi_authorities
1032
+ **/
1033
+ authorities: GenericRuntimeApiMethod<Rv, () => Promise<Array<SpAuthorityDiscoveryAppPublic>>>;
1034
+
1035
+ /**
1036
+ * Generic runtime api call
1037
+ **/
1038
+ [method: string]: GenericRuntimeApiMethod<Rv>;
1039
+ };
1040
+ /**
1041
+ * @runtimeapi: SessionKeys - 0xab3c0572291feb8b
1042
+ **/
1043
+ sessionKeys: {
1044
+ /**
1045
+ * Generate a set of session keys with optionally using the given seed.
1046
+ * The keys should be stored within the keystore exposed via runtime
1047
+ * externalities.
1048
+ *
1049
+ * The seed needs to be a valid `utf8` string.
1050
+ *
1051
+ * Returns the concatenated SCALE encoded public keys.
1052
+ *
1053
+ * @callname: SessionKeys_generate_session_keys
1054
+ * @param {BytesLike | undefined} seed
1055
+ **/
1056
+ generateSessionKeys: GenericRuntimeApiMethod<Rv, (seed?: BytesLike | undefined) => Promise<Bytes>>;
1057
+
1058
+ /**
1059
+ * Decode the given public session keys.
1060
+ *
1061
+ * Returns the list of public raw public keys + key type.
1062
+ *
1063
+ * @callname: SessionKeys_decode_session_keys
1064
+ * @param {BytesLike} encoded
1065
+ **/
1066
+ decodeSessionKeys: GenericRuntimeApiMethod<
1067
+ Rv,
1068
+ (encoded: BytesLike) => Promise<Array<[Bytes, SpCoreCryptoKeyTypeId]> | undefined>
1069
+ >;
1070
+
1071
+ /**
1072
+ * Generic runtime api call
1073
+ **/
1074
+ [method: string]: GenericRuntimeApiMethod<Rv>;
1075
+ };
1076
+ /**
1077
+ * @runtimeapi: AccountNonceApi - 0xbc9d89904f5b923f
1078
+ **/
1079
+ accountNonceApi: {
1080
+ /**
1081
+ * Get current account nonce of given `AccountId`.
1082
+ *
1083
+ * @callname: AccountNonceApi_account_nonce
1084
+ * @param {AccountId32Like} account
1085
+ **/
1086
+ accountNonce: GenericRuntimeApiMethod<Rv, (account: AccountId32Like) => Promise<number>>;
1087
+
1088
+ /**
1089
+ * Generic runtime api call
1090
+ **/
1091
+ [method: string]: GenericRuntimeApiMethod<Rv>;
1092
+ };
1093
+ /**
1094
+ * @runtimeapi: TransactionPaymentApi - 0x37c8bb1350a9a2a8
1095
+ **/
1096
+ transactionPaymentApi: {
1097
+ /**
1098
+ *
1099
+ * @callname: TransactionPaymentApi_query_info
1100
+ * @param {UncheckedExtrinsicLike} uxt
1101
+ * @param {number} len
1102
+ **/
1103
+ queryInfo: GenericRuntimeApiMethod<
1104
+ Rv,
1105
+ (uxt: UncheckedExtrinsicLike, len: number) => Promise<PalletTransactionPaymentRuntimeDispatchInfo>
1106
+ >;
1107
+
1108
+ /**
1109
+ *
1110
+ * @callname: TransactionPaymentApi_query_fee_details
1111
+ * @param {UncheckedExtrinsicLike} uxt
1112
+ * @param {number} len
1113
+ **/
1114
+ queryFeeDetails: GenericRuntimeApiMethod<
1115
+ Rv,
1116
+ (uxt: UncheckedExtrinsicLike, len: number) => Promise<PalletTransactionPaymentFeeDetails>
1117
+ >;
1118
+
1119
+ /**
1120
+ *
1121
+ * @callname: TransactionPaymentApi_query_weight_to_fee
1122
+ * @param {SpWeightsWeightV2Weight} weight
1123
+ **/
1124
+ queryWeightToFee: GenericRuntimeApiMethod<Rv, (weight: SpWeightsWeightV2Weight) => Promise<bigint>>;
1125
+
1126
+ /**
1127
+ *
1128
+ * @callname: TransactionPaymentApi_query_length_to_fee
1129
+ * @param {number} length
1130
+ **/
1131
+ queryLengthToFee: GenericRuntimeApiMethod<Rv, (length: number) => Promise<bigint>>;
1132
+
1133
+ /**
1134
+ * Generic runtime api call
1135
+ **/
1136
+ [method: string]: GenericRuntimeApiMethod<Rv>;
1137
+ };
1138
+ /**
1139
+ * @runtimeapi: BeefyMmrApi - 0x2a5e924655399e60
1140
+ **/
1141
+ beefyMmrApi: {
1142
+ /**
1143
+ * Return the currently active BEEFY authority set proof.
1144
+ *
1145
+ * @callname: BeefyMmrApi_authority_set_proof
1146
+ **/
1147
+ authoritySetProof: GenericRuntimeApiMethod<Rv, () => Promise<SpConsensusBeefyMmrBeefyAuthoritySet>>;
1148
+
1149
+ /**
1150
+ * Return the next/queued BEEFY authority set proof.
1151
+ *
1152
+ * @callname: BeefyMmrApi_next_authority_set_proof
1153
+ **/
1154
+ nextAuthoritySetProof: GenericRuntimeApiMethod<Rv, () => Promise<SpConsensusBeefyMmrBeefyAuthoritySet>>;
1155
+
1156
+ /**
1157
+ * Generic runtime api call
1158
+ **/
1159
+ [method: string]: GenericRuntimeApiMethod<Rv>;
1160
+ };
1161
+ /**
1162
+ * @runtimeapi: GenesisBuilder - 0xfbc577b9d747efd6
1163
+ **/
1164
+ genesisBuilder: {
1165
+ /**
1166
+ * Build `RuntimeGenesisConfig` from a JSON blob not using any defaults and store it in the
1167
+ * storage.
1168
+ *
1169
+ * In the case of a FRAME-based runtime, this function deserializes the full `RuntimeGenesisConfig` from the given JSON blob and
1170
+ * puts it into the storage. If the provided JSON blob is incorrect or incomplete or the
1171
+ * deserialization fails, an error is returned.
1172
+ *
1173
+ * Please note that provided JSON blob must contain all `RuntimeGenesisConfig` fields, no
1174
+ * defaults will be used.
1175
+ *
1176
+ * @callname: GenesisBuilder_build_state
1177
+ * @param {BytesLike} json
1178
+ **/
1179
+ buildState: GenericRuntimeApiMethod<Rv, (json: BytesLike) => Promise<Result<[], string>>>;
1180
+
1181
+ /**
1182
+ * Returns a JSON blob representation of the built-in `RuntimeGenesisConfig` identified by
1183
+ * `id`.
1184
+ *
1185
+ * If `id` is `None` the function returns JSON blob representation of the default
1186
+ * `RuntimeGenesisConfig` struct of the runtime. Implementation must provide default
1187
+ * `RuntimeGenesisConfig`.
1188
+ *
1189
+ * Otherwise function returns a JSON representation of the built-in, named
1190
+ * `RuntimeGenesisConfig` preset identified by `id`, or `None` if such preset does not
1191
+ * exists. Returned `Vec<u8>` contains bytes of JSON blob (patch) which comprises a list of
1192
+ * (potentially nested) key-value pairs that are intended for customizing the default
1193
+ * runtime genesis config. The patch shall be merged (rfc7386) with the JSON representation
1194
+ * of the default `RuntimeGenesisConfig` to create a comprehensive genesis config that can
1195
+ * be used in `build_state` method.
1196
+ *
1197
+ * @callname: GenesisBuilder_get_preset
1198
+ * @param {string | undefined} id
1199
+ **/
1200
+ getPreset: GenericRuntimeApiMethod<Rv, (id?: string | undefined) => Promise<Bytes | undefined>>;
1201
+
1202
+ /**
1203
+ * Returns a list of identifiers for available builtin `RuntimeGenesisConfig` presets.
1204
+ *
1205
+ * The presets from the list can be queried with [`GenesisBuilder::get_preset`] method. If
1206
+ * no named presets are provided by the runtime the list is empty.
1207
+ *
1208
+ * @callname: GenesisBuilder_preset_names
1209
+ **/
1210
+ presetNames: GenericRuntimeApiMethod<Rv, () => Promise<Array<string>>>;
1211
+
1212
+ /**
1213
+ * Generic runtime api call
1214
+ **/
1215
+ [method: string]: GenericRuntimeApiMethod<Rv>;
1216
+ };
1217
+ }