You are here

public function EdgeKeyTypeBase::getClientSecret in Apigee Edge 8

Gets the client secret.

Parameters

\Drupal\key\KeyInterface $key: The key entity.

Return value

string The client secret.

Overrides EdgeKeyTypeInterface::getClientSecret

1 call to EdgeKeyTypeBase::getClientSecret()
ApigeeAuthKeyType::getAuthenticationMethod in src/Plugin/KeyType/ApigeeAuthKeyType.php
Gets the authentication method object.

File

src/Plugin/EdgeKeyTypeBase.php, line 157

Class

EdgeKeyTypeBase
Defines a base class for Apigee Edge Key Type plugins.

Namespace

Drupal\apigee_edge\Plugin

Code

public function getClientSecret(KeyInterface $key) : string {
  return $key
    ->getKeyValues()['client_secret'] ?? Oauth::DEFAULT_CLIENT_SECRET;
}