Loading...
Loading...
Guides building full-stack applications with AWS Blocks — an Infrastructure-from-Code framework. Applies when creating APIs, selecting Building Blocks (KVStore, DistributedTable, Database, AuthBasic, AuthCognito, Realtime, AsyncJob, FileBucket, etc.), running local development, or deploying AWS Blocks applications. Also covers AWS Blocks topics with validated, version-specific patterns that prevent common mistakes. Triggers when user mentions AWS Blocks; project has aws-blocks/ directory; code imports @aws-blocks packages.
npx skill4agent add aws/agent-toolkit-for-aws aws-blocksPackage naming: All packages are published under thescope (e.g.,@aws-blocks,@aws-blocks/core,@aws-blocks/blocks).@aws-blocks/bb-kv-store
aws-blocks/.bb-data/npm run sandboxnpm run deploynpx @aws-blocks/create-blocks-app my-app
cd my-appnpx @aws-blocks/create-blocks-app .aws-blocks/npx @aws-blocks/create-blocks-app .amplify/backend.tsnpx @aws-blocks/create-blocks-app my-app --template demo
cd my-app| Template | Description |
|---|---|
| Vite + lit-html starter app with basic authentication, data persistence, and realtime to help demonstrate basic app architecture and patterns (used when --template is omitted) |
| Vite + lit-html starter with a single "hello world" API method and a bare frontend |
| React + Vite starter with a single API endpoint and typed React frontend |
| Backend-only — no frontend, just the AWS Blocks API with a single endpoint |
| Todo app with AuthBasic, KVStore, DistributedTable, Zod schemas, indexes, and auth-protected CRUD |
| Full AuthCognito passwordless email-OTP with roles, device management, and Authenticator UI |
| Next.js + React starter with AWS Blocks backend integration (SSR + Server Components) |
node_modules/@aws-blocks/bb-kv-store/README.mdawait auth.requireAuth(context)new AppSetting(scope, id, { secret: true }).env*blockPublicAccessCORS_ALLOWED_ORIGINScrossDomain: trueSameSite=None; Secure; Partitionedmonitoring: { enabled: true, snsTopicArn: '...' }