Keycloak integration for Python FastAPI

Overview

FastAPI Keycloak Integration

CodeFactor

Documentation

Introduction

Welcome to fastapi-keycloak. This projects goal is to ease the integration of Keycloak (OpenID Connect) with Python, especially FastAPI. FastAPI is not necessary but is encouraged due to specific features. Currently, this package supports only the password flow. However, the get_current_user() method accepts any JWT that was signed using Keycloak's private key.

!!! Caution This package is currently under development and is not yet officially released. However, you may still use it and contribute to it.

TLDR;

FastAPI Keycloak enables you to do the following things without writing a single line of additional code:

  • Verify identities and roles of users with Keycloak
  • Get a list of available identity providers
  • Create/read/delete users
  • Create/read/delete roles
  • Assign/remove roles from users
  • Implement the password flow (login/callback/logout)

Example

This example assumes you use a frontend technology (such as React, Vue, or whatever suits you) to render your pages and merely depicts a protected backend

app.py

import uvicorn
from fastapi import FastAPI, Depends

from fastapi_keycloak import FastAPIKeycloak, OIDCUser

app = FastAPI()
idp = FastAPIKeycloak(
    app=app,
    server_url="https://auth.some-domain.com/auth",
    client_id="some-client",
    client_secret="some-client-secret",
    admin_client_secret="admin-cli-secret",
    realm="some-realm-name",
    callback_uri="http://localhost:8081/callback"
)


@app.get("/premium", tags=["secured-endpoint"])
def premium(user: OIDCUser = Depends(idp.get_current_user(required_roles=["premium"]))):
    return f'Hi premium user {user}'


@app.get("/user/roles", tags=["secured-endpoint"])
def user_roles(user: OIDCUser = Depends(idp.get_current_user)):
    return f'{user.roles}'


if __name__ == '__main__':
    uvicorn.run('app:app', host="127.0.0.1", port=8081)
