Skip to main content
Glama

getEntry

Fetch Fantasy Premier League team information by entering a specific entry ID to retrieve general team details and statistics.

Instructions

Fetch general info about a team by entry ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
entryIdYes

Implementation Reference

  • The core handler function that fetches the team entry data from the Fantasy Premier League API endpoint `/api/entry/{entryId}/` and returns the JSON response.
    export async function getEntry(entryId: number): Promise<any> { const res = await fetch(`https://fantasy.premierleague.com/api/entry/${entryId}/`); return res.json(); }
  • src/server.ts:284-298 (registration)
    Registers the 'getEntry' MCP tool, defining its input schema (entryId: number), metadata, and a thin wrapper handler that invokes the core getEntry function and formats the response as MCP content.
    server.registerTool("getEntry", { title: "Get Entry", description: "Fetch general info about a team by entry ID", inputSchema: { entryId: z.number() } }, async ({ entryId }) => { const data = await getEntry(entryId); return { content: [ { type: "text", text: JSON.stringify(data) } ] }; });
  • Input schema validation using Zod: requires an entryId as a number.
    inputSchema: { entryId: z.number() }

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/owen-lacey/fpl-mcp'

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