pub fn generate_runtime_api<P>(
    item_mod: ItemMod,
    path: P,
    derives: DerivesRegistry
) -> TokenStream2where
    P: AsRef<Path>,
Expand description

Generates the API for interacting with a Substrate runtime.

Arguments

  • item_mod - The module declaration for which the API is implemented.
  • path - The path to the scale encoded metadata of the runtime node.
  • derives - Provide custom derives for the generated types.

Note: This is a wrapper over RuntimeGenerator for static metadata use-cases.