ExMCP.FeatureFlags (ex_mcp v0.10.0)
View SourceFeature flag system for controlling rollout of new MCP features.
This module provides a centralized way to check if specific features are enabled, allowing for gradual rollout and easy rollback.
Summary
Functions
@spec all() :: map()
Get all feature flags and their current status.
Examples
iex> ExMCP.FeatureFlags.all()
%{
protocol_version_header: false,
structured_output: false,
oauth2_auth: false
}
Check if a specific feature is enabled.
Features
:protocol_version_header- Enforce MCP-Protocol-Version header validation:structured_output- Enable structured tool output with schema validation:oauth2_auth- Enable OAuth 2.1 authorization
Examples
iex> ExMCP.FeatureFlags.enabled?(:protocol_version_header)
false
iex> Application.put_env(:ex_mcp, :protocol_version_required, true)
iex> ExMCP.FeatureFlags.enabled?(:protocol_version_header)
true