Ghostfolio MCP

v1.9.0
io.github.mhajder/ghostfolio-mcp Checked 6 hours ago Published 3 days ago

MCP server for Ghostfolio portfolio management and financial data access

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

get_account_balances Get Account Balances

Get account balances for a specific account. Retrieves balance information for a specific account including current balance, currency, and balance history.

ParameterTypeDescription
account_id *stringAccount ID to get balances for

get_accounts Get Accounts

Get all accounts in your portfolio including account types and balances. Retrieves a list of all accounts in your portfolio including account types, balances, and account-specific information.

create_account Create Account

Create a new account in your portfolio. Creates a new account with the specified name, currency, and optional balance. This is useful for organizing your investments across different account types or platforms. Note: current Ghostfolio versions have no boolean "excluded" flag on an account - exclusion from analysis is done by tagging the account, which is outside this tool's scope.

ParameterTypeDescription
currency *stringCurrency code for the account (e.g., 'USD', 'EUR', 'GBP')
name *stringName of the account (e.g., 'My Brokerage Account', 'Retirement Fund')
balancenumberInitial balance for the account (defaults to 0)
commentstringOptional comment or note for the account
platform_idOptional platform ID for the account (e.g., broker or exchange identifier)

delete_account Delete Account

Delete an existing account from your portfolio. Deletes an account specified by its ID. Be careful, this might delete associated transactions depending on backend rules!

ParameterTypeDescription
account_id *stringAccount ID to delete (e.g., 'cb547e5c-..')

get_account_details Get Account Details

Get details for a specific account.

ParameterTypeDescription
account_id *stringAccount ID to retrieve details for

update_account Update Account

