{
  "markdown": "# lambda-api-plugin\n\nA toolkit for building AWS API Gateway + Lambda server APIs. Provides end-to-end skill coverage from Lambda handler development and test writing to code quality enforcement.\n\n## Installation\n\n### Claude Code\n\nClone the repository and load it with `--plugin-dir`:\n\n```bash\ngit clone https://github.com/hu-shukang/lambda-api-plugin\nclaude --plugin-dir ./lambda-api-plugin\n```\n\nTo load it permanently across sessions, add it to your Claude Code settings:\n\n```json\n{\n  \"pluginDirectories\": [\"/path/to/lambda-api-plugin\"]\n}\n```\n\n### Cowork\n\nDownload the latest `.plugin` file from the [Releases](https://github.com/hu-shukang/lambda-api-plugin/releases) page and install it via the Cowork plugin settings.\n\n## Agents\n\nAgents run as subagents and execute multi-step tasks autonomously.\n\n### generate-lambda\n\nGenerates a new Lambda handler interactively. Asks for the resource name, HTTP method, action name, path parameters, and whether the handler needs DB access, then scaffolds all the files in one run. Creates:\n\n- `src/functions/<resource>/<action>/index.ts` — Middy handler with business logic\n- `src/functions/<resource>/<action>/schema.ts` — Zod event schema + OpenAPI route registration\n- Adds the schema import to `scripts/generate-openapi.ts`\n\nIf the Drizzle DB module is not yet set up, it creates `src/db/schema.ts`, `src/db/index.ts`, and `src/db/types.ts` automatically before generating the handler.\n\n**Triggers**: \"generate a lambda\", \"create a handler\", \"add an endpoint\", \"new lambda function\", \"generate user get\".\n\n### setup-project\n\nInitializes a new project from scratch. Asks for the package manager, database type, and project name, then sets up the full project structure in one run: Lambda utilities, test infrastructure, and Biome config.\n\n**Triggers**: \"setup project\", \"initialize project\", \"init lambda project\", \"scaffold a new API\".\n\n### run-tests\n\nRuns the Vitest test suite. Detects the package manager automatically and supports running unit tests only, integration tests only, the full suite, or with coverage reporting. Reports results with a concise pass/fail summary.\n\n**Triggers**: \"run tests\", \"run unit tests\", \"run integration tests\", \"check test coverage\", \"did the tests pass\".\n\n### write-tests\n\nReads a Lambda handler's source code, infers all testable branches, and writes both unit tests (DB mocked) and integration tests (real Testcontainers DB). Correctly orders table cleanup for FK constraints and generates seed data from the Drizzle schema.\n\n**Triggers**: \"write tests for `<handler>`\", \"add tests\", \"generate tests\", \"add test coverage for `<resource>`\".\n\n### biome-check\n\nLints and formats code using Biome. Supports check-only mode, applying safe fixes, format-only, and scoped runs against a specific file or directory. After fixing, runs a final check pass to confirm the codebase is clean.\n\n**Triggers**: \"run biome\", \"lint the code\", \"fix lint errors\", \"format the code\", \"biome check\".\n\n## Skills\n\nSkills activate automatically based on task context. No manual invocation required.\n\n### lambda-api-developer\n\nGuides development of AWS Lambda API handlers. Use when you want to:\n\n- Add a new API endpoint (create `index.ts` and `schema.ts`)\n- Write Zod validation schemas\n- Configure the Middy middleware chain\n- Use AWS Lambda Powertools (Logger, Parser)\n- Register OpenAPI routes\n\n**Triggers**: \"add an endpoint\", \"create a Lambda handler\", \"write a schema\", \"register an OpenAPI route\", or any work under `src/functions/`.\n\n### api-tester\n\nGuides writing unit and integration tests for Lambda handlers using Vitest and Testcontainers. Use when you want to:\n\n- Configure `vitest.config.ts`\n- Set up database test containers (PostgreSQL / MySQL)\n- Write unit tests with a mocked DB\n- Write integration tests with a real DB container\n- Set up coverage reporting\n\n**Triggers**: \"write tests\", \"unit test\", \"integration test\", \"configure vitest\", or any work under `tests/`.\n\n### drizzle-developer\n\nGuides database access with Drizzle ORM and schema migrations with Drizzle Kit. Use when you want to:\n\n- Define table schemas and relations (`src/db/schema.ts`)\n- Set up the Drizzle database singleton (`src/db/index.ts`)\n- Write queries — select, insert, update, delete, with filters, ordering, and pagination\n- Use the relational query API (`db.query.*`)\n- Configure `drizzle.config.ts` and run Kit commands (`generate`, `migrate`, `push`, `studio`)\n- Integrate Drizzle with Lambda handlers and tests\n\n**Triggers**: \"define a schema\", \"write a query\", \"drizzle migration\", \"db.select\", \"drizzle-kit generate\", or any work under `src/db/`.\n\n### aws-cdk-development\n\nGuides building AWS infrastructure with CDK in TypeScript. Use when you want to:\n\n- Create or refactor CDK stacks and constructs\n- Define Lambda functions, API Gateway, DynamoDB, S3, and other AWS resources as code\n- Configure `NodejsFunction` for TypeScript Lambda bundling\n- Validate stacks before deployment with `cdk-nag` and `cdk synth`\n- Organize stacks — nested stacks, construct boundaries, cross-stack exports\n- Write CDK unit tests and CloudFormation snapshot tests\n- Deploy and verify infrastructure with `cdk deploy`\n\n**Triggers**: \"create a CDK stack\", \"define infrastructure\", \"cdk deploy\", \"cdk synth\", \"IaC\", \"CloudFormation\", or any work on CDK constructs.\n\n### typescript-expert\n\nAdvanced TypeScript expertise covering type-level programming, performance optimization, migration strategies, and modern tooling. Use when you want to:\n\n- Design complex types — branded types, conditional types, template literal types, mapped types\n- Diagnose and fix TypeScript errors — circular types, \"inferred type cannot be named\", excessive stack depth\n- Optimize type checking performance — `incremental`, `skipLibCheck`, project references\n- Migrate JavaScript to TypeScript or upgrade between TypeScript versions\n- Choose and configure tooling — Biome vs ESLint, Turborepo vs Nx, ESM vs CJS\n- Write type tests with Vitest `expectTypeOf`\n- Configure monorepo TypeScript setups with project references\n\n**Triggers**: \"TypeScript error\", \"fix types\", \"type-level\", \"branded type\", \"tsconfig\", \"slow type checking\", \"migrate to TypeScript\", or any deep TypeScript question.\n\n### lint-rule-development\n\nGuides creating custom lint rules in Biome's Analyzer. Use when you want to:\n\n- Create a new lint rule or assist action\n- Add automatic code-fix actions\n- Implement semantic binding analysis\n- Add configurable options to a rule\n\n**Triggers**: \"create a lint rule\", \"implement a Biome rule\", \"noVar\", \"useConst\", or any work on Biome analyzer code.\n\n## Tech Stack\n\n- **Runtime**: AWS Lambda (Node.js / Bun)\n- **API layer**: API Gateway HTTP API\n- **Language**: TypeScript\n- **Middleware**: Middy\n- **Validation**: Zod v4\n- **Observability**: AWS Lambda Powertools\n- **Testing**: Vitest + Testcontainers\n- **ORM**: Drizzle ORM\n- **Migrations**: Drizzle Kit\n- **Linting**: Biome\n\n## Contributing\n\nIssues and pull requests are welcome at [hu-shukang/lambda-api-plugin](https://github.com/hu-shukang/lambda-api-plugin).\n\n## License\n\nMIT\n\n## Changelog\n\n### 0.2.0\n\n- Added `drizzle-developer` skill — Drizzle ORM queries, schema definition, Drizzle Kit migrations, Lambda integration\n- Added `typescript-expert` skill — type-level programming, performance optimization, migration strategies\n- Added `aws-cdk-development` skill — CDK stacks, constructs, NodejsFunction, cdk-nag validation\n- Added `setup-project` agent — initializes full project structure in one run\n- Added `run-tests` agent — runs Vitest suite with pass/fail summary\n- Added `write-tests` agent — generates unit and integration tests from handler source\n- Added `biome-check` agent — lints and formats code with Biome, applies safe fixes\n- Added `generate-lambda` agent — interactive Lambda handler scaffolding with auto DB setup\n- Added `SubagentStart` / `SubagentStop` hooks for subagent lifecycle logging\n\n### 0.1.0\n\n- Initial release\n- `lambda-api-developer` skill\n- `api-tester` skill\n- `lint-rule-development` skill\n\n## Version\n\n0.2.0\n",
  "bytes": 8048,
  "sha": "9371a41a91c20962b48d4e0ae839f3638c61c7fe5b18026cd7b2b71166c12071",
  "repo_slug": "hu-shukang/lambda-api-plugin",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/plg_hu_shukang_lambda_api_plugin_lambda_api__6b1dd4b7/readme"
}