Skip to main content
Glama

stargate_info

Read-only

Retrieve detailed stargate data, including connections and positions, for EVE Online using ESI and SDE APIs. Input up to 50 stargate IDs to access precise navigation and system information.

Instructions

Get comprehensive stargate information from both ESI and SDE APIs, including connections and positions

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
stargateIdsYesArray of stargate IDs to get information for (max 50). Use numeric IDs only, not names.

Implementation Reference

  • The main handler function for the 'stargate_info' tool. It processes an array of stargate IDs, fetches data from both ESI and SDE clients, combines the data using combineStargateData, and returns formatted JSON results.
    execute: async (args: { stargateIds: number[] }) => {
      try {
        const results: CombinedStargateInfo[] = [];
    
        for (const stargateId of args.stargateIds) {
          let esiData: ESIStargateInfo | undefined;
          let sdeData: SDEStargateInfo | undefined;
    
          // Fetch from ESI
          try {
            esiData = await esiClient.getStargateInfo(stargateId);
          } catch (error) {
            console.warn(`Failed to fetch ESI data for stargate ${stargateId}:`, error);
          }
    
          // Fetch from SDE
          try {
            sdeData = await sdeClient.getStargateInfo(stargateId);
          } catch (error) {
            console.warn(`Failed to fetch SDE data for stargate ${stargateId}:`, error);
          }
    
          const combined = await combineStargateData(esiData, sdeData);
          if (combined) {
            results.push(combined);
          }
        }
    
        if (results.length === 0) {
          return JSON.stringify({
            success: false,
            message: "No stargate information found for the provided IDs",
            results: []
          });
        }
    
        return JSON.stringify({
          success: true,
          message: `Found information for ${results.length} stargate(s)`,
          results: results
        });
      } catch (error) {
        return JSON.stringify({
          success: false,
          message: `Error: ${error instanceof Error ? error.message : 'Unknown error'}`,
          results: []
        });
      }
    },
  • Input schema definition using Zod, specifying the stargateIds parameter as an array of numbers (1-50 items).
    name: "stargate_info",
    parameters: z.object({
      stargateIds: z.array(z.number()).min(1).max(50).describe("Array of stargate IDs to get information for (max 50). Use numeric IDs only, not names.")
    }),
  • src/server.ts:52-52 (registration)
    Registration of the stargateInfoTool object into the FastMCP server instance.
    server.addTool(stargateInfoTool);
  • Helper function that combines ESI and SDE stargate data, resolves names using ESI idsToNames, and formats into CombinedStargateInfo.
    async function combineStargateData(
      esiData?: ESIStargateInfo,
      sdeData?: SDEStargateInfo
    ): Promise<CombinedStargateInfo | null> {
      if (!esiData && !sdeData) return null;
    
      const stargateId = esiData?.stargate_id || sdeData?.stargateID;
      if (!stargateId) return null;
    
      // Collect IDs that need names
      const idsToResolve: number[] = [];
      const systemId = esiData?.system_id || sdeData?.solarSystemID || 0;
      const destStargateId = esiData?.destination?.stargate_id || sdeData?.destinationStargateID || 0;
      const destSystemId = esiData?.destination?.system_id || sdeData?.destinationSolarSystemID || 0;
    
      if (systemId) idsToResolve.push(systemId);
      if (destStargateId) idsToResolve.push(destStargateId);
      if (destSystemId) idsToResolve.push(destSystemId);
    
      // Resolve names
      let nameMap = new Map<number, string>();
      if (idsToResolve.length > 0) {
        try {
          const nameResults = await esiClient.idsToNames(idsToResolve);
          nameMap = new Map(nameResults.map(result => [result.id, result.name]));
        } catch (error) {
          console.warn('Failed to fetch names for stargate data:', error);
        }
      }
    
      return {
        stargate_id: stargateId,
        name: esiData?.name,
        system_id: systemId,
        system_name: nameMap.get(systemId),
        type_id: esiData?.type_id || sdeData?.typeID,
        position: {
          x: esiData?.position?.x || (sdeData?.position ? sdeData.position[0] : 0),
          y: esiData?.position?.y || (sdeData?.position ? sdeData.position[1] : 0),
          z: esiData?.position?.z || (sdeData?.position ? sdeData.position[2] : 0),
        },
        destination: {
          stargate_id: destStargateId,
          stargate_name: nameMap.get(destStargateId),
          system_id: destSystemId,
          system_name: nameMap.get(destSystemId),
        },
        source: {
          esi: !!esiData,
          sde: !!sdeData,
        },
        esi_data: esiData,
        sde_data: sdeData,
      };
    }
  • TypeScript interface defining the structure of the combined stargate information returned by the tool.
    export interface CombinedStargateInfo {
      stargate_id: number;
      name?: string;
      system_id: number;
      system_name?: string;
      type_id?: number;
      position: {
        x: number;
        y: number;
        z: number;
      };
      destination: {
        stargate_id: number;
        stargate_name?: string;
        system_id: number;
        system_name?: string;
      };
      source: {
        esi: boolean;
        sde: boolean;
      };
      esi_data?: ESIStargateInfo;
      sde_data?: SDEStargateInfo;
    }
Behavior3/5

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

Annotations already indicate readOnlyHint=true and openWorldHint=true, so the agent knows this is a safe, non-destructive query with potential for unknown data. The description adds value by specifying the APIs involved (ESI and SDE) and the types of information returned (connections and positions), which provides useful context beyond the annotations.

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 a single, efficient sentence that front-loads the core purpose ('Get comprehensive stargate information') and includes essential details (data sources and content). Every word contributes meaning without redundancy, making it optimally concise.

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

Completeness3/5

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

Given the tool's moderate complexity (fetching data from multiple APIs), annotations cover safety and scope, but there's no output schema to describe return values. The description mentions 'connections and positions' as included information, which helps, but doesn't detail format or potential limitations, leaving some gaps for an agent to infer.

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 parameter 'stargateIds' fully documented in the schema (array of numeric IDs, max 50). The description doesn't add any parameter-specific details beyond what the schema provides, so it meets the baseline for high coverage without extra value.

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

Purpose4/5

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

The description clearly states the action ('Get comprehensive stargate information') and the data sources ('from both ESI and SDE APIs'), which is specific and informative. However, it doesn't explicitly differentiate this tool from sibling tools like 'solar_system_info' or 'system_connection_map' that might also provide related spatial data, preventing a perfect score.

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 alternatives. With sibling tools like 'solar_system_info' and 'system_connection_map' available, there's no indication of scenarios where this tool is preferred or excluded, leaving usage context unclear.

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/kongyo2/eve-online-traffic-mcp'

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