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

# Model History

> Lists the overall history of models.

## Endpoint

`GET https://gateway.orkeia.ai/ai-models/history`

## Headers

Requires header `authorization:  <your_token>`.

```http theme={null}
authorization:  <your_token>
Content-Type: application/json
```

## Query string

| Parameter   | Type       | Required | Description                         | Example      |
| ----------- | ---------- | -------- | ----------------------------------- | ------------ |
| `last`      | `string`   | No       | Cursor/offset of the last page read | `"hist_010"` |
| `limit`     | `string`   | No       | Amount per page                     | `"20"`       |
| `field`     | `string`   | No       | Field for sorting                   | `"date"`     |
| `direction` | `asc/desc` | No       | Sorting direction                   | `"desc"`     |

## Request Body

```json theme={null}
{
  "environment": {
    "company": "acme-inc",
    "sector": "engineering"
  }
}
```

## Response (200)

```json theme={null}
{
"status": "ok", 
"data": {
  "items": [
    {
      "id": "hist_001",
      "responsible": "System",
      "responsibleId": "system",
      "action": "created ai model",
      "type": "neutral",
      "date": "2025-08-22T18:32:45.000Z",
      "versionControl": "v1.0.0"
    }
  ],
  "next": "hist_010"
}
```

## Error Codes

### 500 — Server Error

```json theme={null}
{
  "status": "ERROR",
  "code": "server/error",
  "data": null
}
```

### 400 — Client Error

```json theme={null}
{
  "status": "ERROR",
  "code": "client/error",
  "data": null
}
```
