get_team_social_media
Retrieve social media profiles for FIRST Robotics Competition teams using their official team key to access linked accounts and online presence.
Instructions
Get social media information for a team
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| team_key | Yes | Team key in format frcXXXX (e.g., frc86) |
Implementation Reference
- src/handlers.ts:717-729 (handler)Inline switch case handler that parses team_key input, fetches team social media data from TBA API, validates response as array of MediaSchema, and returns JSON text content.case 'get_team_social_media': { const { team_key } = z.object({ team_key: TeamKeySchema }).parse(args); const data = await makeApiRequest(`/team/${team_key}/social_media`); const media = z.array(MediaSchema).parse(data); return { content: [ { type: 'text', text: JSON.stringify(media, null, 2), }, ], }; }
- src/tools.ts:697-710 (schema)Tool definition object with name, description, and JSON schema for input parameters (team_key).name: 'get_team_social_media', description: 'Get social media information for a team', inputSchema: { type: 'object', properties: { team_key: { type: 'string', description: 'Team key in format frcXXXX (e.g., frc86)', pattern: '^frc\\d+$', }, }, required: ['team_key'], }, },
- src/schemas.ts:4-6 (schema)Zod schema used for validating the team_key input parameter in the handler.export const TeamKeySchema = z .string() .regex(/^frc\d+$/, 'Team key must be in format frcXXXX');
- src/schemas.ts:233-240 (schema)Zod schema used for validating each item in the social media array response from the API.export const MediaSchema = z.object({ type: z.string(), foreign_key: z.string().nullish(), details: z.record(z.string(), z.any()).nullish(), preferred: z.boolean().nullish(), direct_url: z.string().nullish(), view_url: z.string().nullish(), });
- src/index.ts:45-47 (registration)MCP server registration of the ListTools handler, which returns the full list of tools including 'get_team_social_media'.server.setRequestHandler(ListToolsRequestSchema, async () => { return { tools }; });