This table outlines the HTTP status codes you may encounter when using the API, along with descriptions to help you understand and troubleshoot issues.

Error codeDescription
400Bad request error: Indicates an issue with the format or content of your request. This error may also encompass other 4XX status errors not specifically listed here.
401Authentication error: There’s an issue with your API key, or it’s missing from your request headers resulting in unauthorized access.
403Permission error: Your API key doesn’t have permission to access the requested resource.
404Model not found error: The specified model couldn’t be found. This may be due to an incorrect URL or model ID.
429Rate limit exceeded: You have exceeded the allotted number of requests per time period for your account. Please wait and try your request again later.
500API error: An unexpected error occurred within our systems. If this persists, contact support for further assistance.
503Service unavailable: The server is currently unable to handle the request due to a temporary overload or maintenance. Please retry your request after some time.
504Timeout error: The server didn’t receive a timely response from an upstream server. Please retry your request after some time.

Best practices

Validate requests

Ensure that all requests are correctly formatted and include all necessary parameters and authentication information before sending them to the server. You can check the API reference for the correct information.

Check API key

Ensure that you are using a valid API key, specific to either the API/SDK or Writer Framework. Use the API Quickstart for the former and the Writer Framework Quickstart for the latter.

Check for firewalls

Ensure that firewalls or security settings are not blocking the Writer API or your application or service using the Writer API or SDK.

Monitor and log errors

Continuously monitor and log errors on your side to identify patterns or recurring issues that may require changes to your application or further investigation.