hoppscotch icon indicating copy to clipboard operation
hoppscotch copied to clipboard

[bug]: openapi support for post/put body schemas

Open christopheblin opened this issue 4 years ago • 8 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Current behavior

After importing an openapi doc, I expect to be able to do post/put request easily but except the path nothing is preloaded !

Capture d’écran 2022-01-25 134302

At least, I'd expect to preload the sample like in the basic swaggerui

Steps to reproduce

Import the petstore openapi Choose addPet operation Go in the body

=> you should see Capture d’écran 2022-01-25 134513

Environment

Production

Version

Local

christopheblin avatar Jan 25 '22 12:01 christopheblin

This is not a bug, and is just the way the body imports are implemented for OpenAPI specs as of right now. This can be a welcome addition to the OpenAPI importer.

We will add this to the backlog.

Or for anyone interested in picking up this issue, you can refer to this file: https://github.com/hoppscotch/hoppscotch/blob/main/packages/hoppscotch-app/helpers/import-export/import/openapi.ts

AndrewBastin avatar Jan 25 '22 16:01 AndrewBastin

This is not a bug, and is just the way the body imports are implemented for OpenAPI specs as of right now. This can be a welcome addition to the OpenAPI importer.

We will add this to the backlog.

Or for anyone interested in picking up this issue, you can refer to this file: https://github.com/hoppscotch/hoppscotch/blob/main/packages/hoppscotch-app/helpers/import-export/import/openapi.ts

Moved to https://github.com/hoppscotch/hoppscotch/blob/main/packages/hoppscotch-common/src/helpers/import-export/import/openapi.ts

jessereynolds avatar Aug 18 '23 05:08 jessereynolds