Skip to main content
Glama
ahmedselimmansor-ctrl

IBM Cloud MCP Server

tg_create_gateway

Create a transit gateway to interconnect virtual networks in IBM Cloud, specifying name, region, and optional global routing.

Instructions

Create a transit gateway

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes
locationYesRegion (e.g. us-south)
global_routingNo

Implementation Reference

  • The tool handler for 'tg_create_gateway'. Registers an MCP tool that creates an IBM Cloud Transit Gateway by POSTing to the Transit Gateway API. Accepts 'name' (string), 'location' (string describing region), and optional 'global_routing' (boolean). Calls assertWriteAllowed via w(), then POSTs to ${tg}/transit_gateways with the provided parameters.
    server.tool("tg_create_gateway", "Create a transit gateway", {
      name: z.string(), location: z.string().describe("Region (e.g. us-south)"),
      global_routing: z.boolean().optional(),
    }, async (p) => safeTool(async () => { w();
      return client.post(`${tg}/transit_gateways`, {name:p.name,location:p.location,global:p.global_routing||false}, {version:"2024-03-01"});
    }));
  • The input schema for 'tg_create_gateway'. Defines Zod validation: 'name' as z.string(), 'location' as z.string() with description 'Region (e.g. us-south)', and optional 'global_routing' as z.boolean().
    server.tool("tg_create_gateway", "Create a transit gateway", {
      name: z.string(), location: z.string().describe("Region (e.g. us-south)"),
      global_routing: z.boolean().optional(),
    }, async (p) => safeTool(async () => { w();
      return client.post(`${tg}/transit_gateways`, {name:p.name,location:p.location,global:p.global_routing||false}, {version:"2024-03-01"});
    }));
  • src/server.ts:71-71 (registration)
    Registration of the networking tools module (which includes tg_create_gateway) via registerNetworkingTools(server, client, config) in the createServer function.
    registerNetworkingTools(server, client, config);
  • Export of the registerNetworkingTools function that receives the McpServer instance and registers all networking tools including tg_create_gateway.
    export function registerNetworkingTools(server: McpServer, client: IBMCloudAPIClient, config: ServerConfig) {
      const w = () => assertWriteAllowed(config.allowWrite);
  • Definition of TRANSIT_GATEWAY endpoint constant used in the tg_create_gateway handler: 'https://transit.cloud.ibm.com/v1'.
    TRANSIT_GATEWAY: "https://transit.cloud.ibm.com/v1",
Behavior1/5

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

With no annotations, the description must fully disclose behavior, but it offers no information about side effects, idempotency, permissions, or error states.

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

Conciseness2/5

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

While the description is short, it is too sparse to be useful; it does not provide any additional context or structure beyond the tool's name.

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

Completeness1/5

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

Given the absence of annotations and output schema, the description fails to provide essential context such as return values, prerequisites, or potential side effects.

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

Parameters1/5

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

Schema coverage is only 33%, and the description adds no parameter explanations beyond the schema, leaving most parameters semantically opaque.

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 verb 'Create' and the resource 'transit gateway', which distinguishes it from sibling tools like tg_delete_gateway and tg_list_gateways.

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 guidance is provided on when to use this tool versus alternatives, nor any prerequisites or context for invocation.

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/ahmedselimmansor-ctrl/IBM_cloud_MCP_SERVER'

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