> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.athenaintel.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.athenaintel.com/_mcp/server.

# Read Workspace Presence Roster

POST https://api.athenaintel.com/api/v0/workspaces/{workspace_id}/presence/roster
Content-Type: application/json

Admin only, and only for a signed-in person: call with the viewing user's own session token, which an app served from a computer receives for its viewer when that viewer created the computer. An API key, a personal token, a computer-asset sandbox credential and the scoped credential such an app receives for any other viewer are refused. Read one page of who is online in a workspace, active first and then by name, each with the places of theirs the caller may open: a document the caller may not open is absent, or shown only as a project that contains it. Names, emails and avatars come from the member directory; a person who appears offline is absent, and one set Away is listed with no places. The same answer as the People page in Athena. Requires the presence roster to be enabled for the deployment and opted in for the workspace. Poll it; a few seconds apart is enough.

Reference: https://docs.athenaintel.com/api-reference/workspaces/get-presence-roster

## Authentication

- `X-API-KEY` header (required) — API Key authentication via header

## Request

### Path parameters

- `workspace_id` (string, required) — The workspace whose presence feed to read.

### Body (application/json)

This endpoint expects a PresenceRosterRequestIn.

- `limit` (integer, optional, default: 100) — People per page. A value above 100 is served as 100, one below 1 as 1; the answer says what was served.
- `offset` (integer, optional, default: 0) — People to skip. A negative value is served as 0.
- `search` (string, optional, nullable) — Keep only people whose name contains this, whatever its case.

## Response

### 200

Successful Response

- `available` (boolean, required) — False only while Athena has no fresh presence data for the workspace yet (it starts observing a workspace when someone asks). people is then empty; ask again in a few seconds.
- `limit` (integer, required) — People per page, as served.
- `offset` (integer, required) — People skipped, as served.
- `total_online` (integer, required) — People online that match search, across every page. Agent runs are not counted.
- `people` (list of PresenceRosterPersonOut, optional) — Active first, then by name. The agent runs the caller may see come with the last page, outside limit and total_online.

## Errors

### 403 Forbidden Error

The caller may not read this roster: not a signed-in person (an API key, a personal token or a credential held by a computer), not an admin, or the roster is not available to them in this workspace.

- `any`

### 422 Unprocessable Entity Error

Validation Error

- `detail` (list of ValidationError, optional)

### 503 Service Unavailable Error

The roster could not be read just now; ask again.

- `any`

## Types

### PresenceRosterPersonOut

- `followable` (boolean, required) — Whether the caller may follow this person in Athena.
- `is_viewer` (boolean, required) — Whether this entry is the caller.
- `key` (string, required) — Stable key of this entry within the roster.
- `kind` (enum, required) — A person or an agent run.
  - Allowed values: `human`, `agent`
- `name` (string, required) — Display name, from the member directory for a person.
- `state` (enum, required) — active or idle as observed; away when the person set themselves Away, in which case contexts is empty.
  - Allowed values: `active`, `idle`, `away`
- `agent_initiator` (PresenceRosterAgentInitiatorOut, optional, nullable) — For an agent run, the person it works for, when a member.
- `avatar_url` (string, optional, nullable) — Avatar URL.
- `contexts` (list of PresenceRosterContextOut, optional) — The places of theirs the caller may see. May be empty.
- `email` (string, optional, nullable) — Email; null for an agent.
- `user_id` (string, optional, nullable) — The person's user id; null for an agent run.

### ValidationError

- `loc` (list of ValidationErrorLocItems, required)
- `msg` (string, required)
- `type` (string, required)
- `ctx` (ValidationErrorCtx, optional)
- `input` (any, optional)

### PresenceRosterAgentInitiatorOut

- `name` (string, required) — Their display name.
- `user_id` (string, required) — The person an agent run works for.

### PresenceRosterContextOut

One place a person is, as the viewer may see it.

