Skip to main content

dispatch_host_call_shared

Function dispatch_host_call_shared 

Source
pub async fn dispatch_host_call_shared(
    ctx: &HostCallContext<'_>,
    call: HostCallPayload,
) -> HostResultPayload
Expand description

Dispatch a hostcall through the unified ABI surface.

This is the single source of truth for hostcall execution, usable by JS extensions, WASM components, and protocol-based runtimes alike.

  1. Resolves the required capability from the payload.
  2. Evaluates policy (allow / deny / prompt).
  3. Routes to the appropriate type-specific handler.
  4. Returns a taxonomy-compliant HostResultPayload.