Skip to main content
Glama
paperinvest

Paper MCP Server

by paperinvest

upgrade_to_margin

Convert a standard portfolio to a margin account on Paper MCP Server by submitting portfolio ID and agreeing to margin terms for enhanced trading flexibility.

Instructions

Upgrade portfolio to margin account

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
marginAgreementYesUser agrees to margin terms
portfolioIdYesPortfolio ID

Implementation Reference

  • Handler implementation for the 'upgrade_to_margin' tool. Sends a PUT request to upgrade the specified portfolio to a margin account, requiring user agreement to margin terms.
    case 'upgrade_to_margin': response = await api.put(`/accounts/portfolios/${args.portfolioId}/margin-upgrade`, { marginAgreement: args.marginAgreement }); break;
  • Schema definition for the 'upgrade_to_margin' tool, specifying required input parameters: portfolioId (string) and marginAgreement (boolean). This is returned in the listTools response for tool discovery.
    { name: 'upgrade_to_margin', description: 'Upgrade portfolio to margin account', inputSchema: { type: 'object', properties: { portfolioId: { type: 'string', description: 'Portfolio ID' }, marginAgreement: { type: 'boolean', description: 'User agrees to margin terms' } }, required: ['portfolioId', 'marginAgreement'] } }

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