Account Endpoints
/account/change-account
Users can switch between multiple accounts within a single app using this endpoint.
Accounts available
Provides a list of accounts available for the current user.
GET /account/change-account
Returns a select list of accounts available.
{
"success": true,
"message": "",
"data": {
"accounts": {
"acc_1234567890": "Alpha Corp.",
"acc_2234567890": "Beta Inc."
},
"current": "acc_1234567890"
}
}
Change account
Submit the account_id
to update the current session.
POST /account/change-account
{
"account_id": "acc_1234567890"
}
Returns an updated /app/session.
{
"success": true,
"message": "",
"data": {
...
"account": {
"id": "acc_1234567890",
...
},
"acccess": {
...
},
...
}
}