Credentials
Managing password, API key, and certificate credentials for entities.
Credentials are attached to entities. An entity may have multiple credentials of different kinds.
Supported credential kinds:
- password;
- API key;
- certificate.
This page covers passwords and API keys. See Certificates for mTLS certificate credentials, CA files, CRL, OCSP, and runtime lookup.
Password credentials
Used for the /auth/login endpoint. The password is hashed with argon2 before storage; the plaintext is never persisted.
Login returns a JWT and session reference:
If ATOM_SELF_REGISTRATION_ENABLED=true, a human can self-register into an
existing global account without selecting a tenant. Password signup stores the
normalized email as the login identifier and requires email verification before
normal login:
Verification and resend endpoints are public:
ATOM_ALLOW_UNVERIFIED_EMAIL_LOGIN=true allows local development login
before email verification, but inactive and suspended entities are still
rejected.
API keys
API keys are long-lived credentials suited for device and service authentication where interactive login is not practical.
Format
The credential ID is embedded in the key for O(1) lookup — the server decodes the ID from the prefix and fetches that specific credential row, then verifies the argon2-hashed secret.
Creating an API key
The full key is returned exactly once at creation time. It is never stored in plaintext and cannot be recovered. Store it securely immediately.
You can set an expiry:
Using an API key
Pass it as a Bearer token — the service detects the atom_ prefix and routes to API key verification:
API key authentication does not create a session and does not return a JWT.
Listing credentials
Returns metadata only — no secret hashes, no plaintext secrets.
Revoking a credential
The credential status is set to revoked. Revoked credentials are rejected immediately on the next request — no token reissuance is required because API keys are verified live against the database on each request.