-
Notifications
You must be signed in to change notification settings - Fork 0
PocketBase Integration
Traliran edited this page Aug 12, 2026
·
1 revision
While Traliran AI Hub works out-of-the-box using local browser storage (LocalStorage), you can connect a self-hosted PocketBase instance to sync your chat history, system prompts, and custom settings across all your devices securely.
- Single-file binary: Extremely lightweight, requires minimal RAM, and runs easily on cheap VPS instances, home servers, or single-board computers.
- Privacy & Control: You own 100% of your data. No third-party tracking or cloud locking.
- REST API out of the box: Perfect match for Traliran AI Hub's zero-build, serverless architecture.
- Download the executable binary for your OS from the Official PocketBase Releases (https://pocketbase.io/docs/).
- Extract the archive and run the executable:
./pocketbase serve --http="0.0.0.0:8090"
- Open your browser and navigate to
http://your-server-ip:8090/_/to create your initial Admin Account.
Traliran AI Hub requires specific collections to store your data. In your PocketBase Admin Dashboard (/_/), create the following collections:
- Type: Base collection
- API Rules: Set list/view/create/update/delete rules according to your auth preference (e.g., restricted to authenticated users or open for personal/local setups).
Fields:
-
title(Plain Text, Required) -
messages(JSON, Stores structured array of chat history) -
provider(Plain Text, Active model provider for the session) -
model(Plain Text, Model identifier string)
- Type: Base collection
Fields:
-
title(Plain Text, Required) -
content(Plain Text, System prompt body) -
tags(Plain Text, Optional categorization tags)
- Type: Base collection
Fields:
-
key(Plain Text, Unique preference key) -
value(JSON / Text, Serialized setting data)
If Traliran AI Hub is hosted on a different domain or port (e.g., GitHub Pages or local HTTP server), you must allow cross-origin requests in PocketBase:
- Open PocketBase Admin Dashboard.
- Go to Settings -> CORS settings.
- Add your hub’s origin URL to the allowed origins list:
- For GitHub Pages:
https://traliran.github.io - For local testing:
http://localhost:8080orhttp://127.0.0.1:8080
- For GitHub Pages:
- Click Save changes.
- Open Traliran AI Hub.
- Go to Settings (Gear icon) -> Database / Storage.
- Toggle storage engine to PocketBase.
- Fill in your instance details:
-
PocketBase URL:
http://your-server-ip:8090(or your domain with HTTPS). - User Auth Credentials: (If authentication rules are enabled on your collections).
-
PocketBase URL:
- Click Test Connection & Sync.
Once connected, your chats and prompts will automatically stream to and sync from your private PocketBase instance.