Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,28 @@
"cdk"
],
"version": "1.0.0"
},
{
"category": "fullstack",
"description": "Build full-stack apps with AWS Amplify Gen 2 using guided workflows and SOPs",
"keywords": [
"aws",
"aws agent skills",
"amazon",
"amplify",
"fullstack",
"gen2",
"workflows"
],
"name": "aws-amplify",
"source": "./plugins/aws-amplify",
"tags": [
"aws",
"amplify",
"fullstack",
"workflows"
],
"version": "1.0.0"
}
]
}
3 changes: 2 additions & 1 deletion .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,9 @@ tools/ @awslabs/agent-plugins-admins

## Plugins (alphabetically listed)

plugins/aws-amplify @awslabs/agent-plugins-admins @awslabs/agent-plugins-maintainers @awslabs/agent-plugins-amplify
plugins/deploy-on-aws @awslabs/agent-plugins-admins @awslabs/agent-plugins-maintainers @awslabs/agent-plugins-deploy-on-aws

## File must end with CODEOWNERS file

.github/CODEOWNERS @awslabs/agent-plugins-admins
.github/CODEOWNERS @awslabs/agent-plugins-admins
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,10 @@ To maximize the benefits of plugin-assisted development while maintaining securi

## Plugins

| Plugin | Description | Status |
| ----------------- | ------------------------------------------------------------------------------------------------ | --------- |
| **deploy-on-aws** | Deploy applications to AWS with architecture recommendations, cost estimates, and IaC deployment | Available |
| Plugin | Description | Status |
| ------------------------------------------ | ------------------------------------------------------------------------------------------------ | --------- |
| [**aws-amplify**](plugins/aws-amplify) | Build full-stack apps with AWS Amplify Gen 2 using guided workflows and SOPs | Available |
| [**deploy-on-aws**](plugins/deploy-on-aws) | Deploy applications to AWS with architecture recommendations, cost estimates, and IaC deployment | Available |

## Installation

Expand Down
18 changes: 18 additions & 0 deletions plugins/aws-amplify/.claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"author": {
"name": "Amazon Web Services"
},
"description": "Build full-stack apps with AWS Amplify Gen 2 using guided workflows and SOPs",
"homepage": "https://github.com/awslabs/agent-plugins",
"keywords": [
"aws",
"amplify",
"fullstack",
"gen2",
"workflows"
],
"license": "Apache-2.0",
"name": "aws-amplify",
"repository": "https://github.com/awslabs/agent-plugins",
"version": "1.0.0"
}
15 changes: 15 additions & 0 deletions plugins/aws-amplify/.mcp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"mcpServers": {
"aws-mcp": {
"command": "uvx",
"timeout": 100000,
"type": "stdio",
"args": [
"mcp-proxy-for-aws@latest",
"--log-level",
"ERROR",
"https://aws-mcp.us-east-1.api.aws/mcp"
]
}
}
}
140 changes: 140 additions & 0 deletions plugins/aws-amplify/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,140 @@
# AWS Amplify Claude Plugin

Build full-stack applications with AWS Amplify Gen 2 using TypeScript code-first development.

## Overview

This plugin provides a workflow orchestrator for AWS Amplify Gen 2 development. It validates prerequisites, analyzes project state, retrieves official AWS SOPs via MCP, and guides you through backend creation, deployment, and frontend integration.

## Features

- **SOP-Driven**: Uses official AWS Amplify Standard Operating Procedures via MCP
- **Phased Workflow**: Backend → Sandbox → Frontend → Testing → Production
- **Framework Support**: React, Next.js, Vue, Angular, React Native, Flutter, Swift, Android
- **Gen 2 Only**: TypeScript code-first (`defineAuth`, `defineData`, `defineStorage`, `defineFunction`)

## Prerequisites

- Node.js 18.x or later
- AWS credentials configured (`aws configure` or `aws sso login`)
- `uv` package manager for MCP server: https://docs.astral.sh/uv/getting-started/installation/

## Installation

### Option 1: Marketplace (recommended)

```bash
/plugin marketplace add awslabs/agent-plugins
/plugin install aws-amplify@awslabs-agent-plugins
```

### Option 2: Load locally (for testing)

```bash
git clone https://github.com/awslabs/agent-plugins
claude --plugin-dir ./agent-plugins/plugins/aws-amplify
```

## Usage

### Slash Command

```
/aws-amplify:build I want to create a todo app with authentication
```

### Auto-Invoked Skill

The `amplify-workflow` skill is automatically invoked when you ask Claude to build, modify, or deploy an Amplify Gen 2 backend or full-stack app, for example:

- "Create a new Amplify backend with auth and a todo data model"
- "Add S3 storage and a Lambda function to my existing Amplify project"

The `amplify-deploy` skill is the mandatory entry point for all Amplify deployments (sandbox and production). It is automatically invoked for deployment requests, for example:

- "Deploy my Amplify sandbox environment"
- "Promote my sandbox to production"
- "Release my Amplify app"

When `amplify-workflow` reaches its deployment phases (Phase 2: Sandbox, Phase 5: Production), it delegates to `amplify-deploy` automatically.

These skills are **not** used for conceptual questions about Amplify, comparisons with other frameworks, or troubleshooting existing projects—ask those as normal questions without expecting the workflow to start. For build/create/deploy tasks, just describe what you want in natural language.

