Get desktop application:
View/edit binary Protocol Buffers messages
Used in:
Time-to-live in seconds for auth tokens. [Default: 1h]
Time-to-live in seconds for refresh tokens. [Default: 30 days] When ttl is zero or negative, no refresh token will be minted.
Time-to-live in seconds for anonymous-auth refresh tokens. [Default: 90 days] When ttl is zero or negative, no refresh token will be minted.
Disables password-based sign-up. Does not affect already registered users.
Whether sign-in via OTP codes (e.g. sent via Email) should be allowed. This may be less secure since ultimately you're delegating operational security to a user's inbox.
Allow the creation of ephemeral user-accounts, e.g. for a frictionless trial.
Minimal password length. [Default: 8]
Password must contain lower and upper-case letters.
Password must contain digits in addition to alphabetic characters..
Password must contain special, non-alphanumeric, characters.
Map of configured OAuth providers.
List of custom URI schemes allowed as auth redirects. This is useful for mobile apps, desktop or SPAs where an app registers a custom scheme for calls it wants to handle.
List of explicitly allowed redirect uris.
Policy covering user registration and change (username|email) flows around what user identifier is expected and accepted. [Default: ONLY_EMAIL]
When using "Sign-in with Apple" in native Mac or iOS apps, the auth flow differs significantly from the web-based OAuth flows. The client signs in with Apple directly using the user's iCloud account. The client then forwards an apple-signed JWT identity token that can be exchanged for TrailBase tokens: https://developer.apple.com/documentation/signinwithapple/authenticating-users-with-sign-in-with-apple The tokens audience (`aud`) is validated against the "client id", which unlike for OAuth is the app `Bundle ID` instead of the `Service ID` (i.e. only configuring the Apple OAuth flow is insufficient for native sign-in): https://developer.apple.com/documentation/signinwithapple/verifying-a-user#Verify-the-identity-token NOTE: while not explicitly required, Apple may reject apps from their stores if they provide a social login w/o also providing an Apple option using their native `AuthenticationServices`: https://acceptmy.app/guides/sign-in-with-apple-rejection.
Used in: ,
NOTE: These top-level fields currently have to be `required` due to the overly simple approach on how we do config merging (from env vars and vault).
Sqlite specific (as opposed to standard SQL) constrained-violation resolution strategy upon insert.
Used in:
SQL default: Keep transaction open and abort the current statement.
Skip the statement and continue. Mostly matters in the context of batches and transaction. Rather than aborting, subsequent operations will continue.
Replaces the conflicting row in case of a collision (e.g. unique constraint).
Used in:
Name will be used as <traildepot>/(data/<name>.db|migrations/<name>/).
Used in:
Which encryption method to use. [Default: STARTTLS]
Used in:
Used in:
System jobs overrides. NOTE: This is technically a map from id to config, however enums are not allowed as map keys.
Used in:
Used in:
Name to display in auth and admin UI.
Urls
User-info scopes to request. [Default: ["openid", "email", "profile"]] NOTE: Claims not covered by the requested scopes won't be returned by the provider's user-info endpoint, e.g. dropping the "email" scope requires a username-based `UserIdentifier`.
Used in:
Used in:
Database record insert.
Database record read/list, i.e. select.
Database record update.
Database record delete.
Lookup JSON schema for the given record api .
Tells the server which proxy-provided header to extract the client-ip from.
Used in:
Try extracting the IP from any of the below sources. This is useful for getting started but does allow client's to forge an IP and thus spoof your logs and circumvent any rate limiting. Make sure to set up your proxy config properly for production use.
No proxy: use peer's IP.
Forward chain provided by trusted reverse proxy (make sure proxy appends). Will take right-most trusted IP. If your setup contains multiple proxies, make sure to add them to the `trusted_proxies` list.
Single IP provided by trusted reverse proxy (make sure proxy overrides).
Used e.g. by CloudFlare enterprise.
CloudFlare's connecting IP.
Fly's client ip header.
AWS' cloudfront.
Configuration for trusted (reverse-)proxies in front of the TrailBase server.
Used in:
Tells the server which proxy-provided header to extract the client-ip from.
List of trusted proxies to pop right-to-left from `X-Forwarded-For` chain.
Used in:
API name, i.e. unique name used to access data via HTTP.
Referenced table to be exposed.
Attached databases - will `ATTACH <traildepot>/data/<name>.db AS <name>`. Can only reference configured databases.
Strategy to be used on insert if a table constraint is violated.
Fill columns referencing _user(id) automatically from current user's authentication context if present. Can be useful for static clients, such as HTML forms, otherwise it's recommended to have the client provide user ids explicitly and to keep this feature off.
Allow subscribing to data changes in realtime using SSE streaming. NOTE: If you're using a reverse proxy, this will likely require configuration changes to allow for server-side streaming HTTP, e.g. tell the proxy to keep listening and not cache.
Access control lists.
Columns excluded from this API. Excluded columns are completely inaccessible via this API. This is different from columns with names prefixed by "_", which are considered hidden. This means they can still be inserted, updated and access checked unlike excluded columns.
Access rules to be evaluated on request. Expected to be valid SQL expression, where `SELECT <expr>` returns a unary boolean. The evaluator injects _USER_, _ROW_ and _REQ_ tables that can be used for validating access, e.g.: _USER_.id = _REQ_.owner ensures that the value provided for the `owner` column during an insert matches the current authenticated user's id. One can also construct arbitrary validations including sub-queries, e.g.: _USER_.id = _REQ_.owner AND EXISTS(SELECT FROM allowed WHERE allowed.user = _USER_.id)
A list of foreign key columns that *can* be expanded on read/list, i.e. the foreign record will be in-lined into the response. By default nothing is expanded. Record-expansion is a convenience read-only feature that requires special consideration with respect to this API's access checks, since you're also granting read access to a foreign table. Moreover, write access to the primary table allows indirect reads to all records of the foreign table. Independently, access restrictions on APIs over the foreign-table are inconsequential, since APIs are independent from one another. Only columns and foreign tables with names not starting with "_", i.e. are allowed to be expanded.
Hard limit for listing records. [Default: 1024]
Used in:
S3 access key, a.k.a. username.
S3 secret access key, a.k.a. password.
Used in:
Application name presented to users, e.g. when sending emails. [Default: "TrailBase"]
Your final, deployed URL. This url is used to build canonical urls for emails, OAuth redirects, ... . [Default: "http://localhost:4000"]
Controls IP extraction, e.g. for logging and rate limiting.
Max age of logs that will be retained during period logs cleanup. Note that this implies that some older logs may persist until the cleanup job reruns. [Default: 7 days]
If present will use S3 setup over local file-system based storage.
If enabled, batches of transactions can be submitted for atomic execution
Request size limit. [Default: 10MB]
Limits the request per IP per second to auth POST APIs for abuse protection. If TrailBase is behind a proxy, make sure to set "X-Forwarded-For". [Default: disabled] Note that login endpoints have additional fixed rate limits on a per credentials level.
Limits how many backups are kept at any time. [Default: 5]
Used in:
Used in:
Identifies the system job by its id.
Cron spec: shorthand or 7-components: (sec, min, hour, day of month, / month, day of week, year).
Disable the system job.
Timeout in milliseconds.
Used in:
What user identifier to use for new user registrations as well as change-(email|username). NOTE: W/o email there's no way to contact users.
Used in:
Behaves like ONLY_EMAIL for legacy reasons.
Only email. Doesn't work for anonymous login.
Only username. No email allowed.
Requires email and allows an optional username.
Requires username and allows an optional email.
Requires both email and username.