OpenAPITools / OpenAPITools/openapi-generator
Allow implicit headers in typescript-axios
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 Typescript Axis client, by default all header params being added as method parameters for each API endpoint.
This causes a problematic developer experience, as you have to continuously pass through header values that should be able to be configured at the HTTP client level (sdk keys, other special custom headers).
Describe the solution you'd like
Use an implicitHeaders property, like the Spring code gen, so that you can choose to include them or not.
Describe alternatives you've considered
Looked at the vendor extensions, felt too hacky.
Additional context
This is essential to generate SDKs that are developer friendly.
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 by examining the typescript-axios generator and comparing its requested behavior with the Spring code generator's implicitHeaders property. Confirm how header parameters are currently exposed and make the option control whether they are included as endpoint method parameters, with coverage for both settings.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- api, tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100