GET /v1/accounts/{id}/portfolio

An account's holdings and cash, as of its latest balance date

cash_balance_cents is derived as balance_cents minus holdings_value_cents. SimpleFIN does not report cash, so the value is an inference, and cash_is_derived is always true. Cash is null when any holding has no value.

Auth. Send the token in the X-Ledger-Token header.

Parameters

NameInTypeRequiredDescription
idpathstringrequired

Responses

StatusMeaningBody
200Portfolio for the accountPortfolio
404Request rejectedError
429Too many requests from this client address. Wait the number of seconds in Retry-After, then try again.Error

Example response

{
  "account_id": "string",
  "name": "string",
  "org_name": "string",
  "currency": "string",
  "as_of": "2026-10-11T00:00:00Z",
  "balance_cents": 0,
  "holdings_value_cents": 0,
  "cash_balance_cents": 0,
  "cash_is_derived": true,
  "holdings": [
    {
      "id": "string",
      "symbol": "string",
      "description": "string",
      "shares": 0,
      "market_value_cents": 0,
      "cost_basis_cents": 0
    }
  ]
}

Code samples

Set KEY to your own token first.

curl

curl \
  -H X-Ledger-Token:$KEY \
  "https://api.sasek.org/ledger/v1/accounts/{id}/portfolio"

JavaScript

const res = await fetch("https://api.sasek.org/ledger/v1/accounts/{id}/portfolio", {
  headers: { "X-Ledger-Token": KEY },
});
const data = await res.json();

Python

import json
import os
import urllib.request

request = urllib.request.Request(
    "https://api.sasek.org/ledger/v1/accounts/{id}/portfolio",
    method="GET",
    headers={
        "X-Ledger-Token": os.environ["KEY"],
    },
)
with urllib.request.urlopen(request) as response:
    print(json.load(response))