Changes to Serverless Function Error Responses
We are updating the error responses for Serverless Functions to provide more accurate status codes when issues originate from your Serverless Function code. Previously, some Serverless Functions that contained errors in their code were incorrectly returning a 500
status code. This change will help you more accurately diagnose issues with your Serverless Functions and enables more granular error handling.
What's Changing?
Previously, some errors within Serverless Functions, with the exception of 429
errors, were returning a 500
status code. This could lead to confusion, as 500
errors typically imply a server-side issue possibly with HubSpot's platform, rather than an issue with your own code.
We are updating the system to ensure that errors originating from your Serverless Function code return appropriate 4xx
status codes. This means:
- You will receive a
4xx
error code when the issue originates directly from your Serverless Function code. - The original error message will continue to be returned, allowing you to troubleshoot the specific problem.
This change will help you more clearly distinguish between issues that are caused by your Serverless Function code and issues that are caused by HubSpot's platform.
When is it happening?
This change will begin rolling out on October 8, 2025. It will be rolled out gradually to all accounts.
Questions or comments? Join us in the developer forums.