# List batches

Launch stage: Beta

`GET /api/2.0/ai-functions/batches`

Lists the batches that the caller created in this workspace.

API scopes: ai-functions

## Query parameters

- `page_size` (int32, optional)
  Maximum number of batches to return in one page.
- `page_token` (string, optional)
  A page token from a previous call to list batches. Omit it to get the first page.

## Returns

Returns a list of Batch objects.

## Response

```json
{
  "batches": [
    {
      "name": "string",
      "endpoint": "string",
      "input_ref": "string",
      "params": {},
      "output_ref": "string",
      "status": "PENDING",
      "create_time": "string",
      "request_counts": {},
      "percent_complete": 0
    }
  ],
  "next_page_token": "string"
}
```

