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

# Available Packages

> Python standard-library and third-party packages available inside Opus Code.

An Opus Code task runs your Python in a secure environment that ships with a curated set of packages. You can `import` any of the packages below directly in your code—alongside the [Opus SDK](/opus-sdk/overview)—without installing anything.

<Note>
  The Opus SDK itself (the `Opus` object) is always available inside Opus Code without an import. See the [Opus SDK overview](/opus-sdk/overview) for what it exposes.
</Note>

## Standard Library

These modules ship with Python and are available in every Opus Code task.

| Category              | Packages                                                            |
| --------------------- | ------------------------------------------------------------------- |
| **Data**              | `json`, `csv`, `collections`, `dataclasses`, `enum`, `copy`         |
| **Text**              | `re`, `string`, `html`                                              |
| **Math**              | `math`, `statistics`, `random`, `decimal`, `fractions`              |
| **Time**              | `datetime`, `time`                                                  |
| **Utilities**         | `itertools`, `functools`, `typing`, `uuid`                          |
| **Encoding**          | `hashlib`, `base64`                                                 |
| **Markup & Archives** | `xml`, `zipfile`                                                    |
| **Advanced**          | `abc`, `warnings`, `contextlib`, `concurrent`, `concurrent.futures` |

## Third-Party Packages

These packages are pre-installed and ready to import. Where the import name differs from the package name, both are shown.

| Category             | Packages                                                                                       |
| -------------------- | ---------------------------------------------------------------------------------------------- |
| **HTTP**             | `requests`                                                                                     |
| **Office Documents** | `openpyxl`, `docx` (python-docx), `pptx` (python-pptx)                                         |
| **PDF**              | `PyPDF2`, `pdfplumber`, `fitz` (pymupdf), `reportlab`, `fpdf` (fpdf2), `pdf2docx`, `pdf2image` |
| **Images**           | `PIL` (pillow), `cv2` (opencv-python-headless)                                                 |
| **Utilities**        | `magic` (python-magic), `dateutil` (python-dateutil), `toon_format` (toon-format)              |

<Tip>
  For packages with an import alias, use the import name on the left in your code—for example `import fitz` for pymupdf, or `import cv2` for opencv-python-headless. See [File Formats](/opus-sdk/file-formats) for which formats the SDK reads and writes directly.
</Tip>

## Related

<CardGroup cols={2}>
  <Card title="Opus SDK Overview" icon="cube" href="/opus-sdk/overview">
    Learn what the always-available `Opus` object exposes.
  </Card>

  <Card title="File Formats" icon="file-lines" href="/opus-sdk/file-formats">
    See which file formats the SDK can read and write.
  </Card>

  <Card title="Opus Code" icon="code" href="/tasks/agent/opus-code">
    Write custom Python logic inside a workflow.
  </Card>
</CardGroup>
