Skip to content

angee.mcp.resource_tools

Generate bounded read tools from the GraphQL data-resource registry.

The resource registry owns which models, roots, and fields a schema exposes. This module translates that declaration once, when the process-wide MCP server is built, then delegates document compilation and actor-scoped execution to :class:~angee.mcp.graphql.GraphQLTool.

RESOURCE_SCHEMA

Schema bucket used by the session UI for messaging, knowledge, and notes.

RESOURCE_READER_TOOL_TAG

Registration marker consumed by the built-in grant-catalogue sync.

ResourceToolCatalogueEntry

python
@dataclass(frozen=True, slots=True)
class ResourceToolCatalogueEntry()

One generated resource and the two tools that expose it.

register_resource_tools

python
def register_resource_tools(server: FastMCP) -> None

Register the honest resource catalogue and deterministic generated readers.

resource_tool_specs

python
def resource_tool_specs(
    schemas: GraphQLSchemas | None = None
) -> tuple[tuple[GraphQLTool, ...], tuple[ResourceToolCatalogueEntry, ...]]

Return generated GraphQL declarations and catalogue entries in stable order.

check_resource_tool_specs

python
def check_resource_tool_specs(app_configs: Any = None,
                              **kwargs: Any) -> list[checks.CheckMessage]

Fail Django's system check when console resources cannot compile to tools.

Released under the AGPL-3.0 License.