Noizu.MCP.Protocol.Methods (Noizu MCP v0.1.1)

Copy Markdown View Source

Compile-time registry of MCP methods: kind (request/notification) and direction (client→server, server→client, or both).

Summary

Functions

True when method may be received by a peer in role.

Types

direction()

@type direction() :: :client_to_server | :server_to_client | :both

kind()

@type kind() :: :request | :notification

Functions

lookup(method)

@spec lookup(String.t()) :: {:ok, {kind(), direction()}} | :error

receivable?(method, role)

@spec receivable?(String.t(), :server | :client) :: boolean()

True when method may be received by a peer in role.