diff --git a/src/Auth0/Login/Auth0Service.php b/src/Auth0/Login/Auth0Service.php index f0f50a69..b61598dd 100644 --- a/src/Auth0/Login/Auth0Service.php +++ b/src/Auth0/Login/Auth0Service.php @@ -66,6 +66,11 @@ public function __construct( $auth0Config['cache_handler'] = $cache; + if(isset($auth0Config['api_identifier'])) { + // Auth0\SDK\Auth0 is using `audience` to create a login link. + $auth0Config['audience'] = $auth0Config['api_identifier']; + } + $this->auth0Config = $auth0Config; $this->auth0 = new Auth0($auth0Config); }