@agecheck/core
v0.2.0
Published
Core verification, policy, and cookie logic for AgeCheck SDKs.
Readme
@agecheck/core
@agecheck/core is the common TypeScript core used by AgeCheck SDK adapters.
It contains:
- token verification (
verifyAgeToken) - gate policy (
isGateRequired) - signed verification cookie helpers
- provider mode helpers for Existing Gate Integration
- typed domain errors and models
Most hostmasters should use @agecheck/node directly. Consume @agecheck/core only if you are building a framework adapter or platform integration.
Integration model support
Core primitives support all three backend integration patterns:
- Managed Gate Mode
- Existing Gate Integration (Provider Mode)
- Hybrid Mode (AgeCheck + other providers)
Provider Mode helpers:
verifyAgeCheckCredential(...)normalizeExternalProviderAssertion(...)buildSetCookieFromProviderAssertion(...)
Install
pnpm add @agecheck/coreQuality gates
pnpm typecheck
pnpm test
pnpm buildNotes
- Runtime requirement: Node 20+
- Module format: ESM + CJS output from
dist/ - Versioning and release policy:
/docs/VERSIONING.md
