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

# Notion

> Set up the Notion resource in Python.

## Dependencies

No additional dependencies - uses `aiohttp` (included).

For credential setup, see the [Notion Setup](/home/setup/notion) guide.

## Configuration

```python theme={null}
import os

from mirage import MountMode, Workspace
from mirage.resource.notion import NotionConfig, NotionResource

config = NotionConfig(api_key=os.environ["NOTION_API_KEY"])
resource = NotionResource(config=config)
ws = Workspace({"/notion/": resource}, mode=MountMode.READ)
```

## Config Reference

| Field      | Required | Description                            |
| ---------- | -------- | -------------------------------------- |
| `api_key`  | Yes      | Notion internal integration secret     |
| `base_url` | No       | API endpoint, defaults to Notion Cloud |
