Records
Versioned records are stored in each collection's typed physical table and exposed through plain HTTP.
Dashboard editor
Open a collection and choose New record. Trestle opens a syntax-highlighted JSON editor prefilled with every field from the collection schema. Editing a row opens the same editor with the complete current values, so a user never starts from an unexplained empty object. Records are fetched in bounded cursor pages without leaving the dashboard, and page checkboxes support version-safe bulk deletion.
Endpoints
GET /api/v1/collections/:collection/records
POST /api/v1/collections/:collection/records
GET /api/v1/collections/:collection/records/:id
PATCH /api/v1/collections/:collection/records/:id
DELETE /api/v1/collections/:collection/records/:idEach response includes a stable ID, positive version, created and updated timestamps, and a values object. Use ?fields=title,status for value projection and ?limit=1..100 for bounded lists.
Language-neutral HTTP
curl -X POST http://127.0.0.1:8090/api/v1/collections/issues/records \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: import-42' \
-d '{"values":{"title":"First issue"}}'Dogfood path
The CP21 incident tracker creates incidents through application-user rules and queries related timeline entries explicitly by incident_id. Follow the complete incident tracker tutorial.
Provider storage
Record semantics are provider-neutral: stable IDs, positive versions, timestamps, optimistic concurrency, defaults and projections behave identically on SQLite and the PostgreSQL provider. Boolean and numeric values are stored using each engine's native types; the API envelope never changes. Concurrent updates with the same version yield exactly one winner and one 412 version_conflict on both providers.