Skip to main content

Developer Documentation

Age Verification is a React Router 7 application built with Shopify’s React Router package (@shopify/shopify-app-react-router), Prisma, PostgreSQL, and React. It ships three Shopify extension packages: a theme app extension, a checkout UI extension, and a POS UI extension.

Integration surfaces

  • Embedded admin — Shopify-managed install and admin authentication, with App Bridge and Polaris web components loaded from Shopify’s CDN.
  • Storefront — a theme app embed and cart app block calling a Shopify-signed app proxy at /apps/age-verification.
  • Checkout — a Shopify Plus checkout UI block driven by app-owned shop and customer metafields.
  • Shopify POS — a smart-grid tile, modal, and post-purchase block calling a POS-session-token-authenticated backend route.
  • Provider callbacks — signed Stripe Identity and Didit webhook routes.
  • Shopify webhooks — subscriptions, uninstall, customer creation, and the three privacy-compliance topics handled at /webhooks.
  • Outbound verification events — an optional Pro feature that posts signed JSON to a merchant-configured public HTTPS endpoint.

Installation lifecycle

The Shopify server is configured with AppDistribution.AppStore, and the app uses the new embedded authentication strategy. That configuration does not by itself establish that a public App Store listing is live. After authentication, the app refreshes legacy offline tokens when needed, ensures the shop and Free subscription records exist, creates Shopify data definitions, and registers webhooks. The requested Admin API scopes are: read_customers, write_customers, read_products, write_products, read_metaobjects, write_metaobjects, read_metaobject_definitions, write_metaobject_definitions, and read_markets.

Repository commands

The package requires Node.js 18.20.0 or newer and uses npm workspaces for the checkout and POS extensions.

Quickstart

Get oriented with the app, its scopes, extensions, and public integration points.

Architecture overview

Follow requests across Shopify, the React Router server, PostgreSQL, and identity providers.

Merchant REST API

Review only the routes and payload fields implemented in the source repository.