📚 Full documentation: docs.auth.vendidit.com
Cross-cutting TypeScript types for every consumer of @vendidit/auth-server. One contract, every TS consumer — @vendidit/auth-client, @vendidit/auth-server-ts, and @vendidit/auth-server-nest all re-export from here.
Repository: Vendidit/auth-shared
- JWT claim shapes —
UserJwtPayload,ServiceJwtPayload,RefreshJwtPayload,AccessJwtPayload, plusImpersonationClaims,PasswordResetClaims,EmailVerificationClaims. - Normalized principal types —
AuthenticatedUser,ServicePrincipal,AuthPrincipal. - Wire DTOs —
User,Organization,MyOrgRecord,TokenPair,AuthResponse,SessionRecord,AuditLogEntry, … - Error envelope + codes —
AuthErrorCode,AuthErrorEnvelope,AuthErrorPayload. - Constants — role codes, token-type constants.
Track main (current convention for in-org consumers — auto-picks up
the latest shape every npm install):
npm install github:Vendidit/auth-sharedOr pin to a tag if you want reproducible installs:
npm install github:Vendidit/auth-shared#v0.1.0npm clones the repo and uses the committed dist/ directly — no build
step on the consumer side.
import type { UserJwtPayload } from '@vendidit/auth-shared/jwt';
import type { User, Organization } from '@vendidit/auth-shared/dto';
import { AuthErrorCode } from '@vendidit/auth-shared/errors';
import { ROLES, TOKEN_TYPES } from '@vendidit/auth-shared/constants';See the full type reference on the docs site.