{"id":15046655,"url":"https://github.com/auth0/auth0-python","last_synced_at":"2025-05-13T23:06:49.428Z","repository":{"id":19200503,"uuid":"22433990","full_name":"auth0/auth0-python","owner":"auth0","description":"Auth0 SDK for Python","archived":false,"fork":false,"pushed_at":"2025-04-02T08:08:25.000Z","size":4796,"stargazers_count":535,"open_issues_count":20,"forks_count":170,"subscribers_count":95,"default_branch":"master","last_synced_at":"2025-04-03T05:06:53.993Z","etag":null,"topics":["dx-sdk","sdk-python"],"latest_commit_sha":null,"homepage":"https://auth0-python.readthedocs.io","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/auth0.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2014-07-30T15:38:33.000Z","updated_at":"2025-04-01T09:26:18.000Z","dependencies_parsed_at":"2023-10-20T14:35:53.581Z","dependency_job_id":"b4389b94-792a-4a54-a57a-6a561257a584","html_url":"https://github.com/auth0/auth0-python","commit_stats":{"total_commits":755,"total_committers":103,"mean_commits":7.330097087378641,"dds":0.794701986754967,"last_synced_commit":"43bc31f7e93ec9e5c1db62aa28f8131417f6366b"},"previous_names":[],"tags_count":51,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0%2Fauth0-python","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0%2Fauth0-python/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0%2Fauth0-python/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0%2Fauth0-python/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/auth0","download_url":"https://codeload.github.com/auth0/auth0-python/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248196613,"owners_count":21063468,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dx-sdk","sdk-python"],"created_at":"2024-09-24T20:53:20.740Z","updated_at":"2025-04-10T09:46:50.570Z","avatar_url":"https://github.com/auth0.png","language":"Python","readme":"![Auth0 SDK for Python](https://cdn.auth0.com/website/sdks/banners/auth0-python-banner.png)\n\n![Release](https://img.shields.io/pypi/v/auth0-python)\n[![Codecov](https://img.shields.io/codecov/c/github/auth0/auth0-python)](https://codecov.io/gh/auth0/auth0-python)\n![Downloads](https://img.shields.io/pypi/dw/auth0-python)\n[![License](https://img.shields.io/:license-MIT-blue.svg?style=flat)](https://opensource.org/licenses/MIT)\n[![CircleCI](https://img.shields.io/circleci/build/github/auth0/auth0-python)](https://circleci.com/gh/auth0/auth0-python)\n\n\u003cdiv\u003e\n📚 \u003ca href=\"#documentation\"\u003eDocumentation\u003c/a\u003e - 🚀 \u003ca href=\"#getting-started\"\u003eGetting started\u003c/a\u003e - 💻 \u003ca href=\"#api-reference\"\u003eAPI reference\u003c/a\u003e - 💬 \u003ca href=\"#feedback\"\u003eFeedback\u003c/a\u003e\n\u003c/div\u003e\n\n\nLearn how to integrate Auth0 with Python.\n## Documentation\n- [Docs site](https://www.auth0.com/docs) - explore our docs site and learn more about Auth0.\n\n## Getting started\n### Installation\nYou can install the auth0 Python SDK using the following command.\n```\npip install auth0-python\n```\n\n\u003e Requires Python 3.7 or higher.\n\n### Usage\n\n#### Authentication SDK\nThe Authentication SDK is organized into components that mirror the structure of the\n[API documentation](https://auth0.com/docs/auth-api).\n\nIf you need to sign up a user using their email and password, you can use the Database object.\n\n```python\nfrom auth0.authentication import Database\n\ndatabase = Database('my-domain.us.auth0.com', 'my-client-id')\n\ndatabase.signup(email='user@domain.com', password='secr3t', connection='Username-Password-Authentication')\n```\n\nIf you need to authenticate a user using their email and password, you can use the `GetToken` object, which enables making requests to the `/oauth/token` endpoint.\n\n```python\nfrom auth0.authentication import GetToken\n\ntoken = GetToken('my-domain.us.auth0.com', 'my-client-id', client_secret='my-client-secret')\n\ntoken.login(username='user@domain.com', password='secr3t', realm='Username-Password-Authentication')\n```\n\n#### Management SDK\nTo use the management library you will need to instantiate an Auth0 object with a domain and a [Management API v2 token](https://auth0.com/docs/api/management/v2/tokens). Please note that these token last 24 hours, so if you need it constantly you should ask for it programmatically using the client credentials grant with a [non interactive client](https://auth0.com/docs/api/management/v2/tokens#1-create-and-authorize-a-client) authorized to access the API. For example:\n\n```python\nfrom auth0.authentication import GetToken\n\ndomain = 'myaccount.auth0.com'\nnon_interactive_client_id = 'exampleid'\nnon_interactive_client_secret = 'examplesecret'\n\nget_token = GetToken(domain, non_interactive_client_id, client_secret=non_interactive_client_secret)\ntoken = get_token.client_credentials('https://{}/api/v2/'.format(domain))\nmgmt_api_token = token['access_token']\n```\n\nThen use the token you've obtained as follows:\n\n```python\nfrom auth0.management import Auth0\n\ndomain = 'myaccount.auth0.com'\nmgmt_api_token = 'MGMT_API_TOKEN'\n\nauth0 = Auth0(domain, mgmt_api_token)\n```\n\nThe `Auth0()` object is now ready to take orders, see our [connections example](https://github.com/auth0/auth0-python/blob/master/EXAMPLES.md#connections) to find out how to use it!\n\nFor more code samples on how to integrate the auth0-python SDK in your Python application, have a look at our [examples](https://github.com/auth0/auth0-python/blob/master/EXAMPLES.md).\n\n## API reference\n\n### Authentication Endpoints\n\n- Database ( `authentication.Database` )\n- Delegated ( `authentication.Delegated` )\n- Enterprise ( `authentication.Enterprise` )\n- API Authorization - Get Token ( `authentication.GetToken`)\n- BackChannelLogin ( `authentication.BackChannelLogin`)\n- Passwordless ( `authentication.Passwordless` )\n- PushedAuthorizationRequests ( `authentication.PushedAuthorizationRequests` )\n- RevokeToken ( `authentication.RevokeToken` )\n- Social ( `authentication.Social` )\n- Users ( `authentication.Users` )\n\n\n### Management Endpoints\n\n- Actions() (`Auth0().action`)\n- AttackProtection() (`Auth0().attack_protection`)\n- Blacklists() ( `Auth0().blacklists` )\n- Branding() ( `Auth0().branding` )\n- ClientCredentials() ( `Auth0().client_credentials` )\n- ClientGrants() ( `Auth0().client_grants` )\n- Clients() ( `Auth0().clients` )\n- Connections() ( `Auth0().connections` )\n- CustomDomains() ( `Auth0().custom_domains` )\n- DeviceCredentials() ( `Auth0().device_credentials` )\n- EmailTemplates() ( `Auth0().email_templates` )\n- Emails() ( `Auth0().emails` )\n- Grants() ( `Auth0().grants` )\n- Guardian() ( `Auth0().guardian` )\n- Hooks() ( `Auth0().hooks` )\n- Jobs() ( `Auth0().jobs` )\n- LogStreams() ( `Auth0().log_streams` )\n- Logs() ( `Auth0().logs` )\n- Organizations() ( `Auth0().organizations` )\n- Prompts() ( `Auth0().prompts` )\n- ResourceServers() (`Auth0().resource_servers` )\n- Roles() ( `Auth0().roles` )\n- RulesConfigs() ( `Auth0().rules_configs` )\n- Rules() ( `Auth0().rules` )\n- Stats() ( `Auth0().stats` )\n- Tenants() ( `Auth0().tenants` )\n- Tickets() ( `Auth0().tickets` )\n- UserBlocks() (`Auth0().user_blocks` )\n- UsersByEmail() ( `Auth0().users_by_email` )\n- Users() ( `Auth0().users` )\n\n## Support Policy\n\nOur support lifecycle policy mirrors the [Python support schedule](https://devguide.python.org/versions/). We do not support running the SDK on unsupported versions of Python that have ceased to receive security updates. Please ensure your environment remains up to date and running the latest Python version possible.\n\n| SDK Version | Python Version | Support Ends |\n|-------------|----------------|--------------|\n| 4.x         | 3.12           | Oct 2028     |\n|             | 3.11           | Oct 2027     |\n|             | 3.10           | Oct 2026     |\n|             | 3.9            | Oct 2025     |\n|             | 3.8            | Oct 2024     |\n\n\u003e As `pip` [reliably avoids](https://packaging.python.org/en/latest/tutorials/packaging-projects/#configuring-metadata) installing package updates that target incompatible Python versions, we may opt to remove support for [end-of-life](https://en.wikipedia.org/wiki/CPython#Version_history) Python versions during minor SDK updates. These are not considered breaking changes by this SDK.\n\nThe following is a list of unsupported Python versions, and the last SDK version supporting them:\n\n| Python Version | Last SDK Version Supporting |\n|----------------|-----------------------------|\n| \u003e= 3.7         | 4.6.1                       |\n| \u003e= 2.0, \u003c= 3.6 | 3.x                         |\n\nYou can determine what version of Python you have installed by running:\n\n```\npython --version\n```\n\n## Feedback\n\n### Contributing\n\nWe appreciate feedback and contribution to this repo! Before you get started, please see the following:\n\n- [Auth0's general contribution guidelines](https://github.com/auth0/open-source-template/blob/master/GENERAL-CONTRIBUTING.md)\n- [Auth0's code of conduct guidelines](https://github.com/auth0/open-source-template/blob/master/CODE-OF-CONDUCT.md)\n\n### Raise an issue\n\nTo provide feedback or report a bug, please [raise an issue on our issue tracker](https://github.com/auth0/auth0-python/issues).\n\n### Vulnerability Reporting\n\nPlease do not report security vulnerabilities on the public GitHub issue tracker. The [Responsible Disclosure Program](https://auth0.com/responsible-disclosure-policy) details the procedure for disclosing security issues.\n\n---\n\n\u003cp align=\"center\"\u003e\n  \u003cpicture\u003e\n    \u003csource media=\"(prefers-color-scheme: light)\" srcset=\"https://cdn.auth0.com/website/sdks/logos/auth0_light_mode.png\"   width=\"150\"\u003e\n    \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://cdn.auth0.com/website/sdks/logos/auth0_dark_mode.png\" width=\"150\"\u003e\n    \u003cimg alt=\"Auth0 Logo\" src=\"https://cdn.auth0.com/website/sdks/logos/auth0_light_mode.png\" width=\"150\"\u003e\n  \u003c/picture\u003e\n\u003c/p\u003e\n\u003cp align=\"center\"\u003eAuth0 is an easy to implement, adaptable authentication and authorization platform. To learn more checkout \u003ca href=\"https://auth0.com/why-auth0\"\u003eWhy Auth0?\u003c/a\u003e\u003c/p\u003e\n\u003cp align=\"center\"\u003e\nThis project is licensed under the MIT license. See the \u003ca href=\"https://github.com/auth0/auth0-python/blob/master/LICENSE\"\u003e LICENSE\u003c/a\u003e file for more info.\u003c/p\u003e\n","funding_links":[],"categories":["Back-End Development"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fauth0%2Fauth0-python","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fauth0%2Fauth0-python","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fauth0%2Fauth0-python/lists"}