# List activity

URL: https://docs.hanzo.ai/docs/openapi/agent/get-agent-activity

> Serves the org-wide recent-activity feed.

`GET /v1/agent/activity`

> [Agent →](https://docs.hanzo.ai/docs/openapi/agent) · [All API references →](https://docs.hanzo.ai/docs/openapi) · [Get started →](https://docs.hanzo.ai/docs/guides)

|               |                                          |
| ------------- | ---------------------------------------- |
| **Address**   | `https://api.hanzo.ai/v1/agent/activity` |
| **Method**    | `GET`                                    |
| **Operation** | `get_agent_activity`                     |
| **Auth**      | `Authorization: Bearer $HANZO_API_KEY`   |

Serves the org-wide recent-activity feed. Events are REAL: each
recorded run is an invoked (ok) or failed (error) event; each agent's own
create/update timestamps are created/updated events. Merged, newest first,
capped. Nothing is invented — an org with no agents and no runs gets \[].

## Request

`GET /v1/agent/activity` takes no parameters and no body — the credential is the whole request.

## Response

| Status    | Body               | Meaning |
| --------- | ------------------ | ------- |
| `200`     | agent.activityFeed | ok      |
| `default` | problem-details    | refused |

`200` body — 6 fields.

| Field                | In   | Type                  | Always | Description                                                                                                                                                                                                                                         |
| -------------------- | ---- | --------------------- | ------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `activity`           | body | agent.activityView\[] | —      | Activity is the merged run/create/update events, newest first, capped at 50.                                                                                                                                                                        |
| `activity[].agent`   | body | string                | —      | agent name                                                                                                                                                                                                                                          |
| `activity[].at`      | body | string                | —      | RFC3339 UTC                                                                                                                                                                                                                                         |
| `activity[].id`      | body | string                | —      | ID identifies the event, and its shape says which kind it is: a run event carries the run's own id, while an agent event is the agent id suffixed ":created" or ":updated".                                                                         |
| `activity[].kind`    | body | string                | —      | invoked\|failed\|created\|updated (from real events)                                                                                                                                                                                                |
| `activity[].message` | body | string                | —      | Message is the line to render, already bounded: "Invoked \<model>" for a run that worked, the run's own error truncated to 200 characters for one that did not (or "Run failed" when it said nothing), and a fixed phrase for the two agent events. |

Failure carries the platform error shape — see [Errors](https://docs.hanzo.ai/docs/errors).

## Examples

**CLI**

```bash
hanzo agent activity
```

**SDK**

**.ts**

```ts
import { Configuration, AgentApi } from 'hanzoai';

const api = new AgentApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.getAgentActivity();
```

**.py**

```python
from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import AgentApi

client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = AgentApi(client).get_agent_activity()
```

**.go**

```go
cfg := hanzoai.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := hanzoai.NewAPIClient(cfg)

resp, _, err := client.AgentAPI.GetAgentActivity(context.Background()).Execute()
if err != nil {
	return err
}
```

**.rs**

```rust
use hanzo_client::apis::{configuration::Configuration, agent_api};

let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();

let result = agent_api::get_agent_activity(&cfg, Default::default()).await?;
```

**.java**

```java
import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.AgentApi;

ApiClient client = new ApiClient();
client.setBearerToken(System.getenv("HANZO_API_KEY"));

var result = new AgentApi(client).getAgentActivity();
```

**HTTP**

```bash
curl https://api.hanzo.ai/v1/agent/activity \
  -H "Authorization: Bearer $HANZO_API_KEY"
```

**MCP**

Tool `agent`, op `get_agent_activity` — POST the JSON-RPC envelope to `https://api.hanzo.ai/v1/mcp`.

```bash
curl -X POST https://api.hanzo.ai/v1/mcp \
  -H "Authorization: Bearer $HANZO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
       "jsonrpc": "2.0",
       "id": 1,
       "method": "tools/call",
       "params": {
         "name": "agent",
         "arguments": {
           "op": "get_agent_activity",
           "input": {}
         }
       }
     }'
```

---

[Agent API](https://docs.hanzo.ai/docs/openapi/agent) · [All Hanzo APIs](https://docs.hanzo.ai/docs/openapi) · [Interactive reference](https://docs.hanzo.ai/docs/openapi/reference)
