get_portfolio
Fetch a T-Bank Invest account's full holdings: total values by asset type, positions, quantities, current prices, and yields by account ID and currency.
Instructions
Get full portfolio for an account: total values by asset type, all positions with prices, yields, and quantities.
Each position has ticker, classCode, figi, instrumentUid, positionUid, instrumentType,
quantity, averagePositionPrice, currentPrice, expectedYield, dailyYield, currentNkd
(bonds) and its currency. Amounts are plain numbers; a field that is zero or false is
left out, and so are the two fields the API has deprecated.
expectedYield and dailyYield of a position are amounts of money in the position's currency, not percentages; the portfolio's own expectedYield, at the top level, is a percentage. A bond's averagePositionPrice and currentPrice are money per bond, and currentNkd is the accrued interest per bond in the same currency — while get_last_prices, get_candles and get_order_book give a bond's price in percent of its nominal. positionUid is the key of a position: one paper can come under several figi and instrumentUid (its listings), all with the same positionUid.
Args: account_id: Account ID (get from get_accounts) currency: Portfolio currency — RUB, USD, or EUR (default: RUB)
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"account_id": "<account_id>"
},
"name": "get_portfolio"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| currency | No | RUB | |
| account_id | Yes |