OpenAPITools / OpenAPITools/openapi-generator

[REQ] how to generage muti-module project under same gateway

Open
#11,403 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Enhancement: Feature
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.

I hava some microservice in a same gateway, in front-server will call both of them,so i want generate all api in one client.

eg: http://locahost:8090/pet/v2/api-docs  //pet is the pet-service context-path
http://locahost:8090/user/v2/api-docs    //user is the user-service context-path

in PetApi,the apiclient.basePath is http://locahost:8090/pet, in UserApi the apiclient.basePath is http://locahost:8090/user,
so whether PetApi can has a context path?
then they can use a same apiclient,and it's basePath is http://locahost:8090
UserApi metod will be expend to : apiclient.basePath +service-module(UserApi ).context-path + method.path

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The request names PetApi, UserApi, and apiclient, but no files, tests, or generator entry points. Start by tracing how generated APIs obtain basePath from the two service specifications. Done would mean one client can route PetApi and UserApi calls through the shared gateway while preserving each service context path.

Written by the indexing model from the issue text.

Assessment

Tech stack
openapi
Domain
api
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.