Skip to Content
FeaturesProject Settings

Project Settings

A project carries a fixed set of settings — branding on user emails, the base URL links are built from, how self-serve signup behaves. They are declared in foir.config.ts and reconciled by foir push, or edited in the console.

The generic key/value settings store is gone. Foir used to offer arbitrary project-scoped key = value pairs, written from a foir settings CLI group. The table was dropped and the commands with it: in practice it held one platform-internal secret and one unused key, and nothing else ever used it.

If you want feature flags or shared constants for your own application, the answer is a model — declare a setting model with the fields you actually use, and you get types, validation, versioning, an editor and the same API as the rest of your data. A typed record beats an untyped string, and there is one fewer subsystem to learn.

What a project setting is

Settings on a project are a known set — the platform reads each one and does something specific with it. They are for whoever manages the project, and are not exposed on the public GraphQL API.

Most of them are reachable from the console, the CLI and UpdateProject alike. Three are not on the config-as-code surface at all, and are marked below: they are console or API only, so foir push will not set them and a config file is not where they live.

SettingWhat it does
displayNameDisplay name in user-facing emails and portal headers
logoUrlPublic URL of the project logo, rendered in user emails
primaryColorHex accent colour in user-facing emails
fromName“From” name on outbound user email
replyTo“Reply-To” address on outbound user email
supportEmailSupport address in email footers
appBaseUrlPublic base URL of your app. Reset, verify and invitation links are built from this, and the platform refuses to mint them while it is unset. It must sit under a custom domain the project has verified: https, its host the domain’s registrable domain or a subdomain of it, and no query or fragment. Verify a domain first; a new project cannot set one at creation, and an address already stored is not checked again
welcomeEmailEnabledWhether registration sends a welcome email. Default true; turn it off for invite-style flows
signupModepublic, restricted (invited emails only), waitlist (queued for approval) or closed
signupRestrictionsEmail hygiene and allow/block lists applied to public signups
passwordEnabledWhether email/password login is exposed. Default true
otpEnabledWhether one-time-code login is exposed. Default false
locksAccountsAfterFailedSignInsWhether ten wrong passwords in an hour lock the address everywhere for an hour, not only from the IP they came from. More. Default false
organizationSignupEnabledWhether a signed-in user may register an organization of their own. Default false
organizationSignupRoleThe key of the role a self-registered organization’s founder holds in it. Required when organizationSignupEnabled is on
organizationUsersWhere somebody who signs up at an organization stands: joined makes them its user, everyone a user of the project and so of every organization that shares its sign-in. Default joined
organizationOwnPoolWhether a new top-level organization keeps its own users. Default false
organizationJoiningWho may join an organization without an invitation: invitation, open (signing in at its page joins) or request (signing in asks, and its staff approve). More. Default invitation
noteScreenshotsEnabledWhether a signed-in user’s note may carry a screenshot. Default true. Also foir notes settings and the foir_update_notes_settings agent tool
anonymousNotesEnabledWhether a visitor who is not signed in may leave a note, through a key that gives them notes:create. Default false. Also foir notes settings and the foir_update_notes_settings agent tool. More
sitesThe project’s own websites, each an exact https origin with a name, and whether it may host editing: frame the console’s field editor so somebody signed in edits a field in place on the site. Default none. Also Settings → Sites in the console, foir sites and the foir_save_site agent tool
sessionIdleDaysThe idle window a user session slides over. NULL inherits the fleet default of 30 days — see Session windows. Console or API only
sessionAbsoluteDaysThe ceiling measured from first login, never extended. NULL inherits the fleet default of 90 days. Must not be below the idle window. Console or API only
organizationAssignableRoleKeysWhich roles an organization may assign within itself. Read-only over the API today — there is no writer for it outside tests, so it reads as empty unless something else set it

In foir.config.ts

This is the version-controlled way, and the one to prefer: the settings live next to the models they belong with, a change is reviewable, and every environment gets the same answer.

import { defineConfig } from '@foir/cli/configs'; export default defineConfig({ key: 'my-app', name: 'My App', project: { id: 'prj_...', tenantId: 'ten_...', settings: { displayName: 'My App', fromName: 'My App', supportEmail: 'help@example.com', appBaseUrl: 'https://app.example.com', signupMode: 'restricted', otpEnabled: true, }, }, });
foir push --dry-run foir push

Omit the settings block entirely to leave the platform’s settings untouched — foir push only reconciles what you declare. It applies them in the same transaction as the rest of the config, so a push refused for any other reason changes none of them. The settings you push are a draft until they are released, so pass --publish to have production serve them at once; a plain push prints Project settings: applied (draft). foir pull writes the block back from the live project, so an existing project can be brought under version control without retyping it.

Branding fields treat an empty string as clear and undefined as leave alone, so removing a value is logoUrl: '', not deleting the line.

In the console

Settings → General holds most of them, and Settings → Sites the sites. How people sign up is under Access → Sign-up. Same values, same effect; the config file wins on the next push, so pick one place to own them.

Secrets do not go here

Third-party API keys, signing certificates and OAuth client secrets belong in the Secret Vault, which encrypts them, keeps them out of your repo and records every read. Project settings are readable by anyone with project access.

Last updated on