Skip to content

Create Your First Admin

The first admin of a local stack is whoever registers with the owner email you gave seamless init. There is no invite to create and no admin command to run, and you never need to read container logs.


Make sure:

  • your local stack is running (docker compose up)
  • you can access the web app at http://localhost:5173
  • you know the email you entered for the owner during init

init writes your email to the auth server as OWNER_EMAIL. When an account is created with an address on that list, the auth server grants it admin:write (or admin on an instance whose available roles list only that).

Email OTP registration creates the account, with the role, before the address is verified, but an unverified account cannot sign in. Only someone who receives the code at the owner address can use it. Signing up through an OAuth provider creates the account from the provider’s verified email.

After the first admin exists, grant admin to other people from the admin console or with seamless users, not through OWNER_EMAIL.


Open http://localhost:5173 and register with the same email you gave init.


The local stack sends no email. When the page asks for a code, get one from the project directory:

Terminal window
npx seamless-cli owner-code

It waits for the auth server, reads the owner address init recorded, and prints a code for it:

Code for admin@example.com: 4K7QZP

Enter that code, and enroll a passkey when prompted.


After registration, the session’s roles include admin:write alongside the instance’s default roles (set by DEFAULT_ROLES):

{
"roles": ["<default roles>", "admin:write"]
}
Admin session with role attached
Admin users have the admin role attached to their session

Navigate to the admin console. By default your API serves it at:

http://localhost:3000/console

If you chose a separate dashboard container during init, it is at http://localhost:5174 instead.

Seamless Admin portal
Admin dashboard overview

  • init recorded your email as the owner
  • registration with that email, and the code owner-code printed for it, verified the account
  • the new account received the admin role at creation
  • the admin console became accessible through normal auth state