Skip to main content
skill CX Codex

debugging-lambda-timeouts — Claude Code skill: how to install

Investigates AWS Lambda timeout failures by inspecting CloudWatch logs, metrics, and configurations. Use it when function runs hit or approach execution limits.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add aws/agent-toolkit-for-aws --skill debugging-lambda-timeouts -a claude-code
Open on GitHub

What debugging-lambda-timeouts does

This skill investigates execution timeouts in AWS Lambda. It gathers runtime settings and checks database connection delays. If source code is provided, the skill inspects it for timeout-prone patterns.

Diagnostics rely on CloudWatch logs and invocation metrics. The skill checks cold start spikes alongside memory limits, because resource starvation often causes execution stalls. All findings go into a structured debugging report with prioritized fixes.

AWS credentials must grant read permissions for Lambda, CloudWatch Logs, and CloudWatch Metrics. Missing permissions break the diagnostic run immediately. When CloudWatch Logs Insights queries fail due to time ranges, the analysis window needs to be shortened.

What it helps with

  • trace timeout causes in CloudWatch logs
  • diagnose database connection delays and network latency
  • evaluate cold start overhead and memory constraints
  • find slow execution patterns in Lambda code

Example prompts for the agent

  • Investigate why the process-orders Lambda function in us-east-1 keeps timing out.
  • Analyze CloudWatch metrics and configuration for sync-users, it is approaching the timeout limit.

How to install debugging-lambda-timeouts

1Skills CLI (Vercel)

npx skills add aws/agent-toolkit-for-aws --skill debugging-lambda-timeouts -a claude-code

2Manually: put the files in place

~/.claude/skills/debugging-lambda-timeouts/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/debugging-lambda-timeouts/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about debugging-lambda-timeouts

How to install debugging-lambda-timeouts in Claude Code?

Run npx skills add aws/agent-toolkit-for-aws --skill debugging-lambda-timeouts -a claude-code.

What does debugging-lambda-timeouts do?

It systematically reviews Lambda configuration, CloudWatch metrics, cold start patterns, and external dependencies. At the end, it outputs a structured debugging report with prioritized fixes.

What AWS access is needed to run the investigation?

AWS credentials must have permissions for Lambda, CloudWatch Logs, and CloudWatch Metrics. Without them, diagnostic queries fail with access denied errors.

Source text

SKILL.md · Apache-2.0
---
name: debugging-lambda-timeouts
description: Debugs AWS Lambda function timeout failures by systematically analyzing function configuration, CloudWatch logs and metrics, VPC/networking, cold starts, memory constraints, and downstream dependencies to identify root causes with actionable fixes. Use when a Lambda function is timing out or approaching its timeout limit.
version: 1
---

# Debugging Lambda Timeouts

## Overview

Domain expertise for systematically investigating AWS Lambda function timeout failures
by analyzing function configuration, CloudWatch logs, metrics, dependencies, cold start
patterns, and code. Identifies common causes such as insufficient timeout settings,
external service delays, database connection issues, memory constraints, and inefficient
code patterns, then provides prioritized recommendations.

## Debug a Lambda timeout

To investigate and resolve Lambda timeout issues, follow the procedure exactly.
See [Lambda timeout debugging procedure](references/lambda-timeout-debugging.md).

The procedure collects function configuration, CloudWatch metrics and logs, dependency
analysis, and cold start patterns. If Lambda code is provided, it also reviews the code
for timeout-prone patterns. Results are compiled into a structured debugging report with
prioritized recommendations.

## Troubleshooting

### Function not found

Verify the function name and region. Use `aws lambda list-functions --region <region>`
to list available functions.

### No logs available

The function may not have been invoked recently or logging may be disabled. Check the
function's log group configuration and invocation metrics.

### Access denied errors

Verify AWS credentials have permissions for Lambda, CloudWatch Logs, and CloudWatch
Metrics. See the full procedure for details.

### Log query time range issues

If CloudWatch Logs Insights queries fail with time range errors, reduce the analysis
window or check log group retention settings. See the full procedure for details.

© aws · Apache-2.0 · aws/agent-toolkit-for-aws

Similar skills

Everything for Cloud: AWS, Azure, GCP →

From the same set133

connecting-lambda-to-dynamodb Connects AWS Lambda functions to DynamoDB tables. Guides IAM execution roles, DynamoDB stream event mappings, and troubleshooting. CX Codex +1 6,500installs troubleshooting-s3-files Diagnoses Amazon S3 Files issues, from mount timeouts and IAM permission errors to sync delays and file conflicts. CX Codex +1 6,300installs launching-ec2-instance-with-best-practices This skill launches EC2 instances with security and cost controls in place. Use it when deploying a new AWS instance and checking its setup after launch. CX Codex +1 6,300installs setting-up-cloudwatch-alarm-notifications Wires CloudWatch alarms to notification channels through SNS: encrypted topics, subscriptions, access policies and alarm actions. CX Codex +1 6,300installs configuring-vpc-endpoints-for-private-aws-service-access A skill that walks the agent through VPC endpoint setup with AWS PrivateLink, so AWS services stay reachable without an internet gateway or public IPs. CX Codex +1 6,400installs setting-up-ec2-instance-profiles Configures EC2 instance profiles and IAM roles so applications call AWS services without hardcoded credentials. Useful when an instance needs temporary access to S3, DynamoDB, or SQS. CX Codex +1 6,200installs routing-traffic-with-route53-and-cloudfront Sets up Route 53 to send a custom domain to a CloudFront distribution with HTTPS and IPv6. Use it when creating alias records or connecting a domain to CloudFront. CX Codex +1 6,200installs creating-api-gateway-stage Builds an API Gateway stage with CloudWatch logging, X-Ray tracing, throttling and WAF. Handy when a REST API ships to dev, test or production. CX Codex +1 6,200installs

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor