@dedot/chaintypes 0.0.1-alpha.4 → 0.0.1-alpha.40

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