Error map

Malformed Lambda proxy response API Gateway {"message": "Internal server error"} 502 — Malformed Lambda proxy response

AWS · layer 6, Platform & cloud

Open the full error page →

Centre: this error. First ring: errors it is linked with (12). Outer ring: what those are linked with. Colours show the layer of a request each error belongs to. Click any dot to re-centre the map on it; hover to follow its connections. The centre dot opens the error page.

Malformed Lambda proxy response — API Gateway {"message": "Internal server error"} 502 — Malformed Lambda proxy response (AWS)Malformed L…500 — HTTP 500 Internal Server Error (HTTP)500Task timed out — AWS Lambda: Task timed out after X seconds (AWS)Task timed outEndpoint request timed out — API Gateway: {"message": "Endpoint request timed out"} (504 after 29 seconds) (AWS)Endpoint request ti…MessageRejected — SES MessageRejected: Email address is not verified. The following identities failed the check in region (AWS)MessageRejectedRequestEntityTooLargeException — Lambda: Request must be smaller than 6291456 bytes for the InvokeFunction operation (RequestEntityTooLargeException) (AWS)RequestEntityTooLar…502 — HTTP 502 Bad Gateway (HTTP)502not authorized to access this resource — API Gateway 403: User is not authorized to access this resource with an explicit deny (AWS)not authorized to a…role cannot be assumed by Lambda — InvalidParameterValueException: The role defined for the function cannot be assumed by Lambda (AWS)role cannot be assu…Runtime.ImportModuleError — Runtime.ImportModuleError: Unable to import module 'lambda_function': No module named 'x' (AWS)Runtime.ImportModul…Runtime.HandlerNotFound — Runtime.HandlerNotFound: index.handler is undefined or not exported (AWS)Runtime.HandlerNotF…Runtime exited with error: signal: killed — Lambda: Runtime exited with error: signal: killed (Runtime.ExitError) (AWS)Runtime exited with…Unzipped size must be smaller than 262144000 bytes — Lambda: Unzipped size must be smaller than 262144000 bytes (AWS)Unzipped size must …404 — HTTP 404 Not Found (HTTP)404503 — HTTP 503 Service Unavailable (HTTP)503SyntaxError: JSON — SyntaxError: Unexpected token < in JSON at position 0 (JavaScript)SyntaxError: JSONThrottlingException — AWS: ThrottlingException / Rate exceeded (AWS)ThrottlingException504 — HTTP 504 Gateway Timeout (HTTP)504TimeoutException — java.util.concurrent.TimeoutException (Java)TimeoutException2006 — MySQL ERROR 2006 (HY000): MySQL server has gone away (MySQL)2006408 — HTTP 408 Request Timeout (HTTP)408499 — HTTP 499 Client Closed Request (Nginx) (HTTP)499PHP mail — PHP mail() returns false / emails not delivered (PHP)PHP mailIAM AccessDeniedException — AccessDeniedException: User: arn:aws:iam::... is not authorized to perform: service:Action on resource: ... (AWS)IAM AccessDeniedExc…Pending validation — ACM certificate stuck in Pending validation (AWS)Pending validation413 — HTTP 413 Content Too Large (Request Entity Too Large) (HTTP)413EMFILE — Too many open files (EMFILE) (Linux)EMFILEfork: retry: Resource temporarily unavailable — fork: retry: Resource temporarily unavailable (process/thread limit) (Linux)fork: retry: Resour…ECONNREFUSED — Error: connect ECONNREFUSED 127.0.0.1:5432 (Node.js)ECONNREFUSED407 — HTTP 407 Proxy Authentication Required (HTTP)407520 — Cloudflare Error 520: Web Server Returned an Unknown Error (Cloudflare)520AccessDenied — AWS S3: AccessDenied (403) when calling GetObject / PutObject (AWS)AccessDenied403 — HTTP 403 Forbidden (HTTP)403AuthorizationFailed — Azure: AuthorizationFailed — The client does not have authorization to perform action (Azure)AuthorizationFailedNot allowed — WordPress: Sorry, you are not allowed to access this page. (WordPress)Not allowedsts:AssumeRole denied — is not authorized to perform: sts:AssumeRole on resource: arn:aws:iam::...:role/... (AWS)sts:AssumeRole deni…KMS AccessDenied kms:Decrypt — KMS: not authorized to perform: kms:Decrypt (or the key policy does not allow access) (AWS)KMS AccessDenied km…ERESOLVE — npm ERR! code ERESOLVE — unable to resolve dependency tree (npm)ERESOLVEMODULE_NOT_FOUND — Error: Cannot find module 'x' (MODULE_NOT_FOUND) (Node.js)MODULE_NOT_FOUNDCould not resolve — Gradle: Could not resolve all files for configuration / Could not resolve dependency (Android)Could not resolveTypeError: not a function — TypeError: x is not a function (JavaScript)TypeError: not a fu…redirect_uri_mismatch — OAuth Error: redirect_uri_mismatch (Authentication)redirect_uri_mismat…DB connection — WordPress: Error Establishing a Database Connection (WordPress)DB connectionOOMKilled — Kubernetes: OOMKilled (exit code 137) (Kubernetes)OOMKilledOutOfMemoryError — java.lang.OutOfMemoryError: Java heap space (Java)OutOfMemoryErrorMEMORY_MANAGEMENT — Blue Screen: MEMORY_MANAGEMENT (Stop code 0x0000001A) (Windows)MEMORY_MANAGEMENT1025 — Cloudflare Error 1025: Please check back later (Workers request limit) (Cloudflare)10251102 — Cloudflare Error 1102: Worker exceeded resource limits (CPU time / memory) (Cloudflare)1102413 (Cloudflare 100 MB) — Cloudflare 413 Request Entity Too Large (upload over the plan limit) (Cloudflare)413 (Cloudflare 100…

Directly related (12)

500HTTP

HTTP 500 Internal Server Error

The server hit an unexpected condition — usually an unhandled exception or misconfiguration in the application.

Task timed outAWS

AWS Lambda: Task timed out after X seconds

The function ran longer than its configured timeout (default 3 seconds) and Lambda stopped it.

Endpoint request timed outAWS

API Gateway: {"message": "Endpoint request timed out"} (504 after 29 seconds)

The backend (usually Lambda) didn’t respond within API Gateway’s integration timeout (29 seconds by default for REST APIs).

MessageRejectedAWS

SES MessageRejected: Email address is not verified. The following identities failed the check in region

SES refused to send because the From address/domain isn’t verified — or the account is still in the SES sandbox, where recipients…

RequestEntityTooLargeExceptionAWS

Lambda: Request must be smaller than 6291456 bytes for the InvokeFunction operation (RequestEntityTooLargeException)

The event payload (or response) is over Lambda’s 6 MB synchronous limit (256 KB for async invocations).

502HTTP

HTTP 502 Bad Gateway

A proxy or gateway (Nginx, load balancer, CDN) got an invalid response — or no response — from the upstream server behind it.

not authorized to access this resourceAWS

API Gateway 403: User is not authorized to access this resource with an explicit deny

An API Gateway authorizer (Lambda/Cognito) or resource policy denied the request.

role cannot be assumed by LambdaAWS

InvalidParameterValueException: The role defined for the function cannot be assumed by Lambda

The execution role’s trust policy doesn’t allow lambda.amazonaws.com — or the role was just created and IAM hasn’t propagated yet.

Runtime.ImportModuleErrorAWS

Runtime.ImportModuleError: Unable to import module 'lambda_function': No module named 'x'

Lambda couldn’t load your handler file or one of its dependencies — the package is missing from the deployment zip/layer or the h…

Runtime.HandlerNotFoundAWS

Runtime.HandlerNotFound: index.handler is undefined or not exported

Lambda loaded the file but couldn’t find the function named in the handler setting.

Runtime exited with error: signal: killedAWS

Lambda: Runtime exited with error: signal: killed (Runtime.ExitError)

The function process was killed — almost always because it ran out of its configured memory.

Unzipped size must be smaller than 262144000 bytesAWS

Lambda: Unzipped size must be smaller than 262144000 bytes

The function code plus layers exceed Lambda’s 250 MB unzipped limit for zip deployments.

Two steps away (36)

404HTTP

HTTP 404 Not Found

The server can’t find anything at the requested URL.

503HTTP

HTTP 503 Service Unavailable

The server is temporarily unable to handle the request — overloaded, in maintenance, or has no healthy backends.

SyntaxError: JSONJavaScript

SyntaxError: Unexpected token < in JSON at position 0

`JSON.parse()` / `response.json()` received something that isn’t JSON — very often an HTML error page.

ThrottlingExceptionAWS

AWS: ThrottlingException / Rate exceeded

You exceeded the request rate for an AWS API; retry with exponential backoff.

504HTTP

HTTP 504 Gateway Timeout

A proxy or gateway waited too long for the upstream server to respond and gave up.

TimeoutExceptionJava

java.util.concurrent.TimeoutException

A Future.get(timeout) or async operation didn’t complete in the allowed time.

2006MySQL

MySQL ERROR 2006 (HY000): MySQL server has gone away

The connection to MySQL was closed — usually by a timeout or a packet larger than `max_allowed_packet`.

408HTTP

HTTP 408 Request Timeout

The server closed the connection because the client took too long to send the complete request.

499HTTP

HTTP 499 Client Closed Request (Nginx)

Nginx-specific code logged when the client disconnected before the server finished responding.

PHP mailPHP

PHP mail() returns false / emails not delivered

PHP’s mail() function failed or emails never arrive (spam or rejected).

IAM AccessDeniedExceptionAWS

AccessDeniedException: User: arn:aws:iam::... is not authorized to perform: service:Action on resource: ...

The IAM user or role making the call has no permission for that action on that resource — the message names both.

Pending validationAWS

ACM certificate stuck in Pending validation

ACM is waiting to see the DNS (or email) validation record — it wasn’t created, was created in the wrong DNS zone, or has a typo.

413HTTP

HTTP 413 Content Too Large (Request Entity Too Large)

The request body is bigger than the server is willing to accept — usually a file upload over the configured limit.

EMFILELinux

Too many open files (EMFILE)

The process hit its file-descriptor limit — sockets, files and pipes all count.

fork: retry: Resource temporarily unavailableLinux

fork: retry: Resource temporarily unavailable (process/thread limit)

The user or container hit its maximum number of processes/threads (ulimit -u, pids cgroup), so new processes can’t be created.

ECONNREFUSEDNode.js

Error: connect ECONNREFUSED 127.0.0.1:5432

Nothing is listening at that host:port — the target service is down or you’re connecting to the wrong address.

407HTTP

HTTP 407 Proxy Authentication Required

A proxy between you and the server requires credentials before it will forward your request.

520Cloudflare

Cloudflare Error 520: Web Server Returned an Unknown Error

Cloudflare connected to your origin, but the origin returned an empty, unknown or invalid response.

AccessDeniedAWS

AWS S3: AccessDenied (403) when calling GetObject / PutObject

An IAM policy, bucket policy, ACL/ownership setting, Block Public Access or KMS key policy denied the S3 request.

403HTTP

HTTP 403 Forbidden

The server understood the request but refuses to authorize it — you (or the server process) are not allowed to access this resour…

AuthorizationFailedAzure

Azure: AuthorizationFailed — The client does not have authorization to perform action

The signed-in identity (user, service principal or managed identity) lacks an Azure RBAC role for that action on that scope.

Not allowedWordPress

WordPress: Sorry, you are not allowed to access this page.

Your user role lacks the capability for that admin screen — or the database table prefix / user capabilities are out of sync afte…

sts:AssumeRole deniedAWS

is not authorized to perform: sts:AssumeRole on resource: arn:aws:iam::...:role/...

The caller can’t assume the role — either its own policy doesn’t allow sts:AssumeRole, or the role’s trust policy doesn’t trust t…

KMS AccessDenied kms:DecryptAWS

KMS: not authorized to perform: kms:Decrypt (or the key policy does not allow access)

The caller can’t use the KMS key that encrypts the data — the key policy or IAM policy doesn’t allow kms:Decrypt/GenerateDataKey.

ERESOLVEnpm

npm ERR! code ERESOLVE — unable to resolve dependency tree

npm 7+ found conflicting peer dependency requirements and refuses to install a broken tree.

MODULE_NOT_FOUNDNode.js

Error: Cannot find module 'x' (MODULE_NOT_FOUND)

Node can’t resolve the module path — the package isn’t installed, or a relative path/extension is wrong.

Could not resolveAndroid

Gradle: Could not resolve all files for configuration / Could not resolve dependency

Gradle couldn’t download a dependency — wrong coordinates/version, missing repository, offline mode, or network/proxy issues.

TypeError: not a functionJavaScript

TypeError: x is not a function

You called something as a function, but its value is not a function (it’s undefined, a string, an object…).

redirect_uri_mismatchAuthentication

OAuth Error: redirect_uri_mismatch

The redirect URI in your OAuth request doesn’t exactly match one registered for the client in the provider’s console.

DB connectionWordPress

WordPress: Error Establishing a Database Connection

WordPress can’t connect to its MySQL/MariaDB database with the credentials in wp-config.php, or the database server is down.

OOMKilledKubernetes

Kubernetes: OOMKilled (exit code 137)

The container used more memory than its limit, and the kernel killed it.

OutOfMemoryErrorJava

java.lang.OutOfMemoryError: Java heap space

The JVM ran out of heap memory and garbage collection couldn’t free enough.

MEMORY_MANAGEMENTWindows

Blue Screen: MEMORY_MANAGEMENT (Stop code 0x0000001A)

Windows detected a severe memory-management error — commonly faulty RAM, unstable memory settings or a bad driver.

1025Cloudflare

Cloudflare Error 1025: Please check back later (Workers request limit)

The site’s Cloudflare Workers plan exceeded its daily request limit (free plan: 100,000 requests/day).

1102Cloudflare

Cloudflare Error 1102: Worker exceeded resource limits (CPU time / memory)

The Worker used more CPU time or memory than its plan allows for a single request.

413 (Cloudflare 100 MB)Cloudflare

Cloudflare 413 Request Entity Too Large (upload over the plan limit)

The request body is larger than Cloudflare allows through the proxy — 100 MB on Free/Pro, 200 MB Business, 500 MB Enterprise defa…