OpenAPITools / OpenAPITools/openapi-generator
[REQ] Generate response skeletons too when generating a postman collection (Only generating requests but no responses)
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 26.8k
- Forks
- 7.7k
- PR merge metrics
- PR metrics pending
Description
Is your feature request related to a problem? Please describe.
When generating a postman collection json from the CLI using a docker image, it generates all requests and folders, but does not generate responses as it does when you import the swagger/openapi into the postman desktop or web application.
For me, and surely for other people, this is very useful when creating API mocks as the collection contains the skeleton of the responses and the data types
Describe the solution you'd like
I would like that when generating the postman collection it would be as complete as when importing it into the postman application, and that not only the requests but also the responses would be generated
Describe alternatives you've considered
I am not sure if there are alternatives as the problem is the lack of richness of the generated document
Additional context
Screenshot of a postman collection created by importing the swagger file into the postman desktop app
(You can see how the request contains examples of the responses)
Screenshot of a postman collection generated with openapi-generator using the following command:
docker run --rm -v C:/openapigenerator:/etc/ openapitools/openapi-generator-cli generate -i /etc/swagger-petstore.yaml -g postman-collection -o /etc/out/postman
(Only contains the request)
Thanks in advance
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the CLI postman-collection generation entry point used by the Docker command and inspect the output produced from swagger-petstore.yaml. Compare it with a collection imported into Postman; done means generated requests also contain response skeletons and data types.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, postman
- Domain
- api, tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100