> ## Documentation Index
> Fetch the complete documentation index at: https://docs.usehenry.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Exports

> The workspace archive layout, audit log CSV columns, and usage CSV grains.

## Workspace data export

Admins request an archive from **Settings → Team settings → Export workspace data**. Henry builds it in the background and emails you when it is ready. The email is a notification only; download from the same settings page, which re-checks that you are still an admin and mints a 5-minute link per click. Archives are available for **7 days**.

### Archive layout

A `.zip` containing:

```
manifest.json
tables/<table_name>.ndjson
attachments/<bucket>/<object-path>
```

* `tables/` holds one file per exported table, one JSON object per line.
* `attachments/` holds file bytes from avatars, Slack attachments, connector logos, project files, and Agent Browser screenshots.
* `manifest.json` lists every table with its row count, every skipped table with the reason, and notes.

### What is stripped

* Secret columns (encryption keys, bot tokens, connection credentials, email reply tokens) are removed. Tables that are pure secrets are omitted and listed under `skipped`.
* The workspace settings row is included with nested secrets removed, such as a bring-your-own model key.
* Embeddings are excluded; they are derivable from the source content.
* Transient tables (pre-auth OAuth state, sandbox run tokens, tool-result overflow cache, SSO provider configuration) are omitted.

<Warning>
  Some payload columns contain your team's own input, such as tool call arguments and pending action payloads, which may include text a user pasted. Treat the archive as sensitive.
</Warning>

## Audit log export

<Note>
  Enterprise workspaces, owners and admins.
</Note>

```
GET https://app.usehenry.ai/api/audit/export?workspaceId=<uuid>
```

Cookie-authenticated (open it while signed in). Returns `text/csv`, filename `henry-audit-<workspace-prefix>-<date>.csv`.

### Query parameters

| Parameter     | Values                                                                           |
| ------------- | -------------------------------------------------------------------------------- |
| `workspaceId` | Required. Your workspace id, shown under **Settings → Team settings → General**. |
| `kind`        | `tool_call` or `settings`                                                        |
| `connector`   | Connector type                                                                   |
| `tool`        | Tool key                                                                         |
| `status`      | Outcome                                                                          |
| `user`        | User id (UUID)                                                                   |
| `from`, `to`  | ISO 8601 timestamps                                                              |

Invalid values return `400 {"error":"invalid filter: ..."}`.

### Columns

```
created_at,kind,actor,source,status,tool_name,tool_key,connector_type,connector_ref,result_summary,model_id,duration_ms,args,action,details
```

* `kind` is `tool_call` or `settings`. Settings rows fill `action` and `details` and leave the tool columns blank.
* Unattended runs show the actor as `Henry (unattended)`.
* `args` is redacted recursively: any key matching password, secret, token, access token, refresh token, API key, authorization, client secret, or private key renders as `[redacted]`.

Exports are capped at **10,000 rows**. A truncated export carries the header `x-audit-truncated: true`; narrow the filters and export again.

## Usage export

Admins download usage CSVs from **Usage → Reports**, or directly:

```
GET https://app.usehenry.ai/api/usage/export?grain=activity|tasks|users&range=<period>&tz=<timezone>
```

| Grain      | Row               | Columns include                                                         |
| ---------- | ----------------- | ----------------------------------------------------------------------- |
| `activity` | one run or thread | `kind,name,userKey,credits,cost,at`                                     |
| `tasks`    | one task          | `taskId,name,isSystem,status,frequency,runs,avgCostPerRun,lastActivity` |
| `users`    | one member        | `userId,credits,cost,threads,taskRuns,lastActivity`                     |

Exports carry both credits and model cost. A very large activity export is truncated and named accordingly.
