# List your API tokens

`GET /v1/workspaces/{workspaceId}/api-tokens`

Your live (not revoked, not expired) tokens for a workspace, newest first.

Needs a signed-in session; API and OAuth tokens get 403.

## Request

```bash
curl "https://api.lydie.co/v1/workspaces/01JCQ3TZ0WJ8K4M2X7T9R6N1PA/api-tokens" \
  -H "Authorization: Bearer $LYDIE_TOKEN"
```

## Path parameters

- `workspaceId` (string, required): (1–64 chars)

## Response

- `tokens` (ApiToken[], required)
  - `id` (string, required): (1–64 chars)
  - `workspaceId` (string, required): (1–64 chars)
  - `name` (string, required)
  - `prefix` (string, required): The secret's first characters, to recognise it.
  - `scopes` (string[], required)
  - `createdAt` (string, required)
  - `lastUsedAt` (string, required, nullable)
  - `expiresAt` (string, required, nullable)

```json
{
  "tokens": [
    {
      "id": "string",
      "workspaceId": "01JCQ3TZ0WJ8K4M2X7T9R6N1PA",
      "name": "Notes",
      "prefix": "string",
      "scopes": [
        "docs:read"
      ],
      "createdAt": "string",
      "lastUsedAt": null,
      "expiresAt": null
    }
  ]
}
```

Errors use the envelope described at https://developers.lydie.co/errors.md.
