Snapshot for
@system-core/core0.8.x. Current docs live at /.
Build On System-Core
If you are an AI agent or a developer using an AI agent, start here before writing application code.
Input Contract
Provide these before implementation starts:
- whether the private registry is already configured in the target project
- host framework and runtime target
- whether the project needs CMS, auth, delivery, and storage
- whether Prisma-backed state already exists
- whether there is an admin UI, public site, or both
- deployment target and CI/CD constraints
Starter Prompt
Build a production-ready project on top of @system-core/core.
Private registry configured:
Framework/runtime:
Database/state:
Needs CMS/auth/delivery/storage:
Needs admin UI/public site:
Deployment target:
Constraints and non-goals:
Rules:
- Import only from published package exports.
- Use createSystem() unless there is a clear reason to stay logic-only.
- Do not rebuild auth, CMS, delivery, or storage boundaries already owned by system-core.
- Explain which export surface owns each concern before writing code.What System-Core Is
system-core is a package-owned backend and CMS platform. It is not a code snippet library. It expects application code to compose around the exported package surfaces rather than bypass them.
Default Build Strategy
- Configure the private
@system-coreregistry and install the package before writing code. - Use
createSystem()for full projects. - Pick the correct integration adapter for the host framework.
- Treat
system.auth,system.cms,system.delivery,system.storage, and platform services as the authoritative runtime surfaces. - Build app-specific routes, UI, policies, and business logic on top of those surfaces.
Install First
If private registry access is missing, ask for Verdaccio access to https://npm.maxnate.com or a ready .npmrc snippet. Do not ask vaguely for an "npm token" without naming the registry.
@system-core:registry=https://npm.maxnate.com
//npm.maxnate.com/:_auth=${NPM_TOKEN}
//npm.maxnate.com/:always-auth=truenpm install @system-core/core
npm install zodAdd peers by runtime:
- full CMS runtime:
npm install @prisma/client - Nuxt/Nitro:
npm install h3 - Express/Fastify:
npm install express fastify - Redis-backed limits/queues:
npm install ioredis - auth and email flows:
npm install bcryptjs jsonwebtoken nodemailer - S3-compatible media storage:
npm install @aws-sdk/client-s3 @aws-sdk/s3-request-presigner
NPM_TOKEN in this repo means the auth value for the private Verdaccio registry. It usually comes from the project owner, registry admin, secret manager, or a base64-encoded username:password pair for npm.maxnate.com.
Correct Defaults
| Requirement | Default choice |
|---|---|
| Full product with CMS or Prisma-backed state | createSystem() |
| Nuxt 3 / Nitro app | @system-core/core/integrations/nuxt |
| Express or Fastify server | @system-core/core/integrations/express |
| NestJS app | @system-core/core/integrations/nestjs |
| Edge runtime | @system-core/core/integrations/workers |
| Browser-safe metadata for admin/editor UIs | client metadata exports |
Non-Negotiable Rules
- Import only from published exports.
- Do not import internal file paths from
core/*,integrations/*, orpackages/*. - Do not rebuild auth, CMS, storage, or delivery subsystems that the package already owns unless you are intentionally replacing a boundary.
- Do not call both
createSystem()andcreateApp()in the same application runtime. - Do not perform ad hoc Prisma auth logic when
system.authalready owns the flow.
Project Recipe
Full product
import { createSystem } from '@system-core/core'
import { h3Adapter } from '@system-core/core/integrations/nuxt'
const system = await createSystem({ prisma })
export default defineEventHandler(async (event) => {
const body = await h3Adapter.readBody(event)
return { ok: true, body, version: system.version }
})Logic-only service
import { createApp, createConfig } from '@system-core/core/logic'
const app = await createApp(createConfig(), { http: adapter })