Auth0 PHP SDK.
The Auth0 PHP SDK provides straight-forward and tested methods for accessing Authentication and Management API endpoints. This README describes how to get started and provides simple examples of how to use the SDK.
For more details about how to install this SDK into an existing project or how to download a preconfigured seed project, see:
- Getting Started
- Support + Feedback
- Vulnerability Reporting
- What is Auth0
We recommend installing the SDK with Composer:
$ composer require auth0/auth0-php
More details on this process as well as a manual option can be found on the main documentation page.
// Instantiate the base Auth0 class. $auth0 = new Auth0([ // The values below are found on the Application settings tab. 'domain' => 'your-tenant.auth0.com', 'client_id' => 'application_client_id', 'client_secret' => 'application_client_secret', // This is your application URL that will be used to process the login. // Save this URL in the "Allowed Callback URLs" field on the Application settings tab 'redirect_uri' => 'https://yourdomain.com/auth/callback', ]);
The values above should not be hard-coded in a production application but will suffice for testing or local development. Please see our complete guide on the main documentation page for more information on how to store and use these values.
We appreciate feedback and contribution to this repo! Before you get started, please see the following:
- Auth0's general contribution guidelines
- Auth0's code of conduct guidelines
- This repo's contribution guide
- Use Community for usage, questions, specific cases
- Use Issues here for code-level support and bug reports
- Customers with a paid Auth0 subscription can use the Support Center to submit a ticket to our support specialists.
Please do not report security vulnerabilities on the public GitHub issue tracker. The Responsible Disclosure Program details the procedure for disclosing security issues.
Auth0 helps you to easily:
- implement authentication with multiple identity providers, including social (e.g., Google, Facebook, Microsoft, LinkedIn, GitHub, Twitter, etc), or enterprise (e.g., Windows Azure AD, Google Apps, Active Directory, ADFS, SAML, etc.)
- log in users with username/password databases, passwordless, or multi-factor authentication
- link multiple user accounts together
- generate signed JSON Web Tokens to authorize your API calls and flow the user identity securely
- access demographics and analytics detailing how, when, and where users are logging in
The Auth0-PHP SDK is licensed under MIT - LICENSE