# get_video_from_path

> **Function** in `deepagents_cli`

📖 [View in docs](https://reference.langchain.com/python/deepagents-cli/media_utils/get_video_from_path)

Read and encode a video file from disk.

## Signature

```python
get_video_from_path(
    path: pathlib.Path,
) -> VideoData | None
```

## Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `path` | `pathlib.Path` | Yes | Path to the video file. |

## Returns

`VideoData | None`

`VideoData` when the file is a valid video, otherwise `None`.

---

[View source on GitHub](https://github.com/langchain-ai/deepagents/blob/a9e6e4f7ad7fe161dd9affc3d74bb19784aca70b/libs/cli/deepagents_cli/media_utils.py#L201)