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

# client.agent

## `get`

```python theme={null}
get(agent_id: int) -> Agent
```

Get details of a specific agent.

**Parameters:**

| Name | Type | Description | Default |
| - | - | - | - |
| `agent_id` | `int` | The ID of the agent | *required* |

## `list`

```python theme={null}
list(
    page_number: int = 0, page_size: int = 50
) -> ListAgentsResponse
```

Get a paginated list of agents.

**Parameters:**

| Name | Type | Description | Default |
| - | - | - | - |
| `page_number` | `int` | Page number for pagination (default: 0) | `0` |
| `page_size` | `int` | Number of items per page (default: 50, max: 1000) | `50` |

## `copy`

```python theme={null}
copy(
    agent_id: int,
    name: str,
    target_workspace_id: Optional[int] = None,
    target_folder_id: Optional[int] = None,
) -> Agent
```

Copy an existing agent to create a new agent.

**Parameters:**

| Name | Type | Description | Default |
| - | - | - | - |
| `agent_id` | `int` | The ID of the agent to copy | *required* |
| `name` | `str` | The name for the new copied agent | *required* |
| `target_workspace_id` | `Optional[int]` | The ID of the workspace to copy the agent to (optional) | `None` |
| `target_folder_id` | `Optional[int]` | The ID of the folder to copy the agent to (optional) | `None` |

## `update`

```python theme={null}
update(
    agent_id: int, metadata: Optional[Dict[str, Any]] = None
) -> Agent
```

Update an agent.

Metadata can be an arbitrary key-value pairs where values can be
primitives (str, int, float, bool, None), arrays.

**Parameters:**

| Name | Type | Description | Default |
| - | - | - | - |
| `agent_id` | `int` | The ID of the agent to update | *required* |
| `metadata` | `Optional[Dict[str, Any]]` | Optional dictionary of metadata key-value pairs | `None` |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.