Skip to main content
Glama

run_scenario_11652

Run scenarios to add new items to inventory by specifying the item name, enabling AI assistants to trigger automation workflows on the Make MCP Server.

Instructions

Tool: Add to Inventory (Add a new item to the inventory.)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesItem name

Implementation Reference

  • Handler for CallToolRequestSchema that matches tool names like 'run_scenario_11652', parses the scenario ID, executes make.scenarios.run, and returns the output or error.
    server.setRequestHandler(CallToolRequestSchema, async request => {
        if (/^run_scenario_\d+$/.test(request.params.name)) {
            try {
                const output = (
                    await make.scenarios.run(parseInt(request.params.name.substring(13)), request.params.arguments)
                ).outputs;
    
                return {
                    content: [
                        {
                            type: 'text',
                            text: output ? JSON.stringify(output, null, 2) : 'Scenario executed successfully.',
                        },
                    ],
                };
            } catch (err: unknown) {
                return {
                    isError: true,
                    content: [
                        {
                            type: 'text',
                            text: String(err),
                        },
                    ],
                };
            }
        }
        throw new Error(`Unknown tool: ${request.params.name}`);
    });
  • src/index.ts:37-57 (registration)
    Registers dynamic tools for on-demand scenarios, naming them 'run_scenario_<id>' (e.g., run_scenario_11652), fetches interface for schema.
    server.setRequestHandler(ListToolsRequestSchema, async () => {
        const scenarios = await make.scenarios.list(teamId);
        return {
            tools: await Promise.all(
                scenarios
                    .filter(scenario => scenario.scheduling.type === 'on-demand')
                    .map(async scenario => {
                        const inputs = (await make.scenarios.interface(scenario.id)).input;
                        return {
                            name: `run_scenario_${scenario.id}`,
                            description: scenario.name + (scenario.description ? ` (${scenario.description})` : ''),
                            inputSchema: remap({
                                name: 'wrapper',
                                type: 'collection',
                                spec: inputs,
                            }),
                        };
                    }),
            ),
        };
    });
  • Converts Make scenario input spec to JSON schema for tool inputSchema, used dynamically for each scenario including 11652.
    export function remap(field: Input): unknown {
        switch (field.type) {
            case 'collection':
                const required: string[] = [];
                const properties: unknown = (Array.isArray(field.spec) ? field.spec : []).reduce((object, subField) => {
                    if (!subField.name) return object;
                    if (subField.required) required.push(subField.name);
    
                    return Object.defineProperty(object, subField.name, {
                        enumerable: true,
                        value: remap(subField),
                    });
                }, {});
    
                return {
                    type: 'object',
                    description: noEmpty(field.help),
                    properties,
                    required,
                };
            case 'array':
                return {
                    type: 'array',
                    description: noEmpty(field.help),
                    items:
                        field.spec &&
                        remap(
                            Array.isArray(field.spec)
                                ? {
                                      type: 'collection',
                                      spec: field.spec,
                                  }
                                : field.spec,
                        ),
                };
            case 'select':
                return {
                    type: 'string',
                    description: noEmpty(field.help),
                    enum: (field.options || []).map(option => option.value),
                };
            default:
                return {
                    type: PRIMITIVE_TYPE_MAP[field.type as keyof typeof PRIMITIVE_TYPE_MAP],
                    default: field.default != '' && field.default != null ? field.default : undefined,
                    description: noEmpty(field.help),
                };
        }
    }
  • Core helper method in Scenarios class that runs the scenario by POSTing inputs to the Make API endpoint.
    async run(scenarioId: number, body: unknown): Promise<ScenarioRunServerResponse> {
        return await this.#fetch<ScenarioRunServerResponse>(`/scenarios/${scenarioId}/run`, {
            method: 'POST',
            body: JSON.stringify({ data: body, responsive: true }),
            headers: {
                'content-type': 'application/json',
            },
        });
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. While 'Add to Inventory' implies a write/mutation operation, the description doesn't specify permissions needed, whether the operation is idempotent, what happens on duplicate items, or what the response contains. For a mutation tool with zero annotation coverage, this leaves significant behavioral gaps.

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

Conciseness4/5

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

The description is extremely concise - just one sentence that states the tool's core function. While this is efficient, it borders on under-specification given the lack of context about what 'inventory' means in this scenario system. Every word earns its place, but more context would be helpful.

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 mutation tool with no annotations and no output schema, the description is insufficiently complete. It doesn't explain what constitutes a valid 'item', how the inventory is structured, what happens after addition, or any error conditions. The agent lacks crucial context to use this tool effectively in the scenario-based system with multiple sibling tools.

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

Parameters3/5

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

Schema description coverage is 100% with the single 'name' parameter well-documented in the schema. The description doesn't add any parameter semantics beyond what the schema already provides (e.g., no format requirements, length limits, or examples). With high schema coverage, the baseline score of 3 is appropriate.

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

Purpose3/5

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

The description states the tool's purpose as 'Add a new item to the inventory', which is a clear verb+resource combination. However, it doesn't distinguish this tool from its siblings (run_scenario_11422, etc.), which all appear to be scenario-based tools with generic names. The description is vague about what 'inventory' refers to in this specific scenario context.

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?

The description provides no guidance on when to use this tool versus its sibling tools. There's no mention of alternative tools, prerequisites, or specific contexts where this inventory addition is appropriate. The agent must infer usage from the generic description alone.

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

Related 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/integromat/make-mcp-server'

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