- `coarse` (boolean, required) — True when the viewer may not open where the person is, only a project that contains it: the entry is that project, and says no more about what the person has open or how many.
- `focused` (boolean, required) — Whether this is the place the person is looking at now.
- `guid` (string, required) — The asset id, the chat's thread id, or the project id.
- `type` (enum, required) — asset: a document, sheet or other asset. session: a chat, named by its thread id. project: somewhere in a project (see coarse).
  - Allowed values: `asset`, `session`, `project`
- `anchor` (map from string to any, optional, nullable) — The spot in a form the asset's own editor understands (a sheet and cell, a slide, a block). Opaque to anything else.
- `asset_type` (string, optional, nullable) — Athena asset type, e.g. document, spreadsheet, session, project.
- `location_label` (string, optional, nullable) — Where in it the person is, as its editor names the spot.
- `projects` (list of string, optional) — Ids of the projects containing it that the viewer may open.
- `title` (string, optional, nullable) — Display title.

### ValidationErrorLocItems

- string
- integer

### ValidationErrorCtx

## Examples

**Request**

```json
{
  "limit": 100,
  "offset": 0
}
```

**Response**

```json
{
  "available": true,
  "limit": 100,
  "offset": 0,
  "total_online": 2,
  "people": [
    {
      "followable": true,
      "is_viewer": false,
      "key": "user_5b8e2c1a-9d4f-4e3b-8c7a-6f1e2d3c4b5a",
      "kind": "human",
      "name": "Ada Example",
      "state": "active",
      "contexts": [
        {
          "coarse": false,
          "focused": true,
          "guid": "asset_1f9b6b2e-4c1d-4a0a-9c1e-2b7d1a0f3c44",
          "type": "asset",
          "asset_type": "document",
          "projects": [
            "asset_7c2d1e0f-3a4b-4c5d-8e6f-1a2b3c4d5e6f"
          ],
          "title": "Q3 close runbook"
        }
      ],
      "email": "ada@example.com",
      "user_id": "user_5b8e2c1a-9d4f-4e3b-8c7a-6f1e2d3c4b5a"
    }
  ]
}
```

**SDK Code**

```python
import requests

url = "https://api.athenaintel.com/api/v0/workspaces/workspace_id/presence/roster"

payload = {
    "limit": 100,
    "offset": 0
}
headers = {
    "X-API-KEY": "<apiKey>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api.athenaintel.com/api/v0/workspaces/workspace_id/presence/roster';
const options = {
  method: 'POST',
  headers: {'X-API-KEY': '<apiKey>', 'Content-Type': 'application/json'},
  body: '{"limit":100,"offset":0}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.athenaintel.com/api/v0/workspaces/workspace_id/presence/roster"

	payload := strings.NewReader("{\n  \"limit\": 100,\n  \"offset\": 0\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("X-API-KEY", "<apiKey>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.athenaintel.com/api/v0/workspaces/workspace_id/presence/roster")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<apiKey>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"limit\": 100,\n  \"offset\": 0\n}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.athenaintel.com/api/v0/workspaces/workspace_id/presence/roster")
  .header("X-API-KEY", "<apiKey>")
  .header("Content-Type", "application/json")
  .body("{\n  \"limit\": 100,\n  \"offset\": 0\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.athenaintel.com/api/v0/workspaces/workspace_id/presence/roster', [
  'body' => '{
  "limit": 100,
  "offset": 0
}',
  'headers' => [
    'Content-Type' => 'application/json',
    'X-API-KEY' => '<apiKey>',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.athenaintel.com/api/v0/workspaces/workspace_id/presence/roster");
var request = new RestRequest(Method.POST);
request.AddHeader("X-API-KEY", "<apiKey>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"limit\": 100,\n  \"offset\": 0\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "X-API-KEY": "<apiKey>",
  "Content-Type": "application/json"
]
let parameters = [
  "limit": 100,
  "offset": 0
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.athenaintel.com/api/v0/workspaces/workspace_id/presence/roster")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```