-
Notifications
You must be signed in to change notification settings - Fork 437
Open
Labels
Description
Description
It should be possible to set default header for each HTTP request. Currently generated ApiClient class for resttemplate library does not allow that and creates duplicates.
The same issue was fixed 8 years ago in version 2 of the swagger-codegen: swagger-api/swagger-codegen#6981 however the fix was never backported to the version 3.
For example, after executing:
apiClient.addDefaultHeader("TestHeader", "foo");
apiClient.addDefaultHeader("TestHeader", "bar");
Only TestHeader with value bar should be added to the request.
Version
all
Language / Generator Affected
Java - resttemplate library
Related Issues / Repos
swagger-api/swagger-codegen#6976
Checklist
- I have searched the existing issues to avoid duplicates.
- I have included a minimal reproducible spec or configuration.
- I have clearly described the steps to reproduce the issue.
- I have specified which generator or template is affected.