ExMCP.HttpPlug.Core (ex_mcp v0.12.0)
View SourcePure request/response decisions for ExMCP.HttpPlug.
The Plug module owns side effects such as reading request bodies, writing responses, ETS/session management, and SSE processes. This module keeps the reusable protocol and origin decisions as data transformations.
Summary
Types
@type origin_context() :: %{ optional(:origin) => String.t() | nil, optional(:scheme) => String.t(), optional(:host) => String.t(), optional(:port) => non_neg_integer() | nil }
Functions
@spec cors_response_origin(origin_context(), map()) :: String.t() | nil
@spec oauth_guard_disabled_error() :: map()
@spec origin_allowed?(origin_context(), map()) :: boolean()