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

# App and wiki imports

> Import from Notion, Airtable, Google Sheets, Obsidian vaults, and Confluence.

These sources pull records or pages from note-taking apps, spreadsheets, and wikis. Every source also accepts the [common flags](https://docs.kiwifs.com/import/overview.md#common-flags).

## Notion

Import the rows of a Notion database. Each row's properties become frontmatter. The page body is not imported.

**1. Create an integration**

Create a [Notion integration](https://www.notion.so/my-integrations) and copy its secret.

**2. Share the database**

Open the database in Notion and add the integration as a connection.

**3. Run the import**

```bash Terminal theme={null}
export NOTION_API_KEY="ntn_..."
kiwifs import --from notion --database-id 1a2b3c4d5e6f --root ./knowledge
```

| Flag | Description |
| - | - |
| `--database-id` | Notion database ID (required) |

The default prefix is `notion`. A row's `title` or `Name` property becomes its file name.

## Airtable

Import the records of one Airtable table.

```bash Terminal theme={null}
export AIRTABLE_API_KEY="pat..."
kiwifs import --from airtable --base-id appXXXX --table-id tblYYYY --root ./knowledge
```

| Flag | Description |
| - | - |
| `--base-id` | Airtable base ID (required) |
| `--table-id` | Airtable table ID (required) |

Create the token on the [personal access tokens](https://airtable.com/create/tokens) page. A record's `Name` field becomes its file name.

### Notion and Airtable over REST and MCP

Both sources work with `POST /api/kiwi/import` and the `kiwi_import` MCP tool. Over REST, pass the token in `api_key` or set the environment variable on the server.

> [tab] REST
>
> ```bash Terminal theme={null}
> curl -X POST http://localhost:3333/api/kiwi/import \
>   -H "Content-Type: application/json" \
>   -d '{
>     "from": "notion",
>     "database_id": "1a2b3c4d5e6f",
>     "api_key": "ntn_...",
>     "prefix": "notion-pages"
>   }'
> ```

> [tab] MCP
>
> ```json kiwi_import theme={null}
> {
>   "from": "airtable",
>   "base_id": "appXXXX",
>   "table_id": "tblYYYY",
>   "prefix": "airtable"
> }
> ```
>
> The MCP tool reads `NOTION_API_KEY` and `AIRTABLE_API_KEY` from its own environment.

> [!NOTE]
>
> Over REST, KiwiFS routes Notion and Airtable through the [Airbyte](https://docs.kiwifs.com/import/airbyte.md) connector when Docker or an Airbyte Cloud key is available, and uses the built-in connector otherwise. Add `"via": "builtin"` to always use the built-in connector.

## Google Sheets

Import the rows of one sheet. The first row is the header.

```bash Terminal theme={null}
kiwifs import --from gsheets \
  --spreadsheet-id "1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgVE2upms" \
  --sheet "Sheet1" \
  --credentials service-account.json \
  --root ./knowledge
```

| Flag | Default | Description |
| - | - | - |
| `--spreadsheet-id` | | Spreadsheet ID from the URL (required) |
| `--sheet` | `Sheet1` | Sheet name. It's also the default prefix. |
| `--credentials` | | Service account JSON file. Without it, KiwiFS uses Application Default Credentials. |

Share the spreadsheet with the service account's email address. Google Sheets is CLI-only.

## Obsidian

Import an Obsidian vault and convert its syntax to KiwiFS conventions.

```bash Terminal theme={null}
kiwifs import --from obsidian --path ~/my-vault --prefix vault --root ./knowledge
```

| Flag | Description |
| - | - |
| `--path` | Vault folder, the one that contains `.obsidian/` (required) |

During the import, KiwiFS:

* Keeps each note's frontmatter and folder structure.
* Rewrites wiki links to lowercase, hyphenated targets: `[[Page Name|Alias]]` becomes `[[page-name|Alias]]`.
* Rewrites embeds to markdown images: `![[diagram.png]]` becomes `![diagram](assets/diagram.png)`.
* Copies images, PDFs, and media into an `assets/` folder.
* Skips `.obsidian/` and `.trash/`.

The vault path is read on the machine running KiwiFS. The web UI import wizard and `POST /api/kiwi/import` both support Obsidian:

```bash Terminal theme={null}
curl -X POST http://localhost:3333/api/kiwi/import \
  -H "Content-Type: application/json" \
  -d '{"from": "obsidian", "path": "/srv/vaults/research", "prefix": "research"}'
```

> [!TIP]
>
> Use [`--from markdown`](https://docs.kiwifs.com/import/files#markdown-folders) for plain markdown folders that you want copied without any rewriting.

## Confluence

Import a space from an HTML export, or fetch it live from Confluence Cloud. Both modes keep the page tree, convert common macros, and import attachments.

> [tab] HTML export
>
> Export the space as HTML from Confluence, unzip it, and point `--path` at the folder.
>
> ```bash Terminal theme={null}
> kiwifs import --from confluence --path ./MYSPACE-export --root ./knowledge
> ```
>
> The default prefix is the export folder's name.

> [tab] Confluence Cloud API
>
> ```bash Terminal theme={null}
> export CONFLUENCE_EMAIL="you@example.com"
> export CONFLUENCE_API_TOKEN="..."
> kiwifs import --from confluence --api \
>   --space MYSPACE \
>   --url https://your-domain.atlassian.net/wiki \
>   --root ./knowledge
> ```
>
> You can set `CONFLUENCE_BASE_URL` instead of passing `--url`. The default prefix is `confluence-<space key>`.

| Flag | Description |
| - | - |
| `--path` | Folder of an unzipped HTML export (export mode) |
| `--api` | Fetch from the Confluence Cloud REST API |
| `--space` | Space key (required with `--api`) |
| `--url` | Confluence base URL (API mode) |

Confluence import is CLI-only.

## Related

> [card] [Import overview](https://docs.kiwifs.com/import/overview.md)
>
> Output format, common flags, and re-import rules.

> [card] [Airbyte import](https://docs.kiwifs.com/import/airbyte.md)
>
> Notion, Airtable, and Firebase through Airbyte connectors.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.