Skip to main content
Glama
Public.com MCP Server

Public.com MCP Server

Official
by PublicDotCom

get_portfolio

Read-only

Retrieve a snapshot of a non-IRA brokerage portfolio, including positions, equity breakdown, buying power, open orders, and cash or withdrawal figures.

Instructions

Get a snapshot of the account portfolio.

Returns positions, equity breakdown, buying power, open orders, and cash/withdrawal figures (including cash, totalAccountValue, and availableToWithdraw). Only non-IRA accounts are supported.

buyingPower includes dayTradeBuyingPower, the buying power available for day trading. It equals buyingPower when the account is not enabled for day-trade buying power, and is omitted when the API does not report it.

Args: account_id: Account ID. Optional if PUBLIC_COM_ACCOUNT_ID is set.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_portfolio"
  }
}

Input Schema

NameRequiredDescriptionDefault
account_idNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.1

TDQS

A4.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint, openWorldHint, and destructiveHint=false, so the safety profile is covered. The description adds value beyond that by disclosing the non-IRA account restriction and explaining how dayTradeBuyingPower behaves (equals buyingPower when not enabled, omitted when unreported).

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The purpose and return contents are front-loaded, and the account-type restriction appears early. The paragraph on dayTradeBuyingPower is slightly deep for a tool description, but it is scoped and relevant to interpreting the output.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given an output schema already exists, the description needn't explain return formatting. It covers the key restriction, the optional-parameter fallback, and the one non-obvious field behavior, leaving no material gap for an agent to call it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate, and it does: it labels account_id as an Account ID and explains that it is optional when PUBLIC_COM_ACCOUNT_ID is set. That resolves the practical ambiguity of a nullable, non-required parameter.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a specific verb and resource ('Get a snapshot of the account portfolio') and enumerates the contents (positions, equity breakdown, buying power, open orders, cash figures). This makes it clearly distinguishable from siblings such as get_accounts or get_orders, which do not return a consolidated snapshot.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It states an important gating constraint ('Only non-IRA accounts are supported') and explains the optional-account_id fallback via PUBLIC_COM_ACCOUNT_ID. It does not explicitly route the agent away from alternatives, but the context is clear enough for correct selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.