Glossary
The words these docs use, in alphabetical order. Each entry says what the word means and links to the page that explains it.
A
Access token
An access token is the short-lived key the SDK sends with every request your app makes for a signed-in user. It lasts 15 minutes, is kept only in the page's memory and works only together with a proof from the browser's key; the SDK renews it by itself. See How sign-in works.
Agent tools
The agent tools are the operations an AI coding tool can call on the server: creating apps, publishing schemas, generating types and reading these docs. They use your developer token and can never read or change user data. See Developer API and agent tools.
App
An app is a web app that a developer builds: static files (HTML, JavaScript, CSS) served from the web addresses the developer registers, which save and read the user's data through the SDK. Each app has an ID that starts with app_, and owns the collections it publishes. See One backend, many apps.
B
Backend
The backend is the object connect() gives your app: one signed-in user's data, for your app, on one server. Your app reads and writes through it, with backend.collection(), backend.files and the other methods in the SDK reference.
C
CLI
The CLI is the command-line tool you run in a terminal, as npx phibac followed by a command: npx phibac init, npx phibac deploy, npx phibac generate, npx phibac dev and npx phibac mcp. See CLI reference.
Collection
A collection is one kind of data in a user's database, such as notes or journal entries, and holds that kind's records. Its name is written like a reversed web address, such as com.example.notes.note, and the app that first publishes it owns it. See Collections and records.
Connect page
The connect page is the page in the sign-in popup that asks the user, the first time they sign in to your app, whether your app may store data in their database, with Allow and Cancel. See Users, sign-in and consent.
Consent
Consent is the user's approval for an app to use their data. They give it once on the connect page for your app's own data, and again, with requestAccess(), for each other app's collection your app wants to read. They can revoke it in their account area. See Users, sign-in and consent.
D
Developer token
A developer token is a secret key, starting with pbd_, that lets the CLI and AI coding tools create and change your apps and publish their schemas. It can never read, write, export or delete any user's data. You create it on the server's account page and give it to tools in PB_TOKEN. The local server that npx phibac dev runs makes its own, in ./.pb/developer-token, which the CLI uses by itself. See Developer API and agent tools.
DPoP
DPoP (Demonstrating Proof of Possession) is the standard the SDK follows to tie the user's tokens to a key kept in the browser: every request carries a proof signed with that key, so a stolen token is useless elsewhere. See How sign-in works.
F
Field
A field is one named value in a record, such as text or pinned. A collection's schema lists its fields, each with a type, a description and its rules. See pb.config.ts reference.
File
A file is content such as a photo that your app uploads with files.upload() and stores next to the records, not inside one. A record keeps only the file's ID, which starts with f_, in a fileRef field. See Upload and show files.
H
History
A record's history is the list of its earlier versions: every update or delete keeps the version it replaced for 30 days. Only the user can see it and restore a version, from their account area. See Collections and records.
Hosted
A hosted server is one run as a service for the public. This server is not: it runs in selfhost mode. See One backend, many apps.
I
Indexed
Indexed is the field option (indexed: true) that lets queries filter and sort on a field. Queries can use only indexed fields, createdAt and updatedAt. See Query, sort and live updates.
L
Live updates
Live updates are the messages the server sends while your page is subscribed to a collection, so the SDK can tell your page when data changes, including changes made on another device. See Query, sort and live updates.
M
Major version
A major version is a numbered version of a collection's schema: the version in pb.config.ts, starting at 1. A breaking change needs the next major version; older ones stay published and each record keeps the major version it was written with until an update moves it to another. See Change your schema safely.
Minor version
A minor version is a numbered step within a major version, such as 1.1 after 1.0. The server adds one each time you publish an additive change, such as a new optional field. You never write it yourself. See Collections and records.
O
Offline queue
The offline queue is the same thing as the write queue, under another name: the changes made on this device that the server does not have yet. These docs say write queue. See Offline writes and sync.
Origin
An origin is the start of a web address: the scheme, the host and the port, such as https://notes.example.com or http://localhost:5173, without any path. The server lets an app sign users in only from the origins registered for it. See Sign users in.
P
Passkey
A passkey is how users sign in: a key pair their device makes for the server, unlocked with the device's screen lock, fingerprint or face. A user signs in with a passkey or with a password, and your app never sees either. See Users, sign-in and consent.
Password
A password is the other way users sign in: they type their email address and password on the server's own sign-in page. In a browser they have not used before, the server also sends a short code to their email address. Your app never sees the password. See Users, sign-in and consent.
PKCE
PKCE (Proof Key for Code Exchange) is the standard the SDK follows during sign-in so that the one-time code the popup returns is useless to anyone but the page that asked for it. See How sign-in works.
Popup
The popup is the small window on the server that connect() opens to sign the user in, and that requestAccess() opens to ask for consent. Browsers open it only from a click or key press. See Sign users in.
R
Record
A record is one saved item in a collection, such as one note. Your app gets it as a PbRecord, with its data, its rkey, its global ID and its status. See Collections and records.
Record ID
A record ID is the global ID of a record, pb://<userId>/<collection>/<rkey>, which names the user, the collection and the record. A recordRef field holds one. See Collections and records.
Refresh token
A refresh token is the key the SDK keeps in the browser to get new access tokens without asking the user to sign in again. Each use replaces it with a new one, and one left unused for 30 days expires. See How sign-in works.
Restore
To restore a record means to bring back an earlier version from its history, which saves that old data as a new version. Only the user can restore, from their account area; there is no SDK call for it. See Collections and records.
rkey
An rkey (record key) is the ID of a record within its collection: a UUIDv7 the SDK makes on the device when your app creates the record, so creating works offline. You pass it to get, update and delete. See Collections and records.
S
Sandbox
A sandbox is a collection whose name starts with sandbox., such as sandbox.settings, that needs no schema and is private to the app that writes it. No other app can ever read it. See Collections and records.
Schema
A schema is the description of a collection: what it holds and, for each field, its name, type, rules and description. You write it in pb.config.ts and publish it with npx phibac deploy, and the server checks every record against it. See Define your data.
SDK
The SDK is the JavaScript library, @phibac/sdk, that your page uses to sign the user in and to read and write their data, offline too. See SDK reference.
Self-hosted
A self-hosted server is one that a person or organisation runs for themselves, in self-host mode, instead of using a hosted service. This server runs in selfhost mode. See One backend, many apps.
Sensitive
Sensitive is the field option (sensitive: true) that marks a field as private on the consent page, where the user decides whether another app may read the collection. It does not change who can read the field. See Define your data.
Status
A record's status is one of two values: pending while a change to it is waiting in the write queue, and synced once the server has its latest change. See Offline writes and sync.
Subscription
A subscription is a function your app gives to subscribe() on a collection or a query: the SDK calls it with the matching records now and again every time they change, until your app ends it. See Query, sort and live updates.
U
User
A user is the person whose data it is: someone with an account on the server, who signs in to your app with a passkey or a password and has one private database that every app they approve shares. See One backend, many apps.
W
WebAuthn
WebAuthn (Web Authentication) is the standard behind passkeys: the browser and the device make and use the key pair, and the server checks the signatures. See How sign-in works.
Write queue
The write queue is the list of changes your app has made on this device that the server does not have yet. The SDK keeps it in the browser, so it survives a reload, and sends it in order whenever the device is online. It is also called the offline queue. See Offline writes and sync.