aws-serverless
建置生產環��� AWS 無伺服器應用程式
此技能可協助開發人員建立具備生產就緒水準的 AWS 無伺服器應用程式,包含正確的 Lambda 模式、API Gateway 整合以及事件驅動架構。
下載技能 ZIP
在 Claude 中上傳
前往 設定 → 功能 → 技能 → 上傳技能
開啟並開始使用
測試它
正在使用「aws-serverless」。 Create a Lambda handler that reads from DynamoDB
預期結果:
A Node.js Lambda handler with AWS SDK v3, proper error handling, DynamoDBDocumentClient setup, and API Gateway response format with CORS headers.
正在使用「aws-serverless」。 Write SAM template for HTTP API with Lambda
預期結果:
A SAM template showing HttpApi definition, Lambda function with DynamoDBReadPolicy and DynamoDBCrudPolicy, and proper CORS configuration.
正在使用「aws-serverless」。 Implement SQS batch processing with retry logic
預期結果:
Lambda handler that iterates through SQS records, catches individual failures, tracks batchItemFailures, and returns them for SQS retry mechanism.
安全審計
安全This skill provides documentation and code patterns for AWS serverless development. Static analyzer flagged 34 potential issues, but all are false positives triggered by YAML code blocks and standard AWS terminology. The skill contains only legitimate code examples for Lambda handlers, SAM templates, and infrastructure configuration. No malicious patterns found.
偵測到的模式
品質評分
你能建構什麼
新無伺服器專案設定
Generate proper Lambda handler structure with DynamoDB integration, error handling, and API Gateway response format.
事件驅動架構
Create SQS-triggered Lambda functions with batch processing, partial failure handling, and dead letter queue configuration.
基礎設施即程式碼
Write SAM templates with proper IAM policies, environment variables, CORS settings, and resource definitions.
試試這些提示
Create a Node.js Lambda handler function that reads from DynamoDB using the AWS SDK v3. Include proper error handling and return an API Gateway compatible response.
Write a SAM template that creates an HTTP API with Lambda integration. Include GET and POST endpoints with DynamoDB read and write policies.
Create a Lambda function that processes SQS messages in batches. Include partial failure handling that reports failed items back to SQS for retry.
Show best practices for reducing Lambda cold start times including memory allocation, dependency management, and VPC considerations.
最佳實務
- Initialize AWS SDK clients and database connections outside the Lambda handler for reuse across invocations
- Use DynamoDBDocumentClient for simplified attribute marshaling and unmarshaling
- Configure appropriate timeout values matching your function execution time plus overhead
- Use provisioned concurrency for latency-sensitive applications
避免
- Do not create monolithic Lambda functions that handle multiple unrelated operations
- Avoid including large dependencies that are rarely used to reduce deployment package size
- Do not make synchronous calls inside VPC-attached Lambda without considering ENI attachment overhead
- Avoid using wildcard CORS AllowOrigins in production unless explicitly required