Skip to content

Commit

Permalink
[IMP] fastapi: Optionnaly authenticated partner
Browse files Browse the repository at this point in the history
Defines specific dependencies to support case where te authentication is optional.
  • Loading branch information
lmignon committed Oct 31, 2023
1 parent e77603f commit aac3160
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions fastapi/dependencies.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ def optionally_authenticated_partner_impl() -> Partner | None:
and you need to get an optional authenticated partner into your endpoint.
"""


def authenticated_partner_env(
partner: Annotated[Partner, Depends(authenticated_partner_impl)]
) -> Environment:
Expand Down

0 comments on commit aac3160

Please sign in to comment.