Create a Project
axs new scaffolds a complete, deployable project from a validated starter template:
axs new my-apiWith no flags you get the rest-v1 starter in module layout, and the CLI prompts you through the choices that matter. Every starter is extracted from a synth-tested example project in the framework repository, so what you scaffold is exactly what CI validates on every commit.
Pick a starter (--template)
Section titled “Pick a starter (--template)”| Starter | Surface | What you get |
|---|---|---|
rest-v1 | API Gateway REST API | The full-breadth starter: REST routes, Cognito auth, DynamoDB, SQS/SNS, KMS, S3, Secrets, WAF/SES, observability, budget (opt-in). |
rest-v2 | API Gateway HTTP API (v2) | Intentionally lean — the API surface only, with JWT auth and a greedy /{proxy+} route. No storage/security breadth. |
graphql | AppSync | GraphQL schema + resolvers alongside the full construct breadth, with resolver Lambdas wired through the same registries. |
worker | No API — standalone compute | A cron Lambda and an SQS queue consumer with a table and observability. Background processing without an HTTP surface. |
bare | No API — the floor | One standalone Lambda and an optional DynamoDB table. Everything else is something you add, not something you strip out. |
axs new my-api --template rest-v1axs new my-api --template rest-v2axs new my-graphql --template graphqlaxs new my-jobs --template workeraxs new my-fn --template bareIf --template is omitted, the CLI prompts for it.
Pick a layout (--layout)
Section titled “Pick a layout (--layout)”module (the default) groups Lambdas by module and kind under lambdas/modules/; feature colocates each feature’s Lambdas and tables under lambdas/features/. In this version, feature is supported for the rest-v1, rest-v2, graphql, and worker starters — only bare is module-only, and the CLI rejects that pairing with an explicit error. On graphql, the feature layout also colocates resolver artifacts under each feature. The full comparison and support matrix live in Layout: Module vs Feature.
axs new my-api --template rest-v1 --layout featureFeature prompts set defaults — nothing is pruned
Section titled “Feature prompts set defaults — nothing is pruned”For starters with optional construct groups, the interactive prompts ask one yes/no per group (queues, topics, KMS, S3, secrets, WAF, SES, EventBridge, …). Your answers become the DEFAULT_FEATURES values in the generated config/features.ts — no code is deleted. A “no” at create time is fully reversible: edit the constant, run axs feature, or pass --context feature.<name>=on at synth. Mandatory groups (like the rest-v1 data layer) are not prompted for. See Feature Toggles.
Composer wiring (--composer)
Section titled “Composer wiring (--composer)”--composer scaffolds a build-your-own project driven by the single defineAxisApp entry point instead of a per-stack bin/app.ts. You pick the API surface’s access model and authorizer at create time, and your selections are recorded in axis.json (wiring: "composer") as the canonical project state:
axs new my-api --composer --template rest-v1Composer-specific flags cover non-interactive use: --api-access public|authenticated|mixed, --authorizer cognito|iam|custom|none, --api-key, and for GraphQL --graphql-auth-mode, --graphql-additional-mode (repeatable), and --oidc-issuer. Under --yes, a composer API surface with no auth flag is an error — a project is never silently public. The model behind all of this is in The Composer.
Other flags
Section titled “Other flags”--skip-install— scaffold files only; skipgit init, dependency install, and Husky setup.-y, --yes— skip the summary confirmation (CI / non-interactive).--local— framework contributors only: resolve@axis-tech-co/*from a local checkout viafile:paths, skipping registry auth.
What the CLI does after scaffolding
Section titled “What the CLI does after scaffolding”- Writes the full project structure from the extracted starter template, plus a
STRUCTURE.mdnarrative at the root for humans and AI tools. - Writes
axis.jsonrecording the starter, layout, paths, and conventions. - Runs
git initand creates the initial commit. - Installs dependencies and activates the Husky git hooks.
- Prints next steps — review the structure, edit
config/dev-config.ts, bootstrap CDK, deploy.
Point CDK at your AWS account: AWS Credentials & Bootstrap.
© 2026 Axis Tech. Powered by axis-tech.co.