# Retrieve account

`account_get`

Who is asking and every workspace they can open. For a person it also joins any workspace they were invited to.

Needs the scope: `account:read`

## Returns

The answer comes back under `structuredContent`, with the same JSON as text in `content`. A call the API refuses comes back with `isError` set, and the code and the message under `structuredContent.error`. [MCP](https://opensend.sh/docs/mcp) shows how to connect a client.

- `object` ("account"): Always `account`.
- `kind` (string): How the request was signed: `session` for a signed-in person, `key` for an API key. One of: `session`, `key`, `demo`.
- `user` (object | null): The signed-in person, or `null` when an API key is asking.
- `user.id` (string): The id of the person.
- `user.name` (string): The name of the person.
- `user.email` (string): The address of the person.
- `user.image` (string | null): The address of their picture, or `null`.
- `workspaces` (object[]): The workspaces this credential can act in.
- `workspaces[].id` (string): The id of the workspace.
- `workspaces[].name` (string): The name of the workspace.
- `workspaces[].role` (string | null): The role of the person there, or `null` for an API key. One of: `owner`, `admin`, `member`, `viewer`.
- `workspaces[].current` (boolean): Whether this is the workspace the request acts in.

## Example

MCP:

```json
{
  "name": "account_get",
  "arguments": {}
}
```

Answer, under structuredContent:

```json
{
  "object": "account",
  "kind": "key",
  "user": null,
  "workspaces": [
    {
      "id": "ws_demo",
      "name": "Acme Mail",
      "role": null,
      "current": true
    }
  ]
}
```
