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

# Error Log • Rust AI Agent SDK

> ErrorLog: Error log entry

# ErrorLog

> Defined in the [**Display Types**](../modules/display_types) module.

<Badge color="orange">Rust AI Agent SDK</Badge>

Error log entry

## Fields

| Name         | Type                    | Description         |
| ------------ | ----------------------- | ------------------- |
| `message`    | `String`                | Error message       |
| `error_type` | `String`                | Error type/category |
| `timestamp`  | `std::time::SystemTime` | Timestamp           |
| `context`    | `HashMap&lt;String`     | Additional context  |

## Methods

### `new`

```rust theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
fn new(message: impl Into<String>, error_type: impl Into<String>) -> Self
```

Create a new error log

**Parameters:**

| Name         | Type                      |
| ------------ | ------------------------- |
| `message`    | `impl Into&lt;String&gt;` |
| `error_type` | `impl Into&lt;String&gt;` |

### `with_context`

```rust theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
fn with_context(mut self, key: impl Into<String>, value: impl Into<String>) -> Self
```

Add context

**Parameters:**

| Name    | Type                      |
| ------- | ------------------------- |
| `key`   | `impl Into&lt;String&gt;` |
| `value` | `impl Into&lt;String&gt;` |

## Source

<Card title="View on GitHub" icon="github" href="https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai-rust/praisonai/src/parity/display_types.rs#L38">
  `praisonai/src/parity/display_types.rs` at line 38
</Card>

***

## Related Documentation

<CardGroup cols={2}>
  <Card title="Rust Error Handling" icon="triangle-exclamation" href="/docs/rust/error-handling" />

  <Card title="Rust Retry" icon="rotate-right" href="/docs/rust/retry" />

  <Card title="Rust Failover" icon="shield" href="/docs/rust/failover" />
</CardGroup>
