gibahjoe / openapi-generator-dart

Openapi Generator for Dart/Flutter
BSD 3-Clause "New" or "Revised" License
112 stars 29 forks source link

Add headers for remote spec #98

Closed Nexushunter closed 10 months ago

Nexushunter commented 10 months ago

With the next gen version of the generator now consumable it would be nice to provide the ability to add custom bearer tokens to the fetch spec requests.

This adds the follow:

Attempts to solve: https://github.com/gibahjoe/openapi-generator-dart/issues/80

gibahjoe commented 10 months ago

@Nexushunter , seems there is an issue with the workflow configuration. Please take a look so all checks can run

Screenshot 2023-09-02 at 15 51 41
Nexushunter commented 10 months ago

@gibahjoe I'll put up a fix in an hour. Looks like I messed up the merge from master sorry

Nexushunter commented 10 months ago

@gibahjoe It should be fixed now

codecov[bot] commented 10 months ago

Codecov Report

Patch coverage: 73.68% and project coverage change: -1.67% :warning:

Comparison is base (229815e) 81.75% compared to head (677a318) 80.08%. Report is 27 commits behind head on master.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #98 +/- ## ========================================== - Coverage 81.75% 80.08% -1.67% ========================================== Files 9 9 Lines 570 668 +98 ========================================== + Hits 466 535 +69 - Misses 104 133 +29 ``` | [Files Changed](https://app.codecov.io/gh/gibahjoe/openapi-generator-dart/pull/98?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=None) | Coverage Δ | | |---|---|---| | [...ns/lib/src/openapi\_generator\_annotations\_base.dart](https://app.codecov.io/gh/gibahjoe/openapi-generator-dart/pull/98?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=None#diff-b3BlbmFwaS1nZW5lcmF0b3ItYW5ub3RhdGlvbnMvbGliL3NyYy9vcGVuYXBpX2dlbmVyYXRvcl9hbm5vdGF0aW9uc19iYXNlLmRhcnQ=) | `84.56% <64.81%> (-9.88%)` | :arrow_down: | | [...pi-generator/lib/src/openapi\_generator\_runner.dart](https://app.codecov.io/gh/gibahjoe/openapi-generator-dart/pull/98?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=None#diff-b3BlbmFwaS1nZW5lcmF0b3IvbGliL3NyYy9vcGVuYXBpX2dlbmVyYXRvcl9ydW5uZXIuZGFydA==) | `72.76% <73.33%> (-1.15%)` | :arrow_down: | | [...-generator/lib/src/models/generator\_arguments.dart](https://app.codecov.io/gh/gibahjoe/openapi-generator-dart/pull/98?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=None#diff-b3BlbmFwaS1nZW5lcmF0b3IvbGliL3NyYy9tb2RlbHMvZ2VuZXJhdG9yX2FyZ3VtZW50cy5kYXJ0) | `93.50% <78.57%> (-3.47%)` | :arrow_down: | | [...api-generator/lib/src/extensions/type\_methods.dart](https://app.codecov.io/gh/gibahjoe/openapi-generator-dart/pull/98?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=None#diff-b3BlbmFwaS1nZW5lcmF0b3IvbGliL3NyYy9leHRlbnNpb25zL3R5cGVfbWV0aG9kcy5kYXJ0) | `67.50% <80.55%> (+10.60%)` | :arrow_up: | | [openapi-generator/lib/src/gen\_on\_spec\_changes.dart](https://app.codecov.io/gh/gibahjoe/openapi-generator-dart/pull/98?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=None#diff-b3BlbmFwaS1nZW5lcmF0b3IvbGliL3NyYy9nZW5fb25fc3BlY19jaGFuZ2VzLmRhcnQ=) | `90.90% <85.71%> (-2.43%)` | :arrow_down: |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.