People and sign-in
There are no passwords and there is no sign-up page. People are invited by an owner and sign in with a link sent to their email, or with a passkey once they have added one.
| Owner | Editor | Author | |
|---|---|---|---|
| Write and save entries | ✓ | ✓ | ✓ |
| Publish, unpublish, trash and delete entries | ✓ | ✓ | |
| Build and change forms, read what was sent | ✓ | ✓ | |
| Contacts and deals | ✓ | ✓ | |
| Content types | ✓ | ||
| People and invitations | ✓ | ||
| Plugins and their settings | ✓ |
Only an owner changes a role.
The first owner
Section titled “The first owner”The first owner is made from the command line, once. It refuses when anyone already has access.
npx velocity-cms owner you@example.com "Your Name"It prints a link that signs them in. It works once, for ten minutes. For someone who already has access and cannot
get an email, npx velocity-cms link <email> prints a new one. Whoever holds a link is that person, so run these
only where you trust the screen.
Inviting people
Section titled “Inviting people”An owner opens People, adds a name, an email and a role, and the person is emailed. They then ask for a sign-in
link at /admin like everyone else.
Signing in
Section titled “Signing in”- Email link. Type your email at
/admin. If it belongs to someone with access, a link arrives. - Passkey. Once signed in, add a passkey from the account menu and use your fingerprint, face or device PIN from then on.
The sign-in page answers the same way whoever an address belongs to, and takes the same time, so it never tells a stranger who has an account. One address is sent at most three links in ten minutes.
Email delivery
Section titled “Email delivery”Without any setup, links and invitations are printed to the server’s log. That is enough to develop with, and
velocity-cms link covers a small site. A deployed site should send real email, in one of two ways.
Resend
Section titled “Resend”Set two variables and the CMS sends through Resend:
VELOCITY_CMS_RESEND_API_KEY=re_...VELOCITY_CMS_EMAIL_FROM="My site <hello@example.com>"Your own provider
Section titled “Your own provider”Name a file in the integration, velocityCms({ mailer: './src/cms-mailer.ts' }), whose default export has two
methods:
export default { async sendSignInLink({ email, name, url, expiresInMinutes, siteName }) { // Send `url` to `email` with your provider. Throw if it cannot be sent. }, async sendInvitation({ email, name, url, siteName }) { // Tell them they were let in. `url` is the editor's address. },};It is only ever called for someone who has an account.