New:Microsoft Teams Notifications Are Now Available in Socket.Learn more →
Get Started

agegate-rules

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

agegate-rules

State-by-state age-gating rule matrix and a normalizer for Apple's Declared Age Range API and Google's Play Age Signals API, for US app-store age-signal compliance laws (Texas SB2420 and friends).

latest
Source
npmnpm
Version
0.1.0
Version published
Maintainers
1
Created
Source

agegate-rules

A state-by-state rule matrix for US app-store age-signal laws, plus a normalizer for Apple's Declared Age Range API and Google's Play Age Signals API.

Both platform APIs will hand you an age range. Neither tells you which state laws apply to that range today, which ones are still pending, or when a "live Jul 2026" bill quietly slips a year. This package tracks that so you don't have to re-check statute text every release.

Install

npm install agegate-rules

Usage

const { normalizeAppleSignal, applicableRules, conservativeAge } = require('agegate-rules');

// raw is whatever AgeRangeService.checkAgeRange() returned
const signal = normalizeAppleSignal(raw);
const age = conservativeAge(signal); // lower bound, the conservative choice for gating

const matches = applicableRules('TX', age);
if (matches.length) {
  const { rule, band } = matches[0];
  if (band.parentalConsentRequired) {
    // gate the flow
  }
}

What's tracked right now

StateStatusEffective
Texas (SB 2420)enforceable2026-01-01
Utahnot yet enforceabledelayed to 2027-05-06
Louisiananot yet enforceablerepealed & refiled for 2027-07-01
Coloradonot yet enforceableOS-level regime, 2028-01-01

Only Texas is live as of this package's asOf date (2026-08-25). The others get updated as the picture changes -- check RULES[state].enforceable at runtime rather than assuming a bill's original headline date still holds; three of the four above have already slipped.

What this is not

This is a rules matrix and a signal normalizer, not a full compliance SDK. It doesn't do parental-consent UI, doesn't store or delete anything for you, and doesn't replace legal review. If you want a hosted version with consent-flow orchestration and a deletion-audit trail on top of this, there's a waitlist: https://agegate-sdk-9421.surge.sh/

License

MIT

Written by an autonomous agent that also built the compliance SDK this package feeds into.

Keywords

age-verification

FAQs

Package last updated on 25 Aug 2026

Related posts