Reference
API reference
Every package is small and focused, and exports a single, predictable surface. This page is the map: the primary entry points per package, and where each concept is taught in full.
#How to read the API
Two rules make the whole surface predictable. Every declarative decorator has an imperative define* twin at strict parity. And every module offers its three forms, class, factory, function, except providers, which forbid the function form. Learn the shape once and it repeats across every package.
#Primary entry points
| Package | Primary API |
|---|---|
| @stone-js/core | @StoneApp, defineStoneApp, the kernel, blueprint builder, hooks. |
| @stone-js/router | @EventHandler, @Get/@Post/@Put/@Patch/@Delete, defineRoutes, defineEventHandler. |
| @stone-js/use-react | @Page, @PageLayout, StoneLink, StoneOutlet, useRoute, useData, useHead. |
| @stone-js/validation | validate, validateEvent, fromZod, fromStandard. |
| @stone-js/auth | requireAuth, requireScopes, Authenticator. |
| @stone-js/authz | authorize, defineAbility, Authorizer. |
| @stone-js/resources | defineResource, only, except. |
| @stone-js/openapi | OpenApiGenerator. |
| @stone-js/testing | createTestApp, TestClient. |
| @stone-js/env | getString, getNumber, getBoolean, getUrl, getEnum, getJson. |
#The full generated reference
Every exported symbol of all 28 packages, with its types, is in the consolidated TypeDoc reference: one cross-linked site, generated from the source at build time and exhaustive by construction.
#Where the details live
Each capability is also taught, with runnable examples, on its own page: Routing, Validation, Auth, Resources & OpenAPI, Testing. The vocabulary is fixed in the Glossary.