Skip to main content
Glama

integrations_abort_config_flow

Abort an ongoing configuration flow using its flow ID to cancel the integration setup process.

Instructions

Abort a config flow in progress.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
flow_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function for the 'abort_config_flow' tool. It calls the HA WebSocket API to abort a config flow in progress by sending the flow_id to 'config_entries/flow/abort'.
    @mcp.tool()
    def abort_config_flow(flow_id: str) -> dict:
        """Abort a config flow in progress."""
        return ha._ws_call("config_entries/flow/abort", flow_id=flow_id)
  • The tool is registered as an MCP tool via the @mcp.tool() decorator on the FastMCP instance named 'integrations'. It is mounted into the main server at namespace 'integrations' (line 55 of server.py).
    @mcp.tool()
    def abort_config_flow(flow_id: str) -> dict:
        """Abort a config flow in progress."""
        return ha._ws_call("config_entries/flow/abort", flow_id=flow_id)
  • The input schema for the tool is simply a 'flow_id' string parameter. The return type is dict.
    def abort_config_flow(flow_id: str) -> dict:
  • The supporting _ws_call helper function that sends the WebSocket command. It wraps _ws_call_async to work both inside and outside an async event loop.
    def _ws_call(msg_type: str, **kwargs) -> Any:
        try:
            asyncio.get_running_loop()
        except RuntimeError:
            return asyncio.run(_ws_call_async(msg_type, **kwargs))
        import concurrent.futures
        with concurrent.futures.ThreadPoolExecutor() as pool:
            return pool.submit(asyncio.run, _ws_call_async(msg_type, **kwargs)).result()
  • server.py:55-55 (registration)
    The integrations MCP server (containing abort_config_flow) is mounted at the 'integrations' namespace in the main server, making the tool accessible as 'integrations_abort_config_flow'.
    mcp.mount(integrations_mcp, namespace="integrations")
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description must fully disclose behavior. It only states 'Abort a config flow in progress' without explaining side effects, whether resources are cleaned up, or if the flow can be aborted at any step. This is insufficient for a mutation tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is one sentence of six words, perfectly concise and front-loaded. Every word is necessary and serves the purpose.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with 1 parameter and no annotations, the description is too sparse. It omits context about when a config flow can be aborted, confirmation of success, and any implications. While output schema exists, behavioral completeness is lacking.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 0% description coverage for the flow_id parameter. The description does not explain what flow_id represents or how to obtain it, leaving the agent to infer from the parameter name alone. The description adds no value beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states 'Abort a config flow in progress,' using a specific verb and resource. It distinguishes this tool from sibling tools like start_config_flow, submit_config_flow_step, etc., by its action of aborting an existing flow.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No usage guidelines are provided. The description doesn't indicate when to use this tool versus alternatives (e.g., when to abort vs. remove an integration), nor does it mention prerequisites or post-conditions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Fistacho/ha-nexus-agent'

If you have feedback or need assistance with the MCP directory API, please join our Discord server