Comments
  • Error when initializing example project

    Error when initializing example project

    Hello!

    really good project, i love keycloak and fastapi :-). Unfortunately I am not able to get it running and I guess this is due to a bug:

    The error happens, when I the token is decoded:

    PS C:\Users\User\Desktop\KeyCloakFastAPI> python .\app.py
    {'exp': 1649355552, 'iat': 1649355252, 'jti': '51e67522-19f7-45b0-9894-e862b440106b', 'iss': 'http://localhost:8085/auth/realms/Test', 'sub': '33b940e2-0bdb-49a7-9356-e6e230f49619', 'ty
    p': 'Bearer', 'azp': 'admin-cli', 'acr': '1', 'scope': 'profile email', 'clientId': 'admin-cli', 'clientHost': '172.23.0.1', 'email_verified': False, 'preferred_username': 'service-acco
    unt-admin-cli', 'clientAddress': '172.23.0.1'}
    

    I my token I don´t have "resource_access, which leads to "None" and to a follow up error:

    AttributeError: 'NoneType' object has no attribute 'get'

    traceback:

    Traceback (most recent call last):
      File ".\app.py", line 7, in <module>
        idp = FastAPIKeycloak(
      File "C:\Users\User\anaconda3\lib\site-packages\fastapi_keycloak\api.py", line 129, in __init__
        self._get_admin_token()  # Requests an admin access token on startup
      File "C:\Users\User\anaconda3\lib\site-packages\fastapi_keycloak\api.py", line 292, in _get_admin_token
        self.admin_token = response.json()['access_token']
      File "C:\Users\User\anaconda3\lib\site-packages\fastapi_keycloak\api.py", line 159, in admin_token
        if not decoded_token.get('resource_access').get('realm-management') or not decoded_token.get('resource_access').get('account'):
    AttributeError: 'NoneType' object has no attribute 'get'
    

    Is there something I did wrong or is this an error in the lib?

    bug 
    opened by Coding-Crashkurse 7
  • Object non evaluated on getting decoded_token from Keycloak

    Object non evaluated on getting decoded_token from Keycloak

    How to reproduce ?

    Env preparation.

    pipenv install fastapi fastapi-keycloak
    

    I followed your quickstart and full example instructions then :

    pipenv run python main.py
    

    What the result?

    pipenv run python main.py 
    Traceback (most recent call last):
      File "main.py", line 10, in <module>
        idp = FastAPIKeycloak(
      File "/home/germainlef/.local/share/virtualenvs/auth-keycloak-WIW7vmvr/lib/python3.8/site-packages/fastapi_keycloak/api.py", line 125, in __init__
        self._get_admin_token()  # Requests an admin access token on startup
      File "/home/germainlef/.local/share/virtualenvs/auth-keycloak-WIW7vmvr/lib/python3.8/site-packages/fastapi_keycloak/api.py", line 285, in _get_admin_token
        self.admin_token = response.json()['access_token']
      File "/home/germainlef/.local/share/virtualenvs/auth-keycloak-WIW7vmvr/lib/python3.8/site-packages/fastapi_keycloak/api.py", line 154, in admin_token
        if not decoded_token.get('resource_access').get('realm-management') or not decoded_token.get('resource_access').get('account'):
    AttributeError: 'NoneType' object has no attribute 'get'
    
    documentation enhancement 
    opened by germainlefebvre4 7
  • Raise a UserNotFound exception when the query on get_user() does not match any users

    Raise a UserNotFound exception when the query on get_user() does not match any users

    It seems that if the search of users based on a query string return no users, the code assumes that there will always be some results and it "chokes" when none are found.

    opened by stratosgear 6
  • run locally

    run locally

    I want to use this example locally without docker https://fastapi-keycloak.code-specialist.com/full_example/ but this give me this error message error at line 7

    • client_secret = client > client_id > credential > Secret
    • admin_client_secret = admin_cli > credential > Secret

    and please specify that fastapi_keycloak will work for new keycloak version 17

    The error message is

    (venv) (base) [email protected]:/office/My Projects/keycloak_implementation$ uvicorn main:app --reload --port 8001 INFO: Will watch for changes in these directories: ['/office/My Projects/keycloak_implementation'] INFO: Uvicorn running on http://127.0.0.1:8001 (Press CTRL+C to quit) INFO: Started reloader process [18160] using watchgod Process SpawnProcess-1: Traceback (most recent call last): File "/usr/lib/python3.8/multiprocessing/process.py", line 315, in _bootstrap self.run() File "/usr/lib/python3.8/multiprocessing/process.py", line 108, in run self._target(*self._args, **self._kwargs) File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/uvicorn/subprocess.py", line 76, in subprocess_started target(sockets=sockets) File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/uvicorn/server.py", line 60, in run return asyncio.run(self.serve(sockets=sockets)) File "/usr/lib/python3.8/asyncio/runners.py", line 44, in run return loop.run_until_complete(main) File "uvloop/loop.pyx", line 1501, in uvloop.loop.Loop.run_until_complete File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/uvicorn/server.py", line 67, in serve config.load() File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/uvicorn/config.py", line 458, in load self.loaded_app = import_from_string(self.app) File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/uvicorn/importer.py", line 21, in import_from_string module = importlib.import_module(module_str) File "/usr/lib/python3.8/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1014, in _gcd_import File "", line 991, in _find_and_load File "", line 975, in _find_and_load_unlocked File "", line 671, in _load_unlocked File "", line 848, in exec_module File "", line 219, in _call_with_frames_removed File "/office/My Projects/keycloak_implementation/./main.py", line 7, in idp = FastAPIKeycloak( File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/fastapi_keycloak/api.py", line 129, in init self._get_admin_token() # Requests an admin access token on startup File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/fastapi_keycloak/api.py", line 288, in _get_admin_token response = requests.post(url=self.token_uri, headers=headers, data=data) File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/requests/api.py", line 117, in post return request('post', url, data=data, json=json, **kwargs) File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/requests/api.py", line 61, in request return session.request(method=method, url=url, **kwargs) File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/requests/sessions.py", line 515, in request prep = self.prepare_request(req) File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/requests/sessions.py", line 443, in prepare_request p.prepare( File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/requests/models.py", line 318, in prepare self.prepare_url(url, params) File "/office/My Projects/keycloak_implementation/venv/lib/python3.8/site-packages/requests/models.py", line 392, in prepare_url raise MissingSchema(error) requests.exceptions.MissingSchema: Invalid URL 'None': No scheme supplied. Perhaps you meant http://None?

    enhancement keycloak compatbility 
    opened by bwithai 6
  • Parse token for additional information

    Parse token for additional information

    I've been using https://github.com/elbernv/fastapi-keycloack to add security to my routes. I was trying to switch to using this library, seeing as though it is getting regular updates. I was wondering if it's currently possible to decode more from the token than what the OIDCUser object currently returns?

    For example, I've added the users group memberships to the profile scope, I've also added it as it's own scope, so two questions:

    1. Is it possible to fetch the group memberships from the token when using the profile scope?
    2. Is it possible to add more scopes? It seems like only profile and email are currently available when adding security to the FastAPI application.

    Thank you.

    documentation enhancement 
    opened by afraazali 6
  • Validate token in current_user

    Validate token in current_user

    We figured that current_user(line 220) function when receiving a token, doesn't validate the token like lib does in admin_token(line 141) method.

    Is it by design or can I create a fix for that?

    opened by valeriiduz 4
  • Upload Example file for fastapi scopes declaration with keycloak support

    Upload Example file for fastapi scopes declaration with keycloak support

    @yannicschroeer ,

    Any timeline for uploading the FastAPI scopes check example using this library?

    Also, I would like to know, if there is an example to configure SSO for multiple microservices and MFA

    Thanks, Uday

    documentation enhancement 
    opened by Udayaprasad 3
  • Fix the type hint of get_current_user

    Fix the type hint of get_current_user

    FastAPIs Depends function expects a callable. get_current_user is returning a callable but its type hint did not reflect this.

    It's just a small change but PyCharms type checker annoyed me...

    opened by DaGuich 2
  • manifest for jboss/keycloak:16.0.1 not found

    manifest for jboss/keycloak:16.0.1 not found

    Hi,

    it seems that the keycloak image tag used in the docker-compose file example in doc/getting_started does not exist: ERROR: manifest for jboss/keycloak:16.0.1 not found The existing tags are shown here (I used 16.1.1).

    opened by julj 2
  • Unable to authenticate users on swagger doc through the Authorize

    Unable to authenticate users on swagger doc through the Authorize "OAuth2PasswordBearer" form

    Unable to connect with user (here [email protected]) using the "Authorize" button and "OAuth2PasswordBearer" form. 2022-01-06 08_48_55-FastAPI - Swagger UI

    A CORS error is achieved on non-https website. 2022-01-06 08_46_49-FastAPI - Swagger UI

    I suggest adding the parameter on your documentation to allow testing the whole process on dev platform (that i the point of playing the quickstart guide).

    Client> test-client : Fil lthe WebOrigins attribute to *.

    2022-01-06 08_55_41-Keycloak Admin Console

    opened by germainlefebvre4 2
  • Initial version proposal

    Initial version proposal

    Done

    • Initial version proposal
    • Docs: https://fastapi-keycloak.code-specialist.com/

    TODO before merging

    • [x] Unit tests - [ ] 100% test coverage - [ ] Test infrastructure running on actions runner
    opened by code-specialist 2
  • Can we pass dynamic realm, client_id and client_secret params to FastAPIKeycloak class

    Can we pass dynamic realm, client_id and client_secret params to FastAPIKeycloak class

    I am looking for a multi-tenant-based solution, where the customer maintains different realms for different vendors. How could we manage the FastAPIKeycloak() creation and .get_current_user() authentication/authorisation?

    Based on the URL I am figuring out the tenant and getting the relevant Database details, but now confused about how we could use the below OIDCUser in the Endpoint definition.

    user: OIDCUser = Depends(keycloak_obj.get_current_user())

    @yannicschroeer

    opened by Udayaprasad 0
  • Unable to pip install from python docker images

    Unable to pip install from python docker images

    Hello,

    pip fails to install fastapi_keycloak on the following docker images:

    • python3.8
    • python3.8-slim
    • python3.9-slim
    • python3.10-slim

    I have no clue why it fails (tested with pip==22.3, 22.1.2, 22.2)

    Obtaining file:///tmp/fastapi-keycloak
      Installing build dependencies: started
      Installing build dependencies: finished with status 'done'
      Checking if build backend supports build_editable: started
      Checking if build backend supports build_editable: finished with status 'done'
      Getting requirements to build editable: started
      Getting requirements to build editable: finished with status 'error'
      error: subprocess-exited-with-error
      
      × Getting requirements to build editable did not run successfully.
      │ exit code: 1
      ╰─> [43 lines of output]
          Traceback (most recent call last):
            File "/usr/local/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 351, in <module>
              main()
            File "/usr/local/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 333, in main
              json_out['return_val'] = hook(**hook_input['kwargs'])
            File "/usr/local/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 132, in get_requires_for_build_editable
              return hook(config_settings)
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 446, in get_requires_for_build_editable
              return self.get_requires_for_build_wheel(config_settings)
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 338, in get_requires_for_build_wheel
              return self._get_build_requires(config_settings, requirements=['wheel'])
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 320, in _get_build_requires
              self.run_setup()
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 483, in run_setup
              super(_BuildMetaLegacyBackend,
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 335, in run_setup
              exec(code, locals())
            File "<string>", line 9, in <module>
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/__init__.py", line 87, in setup
              return distutils.core.setup(**attrs)
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 159, in setup
              dist.parse_config_files()
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/dist.py", line 868, in parse_config_files
              pyprojecttoml.apply_configuration(self, filename, ignore_option_errors)
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/config/pyprojecttoml.py", line 62, in apply_configuration
              config = read_configuration(filepath, True, ignore_option_errors, dist)
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/config/pyprojecttoml.py", line 140, in read_configuration
              return expand_configuration(asdict, root_dir, ignore_option_errors, dist)
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/config/pyprojecttoml.py", line 195, in expand_configuration
              return _ConfigExpander(config, root_dir, ignore_option_errors, dist).expand()
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/config/pyprojecttoml.py", line 242, in expand
              self._expand_all_dynamic(dist, package_dir)
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/config/pyprojecttoml.py", line 279, in _expand_all_dynamic
              obtained_dynamic = {
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/config/pyprojecttoml.py", line 280, in <dictcomp>
              field: self._obtain(dist, field, package_dir)
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/config/pyprojecttoml.py", line 326, in _obtain
              self._ensure_previously_set(dist, field)
            File "/tmp/pip-build-env-q7yvswdc/overlay/lib/python3.10/site-packages/setuptools/config/pyprojecttoml.py", line 305, in _ensure_previously_set
              raise OptionError(msg)
          distutils.errors.DistutilsOptionError: No configuration found for dynamic 'description'.
          Some dynamic fields need to be specified via `tool.setuptools.dynamic`
          others must be specified via the equivalent attribute in `setup.py`.
          [end of output]
      
      note: This error originates from a subprocess, and is likely not a problem with pip.
    error: subprocess-exited-with-error
    
    × Getting requirements to build editable did not run successfully.
    │ exit code: 1
    ╰─> See above for output.
    
    note: This error originates from a subprocess, and is likely not a problem with pip.
    
    
    opened by remicres 2
  • fastapi-keycloak docs outdated?

    fastapi-keycloak docs outdated?

    Hello all,

    Are there any plans on updating this library to use the latest version of Keycloak and also update the docs?

    I think this library is based on Keycloak version 16.1.0 as seen here: https://fastapi-keycloak.code-specialist.com/quick_start/

     keycloak:
        image: jboss/keycloak:16.1.0   
    

    Also: https://fastapi-keycloak.code-specialist.com/reference/ It should be "FastAPIKeycloak" instead of "KeycloakFastAPI"

    Thank you very much for your valuable time.

    Best Regards,

    koufopoulosf

    opened by koufopoulosf 0
  • The `realm-export.json` file in the documentation website needs to be updated

    The `realm-export.json` file in the documentation website needs to be updated

    The link still references the old json file from before #38 was merged

    Reference: https://stackoverflow.com/questions/71787580/keycloak-api-does-not-contain-resource-access/73778730#73778730

    opened by pmav99 0
  • unable to connect to keycloak server

    unable to connect to keycloak server

    keycloak version :: 19.0.0

    requests.exceptions.ConnectionError: HTTPConnectionPool(host='localhost', port=8080): Max retries exceeded with url: /realms/RealmOne/.well-known/openid-configuration (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f94efdfe610>: Failed to establish a new connection: [Errno 111] Connection refused'))

    ( server_url="http://localhost:8080", client_id="myApp", client_secret="Y49wuMTCnLbX2bufuasJ73RSR9ivLWLu", admin_client_secret="admin-cli-secret", realm="RealmOne", callback_uri="http://localhost:8080/callback" ) I cannot find the admin secret anywhere in keycloak .

    opened by abhijitgujar86 1
Releases(1.0.9)
  • 1.0.9(Dec 20, 2022)

    What's Changed

    • Enhanced Maintainer Notice by @JonasScholl in https://github.com/code-specialist/fastapi-keycloak/pull/77
    • Bump certifi from 2021.10.8 to 2022.12.7 by @dependabot in https://github.com/code-specialist/fastapi-keycloak/pull/79
    • Bump certifi from 2021.10.8 to 2022.12.7 in /fastapi_keycloak by @dependabot in https://github.com/code-specialist/fastapi-keycloak/pull/78

    New Contributors

    • @dependabot made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/79

    Full Changelog: https://github.com/code-specialist/fastapi-keycloak/compare/1.0.8...1.0.9

    Source code(tar.gz)
    Source code(zip)
  • 1.0.8(Oct 19, 2022)

    What's Changed

    • Improve test stability by @JonasScholl in https://github.com/code-specialist/fastapi-keycloak/pull/64
    • Move examples from docs to a folder, update docs slightly by @laxdog in https://github.com/code-specialist/fastapi-keycloak/pull/68
    • Update keycloak_configuration.md by @slavong in https://github.com/code-specialist/fastapi-keycloak/pull/73
    • Raise a UserNotFound exception when the query on get_user() does not match any users by @stratosgear in https://github.com/code-specialist/fastapi-keycloak/pull/72

    New Contributors

    • @laxdog made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/68
    • @slavong made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/73

    Full Changelog: https://github.com/code-specialist/fastapi-keycloak/compare/1.0.7...1.0.8

    Source code(tar.gz)
    Source code(zip)
  • 1.0.7(Jul 24, 2022)

    What's Changed

    • Model fix by @twistfire92 in https://github.com/code-specialist/fastapi-keycloak/pull/56
    • Fix the type hint of get_current_user by @DaGuich in https://github.com/code-specialist/fastapi-keycloak/pull/59
    • Move the exception of missing 'realm_access section' into the model itself by @fherrera124 in https://github.com/code-specialist/fastapi-keycloak/pull/62
    • Throws a 404 when a user lookup fails. by @stratosgear in https://github.com/code-specialist/fastapi-keycloak/pull/61

    New Contributors

    • @DaGuich made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/59
    • @fherrera124 made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/62
    • @stratosgear made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/61

    Full Changelog: https://github.com/code-specialist/fastapi-keycloak/compare/1.0.6...1.0.7

    Source code(tar.gz)
    Source code(zip)
  • 1.0.6(Jun 16, 2022)

    What's Changed

    • Extra fields in OIDCUser. #49 by @twistfire92 in https://github.com/code-specialist/fastapi-keycloak/pull/50
    • Update documentation to add error handler by @jonra1993 in https://github.com/code-specialist/fastapi-keycloak/pull/54

    New Contributors

    • @twistfire92 made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/50
    • @jonra1993 made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/54

    Full Changelog: https://github.com/code-specialist/fastapi-keycloak/compare/1.0.5...1.0.6

    Source code(tar.gz)
    Source code(zip)
  • 1.0.5(May 19, 2022)

    What's Changed

    • Minor code improvements by @GitBib in https://github.com/code-specialist/fastapi-keycloak/pull/34
    • update realm-export.json to resolve quickstart issues by @jeromecremers in https://github.com/code-specialist/fastapi-keycloak/pull/38
    • Test Multiple Python Versions by @JonasScholl in https://github.com/code-specialist/fastapi-keycloak/pull/43
    • FastAPIKeycloak Timeout by @valeriiduz in https://github.com/code-specialist/fastapi-keycloak/pull/44
    • Fix Timeout Test by @JonasScholl in https://github.com/code-specialist/fastapi-keycloak/pull/45

    New Contributors

    • @jeromecremers made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/38
    • @JonasScholl made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/43
    • @valeriiduz made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/44

    Full Changelog: https://github.com/code-specialist/fastapi-keycloak/compare/1.0.4...1.0.5

    Source code(tar.gz)
    Source code(zip)
  • 1.0.4(Mar 27, 2022)

    What's Changed

    • Initial roles by @yannicschroeer in https://github.com/code-specialist/fastapi-keycloak/pull/33

    Full Changelog: https://github.com/code-specialist/fastapi-keycloak/compare/1.0.3...1.0.4

    Source code(tar.gz)
    Source code(zip)
  • 1.0.3(Mar 27, 2022)

    What's Changed

    • Fix Initial roles by @yannicschroeer in https://github.com/code-specialist/fastapi-keycloak/pull/32

    Full Changelog: https://github.com/code-specialist/fastapi-keycloak/compare/1.0.2...1.0.3

    Source code(tar.gz)
    Source code(zip)
  • 1.0.2(Mar 27, 2022)

    What's Changed

    • Initial Roles on create_user by @yannicschroeer in https://github.com/code-specialist/fastapi-keycloak/pull/31

    Full Changelog: https://github.com/code-specialist/fastapi-keycloak/compare/1.0.1...1.0.2

    Source code(tar.gz)
    Source code(zip)
  • 1.0.1(Mar 25, 2022)

    What's Changed

    • Fix docs by @yannicschroeer in https://github.com/code-specialist/fastapi-keycloak/pull/26
    • refactor(model): add resource access field in oidc user by @socar-humphrey in https://github.com/code-specialist/fastapi-keycloak/pull/29
    • Increase code quality by @GitBib in https://github.com/code-specialist/fastapi-keycloak/pull/28

    New Contributors

    • @socar-humphrey made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/29
    • @GitBib made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/28

    Full Changelog: https://github.com/code-specialist/fastapi-keycloak/compare/1.0.0...1.0.1

    Source code(tar.gz)
    Source code(zip)
  • 1.0.0(Mar 15, 2022)

    What's Changed

    • Make admin-client configurable by @thomasdarimont in https://github.com/code-specialist/fastapi-keycloak/pull/19
    • Update documentation by @code-specialist in https://github.com/code-specialist/fastapi-keycloak/pull/16
    • Add attributes to KeycloakUser by @tchalupnik in https://github.com/code-specialist/fastapi-keycloak/pull/21

    New Contributors

    • @thomasdarimont made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/19
    • @tchalupnik made their first contribution in https://github.com/code-specialist/fastapi-keycloak/pull/21

    Full Changelog: https://github.com/code-specialist/fastapi-keycloak/compare/0.3a0...1.0.0

    Source code(tar.gz)
    Source code(zip)
Owner
Code Specialist
Code Quality Blog about simplifying concepts and making life easier for developers
Code Specialist
LuSyringe is a documentation injection tool for your classes when using Fast API

LuSyringe LuSyringe is a documentation injection tool for your classes when using Fast API Benefits The main benefit is being able to separate your bu

Enzo Ferrari 2 Sep 06, 2021
Fast, simple API for Apple firmwares.

Loyal Fast, Simple API for fetching Apple Firmwares. The API server is closed due to some reasons. Wait for v2 releases. Features Fetching Signed IPSW

11 Oct 28, 2022
api versioning for fastapi web applications

fastapi-versioning api versioning for fastapi web applications Installation pip install fastapi-versioning Examples from fastapi import FastAPI from f

Dean Way 472 Jan 02, 2023
Practice-python is a simple Fast api project for dealing with modern rest api technologies.

Practice Python Practice-python is a simple Fast api project for dealing with modern rest api technologies. Deployment with docker Go to the project r

0 Sep 19, 2022
FastAPI with async for generating QR codes and bolt11 for Lightning Addresses

sendsats An API for getting QR codes and Bolt11 Invoices from Lightning Addresses. Share anywhere; as a link for tips on a twitter profile, or via mes

Bitkarrot 12 Jan 07, 2023
FastAPI-PostgreSQL-Celery-RabbitMQ-Redis bakcend with Docker containerization

FastAPI - PostgreSQL - Celery - Rabbitmq backend This source code implements the following architecture: All the required database endpoints are imple

Juan Esteban Aristizabal 54 Nov 26, 2022
Stac-fastapi built on Tile38 and Redis to support caching

stac-fastapi-caching Stac-fastapi built on Tile38 to support caching. This code is built on top of stac-fastapi-elasticsearch 0.1.0 with pyle38, a Pyt

Jonathan Healy 4 Apr 11, 2022
REST API with FastAPI and PostgreSQL

REST API with FastAPI and PostgreSQL To have the same data in db: create table CLIENT_DATA (id SERIAL PRIMARY KEY, fullname VARCHAR(50) NOT NULL,email

Luis Quiñones Requelme 1 Nov 11, 2021
Lightning FastAPI

Lightning FastAPI Lightning FastAPI framework, provides boiler plates for FastAPI based on Django Framework Explaination / | │ manage.py │ README.

Rajesh Joshi 1 Oct 15, 2021
A kedro-plugin to serve Kedro Pipelines as API

General informations Software repository Latest release Total downloads Pypi Code health Branch Tests Coverage Links Documentation Deployment Activity

Yolan Honoré-Rougé 12 Jul 15, 2022
Prometheus exporter for Starlette and FastAPI

starlette_exporter Prometheus exporter for Starlette and FastAPI. The middleware collects basic metrics: Counter: starlette_requests_total Histogram:

Steve Hillier 225 Jan 05, 2023
A simple Redis Streams backed Chat app using Websockets, Asyncio and FastAPI/Starlette.

redis-streams-fastapi-chat A simple demo of Redis Streams backed Chat app using Websockets, Python Asyncio and FastAPI/Starlette. Requires Python vers

ludwig404 135 Dec 19, 2022
This repository contains learning resources for Python Fast API Framework and Docker

This repository contains learning resources for Python Fast API Framework and Docker, Build High Performing Apps With Python BootCamp by Lux Academy and Data Science East Africa.

Harun Mbaabu Mwenda 23 Nov 20, 2022
A RESTful API for creating and monitoring resource components of a hypothetical build system. Built with FastAPI and pydantic. Complete with testing and CI.

diskspace-monitor-CRUD Background The build system is part of a large environment with a multitude of different components. Many of the components hav

Nick Hopewell 67 Dec 14, 2022
Town / City geolocations with FastAPI & Mongo

geolocations-api United Kingdom Town / City geolocations with FastAPI & Mongo Build container To build a custom image or extend the api run the follow

Joe Gasewicz 3 Jan 26, 2022
A dynamic FastAPI router that automatically creates CRUD routes for your models

⚡ Create CRUD routes with lighting speed ⚡ A dynamic FastAPI router that automatically creates CRUD routes for your models

Adam Watkins 950 Jan 08, 2023
Instrument your FastAPI app

Prometheus FastAPI Instrumentator A configurable and modular Prometheus Instrumentator for your FastAPI. Install prometheus-fastapi-instrumentator fro

Tim Schwenke 441 Jan 05, 2023
Twitter API monitor with fastAPI + MongoDB

Twitter API monitor with fastAPI + MongoDB You need to have a file .env with the following variables: DB_URL="mongodb+srv://mongodb_path" DB_URL2=

Leonardo Ferreira 3 Apr 08, 2022
API using python and Fastapi framework

Welcome 👋 CFCApi is a API DEVELOPMENT PROJECT UNDER CODE FOR COMMUNITY ! Project Walkthrough 🚀 CFCApi run on Python using FASTapi Framework Docs The

Abhishek kushwaha 7 Jan 02, 2023
FastAPI Project Template

The base to start an openapi project featuring: SQLModel, Typer, FastAPI, JWT Token Auth, Interactive Shell, Management Commands.

A.Freud 4 Dec 05, 2022