danielgtaylor / danielgtaylor/openapi-cli-generator
Links Support
- Dominant language
- Go
- Stars
- 218
- Forks
- 54
- PR merge metrics
- No merged PRs in 30d
Description
Add the ability to follow [OpenAPI 3 links](https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.1.md#linkObject) to fetch additional data and add it to the response for a given operation. For example, you might get an item overview with a link to get item details. A new CLI option like `--link=details` could then be used to trigger the additional request and put a `details` field into the response with the response data from the details call. All of this would happen before response filtering/projection so you can select just the fields you care about.
Bonus: support an extension like `x-collection` so this works for calls that return a list of items, so that you can get the link for each item in the list by treating index 0 as a wildcard in the body pointer.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.