# list_products

`tools/call` · `POST /agent/v1/products:list`

List the workspace's products, sorted by name. Returns products, each with its deployments to environments that are not archived. Archived products are left out unless archived says otherwise. Needs read access.

- Area: Catalog
- Needs the read grant. Read-only. Idempotent.

## Inputs

- `archived` (string, one of: `exclude`, `include`, `only`): Which products to list: exclude (the default) leaves archived ones out, include adds them, only lists just them.

## Request

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "list_products",
    "arguments": {
      "archived": "exclude"
    }
  }
}
```

## HTTP request

The same call over the agent HTTP API, with an agent OAuth access token:

```bash
curl -X POST https://api.qa.clankership.net/agent/v1/products:list \
  -H "Authorization: Bearer $CLANKER_AGENT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "archived": "exclude"
  }'
```
