OpenAPITools / OpenAPITools/openapi-generator
[REQ] [JAVA] Allow multiple interfaces to be generated for similar URI pattern
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.
Problem :
If the URL starts with /animal/mammals Java openapi-generator will generate a API interface as AnimalApi. Suppose we have another URL which starts with /animal/reptiles, the generated APIs interface AnimalApi will have all the APIs of mammals & reptiles together.
For modular design, sometimes it is necessary to segregate the APIs for mammals & reptiles into different classes(with same starting URL - /animal/). In this particular case, it would be helpful if we can generate two separate interface like AnimalMammalApi & AnimalReptileApi.
Right now are no provision for controlling how we generate APIs interfaces.
Describe the solution you'd like
Need to have more control over on how we generate APIs interface.
Describe alternatives you've considered
NA
Additional context
NA
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
Review the Java generator's API grouping and configuration entry points first, then trace how similar URI prefixes are combined into interfaces. Done means the generator can produce separate interfaces for the mammals and reptiles groups while preserving existing generation behavior; the issue does not name specific files or tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, openapi
- Domain
- api, tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100