fastapi-zitadel-auth


Namefastapi-zitadel-auth JSON
Version 0.2.0 PyPI version JSON
download
home_pageNone
SummaryZitadel authentication for FastAPI
upload_time2025-02-12 13:05:54
maintainerNone
docs_urlNone
authorNone
requires_python>=3.10
licenseNone
keywords async asyncio authentication fastapi oauth oidc zitadel
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # FastAPI Zitadel Auth

<p>
    <em>Simplify OAuth2 authentication and authorization in FastAPI apps using <b><a href="https://zitadel.com">Zitadel</a></b>.</em>
</p>

<a href="https://github.com/cleanenergyexchange/fastapi-zitadel-auth/actions/workflows/test.yml" target="_blank">
    <img src="https://github.com/cleanenergyexchange/fastapi-zitadel-auth/actions/workflows/test.yml/badge.svg" alt="Test status">
</a>
<a href="https://codecov.io/gh/cleanenergyexchange/fastapi-zitadel-auth">
    <img src="https://codecov.io/gh/cleanenergyexchange/fastapi-zitadel-auth/graph/badge.svg?token=A3TSXDVLQT" alt="Code coverage"/> 
</a>
<a href="https://pypi.org/pypi/fastapi-zitadel-auth">
    <img src="https://img.shields.io/pypi/v/fastapi-zitadel-auth.svg?logo=pypi&logoColor=white&label=pypi" alt="Package version">
</a>
<a href="https://pepy.tech/projects/fastapi-zitadel-auth">
    <img src="https://static.pepy.tech/badge/fastapi-zitadel-auth/month" alt="PyPI downloads">
</a>
<a href="https://python.org">
    <img src="https://img.shields.io/badge/python-v3.10+-blue.svg?logo=python&logoColor=white&label=python" alt="Python versions">
</a>
<a href="https://mypy-lang.org">
    <img src="https://www.mypy-lang.org/static/mypy_badge.svg" alt="mypy">
</a>
<a href="https://github.com/cleanenergyexchange/fastapi-zitadel-auth/blob/main/LICENSE">
    <img src="https://badgen.net/github/license/cleanenergyexchange/fastapi-zitadel-auth/" alt="License"/>
</a>

---

**Documentation**: <a href="https://cleanenergyexchange.github.io/fastapi-zitadel-auth" target="_blank">https://cleanenergyexchange.github.io/fastapi-zitadel-auth</a>

**Source Code**: <a href="https://github.com/cleanenergyexchange/fastapi-zitadel-auth" target="_blank">https://github.com/cleanenergyexchange/fastapi-zitadel-auth</a>

---

## Features

* Authorization Code flow with PKCE
* JWT validation using Zitadel JWKS
* Role-based access control using Zitadel roles
* Service user authentication (JWT Profile)
* Swagger UI integration
* Type-safe token validation
* Extensible claims and user models


