You are here

class Oauth2Client in OAuth2 Client 8.2

Same name and namespace in other branches
  1. 8.3 src/Annotation/Oauth2Client.php \Drupal\oauth2_client\Annotation\Oauth2Client

Annotation definition Oauth2Client plugins.

Hierarchy

Expanded class hierarchy of Oauth2Client

File

src/Annotation/Oauth2Client.php, line 12

Namespace

Drupal\oauth2_client\Annotation
View source
class Oauth2Client extends Plugin {

  /**
   * The OAuth 2 plugin ID.
   *
   * @var string
   */
  public $id;

  /**
   * The human-readable name of the OAuth2 Client.
   *
   * @var \Drupal\Core\Annotation\Translation
   *
   * @ingroup plugin_translatable
   */
  public $name;

  /**
   * The client_id of the OAuth2 server.
   *
   * @var string
   */
  public $client_id;

  /**
   * The grant type of the OAuth2 authorization.
   *
   * Possible values:
   * - authorization_code
   * - client_credentials
   * - resource_owner - Note that the 'username' and 'password' attributes are
   *   required for this type.
   *
   * @var string
   */
  public $grant_type;

  /**
   * The client_secret of the OAuth2 server.
   *
   * @var string
   */
  public $client_secret;

  /**
   * The authorization endpoint of the OAuth2 server.
   *
   * @var string
   */
  public $authorization_uri;

  /**
   * The token endpoint of the OAuth2 server.
   *
   * @var string
   */
  public $token_uri;

  /**
   * The resource endpoint of the OAuth2 Server.
   *
   * @var string
   */
  public $resource_uri;

  /**
   * The Resource Owner Details endpoint.
   *
   * @var string
   */
  public $resource_owner_uri;

  /**
   * The set of scopes for the provider to use by default.
   *
   * @var array|string|null
   */
  public $scopes;

  /**
   * The separator used to join the scopes in the OAuth2 query string.
   *
   * @var string|null
   */
  public $scope_separator;

  /**
   * The username of the account being authenticated.
   *
   * Note: Used only when the grant_type is set to resource_owner.
   *
   * @var string
   */
  public $username;

  /**
   * The password of the account being authenticated.
   *
   * Note: Used only when the grant_type is set to resource_owner.
   *
   * @var string
   */
  public $password;

}

Members

Namesort descending Modifiers Type Description Overrides
Oauth2Client::$authorization_uri public property The authorization endpoint of the OAuth2 server.
Oauth2Client::$client_id public property The client_id of the OAuth2 server.
Oauth2Client::$client_secret public property The client_secret of the OAuth2 server.
Oauth2Client::$grant_type public property The grant type of the OAuth2 authorization.
Oauth2Client::$id public property The OAuth 2 plugin ID.
Oauth2Client::$name public property The human-readable name of the OAuth2 Client.
Oauth2Client::$password public property The password of the account being authenticated.
Oauth2Client::$resource_owner_uri public property The Resource Owner Details endpoint.
Oauth2Client::$resource_uri public property The resource endpoint of the OAuth2 Server.
Oauth2Client::$scopes public property The set of scopes for the provider to use by default.
Oauth2Client::$scope_separator public property The separator used to join the scopes in the OAuth2 query string.
Oauth2Client::$token_uri public property The token endpoint of the OAuth2 server.
Oauth2Client::$username public property The username of the account being authenticated.
Plugin::$definition protected property The plugin definition read from the class annotation. 1
Plugin::get public function Gets the value of an annotation. Overrides AnnotationInterface::get 5
Plugin::getClass public function Gets the class of the annotated class. Overrides AnnotationInterface::getClass
Plugin::getId public function Gets the unique ID for this annotated class. Overrides AnnotationInterface::getId
Plugin::getProvider public function Gets the name of the provider of the annotated class. Overrides AnnotationInterface::getProvider
Plugin::parse protected function Parses an annotation into its definition.
Plugin::setClass public function Sets the class of the annotated class. Overrides AnnotationInterface::setClass
Plugin::setProvider public function Sets the name of the provider of the annotated class. Overrides AnnotationInterface::setProvider
Plugin::__construct public function Constructs a Plugin object. 2