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

# Data Export

## Zip Export

`bijection export` writes a ZIP of the tables selected by an archive mount
at one pinned installation version. For physical recovery, see
[Backups](https://docs.bijection.com/operate/data/backup-and-restore.md).

### Install the archives mount

Add `@bijectionhq/library-archives` to your application dependencies and
place it in `bijection/app.ts`. Include your existing tables
and operator roles in the app tree. For a single public table, the config
can look like this.

```ts bijection/app.ts theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
import { app, label, role, t, table } from "@bijectionhq/bijection";
import { archives } from "@bijectionhq/library-archives";

const operator = role({});
const notes = table({ text: t.string });

export default app({
  operator,
  notes,
  archives: archives({ allow: [operator], label: label.public }),
});
```

The archive includes cleared tables from the app. Set `exclude: [scratch]`
to leave out a table. The selected table paths appear in `bijection.lock`.

Install the app with this configuration and [grant the caller's principal
the operator role](https://docs.bijection.com/access/grants.md). To include labelled tables, give the
mount an `under` label that clears them and grant the operator that
clearance. An import lands through an ordinary release the app declares,
which only the app's import function may use.

By default the ZIP holds opaque custody copies, including erasable and
lifetime facts. The default recipient is the exporting installation. To
name another recipient, configure `managedRecipient` on the export mount.
The destination needs access to the original custody namespace through the
shared authority and a reviewed mapping from the original relation to its
local table. Import keeps original IDs, erasure units and deadlines, and
reports copies with closed units as `erased`.

To export clear rows for another installation, place the mount with
`archives({ allow: [operator], label: label.public, release: exportRelease })`. Use a declared
release to public and grant the export function the declared release
authority. The lock prints the release on the
`archive` line, and each disclosure is recorded in `sys.disclosures`.

### Export from the mount

```sh theme={"theme":{"light":"github-light-default","dark":"github-dark-default"}}
bijection export --path ~/Downloads
bijection export --library tools.archives --path archive.zip
```

The default mount path is `archives`. Use `--library` when the app places the
library elsewhere. The export pins the installation’s current version.
Referenced Files travel at `_files/<id>` with their ciphertext and wrapped
keys. Larger sealed Files stream as ciphertext parts. The sealed row's
audience must clear the labels of its referenced Files. An archive's declared
clear-copy release can disclose up to 2 MiB of File bytes per File and records
an audit fact in `sys.disclosures`.

Archive facts use Bijection wire JSON in `documents.jsonl`. Tagged values
preserve types such as Int64 and Bytes. In `_archive.json`, `relations`
maps each exported table path to its source catalog's primary relation ID.
Use these IDs when configuring `managedSources` on the destination.

## Streaming Export

Bijection does not offer streaming export, so connectors from data
integration platforms such as Fivetran and Airbyte can't export from a Bijection
installation. To copy your data elsewhere, export an archive as described above.


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