Skip to main content
Glama

get_grid_curl

Discover exact input fields required by a grid and get a ready-to-use curl command to run it, eliminating trial and error.

Instructions

Get a ready-to-use curl command and structured API contract for running a specific Grid. Call this BEFORE run_grid to discover the exact input fields required by the grid — no trial and error needed.

This endpoint returns the derived required inputs (traced from column dependencies), the full run URL, request body shape, and a copy-paste- ready curl command.

💡 Recommended workflow: 1. Call get_grid_curl to discover the exact input fields. 2. Call run_grid with the returned inputs shape and real values.

Args: grid_id: UUID of the grid. Found in the grid URL at app.bitscale.ai/grid/{gridId}, or from list_grids. output_columns: Optional comma-separated list of column key IDs to include in the run. When provided, required inputs are derived only from the dependencies of the specified columns. When omitted, inputs are derived from all runnable columns in the grid. Example: "col-uuid-1,col-uuid-2"

Returns: grid_id, grid_name, run_url, method, headers, request_body (with mode, inputs shape, and optional output_columns), output_columns array (id, name, type for each requested column), and a curl string ready to copy-paste into a terminal (replace YOUR_WORKSPACE_API_KEY).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
grid_idYes
output_columnsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • main.py:264-302 (handler)
    The get_grid_curl MCP tool handler. It accepts grid_id and optional output_columns, validates grid_id, builds query params, calls the BitScale API GET /grids/{grid_id}/curl endpoint via the _get helper, and returns the JSON response as a string.
    def get_grid_curl(
        grid_id: str,
        output_columns: str = "",
    ) -> str:
        """
        Get a ready-to-use curl command and structured API contract for running
        a specific Grid. Call this BEFORE run_grid to discover the exact input
        fields required by the grid — no trial and error needed.
    
        This endpoint returns the derived required inputs (traced from column
        dependencies), the full run URL, request body shape, and a copy-paste-
        ready curl command.
    
        💡 Recommended workflow:
            1. Call get_grid_curl to discover the exact input fields.
            2. Call run_grid with the returned inputs shape and real values.
    
        Args:
            grid_id:        UUID of the grid. Found in the grid URL at
                            app.bitscale.ai/grid/{gridId}, or from list_grids.
            output_columns: Optional comma-separated list of column key IDs to
                            include in the run. When provided, required inputs are
                            derived only from the dependencies of the specified
                            columns. When omitted, inputs are derived from all
                            runnable columns in the grid.
                            Example: "col-uuid-1,col-uuid-2"
    
        Returns: grid_id, grid_name, run_url, method, headers, request_body
        (with mode, inputs shape, and optional output_columns), output_columns
        array (id, name, type for each requested column), and a curl string
        ready to copy-paste into a terminal (replace YOUR_WORKSPACE_API_KEY).
        """
        if not grid_id:
            raise ValueError("grid_id must not be empty")
        params: dict = {}
        if output_columns:
            params["output_columns"] = output_columns
        data = _get(f"/grids/{grid_id}/curl", params=params if params else None)
        return json.dumps(data, indent=2)
  • main.py:263-264 (registration)
    The tool is registered as an MCP tool using the @mcp.tool() decorator on the get_grid_curl function.
    @mcp.tool()
    def get_grid_curl(
  • main.py:47-53 (helper)
    The _get helper function used by get_grid_curl to perform authenticated GET requests against the BitScale API.
    def _get(path: str, params: dict | None = None, timeout: int = 30) -> dict:
        """Perform an authenticated GET request against the BitScale API."""
        url = f"{BITSCALE_API_BASE}{path}"
        with httpx.Client(timeout=timeout) as client:
            response = client.get(url, headers=_headers(), params=params)
        response.raise_for_status()
        return response.json()
Behavior4/5

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

With no annotations provided, the description carries full burden. It explains the tool returns a curl command and structured API contract, including how required inputs are derived from column dependencies. It does not mention authentication needs or side effects, but as a read-only operation, this is sufficient.

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 well-structured with a recommended workflow, bullet points for parameters, and a clear list of returned fields. It is concise, front-loaded, and every sentence adds value.

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

Completeness4/5

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

For a simple tool with 2 parameters and an existing output schema, the description is thorough. It details all return fields and the workflow. Minor omission: no mention of error handling or edge cases, but overall complete.

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

Parameters5/5

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

The input schema has 0% description coverage, so the description compensates fully. It explains grid_id as a UUID from the grid URL or list_grids, and output_columns as an optional comma-separated list with an example, adding significant meaning 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 the tool's purpose: 'Get a ready-to-use curl command and structured API contract for running a specific Grid.' The verb 'Get' and the resource 'curl command and API contract' are specific and distinguish it from sibling tools like 'run_grid' and 'list_grids'.

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

Usage Guidelines4/5

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

The description explicitly recommends calling this tool before 'run_grid' to discover input fields, providing a clear workflow. It implies when to use (before running) and offers guidance on obtaining the grid_id. However, it does not explicitly state when not to use or exclude alternatives.

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/featherflow/bitscale-mcp'

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