npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@ackplus/nest-auth-contracts

v2.10.3

Published

[![npm version](https://img.shields.io/npm/v/@ackplus/nest-auth-contracts.svg)](https://www.npmjs.com/package/@ackplus/nest-auth-contracts) [![npm downloads](https://img.shields.io/npm/dm/@ackplus/nest-auth-contracts.svg)](https://www.npmjs.com/package/@a

Readme

@ackplus/nest-auth-contracts

npm version npm downloads license

Shared TypeScript types and enums for the @ackplus/nest-auth ecosystem. Types-only — zero runtime code, zero bundle cost.

📚 Browse every type at ack-solutions.github.io/nest-auth/docs/api-reference/types


Why this package exists

Backend, JS client, and React layer all need the same types — DTOs, enums, domain interfaces. This package is the single source of truth so a change to a request/response shape on the server breaks the client at compile time, not at runtime.

It is consumed by:

You usually don't install it directly — it's a transitive dependency of all three. Install it explicitly when you want to type-check code that consumes the auth API without pulling in the full backend or client package.

Install

pnpm add @ackplus/nest-auth-contracts

Both ESM and CommonJS builds ship in the package. No peer dependencies.

What's exported

Enums

import {
  NestAuthMFAMethodEnum,   // 'email' | 'sms' | 'totp'
  NestAuthOTPTypeEnum,     // 'passwordless_login' | 'magic_link_login' | 'password_reset' | 'email_verification' | 'phone_verification' | 'mfa'
  TenantModeEnum,          // 'isolated' | 'shared'
} from '@ackplus/nest-auth-contracts';

Request DTOs

ILoginRequest, ISignupRequest, IRefreshRequest, ISwitchTenantRequest, IVerify2faRequest, IToggleMfaRequest, IVerifyTotpSetupRequest, IForgotPasswordRequest, IResetPasswordWithTokenRequest, IChangePasswordRequest, IVerifyForgotPasswordOtpRequest, IVerifyEmailRequest, IVerifyPhoneRequest, IPasswordlessSendRequest, IInitializeAdminRequest, ICreateRoleInput, IUpdateRoleInput, IUpdatePermissionInput

Response DTOs

IAuthResponse, ITokenPair, IUserResponse, ISessionUserData, IMessageResponse, IVerify2faResponse, IMfaStatusResponse, IMfaDevice, ITotpSetupResponse, IVerifyOtpResponse, ISessionVerifyResponse

Credential type unions

ILoginCredentials = IEmailCredentials | IPhoneCredentials | ISocialCredentials | IPasswordlessOtpLoginCredentials

Domain interfaces

INestAuthUser, INestAuthIdentity, INestAuthSession, INestAuthAccessKey, INestAuthOTP, INestAuthMFASecret, INestAuthTrustedDevice, INestAuthRole, INestAuthPermission, INestAuthTenant, INestAuthUserAccess

Configuration interfaces

IEmailAuthConfig, IPhoneAuthConfig, IMfaConfig, IRegistrationConfig, INestAuthTenantOptions, ITenantsConfig, ISsoConfig, IUiConfig

Full type reference →

Common imports

import {
  // Enums
  NestAuthMFAMethodEnum,
  NestAuthOTPTypeEnum,
  TenantModeEnum,

  // Request/response DTOs
  ILoginRequest,
  ISignupRequest,
  IAuthResponse,
  IMfaStatusResponse,
  ISessionUserData,

  // Domain interfaces
  INestAuthUser,
  INestAuthSession,
  INestAuthRole,
  INestAuthTenant,
} from '@ackplus/nest-auth-contracts';

async function login(req: ILoginRequest): Promise<IAuthResponse> {
  return fetch('/auth/login', { method: 'POST', body: JSON.stringify(req) }).then((r) => r.json());
}

Naming conventions

  • Domain entitiesINestAuth{Entity} (e.g. INestAuthUser, INestAuthRole)
  • EnumsNestAuth{Name}Enum (e.g. NestAuthMFAMethodEnum)
  • Request DTOsI{Feature}Request
  • Response DTOsI{Feature}Response
  • ConfigurationI{Feature}Config or I{Feature}Options

Companion packages

| Package | Purpose | | --- | --- | | @ackplus/nest-auth | NestJS backend module | | @ackplus/nest-auth-client | Framework-agnostic JS/TS client | | @ackplus/nest-auth-react | React provider, hooks, guards |

All four packages release together with the same version number. Pin them all to the same version.

Links

License

MIT