Skip to content
Empire Builder KitDocumentation
v1 Documentation

Find your next step.

Search the complete documentation, including code examples.

    Full-text search↑ ↓ navigate Enter open
    Browse documentation
    DocsGetting started

    Introduction

    Empire Builder Kit creates a TypeScript workspace for building products on AWS. You get one shared Foundation and one lean Product Slice per product, with sign-in, data, routing and deployment already wired.

    On this page
    1. What you get
    2. Lean by design
    3. What stays yours
    4. Where to start

    What you get

    A workspace is an Nx and pnpm repository that you own. It has three kinds of project.

    • The Foundation holds what every product shares in a stage: the Router, the Cognito user pool, the event bus, and logs and alarms. See Foundation.
    • A Product Slice holds one product: a Next.js web app, Lambda handlers, DynamoDB persistence, contracts and its own infrastructure. A generated Slice is 32 files. See Product Slices.
    • The optional root site serves the pages at /. It is static by default. See Static sites.
    Architecture plate / workspace

    A shared Foundation. Product-owned Slices.

    Product Slices around a shared FoundationSix example Product Slices surround the Foundation. Dashed links show each Slice consuming the shared capabilities: routing, identity, configuration and observability. The brass ring is the Foundation-owned EventBridge bus for one stage. Circles show responsibilities, not AWS security boundaries.WORKSPACE / ONE STAGEEXAMPLE PRODUCTFoundationSHARED CAPABILITIESIdentity · routingConfigurationObservabilityShared EventBridge busFoundation-owned · one per stageIOrdersPRODUCT SLICEIIBillingPRODUCT SLICEIIIInventoryPRODUCT SLICEIVNotificationsPRODUCT SLICEVReportingPRODUCT SLICEVIAccountsPRODUCT SLICEShared capabilitiesEvent busSix Slices shown as an example

    Choose Detail to inspect the labels. Download the SVG to keep or share this diagram.

    Every Slice consumes the same Foundation: one Router, one user pool and one event bus per stage. The six Slices are an example.

    One Foundation per stage, shared by every Product Slice in the workspace.

    Lean by design

    Code that is the same in every product does not belong in every product. Sign-in handling, key-value persistence and the infrastructure builders live in the @empire-builder-kit/runtime and @empire-builder-kit/nx packages, and a Slice calls them. The files in your repository are the ones you are expected to read and change.

    The same applies to tooling. A Slice has 12 Nx targets, the workspace root has seven, and continuous integration is two workflow files. The reference lists each one.

    What stays yours

    The framework records which generated files it manages. Everything else is yours, including the dependencies in each package.json. You can update Next.js, React or the AWS SDK without waiting for a framework release, and a framework upgrade keeps the changes you made. See Ownership and upgrades.

    Empire Builder Kit generates source and deployment workflows. It does not own an AWS account or run a hosted service: your workspace deploys into your accounts with your credentials.

    Where to start

    Follow the quickstart to create a workspace and a first Slice. If you would rather understand the model first, read Workspace.