Update settings or details of an existing account. Ghostfolio's update endpoint replaces the whole account record, so `name`, `currency` and `platform_id` are required on every request even when they are not changing. Any left unset here are backfilled from the account's current state with a GET before the PUT, so you only need to pass the fields you actually want to change. If `name` or `currency` can't be backfilled (e.g. the account doesn't exist), the update stops before the PUT and names them. Setting `balance` here applies it as *today's* entry in the account's balance history (the sam…

ParameterTypeDescription
account_id *stringAccount ID to update
balanceOptional new balance for the account
commentOptional new comment or note for the account
currencyOptional new currency code for the account (e.g., 'USD', 'EUR')
nameOptional new name of the account
platform_idOptional new platform ID for the account

transfer_account_balance Transfer Account Balance

Transfer cash balances between two accounts.

ParameterTypeDescription
account_id_from *stringThe source account ID to transfer cash from
account_id_to *stringThe target account ID to transfer cash to
balance *numberThe amount of cash to transfer

create_account_balance Create Account Balance

Set an account's balance for a specific date in its balance history. This writes directly to the balance-history series that get_account_balances returns and that get_portfolio_holdings derives its cash figure from - it is not the same as the account's summary balance field. Calling this again for the same account and date updates that entry instead of duplicating it, so setting today's balance is just this call with `date` omitted. The balance is recorded in the account's own currency; Ghostfolio's API does not accept a separate currency for this endpoint.

ParameterTypeDescription
account_id *stringAccount ID to record a balance entry for
balance *numberBalance value to record for the given date
dateISO-8601 date for this balance entry, e.g. '2026-08-27'. Defaults to today.

delete_account_balance Delete Account Balance

Delete a single entry from an account's balance history.

ParameterTypeDescription
balance_id *stringID of the balance-history entry to delete, from get_account_balances (not the account ID)

get_orders Get Orders

Get all activities/orders from your portfolio, optionally filtered by account. Retrieves a list of all buy/sell orders in your portfolio, optionally filtered by a specific account.

ParameterTypeDescription
account_idOptional account ID to filter orders by specific account

create_activity Create Activity

Create a single new transaction/activity.

ParameterTypeDescription
account_id *stringThe account ID where this activity will be recorded
currency *stringCurrency code for the transaction
data_source *stringData source (e.g., 'YAHOO', 'COINGECKO', 'MANUAL')
date *stringDate in ISO 8601 format (e.g. 2026-05-09T00:00:00.000Z)
quantity *numberNumber of shares/units
symbol *stringSymbol profile ID or actual ticker symbol
type *stringType of activity: BUY, SELL, DIVIDEND, INTEREST, FEE, LIABILITY
unit_price *numberPrice per unit
commentstringOptional comment
feenumberOptional fee amount
tagsOptional list of tag IDs to attach to this activity (from get_tags). Omit for no tags.

update_activity Update Activity

Update an existing activity/transaction. Ghostfolio's update endpoint replaces the whole activity record, so `type`, `symbol`, `date`, `quantity`, `unitPrice`, `currency`, `dataSource` and `fee` are required on every request even when they are not changing. Any left unset here (including `tags`, `account_id` and `comment`) are backfilled from the activity's current state with a GET before the PUT, so you only need to pass the fields you actually want to change. If a required field can't be backfilled (Ghostfolio redacts `quantity` and `fee` in restricted views), pass it explicitly. A restrict…

ParameterTypeDescription
activity_id *stringThe unique ID of the activity to update
account_idOptional new account ID. Pass an empty string to detach the activity from its account.
commentOptional new comment
currencyOptional new currency code
data_sourceOptional new data source (e.g., 'YAHOO', 'COINGECKO', 'MANUAL'). Changing it requires symbol and currency too.
dateOptional new date in ISO 8601 format (e.g. 2026-05-09T00:00:00.000Z)
feeOptional new fee amount
quantityOptional new number of shares/units
symbolOptional new ticker symbol. Changing the asset (symbol or data_source) requires symbol, data_source and currency together.
tagsOptional new list of tag IDs (from get_tags) to replace this activity's tags. Omit to leave existing tags unchanged; pass an empty list to clear all tags.
typeOptional new type: BUY, SELL, DIVIDEND, INTEREST, FEE, LIABILITY
unit_priceOptional new price per unit

delete_activity Delete Activity

Delete a single activity/transaction by its ID.

ParameterTypeDescription
activity_id *stringThe unique ID of the activity to delete

get_asset_profile Get Asset Profile

Get asset profile information for a specific symbol. Retrieves detailed profile information about an asset including company information, sector, industry, and other metadata.

ParameterTypeDescription
data_source *stringData source for the symbol (e.g., 'YAHOO', 'COINGECKO', 'MANUAL')
symbol *stringSymbol/ticker of the asset (e.g., 'AAPL', 'BTC-USD')

upsert_asset_profile Upsert Asset Profile

Create-or-update an asset profile. POSTs an empty profile-data record (idempotent — Ghostfolio answers HTTP 400 "already exists" when the profile is already there, and HTTP 500 on some first-time-create paths while still persisting the record, so this tolerates both). Then PATCHes metadata (name, currency, asset class, optional sub-class, optional country and sector allocations). PATCH is the source of truth — if the profile doesn't exist after the POST, PATCH will surface the error. Calling twice with the same input yields the same end state.

ParameterTypeDescription
asset_class *stringAsset class: 'EQUITY', 'FIXED_INCOME', 'REAL_ESTATE', 'COMMODITY', 'LIQUIDITY' (cash), or 'ALTERNATIVE_INVESTMENT'. Note: Ghostfolio's enum does not include 'CASH' — use 'LIQUIDITY'
currency *stringCurrency code of the asset (e.g., 'USD', 'CHF', 'EUR')
data_source *stringData source for the symbol. Typically 'MANUAL' — Ghostfolio rejects profile-data writes for auto-fetched sources
name *stringHuman-readable name for the asset
symbol *stringSymbol/ticker of the asset. Permanent — renaming orphans associated activities and market data
asset_sub_classstringOptional asset sub-class (e.g., 'MUTUALFUND', 'CASH', 'ETF')
countriesOptional country allocation. Entries must contain exactly 'code' (ISO 3166-1 alpha-2, e.g. 'US') and 'weight' (a fraction between 0 and 1, e.g. 0.6907) — any extra key, such as the 'continent' and '…
sectorsOptional sector allocation. Entries must contain exactly 'name' and 'weight' (a fraction between 0 and 1, e.g. 0.2431); any extra key is rejected with HTTP 400. Omit to leave the stored value untouche…

delete_asset_profile Delete Asset Profile

Delete an asset profile. Removes the profile-data record for the given data source and symbol. Be careful, this might delete associated activities and market data depending on backend rules!

ParameterTypeDescription
data_source *stringData source for the symbol. Typically 'MANUAL' — Ghostfolio rejects profile-data deletes for auto-fetched sources
symbol *stringSymbol/ticker of the asset to delete

get_benchmarks Get Benchmarks

Get all configured benchmarks.

get_benchmark_performance Get Benchmark Performance

Compare portfolio performance against a benchmark symbol starting from a specific date.

ParameterTypeDescription
data_source *stringData source for the benchmark (e.g. 'YAHOO', 'COINGECKO')
start_date *stringStart date in YYYY-MM-DD format for comparison
symbol *stringSymbol/ticker of the benchmark (e.g. 'URTH', 'AAPL')
accountsOptional comma-separated list of account IDs to filter by
asset_classesOptional comma-separated list of asset classes to filter by
date_rangestringTime range. Options: 1d, 1w, 1m, 3m, 6m, 1y, 2y, 5y, max
filter_data_sourceOptional data source to filter by
filter_symbolOptional symbol/ticker to filter by
tagsOptional comma-separated list of tags to filter by
with_excluded_accountsbooleanWhether to include excluded accounts in the calculations

get_exchange_rate Get Exchange Rate

Get the exchange rate for a given currency symbol on a specific date.

ParameterTypeDescription
date *stringDate in YYYY-MM-DD format to retrieve the rate for
symbol *stringCurrency symbol to get exchange rate for (e.g. 'USD', 'CHF', 'EUR')

export_portfolio Export Portfolio

Export portfolio activities/transactions data as JSON. Retrieves portfolio transactions with optional query filters.

ParameterTypeDescription
accountsOptional comma-separated list of account IDs to filter by
activity_idsOptional comma-separated list of activity IDs to filter by
activity_typesOptional comma-separated list of activity types to filter by (e.g., BUY, SELL, DIVIDEND)
asset_classesOptional comma-separated list of asset classes to filter by
data_sourceOptional data source to filter by (e.g. 'YAHOO', 'COINGECKO')
symbolOptional symbol/ticker to filter by
tagsOptional comma-separated list of tags to filter by

import_transactions Import Transactions

Import transactions into your portfolio. This is a write operation. Imports a batch of transactions (buy/sell orders) into your Ghostfolio portfolio. This is useful for bulk importing historical data or transactions from other platforms.

ParameterTypeDescription
data *objectTransaction data in the format expected by Ghostfolio API. Should contain an 'activities' list. Each activity must have: 'currency', 'dataSource', 'date' (ISO-8601, e.g. 2021-09-15T00:00:00.000Z), 'qu…

get_dividends_for_import Get Dividends For Import

Fetch historical dividend data formatted for import for a specific symbol.

ParameterTypeDescription
data_source *stringData source for the symbol (e.g. 'YAHOO', 'COINGECKO', 'MANUAL')
symbol *stringSymbol/ticker of the asset to get dividends for

get_market_data_for_asset Get Market Data For Asset

Get market data for a specific asset. Retrieves current market data for a specific symbol including price, volume, market cap, and other relevant market information.

ParameterTypeDescription
data_source *stringData source for the symbol (e.g., 'YAHOO', 'COINGECKO', 'MANUAL')
symbol *stringSymbol/ticker of the asset (e.g., 'AAPL', 'BTC-USD')

add_market_data_points Add Market Data Points

Add one or more market data points for a specific asset. Posts to the market-data endpoint for the given data source and symbol. Same (symbol, date) overwrites the existing point; passing the same input twice yields the same end state.

ParameterTypeDescription
data_source *stringData source for the symbol. Typically 'MANUAL' — Ghostfolio rejects market-data writes for auto-fetched sources like 'YAHOO' or 'COINGECKO'
market_data *arrayList of market data points. Each entry must include 'date' (ISO 8601, e.g. '2026-04-30T00:00:00.000Z') and 'marketPrice' (numeric value of the asset at that date)
symbol *stringSymbol/ticker of the asset (e.g., 'TRUE-UNLISTED', 'PILLAR3A-FINPENSION-X')

get_portfolio_details Get Portfolio Details

Get comprehensive portfolio details including accounts, positions, and summary. Retrieves a complete overview of your portfolio including account information, current positions, performance summary, and portfolio metrics.

get_dividends Get Dividends

Get dividend data grouped by time period showing dividend payments and yield. Retrieves dividend income data grouped by the specified time period, showing dividend payments, yield, and income patterns over time.

ParameterTypeDescription
date_rangestringTime range for dividend data. Options: 1d, 1w, 1m, 3m, 6m, 1y, 2y, 5y, max
group_bystringGrouping period for dividend data. Options: day, week, month, quarter, year

get_portfolio_holdings Get Portfolio Holdings

Get portfolio holdings and positions including allocations and asset breakdowns. Retrieves current portfolio holdings including positions, allocations, and asset breakdowns for the specified time period.

ParameterTypeDescription
date_rangestringTime range for holdings data. Options: 1d, 1w, 1m, 3m, 6m, 1y, 2y, 5y, max

get_investments Get Investments

Get investment data grouped by time period showing cash flows and contributions. Retrieves investment activity data grouped by the specified time period, showing cash flows, contributions, and investment patterns over time.

ParameterTypeDescription
date_rangestringTime range for investment data. Options: 1d, 1w, 1m, 3m, 6m, 1y, 2y, 5y, max
group_bystringGrouping period for investment data. Options: day, week, month, quarter, year

get_portfolio_performance Get Portfolio Performance

Get portfolio performance data including returns, benchmarks, and performance metrics. Retrieves comprehensive performance metrics for your portfolio including returns, benchmarks, and performance comparisons over the specified time period.

ParameterTypeDescription
date_rangestringTime range for performance data. Options: 1d, 1w, 1m, 3m, 6m, 1y, 2y, 5y, max

get_position Get Position

Get position details for a specific symbol from a data source. Retrieves detailed information about a specific position including current value, quantity, performance, and market data.

ParameterTypeDescription
data_source *stringData source for the symbol (e.g., 'YAHOO', 'COINGECKO', 'MANUAL')
symbol *stringSymbol/ticker of the asset (e.g., 'AAPL', 'BTC-USD')

get_symbol_data Get Symbol Data

Get symbol data for a specific asset from a data source. Retrieves detailed information about a specific symbol including current price, market data, and asset information.

ParameterTypeDescription
data_source *stringData source for the symbol (e.g., 'YAHOO', 'COINGECKO', 'MANUAL')
symbol *stringSymbol/ticker of the asset (e.g., 'AAPL', 'BTC')

get_historical_data Get Historical Data

Get historical data for a specific symbol on a specific date. Retrieves historical market data for a symbol on a specific date, including price and volume information.

ParameterTypeDescription
data_source *stringData source for the symbol (e.g., 'YAHOO', 'COINGECKO', 'MANUAL')
date *stringDate in YYYY-MM-DD format for historical data
symbol *stringSymbol/ticker of the asset (e.g., 'AAPL', 'BTC-USD')

lookup_symbols Lookup Symbols

Search for symbols using a query string. Search for financial symbols, stocks, ETFs, and other assets using a text query. Optionally include market indices in the results.

ParameterTypeDescription
query *stringSearch query for symbol lookup. Can be company name, ticker symbol, or partial match
include_indicesbooleanInclude market indices in search results

get_health Get Health

Get system health status. Retrieves the health status of the Ghostfolio backend service. This is useful to verify if the server is up and running correctly.

get_platforms Get Platforms

Get available platforms. Retrieves a list of all available platforms (brokers, exchanges, etc.) that can be used when tracking accounts or transactions.

get_user_info Get User Info

Get user information and settings. Retrieves information about the current user including settings, preferences, and account details.

get_watchlist Get Watchlist

Get all items in the user's watchlist. Retrieves list of all watchlisted symbols.

add_to_watchlist Add To Watchlist

Add a symbol to the user's watchlist.

ParameterTypeDescription
data_source *stringData source for the symbol (e.g. 'YAHOO', 'COINGECKO', 'MANUAL')
symbol *stringSymbol/ticker of the asset to add to the watchlist

remove_from_watchlist Remove From Watchlist

Remove a symbol from the user's watchlist.

ParameterTypeDescription
data_source *stringData source for the symbol (e.g. 'YAHOO', 'COINGECKO', 'MANUAL')
symbol *stringSymbol/ticker of the asset to remove from the watchlist