Closed heyudude closed 3 years ago
👍 Thanks for opening this issue! 🏷 I have applied any labels matching special text in your issue.
The team will review the labels and make any necessary changes.
I figured out the above question by hard coding the value for access_token
in the configuration.py
Now the api call succeeds!
Next question: where to initialize the value correctly from my settings file I use? Because access_token needs to be assigned manually to has it seems
Found the solution... no replies unfortunately o a valid question: why?
@heyudude can you share the solution? I'm facing the same problem.
@GabeL7r Sure. Anytime here to help, this piece of yaml generated the correct code in my API module I had to check also for old and floating modules: I cleaned them all before I build a new one with this change. Just to double check. My yaml can be found at https://github.com/heyudude/brawlstars-swagger I figured out the above question by hard coding the value for access_token in the configuration.py Now the api call succeeds! And the API code is called pybrawl. Good luck with the solution and if I need to peek and help, let me know.
security:
- JWT: []
components:
securitySchemes:
JWT:
type: http
scheme: bearer
bearerFormat: JWT
Description
I am writing a website generator for a game Brawlstars, their API is defined and they use bearer auth with api keys limited to IP addresses. If I make a manual get request the response is OK. Via the generated code and some tests the response is "Missing Authorisation" The api url format is:
openapi-generator version
version 3.0.0 and tried also with 3.0.3 format, latest 5.0.0 beta and the 4.3.1 stable
OpenAPI declaration file content or url
the part which is relevant:
Wrong:
Correct:
Command line used for generation
Config:
Suggest a fix/enhancement
Any help would be appreciated! Thanks for this wonderful toolset