# validate_ttl

> **Function** in `langsmith`

📖 [View in docs](https://reference.langchain.com/python/langsmith/sandbox/_helpers/validate_ttl)

Validate a TTL value for sandbox create/update.

## Signature

```python
validate_ttl(
    value: Optional[int],
    name: str,
) -> None
```

## Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `value` | `Optional[int]` | Yes | TTL in seconds (None means unset, 0 disables). |
| `name` | `str` | Yes | Parameter name for error messages. |

---

[View source on GitHub](https://github.com/langchain-ai/langsmith-sdk/blob/19dc497a3d89638e4cc35db72ea1c29cad35cbbf/python/langsmith/sandbox/_helpers.py#L71)