## Workflow Phases

| Phase | Description | Handled By |
| ---------- | ------------------------------- | ------------------------------------- |
| Backend | Create/modify Amplify resources | SOP: `amplify-backend-implementation` |
| Sandbox | Deploy to sandbox for testing | `amplify-deploy` skill |
| Frontend | Connect frontend to backend | SOP: `amplify-frontend-integration` |
| Testing | Local verification | Manual |
| Production | Deploy to production | `amplify-deploy` skill |

**Common Patterns:**

- New app: Backend → Sandbox → Frontend → Testing → Production
- Add feature: Backend → Sandbox
- Redeploy: Sandbox only
- Connect UI: Frontend → Testing
- Go live: Production only

## Plugin Structure

```
aws-amplify/
├── .claude-plugin/
│ └── plugin.json # Plugin manifest
├── commands/
│ └── build.md # /aws-amplify:build command
├── skills/
│ ├── amplify-deploy/
│ │ └── SKILL.md # Deployment skill (sandbox & production)
│ └── amplify-workflow/
│ └── SKILL.md # Auto-invoked orchestrator
├── .mcp.json # AWS MCP server config
└── README.md
```

## AWS Credentials

Must be configured before use:

```bash
# Option 1: Access keys
aws configure

# Option 2: SSO
aws sso login

# Verify
aws sts get-caller-identity
```

## MCP Server

This plugin requires the AWS MCP server for SOP retrieval. It's automatically configured via `.mcp.json`.

Verify it's working:

```
/mcp
```

Should show `aws-mcp` as active.

**If MCP is unavailable**, the plugin will STOP and ask you to configure it. It will not proceed without MCP.

**Note:** The MCP endpoint (`us-east-1.api.aws`) is the API location for SOP
retrieval only. It does not affect which region your Amplify resources deploy
to — deployment region is controlled by your AWS credentials and CLI configuration.

## License

Apache-2.0

## Resources

- [AWS Amplify Docs](https://docs.amplify.aws/)
- [Amplify Gen 2 Guide](https://docs.amplify.aws/react/start/)
- [Claude Code Plugins](https://code.claude.com/docs/en/plugins)
- [Model Context Protocol](https://modelcontextprotocol.io/)
27 changes: 27 additions & 0 deletions plugins/aws-amplify/commands/build.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
description: Build full-stack apps with AWS Amplify Gen 2 - describe what you want to build
argument-hint: "[description of what to build]"
---

# Build with AWS Amplify Gen 2

**Request:** $ARGUMENTS

## Input Validation

If `$ARGUMENTS` is empty or unclear, ask:

```
What would you like to build? For example:
- "A todo app with user authentication"
- "Add a GraphQL API to my existing Next.js app"
- "Deploy my app to production"
```

## Execution

Delegate to the `amplify-workflow` skill and follow its complete workflow.
The skill handles prerequisite validation, phase planning, SOP retrieval,
and user confirmation gates.

Gen 2 ONLY — no Gen 1 patterns (`amplify init`, `amplify push`).
60 changes: 60 additions & 0 deletions plugins/aws-amplify/skills/amplify-deploy/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
---
name: amplify-deploy
description: Deploy AWS Amplify Gen 2 applications to sandbox (development) or production environments. MUST be used when user wants to DEPLOY, RELEASE, PROMOTE, or PUBLISH an Amplify app. Handles both sandbox deployment for testing and production deployment for going live. This is the mandatory entry point for all Amplify deployment operations.
---

# Amplify Deploy

Deploy an AWS Amplify Gen 2 application to sandbox or production.

## When to Use This Skill

Use for any Amplify deployment:

- Deploy to sandbox for development/testing
- Deploy/promote to production
- Redeploy after code changes
- Any request involving "deploy my Amplify app"

---

## Invocation Context

This skill may be invoked standalone or from the `amplify-workflow` orchestrator.

- **From orchestrator:** The deployment type (sandbox or production) is specified
by the caller. Do not re-ask the user. Prerequisites (Node.js, npm, AWS
credentials) were already validated — skip the SOP's dependency verification step.
- **Standalone:** Determine deployment type from the user's request. Validate
prerequisites per the SOP.

## Mapping Deployment Targets to SOP Parameters

The SOP uses the parameter name `deployment_type` with values `sandbox` or `cicd`.
Map user/caller intent as follows:

- "sandbox", "development", "testing" → SOP deployment_type: **sandbox**
- "production", "prod", "live", "release", "cicd" → SOP deployment_type: **cicd**

---

## Retrieve and Follow the SOP

The **"amplify-deployment-guide"** SOP must be retrieved **at least once**
during the conversation using the SOP retrieval tool from `aws-mcp`.

**All steps in the SOP must be followed** for any type of deployment
(sandbox or production). The SOP contains the latest and most accurate
deployment procedures. Do not improvise or skip steps.

### Critical Rules

1. **Follow the SOP completely** - Do not improvise or skip steps
2. **If you encounter an error:**
- Fix the immediate issue
- Return to the SOP and continue from where you left off
- Do NOT abandon the SOP
3. **If you lose track of where you were:**
- Retrieve the SOP again
- Identify which step you completed last
- Continue from the next step
Loading
Loading