By using AWS re:Post, you agree to the AWS re:Post Terms of Use

API Gateway with swagger documentation export error

0

I added one piece of documentation on our api gateway using the web UI and when I try to export it as swagger, I get the following error:

Cannot deserialize value of type java.lang.String from Object value (token JsonToken.START_OBJECT) at [Source: UNKNOWN; line: -1, column: -1] (through reference chain: io.swagger.models.ModelImpl["default"])

Here is what the documentation part looks like: Enter image description here

What am I doing wrong?

  • This a default example when you click on the documentation button.

2 Answers
0

The documentation is expecting a 'String' type value and you're offering an 'Object' type value.

Change either like this:

"{'Documentation': 'Global Authentication'}"

or

"Documentation: Global Authentication"
AWS
answered 2 years ago
0

The way I resolved the error was to delete the stage and then add it back, then the error went away.

answered 2 years 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