@dedot/chaintypes 0.0.1-alpha.26 → 0.0.1-alpha.3

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 (277) hide show
  1. package/aleph/consts.d.ts +528 -590
  2. package/aleph/consts.js +2 -0
  3. package/aleph/errors.d.ts +818 -981
  4. package/aleph/errors.js +2 -0
  5. package/aleph/events.d.ts +937 -924
  6. package/aleph/events.js +2 -0
  7. package/aleph/index.d.ts +8 -11
  8. package/aleph/index.js +3 -0
  9. package/aleph/query.d.ts +1268 -1477
  10. package/aleph/query.js +2 -0
  11. package/aleph/rpc.d.ts +573 -725
  12. package/aleph/rpc.js +2 -0
  13. package/aleph/runtime.d.ts +406 -541
  14. package/aleph/runtime.js +2 -0
  15. package/aleph/tx.d.ts +2202 -2664
  16. package/aleph/tx.js +2 -0
  17. package/aleph/types.d.ts +5294 -3380
  18. package/aleph/types.js +2 -0
  19. package/astar/consts.d.ts +674 -753
  20. package/astar/consts.js +2 -0
  21. package/astar/errors.d.ts +1313 -1576
  22. package/astar/errors.js +2 -0
  23. package/astar/events.d.ts +1628 -1709
  24. package/astar/events.js +2 -0
  25. package/astar/index.d.ts +8 -11
  26. package/astar/index.js +3 -0
  27. package/astar/query.d.ts +1471 -1756
  28. package/astar/query.js +2 -0
  29. package/astar/rpc.d.ts +773 -972
  30. package/astar/rpc.js +2 -0
  31. package/astar/runtime.d.ts +258 -310
  32. package/astar/runtime.js +2 -0
  33. package/astar/tx.d.ts +4806 -5474
  34. package/astar/tx.js +2 -0
  35. package/astar/types.d.ts +12053 -8793
  36. package/astar/types.js +2 -0
  37. package/cjs/aleph/consts.js +3 -0
  38. package/cjs/aleph/errors.js +3 -0
  39. package/cjs/aleph/events.js +3 -0
  40. package/cjs/aleph/index.js +19 -0
  41. package/cjs/aleph/query.js +3 -0
  42. package/cjs/aleph/rpc.js +3 -0
  43. package/cjs/aleph/runtime.js +3 -0
  44. package/cjs/aleph/tx.js +3 -0
  45. package/cjs/aleph/types.js +3 -0
  46. package/cjs/astar/consts.js +3 -0
  47. package/cjs/astar/errors.js +3 -0
  48. package/cjs/astar/events.js +3 -0
  49. package/cjs/astar/index.js +19 -0
  50. package/cjs/astar/query.js +3 -0
  51. package/cjs/astar/rpc.js +3 -0
  52. package/cjs/astar/runtime.js +3 -0
  53. package/cjs/astar/tx.js +3 -0
  54. package/cjs/astar/types.js +3 -0
  55. package/cjs/index.js +2 -0
  56. package/cjs/kusama/consts.js +3 -0
  57. package/cjs/kusama/errors.js +3 -0
  58. package/cjs/kusama/events.js +3 -0
  59. package/cjs/kusama/index.js +19 -0
  60. package/cjs/kusama/query.js +3 -0
  61. package/cjs/kusama/rpc.js +3 -0
  62. package/cjs/kusama/runtime.js +3 -0
  63. package/cjs/kusama/tx.js +3 -0
  64. package/cjs/kusama/types.js +3 -0
  65. package/cjs/kusamaAssetHub/consts.js +3 -0
  66. package/cjs/kusamaAssetHub/errors.js +3 -0
  67. package/cjs/kusamaAssetHub/events.js +3 -0
  68. package/cjs/kusamaAssetHub/index.js +19 -0
  69. package/cjs/kusamaAssetHub/query.js +3 -0
  70. package/cjs/kusamaAssetHub/rpc.js +3 -0
  71. package/cjs/kusamaAssetHub/runtime.js +3 -0
  72. package/cjs/kusamaAssetHub/tx.js +3 -0
  73. package/cjs/kusamaAssetHub/types.js +3 -0
  74. package/cjs/moonbeam/consts.js +3 -0
  75. package/cjs/moonbeam/errors.js +3 -0
  76. package/cjs/moonbeam/events.js +3 -0
  77. package/cjs/moonbeam/index.js +19 -0
  78. package/cjs/moonbeam/query.js +3 -0
  79. package/cjs/moonbeam/rpc.js +3 -0
  80. package/cjs/moonbeam/runtime.js +3 -0
  81. package/cjs/moonbeam/tx.js +3 -0
  82. package/cjs/moonbeam/types.js +3 -0
  83. package/cjs/package.json +1 -0
  84. package/cjs/packageInfo.js +5 -0
  85. package/cjs/polkadot/consts.js +3 -0
  86. package/cjs/polkadot/errors.js +3 -0
  87. package/cjs/polkadot/events.js +3 -0
  88. package/cjs/polkadot/index.js +19 -0
  89. package/cjs/polkadot/query.js +3 -0
  90. package/cjs/polkadot/rpc.js +3 -0
  91. package/cjs/polkadot/runtime.js +3 -0
  92. package/cjs/polkadot/tx.js +3 -0
  93. package/cjs/polkadot/types.js +3 -0
  94. package/cjs/polkadotAssetHub/consts.js +3 -0
  95. package/cjs/polkadotAssetHub/errors.js +3 -0
  96. package/cjs/polkadotAssetHub/events.js +3 -0
  97. package/cjs/polkadotAssetHub/index.js +19 -0
  98. package/cjs/polkadotAssetHub/query.js +3 -0
  99. package/cjs/polkadotAssetHub/rpc.js +3 -0
  100. package/cjs/polkadotAssetHub/runtime.js +3 -0
  101. package/cjs/polkadotAssetHub/tx.js +3 -0
  102. package/cjs/polkadotAssetHub/types.js +3 -0
  103. package/cjs/rococoAssetHub/consts.js +3 -0
  104. package/cjs/rococoAssetHub/errors.js +3 -0
  105. package/cjs/rococoAssetHub/events.js +3 -0
  106. package/cjs/rococoAssetHub/index.js +19 -0
  107. package/cjs/rococoAssetHub/query.js +3 -0
  108. package/cjs/rococoAssetHub/rpc.js +3 -0
  109. package/cjs/rococoAssetHub/runtime.js +3 -0
  110. package/cjs/rococoAssetHub/tx.js +3 -0
  111. package/cjs/rococoAssetHub/types.js +3 -0
  112. package/cjs/substrate/consts.js +3 -0
  113. package/cjs/substrate/errors.js +3 -0
  114. package/cjs/substrate/events.js +3 -0
  115. package/cjs/substrate/index.js +19 -0
  116. package/cjs/substrate/query.js +3 -0
  117. package/cjs/substrate/rpc.js +3 -0
  118. package/cjs/substrate/runtime.js +3 -0
  119. package/cjs/substrate/tx.js +3 -0
  120. package/cjs/substrate/types.js +3 -0
  121. package/cjs/westendAssetHub/consts.js +3 -0
  122. package/cjs/westendAssetHub/errors.js +3 -0
  123. package/cjs/westendAssetHub/events.js +3 -0
  124. package/cjs/westendAssetHub/index.js +19 -0
  125. package/cjs/westendAssetHub/query.js +3 -0
  126. package/cjs/westendAssetHub/rpc.js +3 -0
  127. package/cjs/westendAssetHub/runtime.js +3 -0
  128. package/cjs/westendAssetHub/tx.js +3 -0
  129. package/cjs/westendAssetHub/types.js +3 -0
  130. package/kusama/consts.d.ts +1422 -1573
  131. package/kusama/consts.js +2 -0
  132. package/kusama/errors.d.ts +2490 -2995
  133. package/kusama/errors.js +2 -0
  134. package/kusama/events.d.ts +2723 -2996
  135. package/kusama/events.js +2 -0
  136. package/kusama/index.d.ts +8 -11
  137. package/kusama/index.js +3 -0
  138. package/kusama/query.d.ts +3248 -3828
  139. package/kusama/query.js +2 -0
  140. package/kusama/rpc.d.ts +724 -902
  141. package/kusama/rpc.js +2 -0
  142. package/kusama/runtime.d.ts +840 -1130
  143. package/kusama/runtime.js +2 -0
  144. package/kusama/tx.d.ts +6010 -7073
  145. package/kusama/tx.js +2 -0
  146. package/kusama/types.d.ts +15336 -10143
  147. package/kusama/types.js +2 -0
  148. package/kusamaAssetHub/consts.d.ts +627 -714
  149. package/kusamaAssetHub/consts.js +2 -0
  150. package/kusamaAssetHub/errors.d.ts +1160 -1405
  151. package/kusamaAssetHub/errors.js +2 -0
  152. package/kusamaAssetHub/events.d.ts +2060 -2149
  153. package/kusamaAssetHub/events.js +2 -0
  154. package/kusamaAssetHub/index.d.ts +8 -11
  155. package/kusamaAssetHub/index.js +3 -0
  156. package/kusamaAssetHub/query.d.ts +1298 -1551
  157. package/kusamaAssetHub/query.js +2 -0
  158. package/kusamaAssetHub/rpc.d.ts +588 -744
  159. package/kusamaAssetHub/rpc.js +2 -0
  160. package/kusamaAssetHub/runtime.d.ts +398 -510
  161. package/kusamaAssetHub/runtime.js +2 -0
  162. package/kusamaAssetHub/tx.d.ts +4212 -5050
  163. package/kusamaAssetHub/tx.js +2 -0
  164. package/kusamaAssetHub/types.d.ts +9997 -5964
  165. package/kusamaAssetHub/types.js +2 -0
  166. package/moonbeam/consts.d.ts +956 -1075
  167. package/moonbeam/consts.js +2 -0
  168. package/moonbeam/errors.d.ts +1793 -2131
  169. package/moonbeam/errors.js +2 -0
  170. package/moonbeam/events.d.ts +2681 -2932
  171. package/moonbeam/events.js +2 -0
  172. package/moonbeam/index.d.ts +8 -11
  173. package/moonbeam/index.js +3 -0
  174. package/moonbeam/query.d.ts +2024 -2391
  175. package/moonbeam/query.js +2 -0
  176. package/moonbeam/rpc.d.ts +807 -1013
  177. package/moonbeam/rpc.js +2 -0
  178. package/moonbeam/runtime.d.ts +502 -665
  179. package/moonbeam/runtime.js +2 -0
  180. package/moonbeam/tx.d.ts +5201 -6152
  181. package/moonbeam/tx.js +2 -0
  182. package/moonbeam/types.d.ts +12035 -7731
  183. package/moonbeam/types.js +2 -0
  184. package/package.json +8 -9
  185. package/packageInfo.js +1 -2
  186. package/polkadot/consts.d.ts +1155 -1272
  187. package/polkadot/consts.js +2 -0
  188. package/polkadot/errors.d.ts +2016 -2420
  189. package/polkadot/errors.js +2 -0
  190. package/polkadot/events.d.ts +2092 -2314
  191. package/polkadot/events.js +2 -0
  192. package/polkadot/index.d.ts +8 -11
  193. package/polkadot/index.js +3 -0
  194. package/polkadot/query.d.ts +2808 -3319
  195. package/polkadot/query.js +2 -0
  196. package/polkadot/rpc.d.ts +724 -902
  197. package/polkadot/rpc.js +2 -0
  198. package/polkadot/runtime.d.ts +840 -1130
  199. package/polkadot/runtime.js +2 -0
  200. package/polkadot/tx.d.ts +5005 -5909
  201. package/polkadot/tx.js +2 -0
  202. package/polkadot/types.d.ts +13402 -8854
  203. package/polkadot/types.js +2 -0
  204. package/polkadotAssetHub/consts.d.ts +519 -586
  205. package/polkadotAssetHub/consts.js +2 -0
  206. package/polkadotAssetHub/errors.d.ts +921 -1115
  207. package/polkadotAssetHub/errors.js +2 -0
  208. package/polkadotAssetHub/events.d.ts +1782 -1850
  209. package/polkadotAssetHub/events.js +2 -0
  210. package/polkadotAssetHub/index.d.ts +8 -11
  211. package/polkadotAssetHub/index.js +3 -0
  212. package/polkadotAssetHub/query.d.ts +1219 -1457
  213. package/polkadotAssetHub/query.js +2 -0
  214. package/polkadotAssetHub/rpc.d.ts +588 -744
  215. package/polkadotAssetHub/rpc.js +2 -0
  216. package/polkadotAssetHub/runtime.d.ts +355 -447
  217. package/polkadotAssetHub/runtime.js +2 -0
  218. package/polkadotAssetHub/tx.d.ts +3487 -4184
  219. package/polkadotAssetHub/tx.js +2 -0
  220. package/polkadotAssetHub/types.d.ts +8891 -5266
  221. package/polkadotAssetHub/types.js +2 -0
  222. package/rococoAssetHub/consts.d.ts +653 -745
  223. package/rococoAssetHub/consts.js +2 -0
  224. package/rococoAssetHub/errors.d.ts +1227 -1490
  225. package/rococoAssetHub/errors.js +2 -0
  226. package/rococoAssetHub/events.d.ts +2047 -2127
  227. package/rococoAssetHub/events.js +2 -0
  228. package/rococoAssetHub/index.d.ts +8 -11
  229. package/rococoAssetHub/index.js +3 -0
  230. package/rococoAssetHub/query.d.ts +1266 -1513
  231. package/rococoAssetHub/query.js +2 -0
  232. package/rococoAssetHub/rpc.d.ts +588 -744
  233. package/rococoAssetHub/rpc.js +2 -0
  234. package/rococoAssetHub/runtime.d.ts +424 -538
  235. package/rococoAssetHub/runtime.js +2 -0
  236. package/rococoAssetHub/tx.d.ts +4302 -5164
  237. package/rococoAssetHub/tx.js +2 -0
  238. package/rococoAssetHub/types.d.ts +10610 -6295
  239. package/rococoAssetHub/types.js +2 -0
  240. package/substrate/consts.d.ts +1966 -2218
  241. package/substrate/consts.js +2 -0
  242. package/substrate/errors.d.ts +3333 -4019
  243. package/substrate/errors.js +2 -0
  244. package/substrate/events.d.ts +4255 -4585
  245. package/substrate/events.js +2 -0
  246. package/substrate/index.d.ts +8 -11
  247. package/substrate/index.js +3 -0
  248. package/substrate/query.d.ts +3347 -3887
  249. package/substrate/query.js +2 -0
  250. package/substrate/rpc.d.ts +716 -892
  251. package/substrate/rpc.js +2 -0
  252. package/substrate/runtime.d.ts +704 -937
  253. package/substrate/runtime.js +2 -0
  254. package/substrate/tx.d.ts +8796 -10387
  255. package/substrate/tx.js +2 -0
  256. package/substrate/types.d.ts +19843 -12891
  257. package/substrate/types.js +2 -0
  258. package/westendAssetHub/consts.d.ts +653 -745
  259. package/westendAssetHub/consts.js +2 -0
  260. package/westendAssetHub/errors.d.ts +1227 -1490
  261. package/westendAssetHub/errors.js +2 -0
  262. package/westendAssetHub/events.d.ts +2047 -2127
  263. package/westendAssetHub/events.js +2 -0
  264. package/westendAssetHub/index.d.ts +8 -11
  265. package/westendAssetHub/index.js +3 -0
  266. package/westendAssetHub/query.d.ts +1266 -1513
  267. package/westendAssetHub/query.js +2 -0
  268. package/westendAssetHub/rpc.d.ts +588 -744
  269. package/westendAssetHub/rpc.js +2 -0
  270. package/westendAssetHub/runtime.d.ts +452 -577
  271. package/westendAssetHub/runtime.js +2 -0
  272. package/westendAssetHub/tx.d.ts +4302 -5164
  273. package/westendAssetHub/tx.js +2 -0
  274. package/westendAssetHub/types.d.ts +10614 -6302
  275. package/westendAssetHub/types.js +2 -0
  276. package/index.ts +0 -10
  277. package/packageInfo.ts +0 -3
@@ -1,1134 +1,844 @@
1
- // Generated by @dedot/codegen
2
-
3
1
  import type { GenericRuntimeApis, GenericRuntimeApiMethod } from '@dedot/types';
4
- import type {
5
- RuntimeVersion,
6
- Header,
7
- DispatchError,
8
- Result,
9
- UncheckedExtrinsicLike,
10
- UncheckedExtrinsic,
11
- H256,
12
- Bytes,
13
- BytesLike,
14
- AccountId32Like,
15
- } from '@dedot/codecs';
16
- import type {
17
- SpRuntimeBlock,
18
- SpCoreOpaqueMetadata,
19
- SpRuntimeTransactionValidityTransactionValidityError,
20
- SpInherentsInherentData,
21
- SpInherentsCheckInherentsResult,
22
- SpRuntimeTransactionValidityValidTransaction,
23
- SpRuntimeTransactionValidityTransactionSource,
24
- PolkadotPrimitivesV6ValidatorAppPublic,
25
- PolkadotPrimitivesV6ValidatorIndex,
26
- PolkadotPrimitivesV6GroupRotationInfo,
27
- PolkadotPrimitivesV6CoreState,
28
- PolkadotPrimitivesV6PersistedValidationData,
29
- PolkadotParachainPrimitivesPrimitivesId,
30
- PolkadotPrimitivesV6OccupiedCoreAssumption,
31
- PolkadotParachainPrimitivesPrimitivesValidationCodeHash,
32
- PolkadotPrimitivesV6CandidateCommitments,
33
- PolkadotParachainPrimitivesPrimitivesValidationCode,
34
- PolkadotPrimitivesV6CommittedCandidateReceipt,
35
- PolkadotPrimitivesV6CandidateEvent,
36
- PolkadotCorePrimitivesInboundDownwardMessage,
37
- PolkadotCorePrimitivesInboundHrmpMessage,
38
- PolkadotPrimitivesV6ScrapedOnChainVotes,
39
- PolkadotPrimitivesV6SessionInfo,
40
- PolkadotPrimitivesV6PvfCheckStatement,
41
- PolkadotPrimitivesV6ValidatorAppSignature,
42
- PolkadotCorePrimitivesCandidateHash,
43
- PolkadotPrimitivesV6DisputeState,
44
- PolkadotPrimitivesV6ExecutorParams,
45
- PolkadotPrimitivesV6SlashingPendingSlashes,
46
- PolkadotPrimitivesV6SlashingOpaqueKeyOwnershipProof,
47
- PolkadotPrimitivesV6SlashingDisputeProof,
48
- PolkadotPrimitivesV6AsyncBackingBackingState,
49
- PolkadotPrimitivesV6AsyncBackingAsyncBackingParams,
50
- SpConsensusBeefyValidatorSet,
51
- SpConsensusBeefyEquivocationProof,
52
- SpConsensusBeefyOpaqueKeyOwnershipProof,
53
- SpConsensusBeefyEcdsaCryptoPublic,
54
- SpMmrPrimitivesError,
55
- SpMmrPrimitivesEncodableOpaqueLeaf,
56
- SpMmrPrimitivesProof,
57
- SpConsensusBeefyMmrBeefyAuthoritySet,
58
- SpConsensusGrandpaAppPublic,
59
- SpConsensusGrandpaEquivocationProof,
60
- SpConsensusGrandpaOpaqueKeyOwnershipProof,
61
- SpConsensusBabeBabeConfiguration,
62
- SpConsensusSlotsSlot,
63
- SpConsensusBabeEpoch,
64
- SpConsensusBabeOpaqueKeyOwnershipProof,
65
- SpConsensusBabeAppPublic,
66
- SpConsensusSlotsEquivocationProof,
67
- SpAuthorityDiscoveryAppPublic,
68
- SpCoreCryptoKeyTypeId,
69
- PalletTransactionPaymentRuntimeDispatchInfo,
70
- PalletTransactionPaymentFeeDetails,
71
- SpWeightsWeightV2Weight,
72
- StagingKusamaRuntimeRuntimeCallLike,
73
- } from './types';
74
-
2
+ import type { RuntimeVersion, Header, DispatchError, Result, UncheckedExtrinsicLike, UncheckedExtrinsic, H256, Bytes, BytesLike, AccountId32Like } from '@dedot/codecs';
3
+ import type { SpRuntimeBlock, SpCoreOpaqueMetadata, SpRuntimeTransactionValidityTransactionValidityError, SpInherentsInherentData, SpInherentsCheckInherentsResult, SpRuntimeTransactionValidityValidTransaction, SpRuntimeTransactionValidityTransactionSource, PolkadotPrimitivesV6ValidatorAppPublic, PolkadotPrimitivesV6ValidatorIndex, PolkadotPrimitivesV6GroupRotationInfo, PolkadotPrimitivesV6CoreState, PolkadotPrimitivesV6PersistedValidationData, PolkadotParachainPrimitivesPrimitivesId, PolkadotPrimitivesV6OccupiedCoreAssumption, PolkadotParachainPrimitivesPrimitivesValidationCodeHash, PolkadotPrimitivesV6CandidateCommitments, PolkadotParachainPrimitivesPrimitivesValidationCode, PolkadotPrimitivesV6CommittedCandidateReceipt, PolkadotPrimitivesV6CandidateEvent, PolkadotCorePrimitivesInboundDownwardMessage, PolkadotCorePrimitivesInboundHrmpMessage, PolkadotPrimitivesV6ScrapedOnChainVotes, PolkadotPrimitivesV6SessionInfo, PolkadotPrimitivesV6PvfCheckStatement, PolkadotPrimitivesV6ValidatorAppSignature, PolkadotCorePrimitivesCandidateHash, PolkadotPrimitivesV6DisputeState, PolkadotPrimitivesV6ExecutorParams, PolkadotPrimitivesV6SlashingPendingSlashes, PolkadotPrimitivesV6SlashingOpaqueKeyOwnershipProof, PolkadotPrimitivesV6SlashingDisputeProof, PolkadotPrimitivesV6AsyncBackingBackingState, PolkadotPrimitivesV6AsyncBackingAsyncBackingParams, SpConsensusBeefyValidatorSet, SpConsensusBeefyEquivocationProof, SpConsensusBeefyOpaqueKeyOwnershipProof, SpConsensusBeefyEcdsaCryptoPublic, SpMmrPrimitivesError, SpMmrPrimitivesEncodableOpaqueLeaf, SpMmrPrimitivesProof, SpConsensusBeefyMmrBeefyAuthoritySet, SpConsensusGrandpaAppPublic, SpConsensusGrandpaEquivocationProof, SpConsensusGrandpaOpaqueKeyOwnershipProof, SpConsensusBabeBabeConfiguration, SpConsensusSlotsSlot, SpConsensusBabeEpoch, SpConsensusBabeOpaqueKeyOwnershipProof, SpConsensusBabeAppPublic, SpConsensusSlotsEquivocationProof, SpAuthorityDiscoveryAppPublic, SpCoreCryptoKeyTypeId, PalletTransactionPaymentRuntimeDispatchInfo, PalletTransactionPaymentFeeDetails, SpWeightsWeightV2Weight, StagingKusamaRuntimeRuntimeCallLike } from './types';
75
4
  export interface RuntimeApis extends GenericRuntimeApis {
76
- /**
77
- * @runtimeapi: Core - 0xdf6acb689907609b
78
- **/
79
- core: {
80
5
  /**
81
- * Returns the version of the runtime.
82
- *
83
- * @callname: Core_version
84
- **/
85
- version: GenericRuntimeApiMethod<() => Promise<RuntimeVersion>>;
86
-
87
- /**
88
- * Execute the given block.
89
- *
90
- * @callname: Core_execute_block
91
- * @param {SpRuntimeBlock} block
92
- **/
93
- executeBlock: GenericRuntimeApiMethod<(block: SpRuntimeBlock) => Promise<[]>>;
94
-
95
- /**
96
- * Initialize a block with the given header.
97
- *
98
- * @callname: Core_initialize_block
99
- * @param {Header} header
100
- **/
101
- initializeBlock: GenericRuntimeApiMethod<(header: Header) => Promise<[]>>;
102
-
103
- /**
104
- * Generic runtime api call
105
- **/
106
- [method: string]: GenericRuntimeApiMethod;
107
- };
108
- /**
109
- * @runtimeapi: Metadata - 0x37e397fc7c91f5e4
110
- **/
111
- metadata: {
112
- /**
113
- * Returns the metadata of a runtime.
114
- *
115
- * @callname: Metadata_metadata
116
- **/
117
- metadata: GenericRuntimeApiMethod<() => Promise<SpCoreOpaqueMetadata>>;
118
-
119
- /**
120
- * Returns the metadata at a given version.
121
- *
122
- * If the given `version` isn't supported, this will return `None`.
123
- * Use [`Self::metadata_versions`] to find out about supported metadata version of the runtime.
124
- *
125
- * @callname: Metadata_metadata_at_version
126
- * @param {number} version
127
- **/
128
- metadataAtVersion: GenericRuntimeApiMethod<(version: number) => Promise<SpCoreOpaqueMetadata | undefined>>;
129
-
130
- /**
131
- * Returns the supported metadata versions.
132
- *
133
- * This can be used to call `metadata_at_version`.
134
- *
135
- * @callname: Metadata_metadata_versions
136
- **/
137
- metadataVersions: GenericRuntimeApiMethod<() => Promise<Array<number>>>;
138
-
139
- /**
140
- * Generic runtime api call
141
- **/
142
- [method: string]: GenericRuntimeApiMethod;
143
- };
144
- /**
145
- * @runtimeapi: BlockBuilder - 0x40fe3ad401f8959a
146
- **/
147
- blockBuilder: {
148
- /**
149
- * Apply the given extrinsic.
150
- *
151
- * Returns an inclusion outcome which specifies if this extrinsic is included in
152
- * this block or not.
153
- *
154
- * @callname: BlockBuilder_apply_extrinsic
155
- * @param {UncheckedExtrinsicLike} extrinsic
156
- **/
157
- applyExtrinsic: GenericRuntimeApiMethod<
158
- (
159
- extrinsic: UncheckedExtrinsicLike,
160
- ) => Promise<Result<Result<[], DispatchError>, SpRuntimeTransactionValidityTransactionValidityError>>
161
- >;
162
-
163
- /**
164
- * Finish the current block.
165
- *
166
- * @callname: BlockBuilder_finalize_block
167
- **/
168
- finalizeBlock: GenericRuntimeApiMethod<() => Promise<Header>>;
169
-
170
- /**
171
- * Generate inherent extrinsics. The inherent data will vary from chain to chain.
172
- *
173
- * @callname: BlockBuilder_inherent_extrinsics
174
- * @param {SpInherentsInherentData} inherent
175
- **/
176
- inherentExtrinsics: GenericRuntimeApiMethod<
177
- (inherent: SpInherentsInherentData) => Promise<Array<UncheckedExtrinsic>>
178
- >;
179
-
180
- /**
181
- * Check that the inherents are valid. The inherent data will vary from chain to chain.
182
- *
183
- * @callname: BlockBuilder_check_inherents
184
- * @param {SpRuntimeBlock} block
185
- * @param {SpInherentsInherentData} data
186
- **/
187
- checkInherents: GenericRuntimeApiMethod<
188
- (block: SpRuntimeBlock, data: SpInherentsInherentData) => Promise<SpInherentsCheckInherentsResult>
189
- >;
190
-
191
- /**
192
- * Generic runtime api call
193
- **/
194
- [method: string]: GenericRuntimeApiMethod;
195
- };
196
- /**
197
- * @runtimeapi: TaggedTransactionQueue - 0xd2bc9897eed08f15
198
- **/
199
- taggedTransactionQueue: {
200
- /**
201
- * Validate the transaction.
202
- *
203
- * This method is invoked by the transaction pool to learn details about given transaction.
204
- * The implementation should make sure to verify the correctness of the transaction
205
- * against current state. The given `block_hash` corresponds to the hash of the block
206
- * that is used as current state.
207
- *
208
- * Note that this call may be performed by the pool multiple times and transactions
209
- * might be verified in any possible order.
210
- *
211
- * @callname: TaggedTransactionQueue_validate_transaction
212
- * @param {SpRuntimeTransactionValidityTransactionSource} source
213
- * @param {UncheckedExtrinsicLike} tx
214
- * @param {H256} block_hash
215
- **/
216
- validateTransaction: GenericRuntimeApiMethod<
217
- (
218
- source: SpRuntimeTransactionValidityTransactionSource,
219
- tx: UncheckedExtrinsicLike,
220
- blockHash: H256,
221
- ) => Promise<
222
- Result<SpRuntimeTransactionValidityValidTransaction, SpRuntimeTransactionValidityTransactionValidityError>
223
- >
224
- >;
225
-
226
- /**
227
- * Generic runtime api call
228
- **/
229
- [method: string]: GenericRuntimeApiMethod;
230
- };
231
- /**
232
- * @runtimeapi: OffchainWorkerApi - 0xf78b278be53f454c
233
- **/
234
- offchainWorkerApi: {
235
- /**
236
- * Starts the off-chain task for given block header.
237
- *
238
- * @callname: OffchainWorkerApi_offchain_worker
239
- * @param {Header} header
240
- **/
241
- offchainWorker: GenericRuntimeApiMethod<(header: Header) => Promise<[]>>;
242
-
243
- /**
244
- * Generic runtime api call
245
- **/
246
- [method: string]: GenericRuntimeApiMethod;
247
- };
248
- /**
249
- * @runtimeapi: ParachainHost - 0xaf2c0297a23e6d3d
250
- **/
251
- parachainHost: {
252
- /**
253
- * Get the current validators.
254
- *
255
- * @callname: ParachainHost_validators
256
- **/
257
- validators: GenericRuntimeApiMethod<() => Promise<Array<PolkadotPrimitivesV6ValidatorAppPublic>>>;
258
-
259
- /**
260
- * Returns the validator groups and rotation info localized based on the hypothetical child
261
- * of a block whose state this is invoked on. Note that `now` in the `GroupRotationInfo`
262
- * should be the successor of the number of the block.
263
- *
264
- * @callname: ParachainHost_validator_groups
265
- **/
266
- validatorGroups: GenericRuntimeApiMethod<
267
- () => Promise<[Array<Array<PolkadotPrimitivesV6ValidatorIndex>>, PolkadotPrimitivesV6GroupRotationInfo]>
268
- >;
269
-
270
- /**
271
- * Yields information on all availability cores as relevant to the child block.
272
- * Cores are either free or occupied. Free cores can have paras assigned to them.
273
- *
274
- * @callname: ParachainHost_availability_cores
275
- **/
276
- availabilityCores: GenericRuntimeApiMethod<() => Promise<Array<PolkadotPrimitivesV6CoreState>>>;
277
-
278
- /**
279
- * Yields the persisted validation data for the given `ParaId` along with an assumption that
280
- * should be used if the para currently occupies a core.
281
- *
282
- * Returns `None` if either the para is not registered or the assumption is `Freed`
283
- * and the para already occupies a core.
284
- *
285
- * @callname: ParachainHost_persisted_validation_data
286
- * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
287
- * @param {PolkadotPrimitivesV6OccupiedCoreAssumption} assumption
288
- **/
289
- persistedValidationData: GenericRuntimeApiMethod<
290
- (
291
- paraId: PolkadotParachainPrimitivesPrimitivesId,
292
- assumption: PolkadotPrimitivesV6OccupiedCoreAssumption,
293
- ) => Promise<PolkadotPrimitivesV6PersistedValidationData | undefined>
294
- >;
295
-
296
- /**
297
- * Returns the persisted validation data for the given `ParaId` along with the corresponding
298
- * validation code hash. Instead of accepting assumption about the para, matches the validation
299
- * data hash against an expected one and yields `None` if they're not equal.
300
- *
301
- * @callname: ParachainHost_assumed_validation_data
302
- * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
303
- * @param {H256} expected_persisted_validation_data_hash
304
- **/
305
- assumedValidationData: GenericRuntimeApiMethod<
306
- (
307
- paraId: PolkadotParachainPrimitivesPrimitivesId,
308
- expectedPersistedValidationDataHash: H256,
309
- ) => Promise<
310
- | [PolkadotPrimitivesV6PersistedValidationData, PolkadotParachainPrimitivesPrimitivesValidationCodeHash]
311
- | undefined
312
- >
313
- >;
314
-
315
- /**
316
- * Checks if the given validation outputs pass the acceptance criteria.
317
- *
318
- * @callname: ParachainHost_check_validation_outputs
319
- * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
320
- * @param {PolkadotPrimitivesV6CandidateCommitments} outputs
321
- **/
322
- checkValidationOutputs: GenericRuntimeApiMethod<
323
- (
324
- paraId: PolkadotParachainPrimitivesPrimitivesId,
325
- outputs: PolkadotPrimitivesV6CandidateCommitments,
326
- ) => Promise<boolean>
327
- >;
328
-
329
- /**
330
- * Returns the session index expected at a child of the block.
331
- *
332
- * This can be used to instantiate a `SigningContext`.
333
- *
334
- * @callname: ParachainHost_session_index_for_child
335
- **/
336
- sessionIndexForChild: GenericRuntimeApiMethod<() => Promise<number>>;
337
-
338
- /**
339
- * Fetch the validation code used by a para, making the given `OccupiedCoreAssumption`.
340
- *
341
- * Returns `None` if either the para is not registered or the assumption is `Freed`
342
- * and the para already occupies a core.
343
- *
344
- * @callname: ParachainHost_validation_code
345
- * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
346
- * @param {PolkadotPrimitivesV6OccupiedCoreAssumption} assumption
347
- **/
348
- validationCode: GenericRuntimeApiMethod<
349
- (
350
- paraId: PolkadotParachainPrimitivesPrimitivesId,
351
- assumption: PolkadotPrimitivesV6OccupiedCoreAssumption,
352
- ) => Promise<PolkadotParachainPrimitivesPrimitivesValidationCode | undefined>
353
- >;
354
-
355
- /**
356
- * Get the receipt of a candidate pending availability. This returns `Some` for any paras
357
- * assigned to occupied cores in `availability_cores` and `None` otherwise.
358
- *
359
- * @callname: ParachainHost_candidate_pending_availability
360
- * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
361
- **/
362
- candidatePendingAvailability: GenericRuntimeApiMethod<
363
- (
364
- paraId: PolkadotParachainPrimitivesPrimitivesId,
365
- ) => Promise<PolkadotPrimitivesV6CommittedCandidateReceipt | undefined>
366
- >;
367
-
368
- /**
369
- * Get a vector of events concerning candidates that occurred within a block.
370
- *
371
- * @callname: ParachainHost_candidate_events
372
- **/
373
- candidateEvents: GenericRuntimeApiMethod<() => Promise<Array<PolkadotPrimitivesV6CandidateEvent>>>;
374
-
375
- /**
376
- * Get all the pending inbound messages in the downward message queue for a para.
377
- *
378
- * @callname: ParachainHost_dmq_contents
379
- * @param {PolkadotParachainPrimitivesPrimitivesId} recipient
380
- **/
381
- dmqContents: GenericRuntimeApiMethod<
382
- (
383
- recipient: PolkadotParachainPrimitivesPrimitivesId,
384
- ) => Promise<Array<PolkadotCorePrimitivesInboundDownwardMessage>>
385
- >;
386
-
387
- /**
388
- * Get the contents of all channels addressed to the given recipient. Channels that have no
389
- * messages in them are also included.
390
- *
391
- * @callname: ParachainHost_inbound_hrmp_channels_contents
392
- * @param {PolkadotParachainPrimitivesPrimitivesId} recipient
393
- **/
394
- inboundHrmpChannelsContents: GenericRuntimeApiMethod<
395
- (
396
- recipient: PolkadotParachainPrimitivesPrimitivesId,
397
- ) => Promise<Array<[PolkadotParachainPrimitivesPrimitivesId, Array<PolkadotCorePrimitivesInboundHrmpMessage>]>>
398
- >;
399
-
400
- /**
401
- * Get the validation code from its hash.
402
- *
403
- * @callname: ParachainHost_validation_code_by_hash
404
- * @param {PolkadotParachainPrimitivesPrimitivesValidationCodeHash} hash
405
- **/
406
- validationCodeByHash: GenericRuntimeApiMethod<
407
- (
408
- hash: PolkadotParachainPrimitivesPrimitivesValidationCodeHash,
409
- ) => Promise<PolkadotParachainPrimitivesPrimitivesValidationCode | undefined>
410
- >;
411
-
412
- /**
413
- * Scrape dispute relevant from on-chain, backing votes and resolved disputes.
414
- *
415
- * @callname: ParachainHost_on_chain_votes
416
- **/
417
- onChainVotes: GenericRuntimeApiMethod<() => Promise<PolkadotPrimitivesV6ScrapedOnChainVotes | undefined>>;
418
-
419
- /**
420
- * Get the session info for the given session, if stored.
421
- *
422
- * NOTE: This function is only available since parachain host version 2.
423
- *
424
- * @callname: ParachainHost_session_info
425
- * @param {number} index
426
- **/
427
- sessionInfo: GenericRuntimeApiMethod<(index: number) => Promise<PolkadotPrimitivesV6SessionInfo | undefined>>;
428
-
429
- /**
430
- * Submits a PVF pre-checking statement into the transaction pool.
431
- *
432
- * NOTE: This function is only available since parachain host version 2.
433
- *
434
- * @callname: ParachainHost_submit_pvf_check_statement
435
- * @param {PolkadotPrimitivesV6PvfCheckStatement} stmt
436
- * @param {PolkadotPrimitivesV6ValidatorAppSignature} signature
437
- **/
438
- submitPvfCheckStatement: GenericRuntimeApiMethod<
439
- (stmt: PolkadotPrimitivesV6PvfCheckStatement, signature: PolkadotPrimitivesV6ValidatorAppSignature) => Promise<[]>
440
- >;
441
-
442
- /**
443
- * Returns code hashes of PVFs that require pre-checking by validators in the active set.
444
- *
445
- * NOTE: This function is only available since parachain host version 2.
446
- *
447
- * @callname: ParachainHost_pvfs_require_precheck
448
- **/
449
- pvfsRequirePrecheck: GenericRuntimeApiMethod<
450
- () => Promise<Array<PolkadotParachainPrimitivesPrimitivesValidationCodeHash>>
451
- >;
452
-
453
- /**
454
- * Fetch the hash of the validation code used by a para, making the given `OccupiedCoreAssumption`.
455
- *
456
- * NOTE: This function is only available since parachain host version 2.
457
- *
458
- * @callname: ParachainHost_validation_code_hash
459
- * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
460
- * @param {PolkadotPrimitivesV6OccupiedCoreAssumption} assumption
461
- **/
462
- validationCodeHash: GenericRuntimeApiMethod<
463
- (
464
- paraId: PolkadotParachainPrimitivesPrimitivesId,
465
- assumption: PolkadotPrimitivesV6OccupiedCoreAssumption,
466
- ) => Promise<PolkadotParachainPrimitivesPrimitivesValidationCodeHash | undefined>
467
- >;
468
-
469
- /**
470
- * Returns all onchain disputes.
471
- *
472
- * @callname: ParachainHost_disputes
473
- **/
474
- disputes: GenericRuntimeApiMethod<
475
- () => Promise<Array<[number, PolkadotCorePrimitivesCandidateHash, PolkadotPrimitivesV6DisputeState]>>
476
- >;
477
-
478
- /**
479
- * Returns execution parameters for the session.
480
- *
481
- * @callname: ParachainHost_session_executor_params
482
- * @param {number} session_index
483
- **/
484
- sessionExecutorParams: GenericRuntimeApiMethod<
485
- (sessionIndex: number) => Promise<PolkadotPrimitivesV6ExecutorParams | undefined>
486
- >;
487
-
488
- /**
489
- * Returns a list of validators that lost a past session dispute and need to be slashed.
490
- * NOTE: This function is only available since parachain host version 5.
491
- *
492
- * @callname: ParachainHost_unapplied_slashes
493
- **/
494
- unappliedSlashes: GenericRuntimeApiMethod<
495
- () => Promise<Array<[number, PolkadotCorePrimitivesCandidateHash, PolkadotPrimitivesV6SlashingPendingSlashes]>>
496
- >;
497
-
498
- /**
499
- * Returns a merkle proof of a validator session key.
500
- * NOTE: This function is only available since parachain host version 5.
501
- *
502
- * @callname: ParachainHost_key_ownership_proof
503
- * @param {PolkadotPrimitivesV6ValidatorAppPublic} validator_id
504
- **/
505
- keyOwnershipProof: GenericRuntimeApiMethod<
506
- (
507
- validatorId: PolkadotPrimitivesV6ValidatorAppPublic,
508
- ) => Promise<PolkadotPrimitivesV6SlashingOpaqueKeyOwnershipProof | undefined>
509
- >;
510
-
511
- /**
512
- * Submit an unsigned extrinsic to slash validators who lost a dispute about
513
- * a candidate of a past session.
514
- * NOTE: This function is only available since parachain host version 5.
515
- *
516
- * @callname: ParachainHost_submit_report_dispute_lost
517
- * @param {PolkadotPrimitivesV6SlashingDisputeProof} dispute_proof
518
- * @param {PolkadotPrimitivesV6SlashingOpaqueKeyOwnershipProof} key_ownership_proof
519
- **/
520
- submitReportDisputeLost: GenericRuntimeApiMethod<
521
- (
522
- disputeProof: PolkadotPrimitivesV6SlashingDisputeProof,
523
- keyOwnershipProof: PolkadotPrimitivesV6SlashingOpaqueKeyOwnershipProof,
524
- ) => Promise<[] | undefined>
525
- >;
526
-
527
- /**
528
- * Get the minimum number of backing votes for a parachain candidate.
529
- * This is a staging method! Do not use on production runtimes!
530
- *
531
- * @callname: ParachainHost_minimum_backing_votes
532
- **/
533
- minimumBackingVotes: GenericRuntimeApiMethod<() => Promise<number>>;
534
-
535
- /**
536
- * Returns the state of parachain backing for a given para.
537
- *
538
- * @callname: ParachainHost_para_backing_state
539
- * @param {PolkadotParachainPrimitivesPrimitivesId} _
540
- **/
541
- paraBackingState: GenericRuntimeApiMethod<
542
- (
543
- undefined: PolkadotParachainPrimitivesPrimitivesId,
544
- ) => Promise<PolkadotPrimitivesV6AsyncBackingBackingState | undefined>
545
- >;
546
-
547
- /**
548
- * Returns candidate's acceptance limitations for asynchronous backing for a relay parent.
549
- *
550
- * @callname: ParachainHost_async_backing_params
551
- **/
552
- asyncBackingParams: GenericRuntimeApiMethod<() => Promise<PolkadotPrimitivesV6AsyncBackingAsyncBackingParams>>;
553
-
554
- /**
555
- * Returns a list of all disabled validators at the given block.
556
- *
557
- * @callname: ParachainHost_disabled_validators
558
- **/
559
- disabledValidators: GenericRuntimeApiMethod<() => Promise<Array<PolkadotPrimitivesV6ValidatorIndex>>>;
560
-
561
- /**
562
- * Generic runtime api call
563
- **/
564
- [method: string]: GenericRuntimeApiMethod;
565
- };
566
- /**
567
- * @runtimeapi: BeefyApi - 0x49eaaf1b548a0cb0
568
- **/
569
- beefyApi: {
570
- /**
571
- * Return the block number where BEEFY consensus is enabled/started
572
- *
573
- * @callname: BeefyApi_beefy_genesis
574
- **/
575
- beefyGenesis: GenericRuntimeApiMethod<() => Promise<number | undefined>>;
576
-
577
- /**
578
- * Return the current active BEEFY validator set
579
- *
580
- * @callname: BeefyApi_validator_set
581
- **/
582
- validatorSet: GenericRuntimeApiMethod<() => Promise<SpConsensusBeefyValidatorSet | undefined>>;
583
-
584
- /**
585
- * Submits an unsigned extrinsic to report an equivocation. The caller
586
- * must provide the equivocation proof and a key ownership proof
587
- * (should be obtained using `generate_key_ownership_proof`). The
588
- * extrinsic will be unsigned and should only be accepted for local
589
- * authorship (not to be broadcast to the network). This method returns
590
- * `None` when creation of the extrinsic fails, e.g. if equivocation
591
- * reporting is disabled for the given runtime (i.e. this method is
592
- * hardcoded to return `None`). Only useful in an offchain context.
593
- *
594
- * @callname: BeefyApi_submit_report_equivocation_unsigned_extrinsic
595
- * @param {SpConsensusBeefyEquivocationProof} equivocation_proof
596
- * @param {SpConsensusBeefyOpaqueKeyOwnershipProof} key_owner_proof
597
- **/
598
- submitReportEquivocationUnsignedExtrinsic: GenericRuntimeApiMethod<
599
- (
600
- equivocationProof: SpConsensusBeefyEquivocationProof,
601
- keyOwnerProof: SpConsensusBeefyOpaqueKeyOwnershipProof,
602
- ) => Promise<[] | undefined>
603
- >;
604
-
605
- /**
606
- * Generates a proof of key ownership for the given authority in the
607
- * given set. An example usage of this module is coupled with the
608
- * session historical module to prove that a given authority key is
609
- * tied to a given staking identity during a specific session. Proofs
610
- * of key ownership are necessary for submitting equivocation reports.
611
- * NOTE: even though the API takes a `set_id` as parameter the current
612
- * implementations ignores this parameter and instead relies on this
613
- * method being called at the correct block height, i.e. any point at
614
- * which the given set id is live on-chain. Future implementations will
615
- * instead use indexed data through an offchain worker, not requiring
616
- * older states to be available.
617
- *
618
- * @callname: BeefyApi_generate_key_ownership_proof
619
- * @param {bigint} set_id
620
- * @param {SpConsensusBeefyEcdsaCryptoPublic} authority_id
621
- **/
622
- generateKeyOwnershipProof: GenericRuntimeApiMethod<
623
- (
624
- setId: bigint,
625
- authorityId: SpConsensusBeefyEcdsaCryptoPublic,
626
- ) => Promise<SpConsensusBeefyOpaqueKeyOwnershipProof | undefined>
627
- >;
628
-
629
- /**
630
- * Generic runtime api call
631
- **/
632
- [method: string]: GenericRuntimeApiMethod;
633
- };
634
- /**
635
- * @runtimeapi: MmrApi - 0x91d5df18b0d2cf58
636
- **/
637
- mmrApi: {
638
- /**
639
- * Return the on-chain MMR root hash.
640
- *
641
- * @callname: MmrApi_mmr_root
642
- **/
643
- mmrRoot: GenericRuntimeApiMethod<() => Promise<Result<H256, SpMmrPrimitivesError>>>;
644
-
645
- /**
646
- * Return the number of MMR blocks in the chain.
647
- *
648
- * @callname: MmrApi_mmr_leaf_count
649
- **/
650
- mmrLeafCount: GenericRuntimeApiMethod<() => Promise<Result<bigint, SpMmrPrimitivesError>>>;
651
-
652
- /**
653
- * Generate MMR proof for a series of block numbers. If `best_known_block_number = Some(n)`,
654
- * use historical MMR state at given block height `n`. Else, use current MMR state.
655
- *
656
- * @callname: MmrApi_generate_proof
657
- * @param {Array<number>} block_numbers
658
- * @param {number | undefined} best_known_block_number
659
- **/
660
- generateProof: GenericRuntimeApiMethod<
661
- (
662
- blockNumbers: Array<number>,
663
- bestKnownBlockNumber?: number | undefined,
664
- ) => Promise<Result<[Array<SpMmrPrimitivesEncodableOpaqueLeaf>, SpMmrPrimitivesProof], SpMmrPrimitivesError>>
665
- >;
666
-
667
- /**
668
- * Verify MMR proof against on-chain MMR for a batch of leaves.
669
- *
670
- * Note this function will use on-chain MMR root hash and check if the proof matches the hash.
671
- * Note, the leaves should be sorted such that corresponding leaves and leaf indices have the
672
- * same position in both the `leaves` vector and the `leaf_indices` vector contained in the [Proof]
673
- *
674
- * @callname: MmrApi_verify_proof
675
- * @param {Array<SpMmrPrimitivesEncodableOpaqueLeaf>} leaves
676
- * @param {SpMmrPrimitivesProof} proof
677
- **/
678
- verifyProof: GenericRuntimeApiMethod<
679
- (
680
- leaves: Array<SpMmrPrimitivesEncodableOpaqueLeaf>,
681
- proof: SpMmrPrimitivesProof,
682
- ) => Promise<Result<[], SpMmrPrimitivesError>>
683
- >;
684
-
685
- /**
686
- * Verify MMR proof against given root hash for a batch of leaves.
687
- *
688
- * Note this function does not require any on-chain storage - the
689
- * proof is verified against given MMR root hash.
690
- *
691
- * Note, the leaves should be sorted such that corresponding leaves and leaf indices have the
692
- * same position in both the `leaves` vector and the `leaf_indices` vector contained in the [Proof]
693
- *
694
- * @callname: MmrApi_verify_proof_stateless
695
- * @param {H256} root
696
- * @param {Array<SpMmrPrimitivesEncodableOpaqueLeaf>} leaves
697
- * @param {SpMmrPrimitivesProof} proof
698
- **/
699
- verifyProofStateless: GenericRuntimeApiMethod<
700
- (
701
- root: H256,
702
- leaves: Array<SpMmrPrimitivesEncodableOpaqueLeaf>,
703
- proof: SpMmrPrimitivesProof,
704
- ) => Promise<Result<[], SpMmrPrimitivesError>>
705
- >;
706
-
707
- /**
708
- * Generic runtime api call
709
- **/
710
- [method: string]: GenericRuntimeApiMethod;
711
- };
712
- /**
713
- * @runtimeapi: BeefyMmrApi - 0x2a5e924655399e60
714
- **/
715
- beefyMmrApi: {
716
- /**
717
- * Return the currently active BEEFY authority set proof.
718
- *
719
- * @callname: BeefyMmrApi_authority_set_proof
720
- **/
721
- authoritySetProof: GenericRuntimeApiMethod<() => Promise<SpConsensusBeefyMmrBeefyAuthoritySet>>;
722
-
723
- /**
724
- * Return the next/queued BEEFY authority set proof.
725
- *
726
- * @callname: BeefyMmrApi_next_authority_set_proof
727
- **/
728
- nextAuthoritySetProof: GenericRuntimeApiMethod<() => Promise<SpConsensusBeefyMmrBeefyAuthoritySet>>;
729
-
730
- /**
731
- * Generic runtime api call
732
- **/
733
- [method: string]: GenericRuntimeApiMethod;
734
- };
735
- /**
736
- * @runtimeapi: GrandpaApi - 0xed99c5acb25eedf5
737
- **/
738
- grandpaApi: {
739
- /**
740
- * Get the current GRANDPA authorities and weights. This should not change except
741
- * for when changes are scheduled and the corresponding delay has passed.
742
- *
743
- * When called at block B, it will return the set of authorities that should be
744
- * used to finalize descendants of this block (B+1, B+2, ...). The block B itself
745
- * is finalized by the authorities from block B-1.
746
- *
747
- * @callname: GrandpaApi_grandpa_authorities
748
- **/
749
- grandpaAuthorities: GenericRuntimeApiMethod<() => Promise<Array<[SpConsensusGrandpaAppPublic, bigint]>>>;
750
-
751
- /**
752
- * Submits an unsigned extrinsic to report an equivocation. The caller
753
- * must provide the equivocation proof and a key ownership proof
754
- * (should be obtained using `generate_key_ownership_proof`). The
755
- * extrinsic will be unsigned and should only be accepted for local
756
- * authorship (not to be broadcast to the network). This method returns
757
- * `None` when creation of the extrinsic fails, e.g. if equivocation
758
- * reporting is disabled for the given runtime (i.e. this method is
759
- * hardcoded to return `None`). Only useful in an offchain context.
760
- *
761
- * @callname: GrandpaApi_submit_report_equivocation_unsigned_extrinsic
762
- * @param {SpConsensusGrandpaEquivocationProof} equivocation_proof
763
- * @param {SpConsensusGrandpaOpaqueKeyOwnershipProof} key_owner_proof
764
- **/
765
- submitReportEquivocationUnsignedExtrinsic: GenericRuntimeApiMethod<
766
- (
767
- equivocationProof: SpConsensusGrandpaEquivocationProof,
768
- keyOwnerProof: SpConsensusGrandpaOpaqueKeyOwnershipProof,
769
- ) => Promise<[] | undefined>
770
- >;
771
-
772
- /**
773
- * Generates a proof of key ownership for the given authority in the
774
- * given set. An example usage of this module is coupled with the
775
- * session historical module to prove that a given authority key is
776
- * tied to a given staking identity during a specific session. Proofs
777
- * of key ownership are necessary for submitting equivocation reports.
778
- * NOTE: even though the API takes a `set_id` as parameter the current
779
- * implementations ignore this parameter and instead rely on this
780
- * method being called at the correct block height, i.e. any point at
781
- * which the given set id is live on-chain. Future implementations will
782
- * instead use indexed data through an offchain worker, not requiring
783
- * older states to be available.
784
- *
785
- * @callname: GrandpaApi_generate_key_ownership_proof
786
- * @param {bigint} set_id
787
- * @param {SpConsensusGrandpaAppPublic} authority_id
788
- **/
789
- generateKeyOwnershipProof: GenericRuntimeApiMethod<
790
- (
791
- setId: bigint,
792
- authorityId: SpConsensusGrandpaAppPublic,
793
- ) => Promise<SpConsensusGrandpaOpaqueKeyOwnershipProof | undefined>
794
- >;
795
-
796
- /**
797
- * Get current GRANDPA authority set id.
798
- *
799
- * @callname: GrandpaApi_current_set_id
800
- **/
801
- currentSetId: GenericRuntimeApiMethod<() => Promise<bigint>>;
802
-
803
- /**
804
- * Generic runtime api call
805
- **/
806
- [method: string]: GenericRuntimeApiMethod;
807
- };
808
- /**
809
- * @runtimeapi: BabeApi - 0xcbca25e39f142387
810
- **/
811
- babeApi: {
812
- /**
813
- * Return the configuration for BABE.
814
- *
815
- * @callname: BabeApi_configuration
816
- **/
817
- configuration: GenericRuntimeApiMethod<() => Promise<SpConsensusBabeBabeConfiguration>>;
818
-
819
- /**
820
- * Returns the slot that started the current epoch.
821
- *
822
- * @callname: BabeApi_current_epoch_start
823
- **/
824
- currentEpochStart: GenericRuntimeApiMethod<() => Promise<SpConsensusSlotsSlot>>;
825
-
826
- /**
827
- * Returns information regarding the current epoch.
828
- *
829
- * @callname: BabeApi_current_epoch
830
- **/
831
- currentEpoch: GenericRuntimeApiMethod<() => Promise<SpConsensusBabeEpoch>>;
832
-
833
- /**
834
- * Returns information regarding the next epoch (which was already
835
- * previously announced).
836
- *
837
- * @callname: BabeApi_next_epoch
838
- **/
839
- nextEpoch: GenericRuntimeApiMethod<() => Promise<SpConsensusBabeEpoch>>;
840
-
841
- /**
842
- * Generates a proof of key ownership for the given authority in the
843
- * current epoch. An example usage of this module is coupled with the
844
- * session historical module to prove that a given authority key is
845
- * tied to a given staking identity during a specific session. Proofs
846
- * of key ownership are necessary for submitting equivocation reports.
847
- * NOTE: even though the API takes a `slot` as parameter the current
848
- * implementations ignores this parameter and instead relies on this
849
- * method being called at the correct block height, i.e. any point at
850
- * which the epoch for the given slot is live on-chain. Future
851
- * implementations will instead use indexed data through an offchain
852
- * worker, not requiring older states to be available.
853
- *
854
- * @callname: BabeApi_generate_key_ownership_proof
855
- * @param {SpConsensusSlotsSlot} slot
856
- * @param {SpConsensusBabeAppPublic} authority_id
857
- **/
858
- generateKeyOwnershipProof: GenericRuntimeApiMethod<
859
- (
860
- slot: SpConsensusSlotsSlot,
861
- authorityId: SpConsensusBabeAppPublic,
862
- ) => Promise<SpConsensusBabeOpaqueKeyOwnershipProof | undefined>
863
- >;
864
-
865
- /**
866
- * Submits an unsigned extrinsic to report an equivocation. The caller
867
- * must provide the equivocation proof and a key ownership proof
868
- * (should be obtained using `generate_key_ownership_proof`). The
869
- * extrinsic will be unsigned and should only be accepted for local
870
- * authorship (not to be broadcast to the network). This method returns
871
- * `None` when creation of the extrinsic fails, e.g. if equivocation
872
- * reporting is disabled for the given runtime (i.e. this method is
873
- * hardcoded to return `None`). Only useful in an offchain context.
874
- *
875
- * @callname: BabeApi_submit_report_equivocation_unsigned_extrinsic
876
- * @param {SpConsensusSlotsEquivocationProof} equivocation_proof
877
- * @param {SpConsensusBabeOpaqueKeyOwnershipProof} key_owner_proof
878
- **/
879
- submitReportEquivocationUnsignedExtrinsic: GenericRuntimeApiMethod<
880
- (
881
- equivocationProof: SpConsensusSlotsEquivocationProof,
882
- keyOwnerProof: SpConsensusBabeOpaqueKeyOwnershipProof,
883
- ) => Promise<[] | undefined>
884
- >;
885
-
886
- /**
887
- * Generic runtime api call
888
- **/
889
- [method: string]: GenericRuntimeApiMethod;
890
- };
891
- /**
892
- * @runtimeapi: AuthorityDiscoveryApi - 0x687ad44ad37f03c2
893
- **/
894
- authorityDiscoveryApi: {
895
- /**
896
- * Retrieve authority identifiers of the current and next authority set.
897
- *
898
- * @callname: AuthorityDiscoveryApi_authorities
899
- **/
900
- authorities: GenericRuntimeApiMethod<() => Promise<Array<SpAuthorityDiscoveryAppPublic>>>;
901
-
902
- /**
903
- * Generic runtime api call
904
- **/
905
- [method: string]: GenericRuntimeApiMethod;
906
- };
907
- /**
908
- * @runtimeapi: SessionKeys - 0xab3c0572291feb8b
909
- **/
910
- sessionKeys: {
911
- /**
912
- * Generate a set of session keys with optionally using the given seed.
913
- * The keys should be stored within the keystore exposed via runtime
914
- * externalities.
915
- *
916
- * The seed needs to be a valid `utf8` string.
917
- *
918
- * Returns the concatenated SCALE encoded public keys.
919
- *
920
- * @callname: SessionKeys_generate_session_keys
921
- * @param {BytesLike | undefined} seed
922
- **/
923
- generateSessionKeys: GenericRuntimeApiMethod<(seed?: BytesLike | undefined) => Promise<Bytes>>;
924
-
925
- /**
926
- * Decode the given public session keys.
927
- *
928
- * Returns the list of public raw public keys + key type.
929
- *
930
- * @callname: SessionKeys_decode_session_keys
931
- * @param {BytesLike} encoded
932
- **/
933
- decodeSessionKeys: GenericRuntimeApiMethod<
934
- (encoded: BytesLike) => Promise<Array<[Bytes, SpCoreCryptoKeyTypeId]> | undefined>
935
- >;
936
-
937
- /**
938
- * Generic runtime api call
939
- **/
940
- [method: string]: GenericRuntimeApiMethod;
941
- };
942
- /**
943
- * @runtimeapi: AccountNonceApi - 0xbc9d89904f5b923f
944
- **/
945
- accountNonceApi: {
946
- /**
947
- * Get current account nonce of given `AccountId`.
948
- *
949
- * @callname: AccountNonceApi_account_nonce
950
- * @param {AccountId32Like} account
951
- **/
952
- accountNonce: GenericRuntimeApiMethod<(account: AccountId32Like) => Promise<number>>;
953
-
954
- /**
955
- * Generic runtime api call
956
- **/
957
- [method: string]: GenericRuntimeApiMethod;
958
- };
959
- /**
960
- * @runtimeapi: TransactionPaymentApi - 0x37c8bb1350a9a2a8
961
- **/
962
- transactionPaymentApi: {
963
- /**
964
- *
965
- * @callname: TransactionPaymentApi_query_info
966
- * @param {UncheckedExtrinsicLike} uxt
967
- * @param {number} len
968
- **/
969
- queryInfo: GenericRuntimeApiMethod<
970
- (uxt: UncheckedExtrinsicLike, len: number) => Promise<PalletTransactionPaymentRuntimeDispatchInfo>
971
- >;
972
-
973
- /**
974
- *
975
- * @callname: TransactionPaymentApi_query_fee_details
976
- * @param {UncheckedExtrinsicLike} uxt
977
- * @param {number} len
978
- **/
979
- queryFeeDetails: GenericRuntimeApiMethod<
980
- (uxt: UncheckedExtrinsicLike, len: number) => Promise<PalletTransactionPaymentFeeDetails>
981
- >;
982
-
983
- /**
984
- *
985
- * @callname: TransactionPaymentApi_query_weight_to_fee
986
- * @param {SpWeightsWeightV2Weight} weight
987
- **/
988
- queryWeightToFee: GenericRuntimeApiMethod<(weight: SpWeightsWeightV2Weight) => Promise<bigint>>;
989
-
990
- /**
991
- *
992
- * @callname: TransactionPaymentApi_query_length_to_fee
993
- * @param {number} length
994
- **/
995
- queryLengthToFee: GenericRuntimeApiMethod<(length: number) => Promise<bigint>>;
996
-
997
- /**
998
- * Generic runtime api call
999
- **/
1000
- [method: string]: GenericRuntimeApiMethod;
1001
- };
1002
- /**
1003
- * @runtimeapi: TransactionPaymentCallApi - 0xf3ff14d5ab527059
1004
- **/
1005
- transactionPaymentCallApi: {
1006
- /**
1007
- * Query information of a dispatch class, weight, and fee of a given encoded `Call`.
1008
- *
1009
- * @callname: TransactionPaymentCallApi_query_call_info
1010
- * @param {StagingKusamaRuntimeRuntimeCallLike} call
1011
- * @param {number} len
1012
- **/
1013
- queryCallInfo: GenericRuntimeApiMethod<
1014
- (call: StagingKusamaRuntimeRuntimeCallLike, len: number) => Promise<PalletTransactionPaymentRuntimeDispatchInfo>
1015
- >;
1016
-
1017
- /**
1018
- * Query fee details of a given encoded `Call`.
1019
- *
1020
- * @callname: TransactionPaymentCallApi_query_call_fee_details
1021
- * @param {StagingKusamaRuntimeRuntimeCallLike} call
1022
- * @param {number} len
1023
- **/
1024
- queryCallFeeDetails: GenericRuntimeApiMethod<
1025
- (call: StagingKusamaRuntimeRuntimeCallLike, len: number) => Promise<PalletTransactionPaymentFeeDetails>
1026
- >;
1027
-
1028
- /**
1029
- * Query the output of the current `WeightToFee` given some input.
1030
- *
1031
- * @callname: TransactionPaymentCallApi_query_weight_to_fee
1032
- * @param {SpWeightsWeightV2Weight} weight
1033
- **/
1034
- queryWeightToFee: GenericRuntimeApiMethod<(weight: SpWeightsWeightV2Weight) => Promise<bigint>>;
1035
-
1036
- /**
1037
- * Query the output of the current `LengthToFee` given some input.
1038
- *
1039
- * @callname: TransactionPaymentCallApi_query_length_to_fee
1040
- * @param {number} length
1041
- **/
1042
- queryLengthToFee: GenericRuntimeApiMethod<(length: number) => Promise<bigint>>;
1043
-
1044
- /**
1045
- * Generic runtime api call
1046
- **/
1047
- [method: string]: GenericRuntimeApiMethod;
1048
- };
1049
- /**
1050
- * @runtimeapi: NominationPoolsApi - 0x17a6bc0d0062aeb3
1051
- **/
1052
- nominationPoolsApi: {
1053
- /**
1054
- * Returns the pending rewards for the member that the AccountId was given for.
1055
- *
1056
- * @callname: NominationPoolsApi_pending_rewards
1057
- * @param {AccountId32Like} who
1058
- **/
1059
- pendingRewards: GenericRuntimeApiMethod<(who: AccountId32Like) => Promise<bigint>>;
1060
-
1061
- /**
1062
- * Returns the equivalent balance of `points` for a given pool.
1063
- *
1064
- * @callname: NominationPoolsApi_points_to_balance
1065
- * @param {number} pool_id
1066
- * @param {bigint} points
1067
- **/
1068
- pointsToBalance: GenericRuntimeApiMethod<(poolId: number, points: bigint) => Promise<bigint>>;
1069
-
1070
- /**
1071
- * Returns the equivalent points of `new_funds` for a given pool.
1072
- *
1073
- * @callname: NominationPoolsApi_balance_to_points
1074
- * @param {number} pool_id
1075
- * @param {bigint} new_funds
1076
- **/
1077
- balanceToPoints: GenericRuntimeApiMethod<(poolId: number, newFunds: bigint) => Promise<bigint>>;
1078
-
1079
- /**
1080
- * Generic runtime api call
1081
- **/
1082
- [method: string]: GenericRuntimeApiMethod;
1083
- };
1084
- /**
1085
- * @runtimeapi: StakingApi - 0x18ef58a3b67ba770
1086
- **/
1087
- stakingApi: {
1088
- /**
1089
- * Returns the nominations quota for a nominator with a given balance.
1090
- *
1091
- * @callname: StakingApi_nominations_quota
1092
- * @param {bigint} balance
1093
- **/
1094
- nominationsQuota: GenericRuntimeApiMethod<(balance: bigint) => Promise<number>>;
1095
-
1096
- /**
1097
- * Generic runtime api call
1098
- **/
1099
- [method: string]: GenericRuntimeApiMethod;
1100
- };
1101
- /**
1102
- * @runtimeapi: GenesisBuilder - 0xfbc577b9d747efd6
1103
- **/
1104
- genesisBuilder: {
1105
- /**
1106
- * Creates the default `GenesisConfig` and returns it as a JSON blob.
1107
- *
1108
- * This function instantiates the default `GenesisConfig` struct for the runtime and serializes it into a JSON
1109
- * blob. It returns a `Vec<u8>` containing the JSON representation of the default `GenesisConfig`.
1110
- *
1111
- * @callname: GenesisBuilder_create_default_config
1112
- **/
1113
- createDefaultConfig: GenericRuntimeApiMethod<() => Promise<Bytes>>;
1114
-
1115
- /**
1116
- * Build `GenesisConfig` from a JSON blob not using any defaults and store it in the storage.
1117
- *
1118
- * This function deserializes the full `GenesisConfig` from the given JSON blob and puts it into the storage.
1119
- * If the provided JSON blob is incorrect or incomplete or the deserialization fails, an error is returned.
1120
- * It is recommended to log any errors encountered during the process.
1121
- *
1122
- * Please note that provided json blob must contain all `GenesisConfig` fields, no defaults will be used.
1123
- *
1124
- * @callname: GenesisBuilder_build_config
1125
- * @param {BytesLike} json
1126
- **/
1127
- buildConfig: GenericRuntimeApiMethod<(json: BytesLike) => Promise<Result<[], string>>>;
1128
-
1129
- /**
1130
- * Generic runtime api call
1131
- **/
1132
- [method: string]: GenericRuntimeApiMethod;
1133
- };
6
+ * @runtimeapi: Core - 0xdf6acb689907609b
7
+ **/
8
+ core: {
9
+ /**
10
+ * Returns the version of the runtime.
11
+ *
12
+ * @callname: Core_version
13
+ **/
14
+ version: GenericRuntimeApiMethod<() => Promise<RuntimeVersion>>;
15
+ /**
16
+ * Execute the given block.
17
+ *
18
+ * @callname: Core_execute_block
19
+ * @param {SpRuntimeBlock} block
20
+ **/
21
+ executeBlock: GenericRuntimeApiMethod<(block: SpRuntimeBlock) => Promise<[]>>;
22
+ /**
23
+ * Initialize a block with the given header.
24
+ *
25
+ * @callname: Core_initialize_block
26
+ * @param {Header} header
27
+ **/
28
+ initializeBlock: GenericRuntimeApiMethod<(header: Header) => Promise<[]>>;
29
+ /**
30
+ * Generic runtime api call
31
+ **/
32
+ [method: string]: GenericRuntimeApiMethod;
33
+ };
34
+ /**
35
+ * @runtimeapi: Metadata - 0x37e397fc7c91f5e4
36
+ **/
37
+ metadata: {
38
+ /**
39
+ * Returns the metadata of a runtime.
40
+ *
41
+ * @callname: Metadata_metadata
42
+ **/
43
+ metadata: GenericRuntimeApiMethod<() => Promise<SpCoreOpaqueMetadata>>;
44
+ /**
45
+ * Returns the metadata at a given version.
46
+ *
47
+ * If the given `version` isn't supported, this will return `None`.
48
+ * Use [`Self::metadata_versions`] to find out about supported metadata version of the runtime.
49
+ *
50
+ * @callname: Metadata_metadata_at_version
51
+ * @param {number} version
52
+ **/
53
+ metadataAtVersion: GenericRuntimeApiMethod<(version: number) => Promise<SpCoreOpaqueMetadata | undefined>>;
54
+ /**
55
+ * Returns the supported metadata versions.
56
+ *
57
+ * This can be used to call `metadata_at_version`.
58
+ *
59
+ * @callname: Metadata_metadata_versions
60
+ **/
61
+ metadataVersions: GenericRuntimeApiMethod<() => Promise<Array<number>>>;
62
+ /**
63
+ * Generic runtime api call
64
+ **/
65
+ [method: string]: GenericRuntimeApiMethod;
66
+ };
67
+ /**
68
+ * @runtimeapi: BlockBuilder - 0x40fe3ad401f8959a
69
+ **/
70
+ blockBuilder: {
71
+ /**
72
+ * Apply the given extrinsic.
73
+ *
74
+ * Returns an inclusion outcome which specifies if this extrinsic is included in
75
+ * this block or not.
76
+ *
77
+ * @callname: BlockBuilder_apply_extrinsic
78
+ * @param {UncheckedExtrinsicLike} extrinsic
79
+ **/
80
+ applyExtrinsic: GenericRuntimeApiMethod<(extrinsic: UncheckedExtrinsicLike) => Promise<Result<Result<[], DispatchError>, SpRuntimeTransactionValidityTransactionValidityError>>>;
81
+ /**
82
+ * Finish the current block.
83
+ *
84
+ * @callname: BlockBuilder_finalize_block
85
+ **/
86
+ finalizeBlock: GenericRuntimeApiMethod<() => Promise<Header>>;
87
+ /**
88
+ * Generate inherent extrinsics. The inherent data will vary from chain to chain.
89
+ *
90
+ * @callname: BlockBuilder_inherent_extrinsics
91
+ * @param {SpInherentsInherentData} inherent
92
+ **/
93
+ inherentExtrinsics: GenericRuntimeApiMethod<(inherent: SpInherentsInherentData) => Promise<Array<UncheckedExtrinsic>>>;
94
+ /**
95
+ * Check that the inherents are valid. The inherent data will vary from chain to chain.
96
+ *
97
+ * @callname: BlockBuilder_check_inherents
98
+ * @param {SpRuntimeBlock} block
99
+ * @param {SpInherentsInherentData} data
100
+ **/
101
+ checkInherents: GenericRuntimeApiMethod<(block: SpRuntimeBlock, data: SpInherentsInherentData) => Promise<SpInherentsCheckInherentsResult>>;
102
+ /**
103
+ * Generic runtime api call
104
+ **/
105
+ [method: string]: GenericRuntimeApiMethod;
106
+ };
107
+ /**
108
+ * @runtimeapi: TaggedTransactionQueue - 0xd2bc9897eed08f15
109
+ **/
110
+ taggedTransactionQueue: {
111
+ /**
112
+ * Validate the transaction.
113
+ *
114
+ * This method is invoked by the transaction pool to learn details about given transaction.
115
+ * The implementation should make sure to verify the correctness of the transaction
116
+ * against current state. The given `block_hash` corresponds to the hash of the block
117
+ * that is used as current state.
118
+ *
119
+ * Note that this call may be performed by the pool multiple times and transactions
120
+ * might be verified in any possible order.
121
+ *
122
+ * @callname: TaggedTransactionQueue_validate_transaction
123
+ * @param {SpRuntimeTransactionValidityTransactionSource} source
124
+ * @param {UncheckedExtrinsicLike} tx
125
+ * @param {H256} block_hash
126
+ **/
127
+ validateTransaction: GenericRuntimeApiMethod<(source: SpRuntimeTransactionValidityTransactionSource, tx: UncheckedExtrinsicLike, blockHash: H256) => Promise<Result<SpRuntimeTransactionValidityValidTransaction, SpRuntimeTransactionValidityTransactionValidityError>>>;
128
+ /**
129
+ * Generic runtime api call
130
+ **/
131
+ [method: string]: GenericRuntimeApiMethod;
132
+ };
133
+ /**
134
+ * @runtimeapi: OffchainWorkerApi - 0xf78b278be53f454c
135
+ **/
136
+ offchainWorkerApi: {
137
+ /**
138
+ * Starts the off-chain task for given block header.
139
+ *
140
+ * @callname: OffchainWorkerApi_offchain_worker
141
+ * @param {Header} header
142
+ **/
143
+ offchainWorker: GenericRuntimeApiMethod<(header: Header) => Promise<[]>>;
144
+ /**
145
+ * Generic runtime api call
146
+ **/
147
+ [method: string]: GenericRuntimeApiMethod;
148
+ };
149
+ /**
150
+ * @runtimeapi: ParachainHost - 0xaf2c0297a23e6d3d
151
+ **/
152
+ parachainHost: {
153
+ /**
154
+ * Get the current validators.
155
+ *
156
+ * @callname: ParachainHost_validators
157
+ **/
158
+ validators: GenericRuntimeApiMethod<() => Promise<Array<PolkadotPrimitivesV6ValidatorAppPublic>>>;
159
+ /**
160
+ * Returns the validator groups and rotation info localized based on the hypothetical child
161
+ * of a block whose state this is invoked on. Note that `now` in the `GroupRotationInfo`
162
+ * should be the successor of the number of the block.
163
+ *
164
+ * @callname: ParachainHost_validator_groups
165
+ **/
166
+ validatorGroups: GenericRuntimeApiMethod<() => Promise<[Array<Array<PolkadotPrimitivesV6ValidatorIndex>>, PolkadotPrimitivesV6GroupRotationInfo]>>;
167
+ /**
168
+ * Yields information on all availability cores as relevant to the child block.
169
+ * Cores are either free or occupied. Free cores can have paras assigned to them.
170
+ *
171
+ * @callname: ParachainHost_availability_cores
172
+ **/
173
+ availabilityCores: GenericRuntimeApiMethod<() => Promise<Array<PolkadotPrimitivesV6CoreState>>>;
174
+ /**
175
+ * Yields the persisted validation data for the given `ParaId` along with an assumption that
176
+ * should be used if the para currently occupies a core.
177
+ *
178
+ * Returns `None` if either the para is not registered or the assumption is `Freed`
179
+ * and the para already occupies a core.
180
+ *
181
+ * @callname: ParachainHost_persisted_validation_data
182
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
183
+ * @param {PolkadotPrimitivesV6OccupiedCoreAssumption} assumption
184
+ **/
185
+ persistedValidationData: GenericRuntimeApiMethod<(paraId: PolkadotParachainPrimitivesPrimitivesId, assumption: PolkadotPrimitivesV6OccupiedCoreAssumption) => Promise<PolkadotPrimitivesV6PersistedValidationData | undefined>>;
186
+ /**
187
+ * Returns the persisted validation data for the given `ParaId` along with the corresponding
188
+ * validation code hash. Instead of accepting assumption about the para, matches the validation
189
+ * data hash against an expected one and yields `None` if they're not equal.
190
+ *
191
+ * @callname: ParachainHost_assumed_validation_data
192
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
193
+ * @param {H256} expected_persisted_validation_data_hash
194
+ **/
195
+ assumedValidationData: GenericRuntimeApiMethod<(paraId: PolkadotParachainPrimitivesPrimitivesId, expectedPersistedValidationDataHash: H256) => Promise<[PolkadotPrimitivesV6PersistedValidationData, PolkadotParachainPrimitivesPrimitivesValidationCodeHash] | undefined>>;
196
+ /**
197
+ * Checks if the given validation outputs pass the acceptance criteria.
198
+ *
199
+ * @callname: ParachainHost_check_validation_outputs
200
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
201
+ * @param {PolkadotPrimitivesV6CandidateCommitments} outputs
202
+ **/
203
+ checkValidationOutputs: GenericRuntimeApiMethod<(paraId: PolkadotParachainPrimitivesPrimitivesId, outputs: PolkadotPrimitivesV6CandidateCommitments) => Promise<boolean>>;
204
+ /**
205
+ * Returns the session index expected at a child of the block.
206
+ *
207
+ * This can be used to instantiate a `SigningContext`.
208
+ *
209
+ * @callname: ParachainHost_session_index_for_child
210
+ **/
211
+ sessionIndexForChild: GenericRuntimeApiMethod<() => Promise<number>>;
212
+ /**
213
+ * Fetch the validation code used by a para, making the given `OccupiedCoreAssumption`.
214
+ *
215
+ * Returns `None` if either the para is not registered or the assumption is `Freed`
216
+ * and the para already occupies a core.
217
+ *
218
+ * @callname: ParachainHost_validation_code
219
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
220
+ * @param {PolkadotPrimitivesV6OccupiedCoreAssumption} assumption
221
+ **/
222
+ validationCode: GenericRuntimeApiMethod<(paraId: PolkadotParachainPrimitivesPrimitivesId, assumption: PolkadotPrimitivesV6OccupiedCoreAssumption) => Promise<PolkadotParachainPrimitivesPrimitivesValidationCode | undefined>>;
223
+ /**
224
+ * Get the receipt of a candidate pending availability. This returns `Some` for any paras
225
+ * assigned to occupied cores in `availability_cores` and `None` otherwise.
226
+ *
227
+ * @callname: ParachainHost_candidate_pending_availability
228
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
229
+ **/
230
+ candidatePendingAvailability: GenericRuntimeApiMethod<(paraId: PolkadotParachainPrimitivesPrimitivesId) => Promise<PolkadotPrimitivesV6CommittedCandidateReceipt | undefined>>;
231
+ /**
232
+ * Get a vector of events concerning candidates that occurred within a block.
233
+ *
234
+ * @callname: ParachainHost_candidate_events
235
+ **/
236
+ candidateEvents: GenericRuntimeApiMethod<() => Promise<Array<PolkadotPrimitivesV6CandidateEvent>>>;
237
+ /**
238
+ * Get all the pending inbound messages in the downward message queue for a para.
239
+ *
240
+ * @callname: ParachainHost_dmq_contents
241
+ * @param {PolkadotParachainPrimitivesPrimitivesId} recipient
242
+ **/
243
+ dmqContents: GenericRuntimeApiMethod<(recipient: PolkadotParachainPrimitivesPrimitivesId) => Promise<Array<PolkadotCorePrimitivesInboundDownwardMessage>>>;
244
+ /**
245
+ * Get the contents of all channels addressed to the given recipient. Channels that have no
246
+ * messages in them are also included.
247
+ *
248
+ * @callname: ParachainHost_inbound_hrmp_channels_contents
249
+ * @param {PolkadotParachainPrimitivesPrimitivesId} recipient
250
+ **/
251
+ inboundHrmpChannelsContents: GenericRuntimeApiMethod<(recipient: PolkadotParachainPrimitivesPrimitivesId) => Promise<Array<[PolkadotParachainPrimitivesPrimitivesId, Array<PolkadotCorePrimitivesInboundHrmpMessage>]>>>;
252
+ /**
253
+ * Get the validation code from its hash.
254
+ *
255
+ * @callname: ParachainHost_validation_code_by_hash
256
+ * @param {PolkadotParachainPrimitivesPrimitivesValidationCodeHash} hash
257
+ **/
258
+ validationCodeByHash: GenericRuntimeApiMethod<(hash: PolkadotParachainPrimitivesPrimitivesValidationCodeHash) => Promise<PolkadotParachainPrimitivesPrimitivesValidationCode | undefined>>;
259
+ /**
260
+ * Scrape dispute relevant from on-chain, backing votes and resolved disputes.
261
+ *
262
+ * @callname: ParachainHost_on_chain_votes
263
+ **/
264
+ onChainVotes: GenericRuntimeApiMethod<() => Promise<PolkadotPrimitivesV6ScrapedOnChainVotes | undefined>>;
265
+ /**
266
+ * Get the session info for the given session, if stored.
267
+ *
268
+ * NOTE: This function is only available since parachain host version 2.
269
+ *
270
+ * @callname: ParachainHost_session_info
271
+ * @param {number} index
272
+ **/
273
+ sessionInfo: GenericRuntimeApiMethod<(index: number) => Promise<PolkadotPrimitivesV6SessionInfo | undefined>>;
274
+ /**
275
+ * Submits a PVF pre-checking statement into the transaction pool.
276
+ *
277
+ * NOTE: This function is only available since parachain host version 2.
278
+ *
279
+ * @callname: ParachainHost_submit_pvf_check_statement
280
+ * @param {PolkadotPrimitivesV6PvfCheckStatement} stmt
281
+ * @param {PolkadotPrimitivesV6ValidatorAppSignature} signature
282
+ **/
283
+ submitPvfCheckStatement: GenericRuntimeApiMethod<(stmt: PolkadotPrimitivesV6PvfCheckStatement, signature: PolkadotPrimitivesV6ValidatorAppSignature) => Promise<[]>>;
284
+ /**
285
+ * Returns code hashes of PVFs that require pre-checking by validators in the active set.
286
+ *
287
+ * NOTE: This function is only available since parachain host version 2.
288
+ *
289
+ * @callname: ParachainHost_pvfs_require_precheck
290
+ **/
291
+ pvfsRequirePrecheck: GenericRuntimeApiMethod<() => Promise<Array<PolkadotParachainPrimitivesPrimitivesValidationCodeHash>>>;
292
+ /**
293
+ * Fetch the hash of the validation code used by a para, making the given `OccupiedCoreAssumption`.
294
+ *
295
+ * NOTE: This function is only available since parachain host version 2.
296
+ *
297
+ * @callname: ParachainHost_validation_code_hash
298
+ * @param {PolkadotParachainPrimitivesPrimitivesId} para_id
299
+ * @param {PolkadotPrimitivesV6OccupiedCoreAssumption} assumption
300
+ **/
301
+ validationCodeHash: GenericRuntimeApiMethod<(paraId: PolkadotParachainPrimitivesPrimitivesId, assumption: PolkadotPrimitivesV6OccupiedCoreAssumption) => Promise<PolkadotParachainPrimitivesPrimitivesValidationCodeHash | undefined>>;
302
+ /**
303
+ * Returns all onchain disputes.
304
+ *
305
+ * @callname: ParachainHost_disputes
306
+ **/
307
+ disputes: GenericRuntimeApiMethod<() => Promise<Array<[number, PolkadotCorePrimitivesCandidateHash, PolkadotPrimitivesV6DisputeState]>>>;
308
+ /**
309
+ * Returns execution parameters for the session.
310
+ *
311
+ * @callname: ParachainHost_session_executor_params
312
+ * @param {number} session_index
313
+ **/
314
+ sessionExecutorParams: GenericRuntimeApiMethod<(sessionIndex: number) => Promise<PolkadotPrimitivesV6ExecutorParams | undefined>>;
315
+ /**
316
+ * Returns a list of validators that lost a past session dispute and need to be slashed.
317
+ * NOTE: This function is only available since parachain host version 5.
318
+ *
319
+ * @callname: ParachainHost_unapplied_slashes
320
+ **/
321
+ unappliedSlashes: GenericRuntimeApiMethod<() => Promise<Array<[number, PolkadotCorePrimitivesCandidateHash, PolkadotPrimitivesV6SlashingPendingSlashes]>>>;
322
+ /**
323
+ * Returns a merkle proof of a validator session key.
324
+ * NOTE: This function is only available since parachain host version 5.
325
+ *
326
+ * @callname: ParachainHost_key_ownership_proof
327
+ * @param {PolkadotPrimitivesV6ValidatorAppPublic} validator_id
328
+ **/
329
+ keyOwnershipProof: GenericRuntimeApiMethod<(validatorId: PolkadotPrimitivesV6ValidatorAppPublic) => Promise<PolkadotPrimitivesV6SlashingOpaqueKeyOwnershipProof | undefined>>;
330
+ /**
331
+ * Submit an unsigned extrinsic to slash validators who lost a dispute about
332
+ * a candidate of a past session.
333
+ * NOTE: This function is only available since parachain host version 5.
334
+ *
335
+ * @callname: ParachainHost_submit_report_dispute_lost
336
+ * @param {PolkadotPrimitivesV6SlashingDisputeProof} dispute_proof
337
+ * @param {PolkadotPrimitivesV6SlashingOpaqueKeyOwnershipProof} key_ownership_proof
338
+ **/
339
+ submitReportDisputeLost: GenericRuntimeApiMethod<(disputeProof: PolkadotPrimitivesV6SlashingDisputeProof, keyOwnershipProof: PolkadotPrimitivesV6SlashingOpaqueKeyOwnershipProof) => Promise<[] | undefined>>;
340
+ /**
341
+ * Get the minimum number of backing votes for a parachain candidate.
342
+ * This is a staging method! Do not use on production runtimes!
343
+ *
344
+ * @callname: ParachainHost_minimum_backing_votes
345
+ **/
346
+ minimumBackingVotes: GenericRuntimeApiMethod<() => Promise<number>>;
347
+ /**
348
+ * Returns the state of parachain backing for a given para.
349
+ *
350
+ * @callname: ParachainHost_para_backing_state
351
+ * @param {PolkadotParachainPrimitivesPrimitivesId} _
352
+ **/
353
+ paraBackingState: GenericRuntimeApiMethod<(undefined: PolkadotParachainPrimitivesPrimitivesId) => Promise<PolkadotPrimitivesV6AsyncBackingBackingState | undefined>>;
354
+ /**
355
+ * Returns candidate's acceptance limitations for asynchronous backing for a relay parent.
356
+ *
357
+ * @callname: ParachainHost_async_backing_params
358
+ **/
359
+ asyncBackingParams: GenericRuntimeApiMethod<() => Promise<PolkadotPrimitivesV6AsyncBackingAsyncBackingParams>>;
360
+ /**
361
+ * Returns a list of all disabled validators at the given block.
362
+ *
363
+ * @callname: ParachainHost_disabled_validators
364
+ **/
365
+ disabledValidators: GenericRuntimeApiMethod<() => Promise<Array<PolkadotPrimitivesV6ValidatorIndex>>>;
366
+ /**
367
+ * Generic runtime api call
368
+ **/
369
+ [method: string]: GenericRuntimeApiMethod;
370
+ };
371
+ /**
372
+ * @runtimeapi: BeefyApi - 0x49eaaf1b548a0cb0
373
+ **/
374
+ beefyApi: {
375
+ /**
376
+ * Return the block number where BEEFY consensus is enabled/started
377
+ *
378
+ * @callname: BeefyApi_beefy_genesis
379
+ **/
380
+ beefyGenesis: GenericRuntimeApiMethod<() => Promise<number | undefined>>;
381
+ /**
382
+ * Return the current active BEEFY validator set
383
+ *
384
+ * @callname: BeefyApi_validator_set
385
+ **/
386
+ validatorSet: GenericRuntimeApiMethod<() => Promise<SpConsensusBeefyValidatorSet | undefined>>;
387
+ /**
388
+ * Submits an unsigned extrinsic to report an equivocation. The caller
389
+ * must provide the equivocation proof and a key ownership proof
390
+ * (should be obtained using `generate_key_ownership_proof`). The
391
+ * extrinsic will be unsigned and should only be accepted for local
392
+ * authorship (not to be broadcast to the network). This method returns
393
+ * `None` when creation of the extrinsic fails, e.g. if equivocation
394
+ * reporting is disabled for the given runtime (i.e. this method is
395
+ * hardcoded to return `None`). Only useful in an offchain context.
396
+ *
397
+ * @callname: BeefyApi_submit_report_equivocation_unsigned_extrinsic
398
+ * @param {SpConsensusBeefyEquivocationProof} equivocation_proof
399
+ * @param {SpConsensusBeefyOpaqueKeyOwnershipProof} key_owner_proof
400
+ **/
401
+ submitReportEquivocationUnsignedExtrinsic: GenericRuntimeApiMethod<(equivocationProof: SpConsensusBeefyEquivocationProof, keyOwnerProof: SpConsensusBeefyOpaqueKeyOwnershipProof) => Promise<[] | undefined>>;
402
+ /**
403
+ * Generates a proof of key ownership for the given authority in the
404
+ * given set. An example usage of this module is coupled with the
405
+ * session historical module to prove that a given authority key is
406
+ * tied to a given staking identity during a specific session. Proofs
407
+ * of key ownership are necessary for submitting equivocation reports.
408
+ * NOTE: even though the API takes a `set_id` as parameter the current
409
+ * implementations ignores this parameter and instead relies on this
410
+ * method being called at the correct block height, i.e. any point at
411
+ * which the given set id is live on-chain. Future implementations will
412
+ * instead use indexed data through an offchain worker, not requiring
413
+ * older states to be available.
414
+ *
415
+ * @callname: BeefyApi_generate_key_ownership_proof
416
+ * @param {bigint} set_id
417
+ * @param {SpConsensusBeefyEcdsaCryptoPublic} authority_id
418
+ **/
419
+ generateKeyOwnershipProof: GenericRuntimeApiMethod<(setId: bigint, authorityId: SpConsensusBeefyEcdsaCryptoPublic) => Promise<SpConsensusBeefyOpaqueKeyOwnershipProof | undefined>>;
420
+ /**
421
+ * Generic runtime api call
422
+ **/
423
+ [method: string]: GenericRuntimeApiMethod;
424
+ };
425
+ /**
426
+ * @runtimeapi: MmrApi - 0x91d5df18b0d2cf58
427
+ **/
428
+ mmrApi: {
429
+ /**
430
+ * Return the on-chain MMR root hash.
431
+ *
432
+ * @callname: MmrApi_mmr_root
433
+ **/
434
+ mmrRoot: GenericRuntimeApiMethod<() => Promise<Result<H256, SpMmrPrimitivesError>>>;
435
+ /**
436
+ * Return the number of MMR blocks in the chain.
437
+ *
438
+ * @callname: MmrApi_mmr_leaf_count
439
+ **/
440
+ mmrLeafCount: GenericRuntimeApiMethod<() => Promise<Result<bigint, SpMmrPrimitivesError>>>;
441
+ /**
442
+ * Generate MMR proof for a series of block numbers. If `best_known_block_number = Some(n)`,
443
+ * use historical MMR state at given block height `n`. Else, use current MMR state.
444
+ *
445
+ * @callname: MmrApi_generate_proof
446
+ * @param {Array<number>} block_numbers
447
+ * @param {number | undefined} best_known_block_number
448
+ **/
449
+ generateProof: GenericRuntimeApiMethod<(blockNumbers: Array<number>, bestKnownBlockNumber?: number | undefined) => Promise<Result<[Array<SpMmrPrimitivesEncodableOpaqueLeaf>, SpMmrPrimitivesProof], SpMmrPrimitivesError>>>;
450
+ /**
451
+ * Verify MMR proof against on-chain MMR for a batch of leaves.
452
+ *
453
+ * Note this function will use on-chain MMR root hash and check if the proof matches the hash.
454
+ * Note, the leaves should be sorted such that corresponding leaves and leaf indices have the
455
+ * same position in both the `leaves` vector and the `leaf_indices` vector contained in the [Proof]
456
+ *
457
+ * @callname: MmrApi_verify_proof
458
+ * @param {Array<SpMmrPrimitivesEncodableOpaqueLeaf>} leaves
459
+ * @param {SpMmrPrimitivesProof} proof
460
+ **/
461
+ verifyProof: GenericRuntimeApiMethod<(leaves: Array<SpMmrPrimitivesEncodableOpaqueLeaf>, proof: SpMmrPrimitivesProof) => Promise<Result<[], SpMmrPrimitivesError>>>;
462
+ /**
463
+ * Verify MMR proof against given root hash for a batch of leaves.
464
+ *
465
+ * Note this function does not require any on-chain storage - the
466
+ * proof is verified against given MMR root hash.
467
+ *
468
+ * Note, the leaves should be sorted such that corresponding leaves and leaf indices have the
469
+ * same position in both the `leaves` vector and the `leaf_indices` vector contained in the [Proof]
470
+ *
471
+ * @callname: MmrApi_verify_proof_stateless
472
+ * @param {H256} root
473
+ * @param {Array<SpMmrPrimitivesEncodableOpaqueLeaf>} leaves
474
+ * @param {SpMmrPrimitivesProof} proof
475
+ **/
476
+ verifyProofStateless: GenericRuntimeApiMethod<(root: H256, leaves: Array<SpMmrPrimitivesEncodableOpaqueLeaf>, proof: SpMmrPrimitivesProof) => Promise<Result<[], SpMmrPrimitivesError>>>;
477
+ /**
478
+ * Generic runtime api call
479
+ **/
480
+ [method: string]: GenericRuntimeApiMethod;
481
+ };
482
+ /**
483
+ * @runtimeapi: BeefyMmrApi - 0x2a5e924655399e60
484
+ **/
485
+ beefyMmrApi: {
486
+ /**
487
+ * Return the currently active BEEFY authority set proof.
488
+ *
489
+ * @callname: BeefyMmrApi_authority_set_proof
490
+ **/
491
+ authoritySetProof: GenericRuntimeApiMethod<() => Promise<SpConsensusBeefyMmrBeefyAuthoritySet>>;
492
+ /**
493
+ * Return the next/queued BEEFY authority set proof.
494
+ *
495
+ * @callname: BeefyMmrApi_next_authority_set_proof
496
+ **/
497
+ nextAuthoritySetProof: GenericRuntimeApiMethod<() => Promise<SpConsensusBeefyMmrBeefyAuthoritySet>>;
498
+ /**
499
+ * Generic runtime api call
500
+ **/
501
+ [method: string]: GenericRuntimeApiMethod;
502
+ };
503
+ /**
504
+ * @runtimeapi: GrandpaApi - 0xed99c5acb25eedf5
505
+ **/
506
+ grandpaApi: {
507
+ /**
508
+ * Get the current GRANDPA authorities and weights. This should not change except
509
+ * for when changes are scheduled and the corresponding delay has passed.
510
+ *
511
+ * When called at block B, it will return the set of authorities that should be
512
+ * used to finalize descendants of this block (B+1, B+2, ...). The block B itself
513
+ * is finalized by the authorities from block B-1.
514
+ *
515
+ * @callname: GrandpaApi_grandpa_authorities
516
+ **/
517
+ grandpaAuthorities: GenericRuntimeApiMethod<() => Promise<Array<[SpConsensusGrandpaAppPublic, bigint]>>>;
518
+ /**
519
+ * Submits an unsigned extrinsic to report an equivocation. The caller
520
+ * must provide the equivocation proof and a key ownership proof
521
+ * (should be obtained using `generate_key_ownership_proof`). The
522
+ * extrinsic will be unsigned and should only be accepted for local
523
+ * authorship (not to be broadcast to the network). This method returns
524
+ * `None` when creation of the extrinsic fails, e.g. if equivocation
525
+ * reporting is disabled for the given runtime (i.e. this method is
526
+ * hardcoded to return `None`). Only useful in an offchain context.
527
+ *
528
+ * @callname: GrandpaApi_submit_report_equivocation_unsigned_extrinsic
529
+ * @param {SpConsensusGrandpaEquivocationProof} equivocation_proof
530
+ * @param {SpConsensusGrandpaOpaqueKeyOwnershipProof} key_owner_proof
531
+ **/
532
+ submitReportEquivocationUnsignedExtrinsic: GenericRuntimeApiMethod<(equivocationProof: SpConsensusGrandpaEquivocationProof, keyOwnerProof: SpConsensusGrandpaOpaqueKeyOwnershipProof) => Promise<[] | undefined>>;
533
+ /**
534
+ * Generates a proof of key ownership for the given authority in the
535
+ * given set. An example usage of this module is coupled with the
536
+ * session historical module to prove that a given authority key is
537
+ * tied to a given staking identity during a specific session. Proofs
538
+ * of key ownership are necessary for submitting equivocation reports.
539
+ * NOTE: even though the API takes a `set_id` as parameter the current
540
+ * implementations ignore this parameter and instead rely on this
541
+ * method being called at the correct block height, i.e. any point at
542
+ * which the given set id is live on-chain. Future implementations will
543
+ * instead use indexed data through an offchain worker, not requiring
544
+ * older states to be available.
545
+ *
546
+ * @callname: GrandpaApi_generate_key_ownership_proof
547
+ * @param {bigint} set_id
548
+ * @param {SpConsensusGrandpaAppPublic} authority_id
549
+ **/
550
+ generateKeyOwnershipProof: GenericRuntimeApiMethod<(setId: bigint, authorityId: SpConsensusGrandpaAppPublic) => Promise<SpConsensusGrandpaOpaqueKeyOwnershipProof | undefined>>;
551
+ /**
552
+ * Get current GRANDPA authority set id.
553
+ *
554
+ * @callname: GrandpaApi_current_set_id
555
+ **/
556
+ currentSetId: GenericRuntimeApiMethod<() => Promise<bigint>>;
557
+ /**
558
+ * Generic runtime api call
559
+ **/
560
+ [method: string]: GenericRuntimeApiMethod;
561
+ };
562
+ /**
563
+ * @runtimeapi: BabeApi - 0xcbca25e39f142387
564
+ **/
565
+ babeApi: {
566
+ /**
567
+ * Return the configuration for BABE.
568
+ *
569
+ * @callname: BabeApi_configuration
570
+ **/
571
+ configuration: GenericRuntimeApiMethod<() => Promise<SpConsensusBabeBabeConfiguration>>;
572
+ /**
573
+ * Returns the slot that started the current epoch.
574
+ *
575
+ * @callname: BabeApi_current_epoch_start
576
+ **/
577
+ currentEpochStart: GenericRuntimeApiMethod<() => Promise<SpConsensusSlotsSlot>>;
578
+ /**
579
+ * Returns information regarding the current epoch.
580
+ *
581
+ * @callname: BabeApi_current_epoch
582
+ **/
583
+ currentEpoch: GenericRuntimeApiMethod<() => Promise<SpConsensusBabeEpoch>>;
584
+ /**
585
+ * Returns information regarding the next epoch (which was already
586
+ * previously announced).
587
+ *
588
+ * @callname: BabeApi_next_epoch
589
+ **/
590
+ nextEpoch: GenericRuntimeApiMethod<() => Promise<SpConsensusBabeEpoch>>;
591
+ /**
592
+ * Generates a proof of key ownership for the given authority in the
593
+ * current epoch. An example usage of this module is coupled with the
594
+ * session historical module to prove that a given authority key is
595
+ * tied to a given staking identity during a specific session. Proofs
596
+ * of key ownership are necessary for submitting equivocation reports.
597
+ * NOTE: even though the API takes a `slot` as parameter the current
598
+ * implementations ignores this parameter and instead relies on this
599
+ * method being called at the correct block height, i.e. any point at
600
+ * which the epoch for the given slot is live on-chain. Future
601
+ * implementations will instead use indexed data through an offchain
602
+ * worker, not requiring older states to be available.
603
+ *
604
+ * @callname: BabeApi_generate_key_ownership_proof
605
+ * @param {SpConsensusSlotsSlot} slot
606
+ * @param {SpConsensusBabeAppPublic} authority_id
607
+ **/
608
+ generateKeyOwnershipProof: GenericRuntimeApiMethod<(slot: SpConsensusSlotsSlot, authorityId: SpConsensusBabeAppPublic) => Promise<SpConsensusBabeOpaqueKeyOwnershipProof | undefined>>;
609
+ /**
610
+ * Submits an unsigned extrinsic to report an equivocation. The caller
611
+ * must provide the equivocation proof and a key ownership proof
612
+ * (should be obtained using `generate_key_ownership_proof`). The
613
+ * extrinsic will be unsigned and should only be accepted for local
614
+ * authorship (not to be broadcast to the network). This method returns
615
+ * `None` when creation of the extrinsic fails, e.g. if equivocation
616
+ * reporting is disabled for the given runtime (i.e. this method is
617
+ * hardcoded to return `None`). Only useful in an offchain context.
618
+ *
619
+ * @callname: BabeApi_submit_report_equivocation_unsigned_extrinsic
620
+ * @param {SpConsensusSlotsEquivocationProof} equivocation_proof
621
+ * @param {SpConsensusBabeOpaqueKeyOwnershipProof} key_owner_proof
622
+ **/
623
+ submitReportEquivocationUnsignedExtrinsic: GenericRuntimeApiMethod<(equivocationProof: SpConsensusSlotsEquivocationProof, keyOwnerProof: SpConsensusBabeOpaqueKeyOwnershipProof) => Promise<[] | undefined>>;
624
+ /**
625
+ * Generic runtime api call
626
+ **/
627
+ [method: string]: GenericRuntimeApiMethod;
628
+ };
629
+ /**
630
+ * @runtimeapi: AuthorityDiscoveryApi - 0x687ad44ad37f03c2
631
+ **/
632
+ authorityDiscoveryApi: {
633
+ /**
634
+ * Retrieve authority identifiers of the current and next authority set.
635
+ *
636
+ * @callname: AuthorityDiscoveryApi_authorities
637
+ **/
638
+ authorities: GenericRuntimeApiMethod<() => Promise<Array<SpAuthorityDiscoveryAppPublic>>>;
639
+ /**
640
+ * Generic runtime api call
641
+ **/
642
+ [method: string]: GenericRuntimeApiMethod;
643
+ };
644
+ /**
645
+ * @runtimeapi: SessionKeys - 0xab3c0572291feb8b
646
+ **/
647
+ sessionKeys: {
648
+ /**
649
+ * Generate a set of session keys with optionally using the given seed.
650
+ * The keys should be stored within the keystore exposed via runtime
651
+ * externalities.
652
+ *
653
+ * The seed needs to be a valid `utf8` string.
654
+ *
655
+ * Returns the concatenated SCALE encoded public keys.
656
+ *
657
+ * @callname: SessionKeys_generate_session_keys
658
+ * @param {BytesLike | undefined} seed
659
+ **/
660
+ generateSessionKeys: GenericRuntimeApiMethod<(seed?: BytesLike | undefined) => Promise<Bytes>>;
661
+ /**
662
+ * Decode the given public session keys.
663
+ *
664
+ * Returns the list of public raw public keys + key type.
665
+ *
666
+ * @callname: SessionKeys_decode_session_keys
667
+ * @param {BytesLike} encoded
668
+ **/
669
+ decodeSessionKeys: GenericRuntimeApiMethod<(encoded: BytesLike) => Promise<Array<[Bytes, SpCoreCryptoKeyTypeId]> | undefined>>;
670
+ /**
671
+ * Generic runtime api call
672
+ **/
673
+ [method: string]: GenericRuntimeApiMethod;
674
+ };
675
+ /**
676
+ * @runtimeapi: AccountNonceApi - 0xbc9d89904f5b923f
677
+ **/
678
+ accountNonceApi: {
679
+ /**
680
+ * Get current account nonce of given `AccountId`.
681
+ *
682
+ * @callname: AccountNonceApi_account_nonce
683
+ * @param {AccountId32Like} account
684
+ **/
685
+ accountNonce: GenericRuntimeApiMethod<(account: AccountId32Like) => Promise<number>>;
686
+ /**
687
+ * Generic runtime api call
688
+ **/
689
+ [method: string]: GenericRuntimeApiMethod;
690
+ };
691
+ /**
692
+ * @runtimeapi: TransactionPaymentApi - 0x37c8bb1350a9a2a8
693
+ **/
694
+ transactionPaymentApi: {
695
+ /**
696
+ *
697
+ * @callname: TransactionPaymentApi_query_info
698
+ * @param {UncheckedExtrinsicLike} uxt
699
+ * @param {number} len
700
+ **/
701
+ queryInfo: GenericRuntimeApiMethod<(uxt: UncheckedExtrinsicLike, len: number) => Promise<PalletTransactionPaymentRuntimeDispatchInfo>>;
702
+ /**
703
+ *
704
+ * @callname: TransactionPaymentApi_query_fee_details
705
+ * @param {UncheckedExtrinsicLike} uxt
706
+ * @param {number} len
707
+ **/
708
+ queryFeeDetails: GenericRuntimeApiMethod<(uxt: UncheckedExtrinsicLike, len: number) => Promise<PalletTransactionPaymentFeeDetails>>;
709
+ /**
710
+ *
711
+ * @callname: TransactionPaymentApi_query_weight_to_fee
712
+ * @param {SpWeightsWeightV2Weight} weight
713
+ **/
714
+ queryWeightToFee: GenericRuntimeApiMethod<(weight: SpWeightsWeightV2Weight) => Promise<bigint>>;
715
+ /**
716
+ *
717
+ * @callname: TransactionPaymentApi_query_length_to_fee
718
+ * @param {number} length
719
+ **/
720
+ queryLengthToFee: GenericRuntimeApiMethod<(length: number) => Promise<bigint>>;
721
+ /**
722
+ * Generic runtime api call
723
+ **/
724
+ [method: string]: GenericRuntimeApiMethod;
725
+ };
726
+ /**
727
+ * @runtimeapi: TransactionPaymentCallApi - 0xf3ff14d5ab527059
728
+ **/
729
+ transactionPaymentCallApi: {
730
+ /**
731
+ * Query information of a dispatch class, weight, and fee of a given encoded `Call`.
732
+ *
733
+ * @callname: TransactionPaymentCallApi_query_call_info
734
+ * @param {StagingKusamaRuntimeRuntimeCallLike} call
735
+ * @param {number} len
736
+ **/
737
+ queryCallInfo: GenericRuntimeApiMethod<(call: StagingKusamaRuntimeRuntimeCallLike, len: number) => Promise<PalletTransactionPaymentRuntimeDispatchInfo>>;
738
+ /**
739
+ * Query fee details of a given encoded `Call`.
740
+ *
741
+ * @callname: TransactionPaymentCallApi_query_call_fee_details
742
+ * @param {StagingKusamaRuntimeRuntimeCallLike} call
743
+ * @param {number} len
744
+ **/
745
+ queryCallFeeDetails: GenericRuntimeApiMethod<(call: StagingKusamaRuntimeRuntimeCallLike, len: number) => Promise<PalletTransactionPaymentFeeDetails>>;
746
+ /**
747
+ * Query the output of the current `WeightToFee` given some input.
748
+ *
749
+ * @callname: TransactionPaymentCallApi_query_weight_to_fee
750
+ * @param {SpWeightsWeightV2Weight} weight
751
+ **/
752
+ queryWeightToFee: GenericRuntimeApiMethod<(weight: SpWeightsWeightV2Weight) => Promise<bigint>>;
753
+ /**
754
+ * Query the output of the current `LengthToFee` given some input.
755
+ *
756
+ * @callname: TransactionPaymentCallApi_query_length_to_fee
757
+ * @param {number} length
758
+ **/
759
+ queryLengthToFee: GenericRuntimeApiMethod<(length: number) => Promise<bigint>>;
760
+ /**
761
+ * Generic runtime api call
762
+ **/
763
+ [method: string]: GenericRuntimeApiMethod;
764
+ };
765
+ /**
766
+ * @runtimeapi: NominationPoolsApi - 0x17a6bc0d0062aeb3
767
+ **/
768
+ nominationPoolsApi: {
769
+ /**
770
+ * Returns the pending rewards for the member that the AccountId was given for.
771
+ *
772
+ * @callname: NominationPoolsApi_pending_rewards
773
+ * @param {AccountId32Like} who
774
+ **/
775
+ pendingRewards: GenericRuntimeApiMethod<(who: AccountId32Like) => Promise<bigint>>;
776
+ /**
777
+ * Returns the equivalent balance of `points` for a given pool.
778
+ *
779
+ * @callname: NominationPoolsApi_points_to_balance
780
+ * @param {number} pool_id
781
+ * @param {bigint} points
782
+ **/
783
+ pointsToBalance: GenericRuntimeApiMethod<(poolId: number, points: bigint) => Promise<bigint>>;
784
+ /**
785
+ * Returns the equivalent points of `new_funds` for a given pool.
786
+ *
787
+ * @callname: NominationPoolsApi_balance_to_points
788
+ * @param {number} pool_id
789
+ * @param {bigint} new_funds
790
+ **/
791
+ balanceToPoints: GenericRuntimeApiMethod<(poolId: number, newFunds: bigint) => Promise<bigint>>;
792
+ /**
793
+ * Generic runtime api call
794
+ **/
795
+ [method: string]: GenericRuntimeApiMethod;
796
+ };
797
+ /**
798
+ * @runtimeapi: StakingApi - 0x18ef58a3b67ba770
799
+ **/
800
+ stakingApi: {
801
+ /**
802
+ * Returns the nominations quota for a nominator with a given balance.
803
+ *
804
+ * @callname: StakingApi_nominations_quota
805
+ * @param {bigint} balance
806
+ **/
807
+ nominationsQuota: GenericRuntimeApiMethod<(balance: bigint) => Promise<number>>;
808
+ /**
809
+ * Generic runtime api call
810
+ **/
811
+ [method: string]: GenericRuntimeApiMethod;
812
+ };
813
+ /**
814
+ * @runtimeapi: GenesisBuilder - 0xfbc577b9d747efd6
815
+ **/
816
+ genesisBuilder: {
817
+ /**
818
+ * Creates the default `GenesisConfig` and returns it as a JSON blob.
819
+ *
820
+ * This function instantiates the default `GenesisConfig` struct for the runtime and serializes it into a JSON
821
+ * blob. It returns a `Vec<u8>` containing the JSON representation of the default `GenesisConfig`.
822
+ *
823
+ * @callname: GenesisBuilder_create_default_config
824
+ **/
825
+ createDefaultConfig: GenericRuntimeApiMethod<() => Promise<Bytes>>;
826
+ /**
827
+ * Build `GenesisConfig` from a JSON blob not using any defaults and store it in the storage.
828
+ *
829
+ * This function deserializes the full `GenesisConfig` from the given JSON blob and puts it into the storage.
830
+ * If the provided JSON blob is incorrect or incomplete or the deserialization fails, an error is returned.
831
+ * It is recommended to log any errors encountered during the process.
832
+ *
833
+ * Please note that provided json blob must contain all `GenesisConfig` fields, no defaults will be used.
834
+ *
835
+ * @callname: GenesisBuilder_build_config
836
+ * @param {BytesLike} json
837
+ **/
838
+ buildConfig: GenericRuntimeApiMethod<(json: BytesLike) => Promise<Result<[], string>>>;
839
+ /**
840
+ * Generic runtime api call
841
+ **/
842
+ [method: string]: GenericRuntimeApiMethod;
843
+ };
1134
844
  }