Can't export swagger documentation anymore

0

After publishing documentation from api gateway, I can't download the swagger documentation anymore. I click "Download Documentation" and then click "Export API" to get an export of the swagger and it won't start the download of the swagger file

In developer tools i do see a console error: Panorama: Event of size 543334 bytes is too long - the maximum size is 45000

  • I'd suggest using the "Feedback" link on the Console page to report this, and include that error message. That report will go directly to the team which owns that page.

2 Answers
0

This limitation might not be directly related to the Swagger export itself but could be part of a logging or event handling system within your environment or the API Gateway's management console. If the UI is causing issues due to this limitation, consider using the API Gateway's CLI or SDKs to export your Swagger documentation.

profile picture
EXPERT
answered a month ago
0

According to the AWS documentation, API Gateway has a limit of 45KB on the size of events.

A few things you can try:

Simplify your API documentation by removing unnecessary details or examples to reduce the file size. API Gateway supports documentation inheritance which allows defining strings once and reusing them, which can help reduce size.

Export the documentation without including examples by setting the examples=false parameter in the export request. This will exclude example values from the exported file.

Break up your documentation into smaller versions or modules if possible to stay within the event size limit for individual exports. You can then download the pieces separately.

Check if your API Gateway usage and limits allow increasing the event size quota. Some AWS accounts have higher limits that can be requested.

As a last resort, programmatically export the documentation using the API Gateway APIs or SDKs to have more control over the export process and response handling compared to the console download

profile picture
EXPERT
answered a month ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions