get_ticker_details
Retrieve comprehensive information about a specific stock or asset by providing its ticker symbol. This tool accesses financial market data to deliver key details for investment analysis and decision-making.
Instructions
Get details about a ticker symbol
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ticker | Yes | Ticker symbol (e.g., AAPL) |
Implementation Reference
- src/index.ts:42-60 (handler)The handler function for get_ticker_details that queries the Polygon API for ticker details and returns the response as formatted JSON or an error.get_ticker_details: async (args: { ticker: string }) => { try { const response = await polygonApi.get(`/v3/reference/tickers/${args.ticker}`); return { content: [{ type: "text", text: JSON.stringify(response.data, null, 2) }] }; } catch (error: any) { return { content: [{ type: "text", text: `Error getting ticker details: ${error.response?.data?.message || error.message}` }], isError: true }; } },
- src/index.ts:244-257 (registration)Tool registration in the ListToolsRequestHandler, providing the tool name, description, and input schema definition.{ name: "get_ticker_details", description: "Get details about a ticker symbol", inputSchema: { type: "object", properties: { ticker: { type: "string", description: "Ticker symbol (e.g., AAPL)" } }, required: ["ticker"] } },
- src/index.ts:247-256 (schema)Input schema definition for the get_ticker_details tool, specifying the required 'ticker' string parameter.inputSchema: { type: "object", properties: { ticker: { type: "string", description: "Ticker symbol (e.g., AAPL)" } }, required: ["ticker"] }