# List a company's history

`GET /v1/companies/{record_id}/history`

Required scope: `companies:read`

Every value each field has had, newest first, with its source (`manual`, `api`, `import`, `ai`, …) and who set it. `field` and `source` narrow it. Paged with `limit` (at most 200) and `cursor`.

## Path parameters

- `record_id` (string, required)

## Query parameters

- `field` (string or null, optional)
- `source` (string or null, optional)
- `limit` (integer, optional) Default: `50`.
- `cursor` (string or null, optional)

## Responses

- `200`: Successful Response
- `400`: The request is not valid.
- `401`: Not signed in, or the credentials are not valid.
- `402`: The balance is too low.
- `403`: Not allowed to do this.
- `404`: Not found.
- `409`: Conflicts with the current state.
- `413`: The request body is too large.
- `415`: The content type is not supported.
- `422`: A value in the request is not valid.
- `429`: Too many requests. Wait for `Retry-After` seconds.
- `500`: Something went wrong on our side.
- `502`: A service Valeron depends on refused the request.
- `503`: A service Valeron depends on is unavailable.

## Examples

### Request

```bash title="cURL"
curl "https://api.valeron.io/v1/companies/co_01JJYQZGBG/history?limit=50" \
  -H "Authorization: Bearer $VALERON_API_KEY"
```

```js title="JavaScript"
const response = await fetch("https://api.valeron.io/v1/companies/co_01JJYQZGBG/history?limit=50", {
  method: "GET",
  headers: {
    Authorization: `Bearer ${process.env.VALERON_API_KEY}`,
  },
});
if (!response.ok) throw new Error(`Valeron returned ${response.status}`);
const data = await response.json();
```

```python title="Python"
import os
import requests

response = requests.get(
    "https://api.valeron.io/v1/companies/co_01JJYQZGBG/history",
    headers={"Authorization": f"Bearer {os.environ['VALERON_API_KEY']}"},
    params={
        "limit": 50,
    },
)
response.raise_for_status()
data = response.json()
```

### Response 200

```json
{
  "data": [
    {
      "actor": {
        "id": "co_01JPDT9JQF",
        "name": "Jordan Rivera"
      },
      "field": "example",
      "id": "co_01JPDT9JQF",
      "label": "Example",
      "old_value": {
        "amount": 2400000,
        "currency": "USD"
      },
      "origin": {
        "ai_run_id": "co_01J130041N",
        "approval_id": "apr_01JF8N4TDJ",
        "automation_id": "aut_01J2VCPWXA",
        "event": "example",
        "external_id": "co_01JW0GTC1C",
        "import_id": "imp_01J0W1CQFN",
        "merge_id": "mrg_01J97JCXMN",
        "merged_from": "example",
        "message_id": "msg_01J31EX3KK",
        "object": "example",
        "payment_id": "pay_01J5M1MJA8",
        "provider": "example",
        "quote": "We need this live before the end of the quarter.",
        "recording_id": "rec_01JR70S5VT",
        "row": 1,
        "run_id": "run_01JKBHGW4W"
      },
      "replaced_at": "2026-12-03T14:30:00Z",
      "seen_at": "2026-12-03T14:30:00Z",
      "source": {
        "label": "Example",
        "value": "example"
      },
      "value": {
        "amount": 2400000,
        "currency": "USD"
      }
    }
  ],
  "has_more": false,
  "next_cursor": "eyJ1cGRhdGVkX2F0IjoiMjAyNi0xMi0wM1QxNDozMDowMFoifQ"
}
```

### Response 401

```json
{
  "error": null
}
```

### Response 402

```json
{
  "error": null
}
```

### Response 403

```json
{
  "error": null
}
```

### Response 404

```json
{
  "error": null
}
```
