Skip to content

What each portfolio owns beyond cash, with cost base and value

GET
/v1/accounts/{id}/positions
curl "https://api.staging.idealx.com/v1/accounts/acc_01937c4e8a2b7d1f9e0c3b5a6d7e8f90/positions" \
-H "Authorization: Bearer $IDEALX_API_KEY"
id
required
string

OK

Media typeapplication/json
object
positions
required
Array<object>
object
portfolioId
required
string
investment
required
object
id
required
string
symbol
required
string
name
required
string
assetClass
required
string
market
required
string
currency
required
string
description
required
string
quantityDecimals
required
number
priceDecimals
required

Most decimals its prices carry (four, more for coins below a cent)

number
securityType
required

Common, preferred, etf, fund, adr, warrant, bond, index, crypto…

string | null
logo
required

Its logo, a path on this API (an image)

string
tradable
required

On offer now: an active, tradable listing with a price (always true in lists)

boolean
accent
required

Its logo’s colour (#rrggbb) for washes, lines and borders, never text; null without one

string | null
priceUsd
required

Digital assets: the last price in US dollars, shown beside the price in the account’s currency; null for others

string | null
quote
required

Prices in the investment’s currency; bonds per 100 of face value

object
bid
required
string
ask
required
string
last
required
string
previousClose
required
string | null
asOf
required

When the price is from

string
freshness
required

Live: minutes old; delayed: the usual 15–20 minute delay while the exchange trades; close: the exchange is shut or the price is from before today’s open

string
Allowed values: live delayed close
bond
required
object
couponRate
required
string
couponsPerYear
required
number
maturityDate
required
string
accruedPer100
required

Accrued interest today per 100 of face value

string
term
required

Yield: rate a year, length and smallest amount

object
rate
required
string
termDays
required
number
minAmount
required
string
quantity
required
string
quantityInOrders
required
string
costBase
required
object
amount
required
string
currency
required
string
value
required
object
amount
required
string
currency
required
string
gain
required
object
amount
required
string
currency
required
string
valueInAccountCurrency
required
object
amount
required
string
currency
required
string
gainInAccountCurrency
required
object
amount
required
string
currency
required
string

Example

{
"positions": [
{
"investment": {
"accent": "#f7931a",
"quote": {
"freshness": "live"
},
"bond": {
"couponRate": "4.50"
},
"term": {
"rate": "4.60"
}
},
"costBase": {
"amount": "1250.00",
"currency": "AUD"
},
"value": {
"amount": "1250.00",
"currency": "AUD"
},
"gain": {
"amount": "1250.00",
"currency": "AUD"
},
"valueInAccountCurrency": {
"amount": "1250.00",
"currency": "AUD"
},
"gainInAccountCurrency": {
"amount": "1250.00",
"currency": "AUD"
}
}
]
}