Skip to main content
Glama
paperinvest

Paper MCP Server

by paperinvest

get_portfolio

Retrieve detailed portfolio information by specifying a portfolio ID, enabling users to manage and analyze trading data through the Paper MCP Server interface.

Instructions

Get portfolio details

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
portfolioIdYesPortfolio ID

Implementation Reference

  • Tool definition including name, description, and input schema for validating portfolioId parameter.
    { name: 'get_portfolio', description: 'Get portfolio details', inputSchema: { type: 'object', properties: { portfolioId: { type: 'string', description: 'Portfolio ID' } }, required: ['portfolioId'] } },
  • Core handler logic: performs authenticated GET request to the Paper Invest API endpoint for portfolio details using the provided portfolioId.
    case 'get_portfolio': response = await api.get(`/accounts/portfolios/${args.portfolioId}`); break;
  • src/index.ts:388-392 (registration)
    Registers the listTools handler which exposes the get_portfolio tool (among others) to MCP clients.
    server.setRequestHandler(ListToolsRequestSchema, async () => { return { tools }; });

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

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