Chat Archive
Takeout exports from social networks are complete but hard to search. Chat Archive imports those exports into a searchable MariaDB database and exposes a REST API for further analysis, without uploading the messages to another service.
Architecture
- Tauri importer, a desktop tool extracts the takeout ZIP locally and sends the raw JSON files to the API over HTTP. It contains no parsing or database logic.
- FastAPI service, the API handles encoding fixes, parsing and normalization for each platform, writes to MySQL or MariaDB, and exposes REST endpoints for later analysis.
- Two clear halves, the importer is the transport and the API owns the data model. That keeps the desktop tool small and lets the parser evolve without rebuilding it.
Supported platforms
- Instagram takeout messages.
- Facebook messages, including the end-to-end encrypted export.
- XING and LinkedIn exports, as a ZIP or a single CSV file.
Security model
The API does not sit behind Authelia, because the Tauri client is a plain HTTP client without a browser session, while Authelia forward-auth depends on cookie-based browser logins. Instead, the API protects itself with a static API token in the X-API-Key header. That is sufficient for the internal homelab network, but the API should not be exposed to the internet without an additional network allowlist or proxy rule.
Setup order
- Deploy the API and set the token in its environment.
- Build or run the Tauri importer with the same token.
- Point the importer at a takeout ZIP and import.
The API stores the normalized messages in MariaDB, so the database can be backed up with the normal database job. See the Chat Archive repository for the API setup, importer build and platform details.
Deployment
The API runs as an internal container or service and connects to the central MariaDB LXC container. The importer runs on a desktop machine where the takeout files already are, which keeps the raw export local until it is sent to the API.
The messages themselves are personal data and are not published here.