!!! info "JWT vs Opaque tokens"

    This library implements JWT, locally validated using JWKS, as it **prioritizes performance**, 
    see [Zitadel docs on Opaque tokens vs JWT](https://zitadel.com/docs/concepts/knowledge/opaque-tokens#use-cases-and-trade-offs). 
    If you need to validate opaque tokens using Introspection, please [open an issue](https://github.com/cleanenergyexchange/fastapi-zitadel-auth/issues) – PRs are welcome!


## License

This project is licensed under the terms of the [MIT license](https://github.com/cleanenergyexchange/fastapi-zitadel-auth/blob/main/LICENCE).

## Acknowledgements

This package was heavily inspired by [intility/fastapi-azure-auth](https://github.com/intility/fastapi-azure-auth/). 
Give them a star ⭐️!
            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "fastapi-zitadel-auth",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": null,
    "keywords": "async, asyncio, authentication, fastapi, oauth, oidc, zitadel",
    "author": null,
    "author_email": "Clean Energy Exchange <info@ceex.ch>",
    "download_url": "https://files.pythonhosted.org/packages/7e/90/ee1fe7bae213209cb82f10c6798b65bbcb8bb626de281c9acac7d8cfe96b/fastapi_zitadel_auth-0.2.0.tar.gz",
    "platform": null,
    "description": "# FastAPI Zitadel Auth\n\n<p>\n    <em>Simplify OAuth2 authentication and authorization in FastAPI apps using <b><a href=\"https://zitadel.com\">Zitadel</a></b>.</em>\n</p>\n\n<a href=\"https://github.com/cleanenergyexchange/fastapi-zitadel-auth/actions/workflows/test.yml\" target=\"_blank\">\n    <img src=\"https://github.com/cleanenergyexchange/fastapi-zitadel-auth/actions/workflows/test.yml/badge.svg\" alt=\"Test status\">\n</a>\n<a href=\"https://codecov.io/gh/cleanenergyexchange/fastapi-zitadel-auth\">\n    <img src=\"https://codecov.io/gh/cleanenergyexchange/fastapi-zitadel-auth/graph/badge.svg?token=A3TSXDVLQT\" alt=\"Code coverage\"/> \n</a>\n<a href=\"https://pypi.org/pypi/fastapi-zitadel-auth\">\n    <img src=\"https://img.shields.io/pypi/v/fastapi-zitadel-auth.svg?logo=pypi&logoColor=white&label=pypi\" alt=\"Package version\">\n</a>\n<a href=\"https://pepy.tech/projects/fastapi-zitadel-auth\">\n    <img src=\"https://static.pepy.tech/badge/fastapi-zitadel-auth/month\" alt=\"PyPI downloads\">\n</a>\n<a href=\"https://python.org\">\n    <img src=\"https://img.shields.io/badge/python-v3.10+-blue.svg?logo=python&logoColor=white&label=python\" alt=\"Python versions\">\n</a>\n<a href=\"https://mypy-lang.org\">\n    <img src=\"https://www.mypy-lang.org/static/mypy_badge.svg\" alt=\"mypy\">\n</a>\n<a href=\"https://github.com/cleanenergyexchange/fastapi-zitadel-auth/blob/main/LICENSE\">\n    <img src=\"https://badgen.net/github/license/cleanenergyexchange/fastapi-zitadel-auth/\" alt=\"License\"/>\n</a>\n\n---\n\n**Documentation**: <a href=\"https://cleanenergyexchange.github.io/fastapi-zitadel-auth\" target=\"_blank\">https://cleanenergyexchange.github.io/fastapi-zitadel-auth</a>\n\n**Source Code**: <a href=\"https://github.com/cleanenergyexchange/fastapi-zitadel-auth\" target=\"_blank\">https://github.com/cleanenergyexchange/fastapi-zitadel-auth</a>\n\n---\n\n## Features\n\n* Authorization Code flow with PKCE\n* JWT validation using Zitadel JWKS\n* Role-based access control using Zitadel roles\n* Service user authentication (JWT Profile)\n* Swagger UI integration\n* Type-safe token validation\n* Extensible claims and user models\n\n\n!!! info \"JWT vs Opaque tokens\"\n\n    This library implements JWT, locally validated using JWKS, as it **prioritizes performance**, \n    see [Zitadel docs on Opaque tokens vs JWT](https://zitadel.com/docs/concepts/knowledge/opaque-tokens#use-cases-and-trade-offs). \n    If you need to validate opaque tokens using Introspection, please [open an issue](https://github.com/cleanenergyexchange/fastapi-zitadel-auth/issues) \u2013 PRs are welcome!\n\n\n## License\n\nThis project is licensed under the terms of the [MIT license](https://github.com/cleanenergyexchange/fastapi-zitadel-auth/blob/main/LICENCE).\n\n## Acknowledgements\n\nThis package was heavily inspired by [intility/fastapi-azure-auth](https://github.com/intility/fastapi-azure-auth/). \nGive them a star \u2b50\ufe0f!",
    "bugtrack_url": null,
    "license": null,
    "summary": "Zitadel authentication for FastAPI",
    "version": "0.2.0",
    "project_urls": null,
    "split_keywords": [
        "async",
        " asyncio",
        " authentication",
        " fastapi",
        " oauth",
        " oidc",
        " zitadel"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "27edbf9ae77dc709b2b46068a624b82783573a23b6c3c3fa9513a59f1f9e4bfb",
                "md5": "c8a0a14218da1fca89ba16c1c904a564",
                "sha256": "1ac2b73577591b15590fde440481b3b65cb59d56af212e6086e91758d33a0d76"
            },
            "downloads": -1,
            "filename": "fastapi_zitadel_auth-0.2.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "c8a0a14218da1fca89ba16c1c904a564",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 9891,
            "upload_time": "2025-02-12T13:05:53",
            "upload_time_iso_8601": "2025-02-12T13:05:53.244263Z",
            "url": "https://files.pythonhosted.org/packages/27/ed/bf9ae77dc709b2b46068a624b82783573a23b6c3c3fa9513a59f1f9e4bfb/fastapi_zitadel_auth-0.2.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "7e90ee1fe7bae213209cb82f10c6798b65bbcb8bb626de281c9acac7d8cfe96b",
                "md5": "9cb8132acb98adbc28e361c6a21227f9",
                "sha256": "c0bf023a5552bd48647f6da27d8906c6998d8c88df8743f6a1cb650aaf8d474b"
            },
            "downloads": -1,
            "filename": "fastapi_zitadel_auth-0.2.0.tar.gz",
            "has_sig": false,
            "md5_digest": "9cb8132acb98adbc28e361c6a21227f9",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 103170,
            "upload_time": "2025-02-12T13:05:54",
            "upload_time_iso_8601": "2025-02-12T13:05:54.757272Z",
            "url": "https://files.pythonhosted.org/packages/7e/90/ee1fe7bae213209cb82f10c6798b65bbcb8bb626de281c9acac7d8cfe96b/fastapi_zitadel_auth-0.2.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-02-12 13:05:54",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "fastapi-zitadel-auth"
}
        
Elapsed time: 6.39137s