duck.contrib.mcp.auth¶
Authentication module for MCP.
Module Contents¶
Classes¶
Return value expected from |
API¶
- class duck.contrib.mcp.auth.AuthResult(allowed: bool = True, scopes=None)[source]¶
Return value expected from
MCPView.authenticate().allowedcontrols whether the connection is accepted at all;scopescontrols what scope- gated tools/resources/prompts the caller can use -Nonemeans unrestricted (the default, i.e. no scope checking), an empty set/list means no scopes granted, anything else is checked as a subset byauthorize().Initialization