Skip to main content
Glama
kongyo2

EVE Tycoon MCP Server

get_market_history

Retrieve historical price data for EVE Online items in specific regions to analyze market trends and make informed trading decisions.

Instructions

Returns the price history of an item in a particular region

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
regionIdYesRegion ID
typeIdYesItem type ID

Implementation Reference

  • The execute handler for the get_market_history tool, which constructs the EVE Tycoon API endpoint for market history using the provided regionId and typeId, fetches the data via makeApiRequest, and returns it as a formatted JSON string.
    execute: async (args) => {
      const endpoint = `/v1/market/history/${args.regionId}/${args.typeId}`;
      const data = await makeApiRequest(endpoint);
      return JSON.stringify(data, null, 2);
    },
  • Zod input schema defining the required parameters: regionId (number) and typeId (number) for the get_market_history tool.
    parameters: z.object({
      regionId: z.number().describe("Region ID"),
      typeId: z.number().describe("Item type ID"),
    }),
  • src/server.ts:97-114 (registration)
    Full registration of the 'get_market_history' tool using FastMCP's server.addTool method, including annotations, description, inline handler, name, and parameters schema.
    server.addTool({
      annotations: {
        openWorldHint: true,
        readOnlyHint: true,
        title: "Get Market History",
      },
      description: "Returns the price history of an item in a particular region",
      execute: async (args) => {
        const endpoint = `/v1/market/history/${args.regionId}/${args.typeId}`;
        const data = await makeApiRequest(endpoint);
        return JSON.stringify(data, null, 2);
      },
      name: "get_market_history",
      parameters: z.object({
        regionId: z.number().describe("Region ID"),
        typeId: z.number().describe("Item type ID"),
      }),
    });
  • Shared utility function used by the tool handler to perform HTTP GET requests to the EVE Tycoon API (https://evetycoon.com/api), handling errors and returning parsed JSON.
    async function makeApiRequest(endpoint: string): Promise<any> {
      const url = `${BASE_URL}${endpoint}`;
      const response = await fetch(url);
      
      if (!response.ok) {
        throw new Error(`API request failed: ${response.status} ${response.statusText}`);
      }
      
      return response.json();
    }

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/evetycoon-mcp-server'

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