Skip to main content
Glama

get_team_history

Retrieve comprehensive historical data for FIRST Robotics Competition teams across all competition years to analyze performance trends and track achievements.

Instructions

Get historical data for a team across all years

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
team_keyYesTeam key in format frcXXXX (e.g., frc86)

Implementation Reference

  • The handler implementation for the 'get_team_history' tool. It validates the input team_key using TeamKeySchema, fetches the team history data from the TBA API endpoint `/team/${team_key}/history`, parses the response using TeamHistorySchema, and returns the JSON-formatted history.
    case 'get_team_history': { const { team_key } = z.object({ team_key: TeamKeySchema }).parse(args); const data = await makeApiRequest(`/team/${team_key}/history`); const history = TeamHistorySchema.parse(data); return { content: [ { type: 'text', text: JSON.stringify(history, null, 2), }, ], }; }
  • src/tools.ts:839-852 (registration)
    The tool registration definition including name, description, and input schema for 'get_team_history'. This object is part of the tools array exported and registered with the MCP server via ListToolsRequestHandler.
    { name: 'get_team_history', description: 'Get historical data for a team across all years', inputSchema: { type: 'object', properties: { team_key: { type: 'string', description: 'Team key in format frcXXXX (e.g., frc86)', pattern: '^frc\\d+$', }, }, required: ['team_key'], },
  • The Zod schema for validating the output of the get_team_history API response, defining the structure with awards, events, matches, and robots arrays.
    export const TeamHistorySchema = z.object({ awards: z.array(AwardSchema).nullish(), events: z.array(EventSchema).nullish(), matches: z.array(MatchSchema).nullish(), robots: z.array(RobotSchema).nullish(), });
  • The Zod schema for validating the team_key input parameter, used in the handler for parsing arguments.
    export const TeamKeySchema = z .string() .regex(/^frc\d+$/, 'Team key must be in format frcXXXX');

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/withinfocus/tba'

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