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

# autogen.llm_config.LLMConfigEntry

<h2 id="autogen.llm_config.LLMConfigEntry" class="doc doc-heading">
  <code class="doc-symbol doc-symbol-heading doc-symbol-class" />

  <span class="doc doc-object-name doc-class-name">LLMConfigEntry</span>
</h2>

```python theme={null}
LLMConfigEntry(**data: Any)
```

!!! abstract "Usage Documentation"
[Models](/docs/api-reference/autogen/concepts/models)

A base class for creating Pydantic models.<br />

<b>Parameters:</b>

| Name     | Description   |
| -------- | ------------- |
| `**data` | **Type:** Any |

### Class Attributes

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### api\_key

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### api\_type

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### api\_version

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### base\_url

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### default\_headers

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### http\_client

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### max\_tokens

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### model

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### model\_client\_cls

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### model\_config

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### response\_format

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### tags

<br />

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-attribute" />

#### voice

<br />

<br />

### Static Methods

<code class="doc-symbol doc-symbol-heading doc-symbol-method" />

#### check\_base\_url

```python theme={null}
check_base_url(v: Any, info: ValidationInfo) -> Any
```

<b>Parameters:</b>

| Name   | Description                                          |
| ------ | ---------------------------------------------------- |
| `v`    | **Type:** Any                                        |
| `info` | **Type:** pydantic\_core.core\_schema.ValidationInfo |

<br />

### Instance Methods

<code class="doc-symbol doc-symbol-heading doc-symbol-method" />

#### create\_client

```python theme={null}
create_client(self) -> ModelClient
```

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-method" />

#### get

```python theme={null}
get(
    self,
    key: str,
    default: Any | None = None
) -> Any
```

<b>Parameters:</b>

| Name      | Description                                        |
| --------- | -------------------------------------------------- |
| `key`     | **Type:** str                                      |
| `default` | **Type:** Any \| None<br /><br />**Default:** None |

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-method" />

#### items

```python theme={null}
items(self) -> Iterable[tuple[str, Any]]
```

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-method" />

#### keys

```python theme={null}
keys(self) -> Iterable[str]
```

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-method" />

#### model\_dump

```python theme={null}
model_dump(
    self,
    *args: Any,
    exclude_none: bool = True,
    **kwargs: Any
) -> dict[str, Any]
```

!!! abstract "Usage Documentation"
[`model_dump`](/docs/api-reference/autogen/concepts/serialization#modelmodel_dump)

Generate a dictionary representation of the model, optionally specifying which fields to include or exclude.<br />

<b>Parameters:</b>

| Name           | Description                                                                                                   |
| -------------- | ------------------------------------------------------------------------------------------------------------- |
| `*args`        | **Type:** Any                                                                                                 |
| `exclude_none` | Whether to exclude fields that have a value of `None`.<br /><br />**Type:** bool<br /><br />**Default:** True |
| `**kwargs`     | **Type:** Any                                                                                                 |

<b>Returns:</b>

| Type                   | Description                               |
| ---------------------- | ----------------------------------------- |
| dict\[str, typing.Any] | A dictionary representation of the model. |

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-method" />

#### model\_dump\_json

```python theme={null}
model_dump_json(
    self,
    *args: Any,
    exclude_none: bool = True,
    **kwargs: Any
) -> str
```

!!! abstract "Usage Documentation"
[`model_dump_json`](/docs/api-reference/autogen/concepts/serialization#modelmodel_dump_json)

Generates a JSON representation of the model using Pydantic's `to_json` method.<br />

<b>Parameters:</b>

| Name           | Description                                                                                                   |
| -------------- | ------------------------------------------------------------------------------------------------------------- |
| `*args`        | **Type:** Any                                                                                                 |
| `exclude_none` | Whether to exclude fields that have a value of `None`.<br /><br />**Type:** bool<br /><br />**Default:** True |
| `**kwargs`     | **Type:** Any                                                                                                 |

<b>Returns:</b>

| Type | Description                                |
| ---- | ------------------------------------------ |
| str  | A JSON string representation of the model. |

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-method" />

#### serialize\_api\_key

```python theme={null}
serialize_api_key(self, v: SecretStr) -> Any
```

<b>Parameters:</b>

| Name | Description                        |
| ---- | ---------------------------------- |
| `v`  | **Type:** pydantic.types.SecretStr |

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-method" />

#### serialize\_base\_url

```python theme={null}
serialize_base_url(self, v: Any) -> Any
```

<b>Parameters:</b>

| Name | Description   |
| ---- | ------------- |
| `v`  | **Type:** Any |

<br />

<code class="doc-symbol doc-symbol-heading doc-symbol-method" />

#### values

```python theme={null}
values(self) -> Iterable[Any]
```

<br />
