Skip to content

Account Trends Endpoint

GET
/api/v1/charts/account-trends
curl --request GET \
--url https://example.com/api/v1/charts/account-trends

Per-account balance trends over time (converted to base currency).

from
Any of:
string format: date
to
Any of:
string format: date

Successful Response

Media typeapplication/json
Response Account Trends Endpoint Api V1 Charts Account Trends Get
Array<object>
AccountTrendSeries

One account’s trend data with metadata for legend/colors.

data[].balance is always the account’s raw, unsigned converted balance – this endpoint never applies a sign flip itself. A caller that needs a net-worth-style signed value (e.g. a stacked chart summing multiple accounts, or a per-account display that should read negative for a liability) negates it itself using is_liability, matching chart_service.get_net_worth()’s sign convention.

object
account_id
required
Account Id
integer
name
required
Name
string
short_name
required
Any of:
string
institution
required
Any of:
string
color
required
Any of:
string
is_liability
required
Is Liability
boolean
data
required
Data
Array<object>
AccountTrendPoint

Single data point in an account trend series.

object
date
required
Date
string
balance
required
Balance
string

Example generated

[
{
"account_id": 1,
"name": "example",
"short_name": "example",
"institution": "example",
"color": "example",
"is_liability": true,
"data": [
{
"date": "example",
"balance": "example"
}
]
}
]

Validation Error

Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationError
object
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object

Example generated

{
"detail": [
{
"loc": [
"example"
],
"msg": "example",
"type": "example",
"input": "example",
"ctx": {}
}
]
}