{"id":15046636,"url":"https://github.com/auth0/auth0-java","last_synced_at":"2025-05-15T04:03:36.321Z","repository":{"id":3637921,"uuid":"49220316","full_name":"auth0/auth0-java","owner":"auth0","description":"Java client library for the Auth0 platform","archived":false,"fork":false,"pushed_at":"2025-03-28T08:47:17.000Z","size":3143,"stargazers_count":305,"open_issues_count":13,"forks_count":133,"subscribers_count":41,"default_branch":"master","last_synced_at":"2025-04-06T23:11:32.686Z","etag":null,"topics":["dx-sdk","hacktoberfest","java"],"latest_commit_sha":null,"homepage":"https://auth0.com","language":"Java","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":"2016-01-07T17:45:04.000Z","updated_at":"2025-04-04T02:12:43.000Z","dependencies_parsed_at":"2023-11-07T05:04:56.262Z","dependency_job_id":"19ebb722-72d9-4859-83bf-1622488c6257","html_url":"https://github.com/auth0/auth0-java","commit_stats":{"total_commits":688,"total_committers":54,"mean_commits":12.74074074074074,"dds":0.626453488372093,"last_synced_commit":"920affc0b0327e78e329272ac29cc5bd34dd5b76"},"previous_names":[],"tags_count":96,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0%2Fauth0-java","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0%2Fauth0-java/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0%2Fauth0-java/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0%2Fauth0-java/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/auth0","download_url":"https://codeload.github.com/auth0/auth0-java/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248819381,"owners_count":21166477,"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","hacktoberfest","java"],"created_at":"2024-09-24T20:53:19.596Z","updated_at":"2025-05-15T04:03:36.303Z","avatar_url":"https://github.com/auth0.png","language":"Java","readme":"\u003e **Note**\n\u003e As part of our ongoing commitment to best security practices, we have rotated the signing keys used to sign previous releases of this SDK. As a result, new patch builds have been released using the new signing key. Please upgrade at your earliest convenience.\n\u003e\n\u003e While this change won't affect most developers, if you have implemented a dependency signature validation step in your build process, you may notice a warning that past releases can't be verified. This is expected, and a result of the key rotation process. Updating to the latest version will resolve this for you.\n\n![A Java client library for the Auth0 Authentication and Management APIs.](https://cdn.auth0.com/website/sdks/banners/auth0-java-banner.png)\n\n![Build Status](https://img.shields.io/github/checks-status/auth0/auth0-java/master)\n[![Coverage Status](https://codecov.io/gh/auth0/auth0-java/branch/master/graph/badge.svg?style=flat-square)](https://codecov.io/github/auth0/auth0-java)\n[![License](http://img.shields.io/:license-mit-blue.svg?style=flat)](https://doge.mit-license.org/)\n[![Maven Central](https://img.shields.io/maven-central/v/com.auth0/auth0.svg?style=flat-square)](https://search.maven.org/#search%7Cga%7C1%7Cg%3A%22com.auth0%22%20AND%20a%3A%22auth0%22)\n[![javadoc](https://javadoc.io/badge2/com.auth0/auth0/javadoc.svg)](https://javadoc.io/doc/com.auth0/auth0)\n\n:books: [Documentation](#documentation) - :rocket: [Getting Started](#getting-started) - :computer: [API Reference](#api-reference) :speech_balloon: [Feedback](#feedback)\n\n## Documentation\n- [Examples](./EXAMPLES.md) - code samples for common auth0-java scenarios.\n- [Migration Guide](./MIGRATION_GUIDE.md) - guidance for updating your application to use version 2 of auth0-java.\n- [Docs site](https://www.auth0.com/docs) - explore our docs site and learn more about Auth0.\n\n## Getting Started\n\n### Requirements\n\nJava 8 or above.\n\n\u003e `auth0-java` is intended for server-side JVM applications. Android applications should use the [Auth0.Android SDK](https://github.com/auth0/auth0.android).\n\n### Installation\n\nAdd the dependency via Maven:\n\n```xml\n\u003cdependency\u003e\n  \u003cgroupId\u003ecom.auth0\u003c/groupId\u003e\n  \u003cartifactId\u003eauth0\u003c/artifactId\u003e\n  \u003cversion\u003e2.20.0\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\nor Gradle:\n\n```gradle\nimplementation 'com.auth0:auth0:2.20.0'\n```\n\n### Configure the SDK\n\n#### Authentication API Client\n\nThe Authentication API client is based on the [Auth0 Authentication API](https://auth0.com/docs/api/authentication).\n\nCreate an `AuthAPI` instance by providing the Application details from the [dashboard](https://manage.auth0.com/#/applications).\n\n```java\nAuthAPI auth = AuthAPI.newBuilder(\"{YOUR_DOMAIN}\", \"{YOUR_CLIENT_ID}\", \"{YOUR_CLIENT_SECRET}\").build();\n```\n\n#### Management API Client\n\nThe Management API client is based on the [Management API Docs](https://auth0.com/docs/api/management/v2).\n\nCreate a `ManagementAPI` instance by providing the domain from the [Application dashboard](https://manage.auth0.com/#/applications) and a valid API Token.\n\n```java\nManagementAPI mgmt = ManagementAPI.newBuilder(\"{YOUR_DOMAIN}\", \"{YOUR_API_TOKEN}\").build();\n```\n\nThe Management API is organized by entities represented by the Auth0 Management API objects.\n\n```java\nUser user = mgmt.users().get(\"auth0|user-id\", new UserFilter()).execute().getBody();\nRole role = mgmt.roles().get(\"role-id\").execute().getBody();\n```\n\nYou can use the Authentication API to obtain a token for a previously authorized Application:\n\n```java\nAuthAPI authAPI = AuthAPI.newBuilder(\"{YOUR_DOMAIN}\", \"{YOUR_CLIENT_ID}\", \"{YOUR_CLIENT_SECRET}\").build();\nTokenRequest tokenRequest = authAPI.requestToken(\"https://{YOUR_DOMAIN}/api/v2/\");\nTokenHolder holder = tokenRequest.execute().getBody();\nString accessToken = holder.getAccessToken();\nManagementAPI mgmt = ManagementAPI.newBuilder(\"{YOUR_DOMAIN}\", accessToken).build();\n```\n\nAn expired token for an existing `ManagementAPI` instance can be replaced by calling the `setApiToken` method with the new token.\n\nSee the [Auth0 Management API documentation](https://auth0.com/docs/api/management/v2/tokens) for more information on how to obtain API Tokens.\n\n## API Reference\n\n- [AuthAPI](https://javadoc.io/doc/com.auth0/auth0/latest/com/auth0/client/auth/AuthAPI.html)\n- [ManagementAPI](https://javadoc.io/doc/com.auth0/auth0/latest/com/auth0/client/mgmt/ManagementAPI.html)\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\nTo provide feedback or report a bug, [please raise an issue on our issue tracker](https://github.com/auth0/auth0-java/issues).\n\n### Vulnerability Reporting\nPlease do not report security vulnerabilities on the public Github issue tracker. The [Responsible Disclosure Program](https://auth0.com/whitehat) 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=\"./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=\"./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-java","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fauth0%2Fauth0-java","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fauth0%2Fauth0-java/lists"}