angee.agents.schema
GraphQL schema contributions for the agents addon.
Admin console surface for the agent catalogue: agents (and their templates), the skills they mount, the MCP servers/tools they reach, and the inference provider/model catalogue they run on. Platform-admin gated like the integrate console, so the REBAC-guarded relations these types expose (integration, credential, source, template) are safe — the const-admin reaches every related row. Skill sources are managed in the integrate VCS console (a kind="skill" source); this addon owns only the discovered :class:Skill rows.
InferenceProviderType
@strawberry_django.type(InferenceProvider)
class InferenceProviderType(AngeeNode)Admin projection of an inference provider child model.
IntegrationInferenceProviderExtension
@strawberry_django.type(Integration, name="IntegrationType", extend=True)
class IntegrationInferenceProviderExtension()Contributes the inference provider child onto integrate's IntegrationType.
inference_provider
@strawberry_django.field(only=["id"])
def inference_provider() -> InferenceProviderType | NoneReturn this integration's inference provider child when present.
InferenceModelType
@strawberry_django.type(InferenceModel)
class InferenceModelType(AngeeNode)Admin projection of one model in a provider's catalogue.
SkillType
@strawberry_django.type(Skill)
class SkillType(AngeeNode)Admin projection of one discovered skill.
MCPServerType
@strawberry_django.type(MCPServer)
class MCPServerType(AngeeNode)Admin projection of one MCP server.
MCPToolType
@strawberry_django.type(MCPTool)
class MCPToolType(AngeeNode)Admin projection of one MCP tool.
AgentType
@strawberry_django.type(Agent)
class AgentType(AngeeNode)Admin projection of an agent (or, when is_template, an agent template).
AgentChatEndpoint
@strawberry.type
class AgentChatEndpoint()Browser-reachable chat endpoint for a running agent.
url is the agent's routed WebSocket URL (no token); the browser appends token as a query parameter, which the central Caddy forward-auths against the operator. mcp_servers is the agent's rendered .mcp.json server map, so the chat session can advertise the same MCP servers the agent runs with. model_handle is the selected agent model in the service runtime's convention, used to select the ACP session model explicitly after session creation.
AgentSession
@strawberry.type
class AgentSession()The agent that serves the user's current view, for the side chatter.
The view-driven counterpart to :class:AgentChatEndpoint: the chatter knows the view, not the agent, so this resolves which agent (identity only — name, status, model). The client then mints the chat endpoint for agent_id with agentChatEndpoint. A None result means the user has no running agent.
InferenceProviderInput
@strawberry.input
class InferenceProviderInput()Fields accepted when creating an inference provider.
InferenceProviderPatch
@strawberry.input
class InferenceProviderPatch()Fields accepted when updating an inference provider.
InferenceProviderCreateMutation
@strawberry.type
class InferenceProviderCreateMutation()Admin create for an inference provider child row.
create_inference_provider
@strawberry.mutation(permission_classes=_ADMIN_PERMISSION_CLASSES)
def create_inference_provider(
data: InferenceProviderInput) -> InferenceProviderTypeCreate an inference provider directly.
InferenceProviderConnectMutation
@strawberry.type
class InferenceProviderConnectMutation()Authenticated OAuth connect for an inference provider child row.
connect_inference_provider
@strawberry.mutation
def connect_inference_provider(
info: strawberry.Info,
id: PublicID,
redirect_uri: str = "",
next: str = "/agents/providers") -> ConnectIntegrationResultAttach the current user's OAuth credential to this inference provider.
InferenceProviderUpdateMutation
@strawberry.type
class InferenceProviderUpdateMutation()Admin update for an inference provider child row.
update_inference_provider
@strawberry.mutation(permission_classes=_ADMIN_PERMISSION_CLASSES)
def update_inference_provider(
data: InferenceProviderPatch) -> InferenceProviderTypeUpdate a provider, rematerializing backend defaults when the backend changes.
AgentSessionQuery
@strawberry.type
class AgentSessionQuery()Authenticated agent session queries for chat surfaces.
resolve_session_for_view
@strawberry.field
def resolve_session_for_view(view: JSON) -> AgentSession | NoneResolve the agent that serves the user's current view, for the side chatter.
The chatter knows the view, not the agent: this picks the actor's running agent (view["type"] is the routing seam for a later view-specialised agent) so the client can mint its chat endpoint (agentChatEndpoint). Returns None when the user has no running agent, so the chatter shows a call-to-action instead of erroring.
InferenceActionMutation
@strawberry.type
class InferenceActionMutation()Operational actions on an inference provider.
refresh_provider_models
@strawberry.mutation(permission_classes=_ADMIN_PERMISSION_CLASSES)
def refresh_provider_models(id: PublicID) -> ActionResultRe-list one provider's models into the catalogue now.
AgentActionMutation
@strawberry.type
class AgentActionMutation()GraphQL action bridge for agent runtime operations.
provision_agent
@strawberry.mutation(permission_classes=_ADMIN_PERMISSION_CLASSES)
def provision_agent(id: PublicID) -> ActionResultRender the agent into an operator workspace and service.
reprovision_agent
@strawberry.mutation(permission_classes=_ADMIN_PERMISSION_CLASSES)
def reprovision_agent(id: PublicID) -> ActionResultRecreate the agent service over its existing workspace.
agent_chat_endpoint
@strawberry.mutation(permission_classes=_ADMIN_PERMISSION_CLASSES)
def agent_chat_endpoint(id: PublicID) -> AgentChatEndpointMint the chat WebSocket endpoint + route token for a running agent.
A mutation, not a query: each call mints a fresh, short-lived per-actor route token (the operator admin bearer never reaches the browser). The browser speaks ACP to the agent's routed WebSocket through the central Caddy, forward-authed with that token. Errors when the agent is not running (no rendered service) or its service is not routed. The actor is the same identity operatorConnection mints with — the session user.
render_agent_prompt
@strawberry.mutation(permission_classes=_ADMIN_PERMISSION_CLASSES)
def render_agent_prompt(id: PublicID, view: JSON) -> strRender the <system_context> block for an agent and the user's open view.
view is the view envelope {kind, type: "<app>/<model>", sqid?, sqids?, params?}. The chat client calls this each send and prefixes the result, so the agent reads what the user is looking at. Resolving the agent (admin-gated) confirms the caller may drive it; the model-generic rendering lives in agents.context.
deprovision_agent
@strawberry.mutation(permission_classes=_ADMIN_PERMISSION_CLASSES)
def deprovision_agent(id: PublicID) -> ActionResultTear down the agent's operator workspace and service.
schemas
GraphQL contributions installed by the agents addon.