Gets a list of subaccounts in reverse chronological order up to the provided limit number of subaccounts per call.
Pagination is supported by passing the first subaccount id from a previous call into ending_before to retrieve
the previous page, or the last subaccount id from a previous call into starting_after to retrieve the next page.
/subaccountsAuthorization
string
header
requiredBearer authentication header of the form Bearer <token>, where <token> is your CNaught API key.
limit
integer | null
default: 20
Limits the number of subaccounts returned, default is 20, max is 100
starting_after
string | null
If specified, returns subaccounts created before (earlier than) the subaccount with this id, exclusive (subaccount with this id is not included). Only one of starting_after and ending_before can be specified.
ending_before
string | null
If specified, returns subaccounts created after (later than) the order with this id, exclusive (subaccount with this id is not included). Only one of starting_after and ending_before can be specified.
List of Subaccounts
Show response attributes
data
Subaccount[]
Show child attributes
id
string
Identifier that can be used to retrieve the subaccount details
created_on
string
Timestamp of when the subaccount was created (in UTC)
name
string
Name of the subaccount
string | null
Optional email associated with the subaccount.
default_portfolio_id
string | null
Optional ID of the default portfolio used to fulfilling orders placed for this subaccount. If not specified, the parent account's default portfolio is the default portfolio for the subaccount.
logo_url
string | null
Optional URL for the logo used for this subaccount, if any. This URL is for the logo as stored on CNaught's hosting.
Get List of Subaccounts
curl --request GET \
--url https://api.cnaught.com/v1/subaccounts \
--header 'Authorization: Bearer <token>'{
"data": [
{
"id": "5nubL0NS",
"name": "Marketing Department",
"email": "jane.doe@example.com",
"default_portfolio_id": "mHvNvWbq",
"created_on": "2023-08-01T18:00:00.000000Z"
}
]
}