Skip to main content
GET
/
portfolios
Get all portfolios for the signed-in user
curl --request GET \
  --url https://{host}/portfolios \
  --header 'Authorization: Bearer <token>' \
  --header 'x-user-id: <x-user-id>'
[
  {
    "id": "64f0c51e7fb3fc001234abcd",
    "currency": "EUR",
    "holdings": [
      {
        "isin": "US0378331005",
        "assetCommonId": "equities_apple",
        "quantity": 12.5
      },
      {
        "isin": "EU0009658145",
        "assetCommonId": "etf_vanguard_snp500",
        "quantity": 8
      }
    ],
    "targetAllocation": [
      {
        "assetCommonId": "equities_apple",
        "percentage": 40
      },
      {
        "assetCommonId": "etf_vanguard_snp500",
        "percentage": 60
      }
    ],
    "createdAt": "2024-03-01T10:00:00.000Z",
    "updatedAt": "2024-07-10T12:00:00.000Z"
  }
]

Documentation Index

Fetch the complete documentation index at: https://docs.wealthyhood.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Auth0-issued access token that includes the scopes listed for the route.

Headers

x-user-id
string
required

MongoDB identifier of the user whose portfolio is being queried.

Pattern: ^[a-f0-9]{24}$

Response

Array of user portfolios with holdings and target allocation.

id
string
required

Portfolio unique identifier.

currency
string
required

ISO currency code for the portfolio (e.g. EUR, GBP, USD).

holdings
object[]
required

Array of holdings with asset details and quantities.

targetAllocation
object[]
required

Target allocation by asset. Weights are persisted with the portfolio. May be an empty array when unset.

createdAt
string<date-time>
required

Portfolio creation timestamp.

updatedAt
string<date-time>
required

Last update timestamp.