Session
2 operations.
GET
/v1/me
The signed-in person, their accounts, and the account this session acts in.
- Operation id
getMe- Who can call it
- A signed-in person, for themselves. Not tied to an account.
- Credentials
- session
Answers
200 The person and their accounts. application/json
| Field | Type | Always sent | Notes |
|---|---|---|---|
person
|
object | yes | |
person.id
|
string | yes | |
person.email
|
string | yes | |
person.name
|
string | yes | |
operator
|
boolean | yes | |
may_create_account
|
boolean | yes | |
support
|
object or null | yes | |
support.id
|
string | yes | |
support.account
|
object | yes | |
support.account.id
|
string | yes | |
support.account.handle
|
string | yes | |
support.account.name
|
string | yes | |
support.account.status
|
string | yes | |
support.ends_at
|
string | yes | Limits: format date-time. |
support.operations
|
array of string | yes | |
active_account_id
|
string or null | yes | |
accounts
|
array of object | yes | |
accounts[]
|
object | yes | |
accounts[].id
|
string | yes | |
accounts[].handle
|
string | yes | |
accounts[].name
|
string | yes | |
accounts[].role
|
string | yes |
Values:
owner
,
admin
,
member
.
|
deletions
|
array of object | yes | |
deletions[]
|
object | yes | |
deletions[].account
|
object | yes | |
deletions[].account.id
|
string | yes | |
deletions[].account.handle
|
string | yes | |
deletions[].account.name
|
string | yes | |
deletions[].account.status
|
string | yes | |
deletions[].deletion_requested_at
|
string or null | yes | Limits: format date-time. |
deletions[].purge_after
|
string or null | yes | Limits: format date-time. |
deletions[].purge_started_at
|
string or null | yes | Limits: format date-time. |
Refusals
| Status | Meaning | Codes |
|---|---|---|
| 400 | The request is not valid. |
invalid_request
|
| 401 | Sign in is required. |
unauthenticated
|
| 403 | You are not allowed to do that. |
forbidden
|
| 429 | Too many attempts. |
rate_limited
|
POST
/v1/session/active-account
Chooses which of the person's accounts this session acts in.
- Operation id
setActiveAccount- Who can call it
- A signed-in person, for themselves. Not tied to an account.
- Credentials
- session
Request body application/json, required
| Field | Type | Required | Notes |
|---|---|---|---|
account_id
|
string | yes | Limits: 1 to 64 characters. |
Answers
200 The account this session now acts in, read back from the session. application/json
| Field | Type | Always sent | Notes |
|---|---|---|---|
active_account_id
|
string or null | yes |
Refusals
| Status | Meaning | Codes |
|---|---|---|
| 400 | The body is not valid JSON. The request is not valid. |
invalid_json
,
invalid_request
|
| 401 | Sign in is required. |
unauthenticated
|
| 403 | You are not allowed to do that. |
forbidden
|
| 404 | Nothing was found there. |
not_found
|
| 415 | Send the body as JSON. |
unsupported_media_type
|
| 429 | Too many attempts. |
rate_limited
|