Class yii\authclient\clients\Live
Inheritance | yii\authclient\clients\Live » yii\authclient\OAuth2 » yii\authclient\BaseOAuth » yii\authclient\BaseClient » yii\base\Component » yii\base\BaseObject |
---|---|
Implements | yii\authclient\ClientInterface, yii\base\Configurable |
Available since version | 2.0 |
Source Code | https://github.com/yiisoft/yii2-authclient/blob/master/clients/Live.php |
Live allows authentication via Microsoft Live OAuth.
In order to use Microsoft Live OAuth you must register your application at https://account.live.com/developers/applications
Example application configuration:
'components' => [
'authClientCollection' => [
'class' => 'yii\authclient\Collection',
'clients' => [
'live' => [
'class' => 'yii\authclient\clients\Live',
'clientId' => 'live_client_id',
'clientSecret' => 'live_client_secret',
],
],
]
// ...
]
See also:
Public Properties
Property | Type | Description | Defined By |
---|---|---|---|
$apiBaseUrl | {@inheritdoc} | yii\authclient\clients\Live | |
$authUrl | {@inheritdoc} | yii\authclient\clients\Live | |
$autoRefreshAccessToken | boolean | Whether to automatically perform 'refresh access token' request on expired access token. | yii\authclient\BaseOAuth |
$clientId | string | OAuth client ID. | yii\authclient\OAuth2 |
$clientSecret | string | OAuth client secret. | yii\authclient\OAuth2 |
$parametersToKeepInReturnUrl | array | List of the parameters to keep in default return url. | yii\authclient\BaseOAuth |
$scope | string | Auth request scope. | yii\authclient\BaseOAuth |
$tokenUrl | {@inheritdoc} | yii\authclient\clients\Live | |
$validateAuthState | boolean | Whether to use and validate auth 'state' parameter in authentication flow. | yii\authclient\OAuth2 |
$version | string | Protocol version. | yii\authclient\BaseOAuth |
Public Methods
Protected Methods
Method | Description | Defined By |
---|---|---|
applyClientCredentialsToRequest() | Applies client credentials (e.g. $clientId and $clientSecret) to the HTTP request instance. | yii\authclient\OAuth2 |
composeUrl() | Composes URL from base URL and GET params. | yii\authclient\BaseOAuth |
createHttpClient() | Creates HTTP client instance from reference or configuration. | yii\authclient\BaseClient |
createSignatureMethod() | Creates signature method instance from its configuration. | yii\authclient\BaseOAuth |
createToken() | Creates token from its configuration. | yii\authclient\BaseOAuth |
defaultName() | {@inheritdoc} | yii\authclient\clients\Live |
defaultNormalizeUserAttributeMap() | Returns the default \yii\authclient\normalizeUserAttributeMap value. | yii\authclient\BaseClient |
defaultRequestOptions() | Returns default HTTP request options. | yii\authclient\BaseClient |
defaultReturnUrl() | Composes default \yii\authclient\returnUrl value. | yii\authclient\BaseOAuth |
defaultTitle() | {@inheritdoc} | yii\authclient\clients\Live |
defaultViewOptions() | Returns the default \yii\authclient\viewOptions value. | yii\authclient\BaseClient |
generateAuthState() | Generates the auth state value. | yii\authclient\OAuth2 |
getState() | Returns persistent state value. | yii\authclient\BaseClient |
getStateKeyPrefix() | Returns session key prefix, which is used to store internal states. | yii\authclient\BaseClient |
initUserAttributes() | {@inheritdoc} | yii\authclient\clients\Live |
normalizeUserAttributes() | Normalize given user attributes according to \yii\authclient\normalizeUserAttributeMap. | yii\authclient\BaseClient |
removeState() | Removes persistent state value. | yii\authclient\BaseClient |
restoreAccessToken() | Restores access token. | yii\authclient\BaseOAuth |
saveAccessToken() | Saves token as persistent state. | yii\authclient\BaseOAuth |
sendRequest() | Sends the given HTTP request, returning response data. | yii\authclient\BaseOAuth |
setState() | Sets persistent state. | yii\authclient\BaseClient |
Property Details
Method Details
{@inheritdoc}
protected void defaultName ( ) |
{@inheritdoc}
protected void defaultTitle ( ) |
{@inheritdoc}
public void init ( ) |
{@inheritdoc}
protected void initUserAttributes ( ) |