Skip to content

Metadata Reactor Demo

This example demonstrates how to use the MetadataReactor to fetch and display canister metadata, such as Candid files, canister status, and standard-specific metadata (e.g., ICRC-1 metadata).

  • Metadata Fetching: Access canister metadata defined in the WASM.
  • Canister Status: Check if a canister is running and see its memory usage.
  • Candid Export: Dynamically retrieve the Candid interface from a live canister.
  • Standard Detection: Automatically detect supported standards like ICRC-1 or DIP-20.
// Fetching Candid metadata
const { data: candid } = useActorQuery({
functionName: "get_candid",
})
// Fetching ICRC-1 metadata
const { data: metadata } = useActorQuery({
functionName: "icrc1_metadata",
})