interface SalesforceAuthProviderInterface in Salesforce Suite 8.4
Same name and namespace in other branches
- 8.3 src/SalesforceAuthProviderInterface.php \Drupal\salesforce\SalesforceAuthProviderInterface
- 5.0.x src/SalesforceAuthProviderInterface.php \Drupal\salesforce\SalesforceAuthProviderInterface
Class SalesforceAuthProvider.
Hierarchy
- interface \Drupal\Core\Plugin\PluginFormInterface; interface \Drupal\Core\Plugin\ContainerFactoryPluginInterface; interface \Drupal\Component\Plugin\PluginInspectionInterface
- interface \Drupal\salesforce\SalesforceAuthProviderInterface extends \OAuth\OAuth2\Service\ServiceInterface
Expanded class hierarchy of SalesforceAuthProviderInterface
All classes that implement SalesforceAuthProviderInterface
2 files declare their use of SalesforceAuthProviderInterface
- RestClientTest.php in tests/
src/ Unit/ RestClientTest.php - SalesforceOAuthController.php in modules/
salesforce_oauth/ src/ Controller/ SalesforceOAuthController.php
File
- src/
SalesforceAuthProviderInterface.php, line 15
Namespace
Drupal\salesforceView source
interface SalesforceAuthProviderInterface extends ServiceInterface, PluginFormInterface, ContainerFactoryPluginInterface, PluginInspectionInterface {
const AUTH_TOKEN_PATH = '/services/oauth2/token';
const AUTH_ENDPOINT_PATH = '/services/oauth2/authorize';
const SOAP_CLASS_PATH = '/services/Soap/class/';
const LATEST_API_VERSION = '44.0';
/**
* Id of this service.
*
* @return string
* Id of this service.
*/
public function id();
/**
* Label of this service.
*
* @return string
* Id of this service.
*/
public function label();
/**
* Perform a refresh of the given token.
*
* NB: This method should also refresh any associated identity.
*
* @param \OAuth\Common\Token\TokenInterface $token
* The token.
*
* @return \OAuth\Common\Token\TokenInterface
* The refreshed token.
*
* @throws \OAuth\OAuth2\Service\Exception\MissingRefreshTokenException
* Comment.
*/
public function refreshAccessToken(TokenInterface $token);
/**
* Given a token, fetch the SF identity.
*
* @param \OAuth\Common\Token\TokenInterface $token
* The token.
*
* @return \Drupal\salesforce\Rest\SalesforceIdentityInterface
* The refreshed identity.
*
* @throws \OAuth\OAuth2\Service\Exception\MissingRefreshTokenException
* Comment.
*/
public function refreshIdentity(TokenInterface $token);
/**
* Return the credentials configured for this auth provider instance.
*
* Credentials contain consumer key, login url, secret, etc.
*
* @return \Drupal\salesforce\Consumer\SalesforceCredentialsInterface
* The credentials.
*/
public function getCredentials();
/**
* Access token for this plugin.
*
* @return \OAuth\OAuth2\Token\TokenInterface
* The Token.
*
* @throws \OAuth\Common\Storage\Exception\TokenNotFoundException
*/
public function getAccessToken();
/**
* Identify for this connection.
*
* @return \Drupal\salesforce\Rest\SalesforceIdentityInterface
* Identity for this connection.
*
* @throws \Drupal\salesforce\IdentityNotFoundException
* If there is no identity.
*/
public function getIdentity();
/**
* TRUE if the connection has a token, regardless of validity.
*
* @return bool
* TRUE if the connection has a token, regardless of validity.
*/
public function hasAccessToken();
/**
* Clear the access token for this auth provider plugin.
*
* @return $this
*/
public function revokeAccessToken();
/**
* Default configuration for this plugin type.
*
* @return array
* Default configuration.
*/
public static function defaultConfiguration();
/**
* Authorization URL for this plugin type.
*
* @return string
* Authorization URL for this plugin type.
*/
public function getAuthorizationEndpoint();
/**
* Access token URL for this plugin type.
*
* @return string
* Access token URL for this plugin type.
*/
public function getAccessTokenEndpoint();
/**
* Get the globally configured API version to use.
*
* @return string
* The string name of the API version.
*/
public function getApiVersion();
/**
* API Url for this plugin.
*
* @param string $api_type
* (optional) Which API for which to retrieve URL, defaults to "rest".
*
* @return string
* The URL.
*/
public function getApiEndpoint($api_type = 'rest');
/**
* Instance URL for this connection.
*
* @return string
* Instance URL for this connection.
*
* @throws \OAuth\Common\Storage\Exception\TokenNotFoundException
*/
public function getInstanceUrl();
/**
* Callback for configuration form after saving config entity.
*
* @param array $form
* The configuration form.
* @param \Drupal\Core\Form\FormStateInterface $form_state
* The form state.
*/
public function save(array $form, FormStateInterface $form_state);
/**
* The auth provider service.
*
* @return \Drupal\salesforce\SalesforceAuthProviderInterface
* The auth provider service.
*/
public function service();
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ContainerFactoryPluginInterface:: |
public static | function | Creates an instance of the plugin. | 112 |
PluginFormInterface:: |
public | function | Form constructor. | 36 |
PluginFormInterface:: |
public | function | Form submission handler. | 32 |
PluginFormInterface:: |
public | function | Form validation handler. | 18 |
PluginInspectionInterface:: |
public | function | Gets the definition of the plugin implementation. | 4 |
PluginInspectionInterface:: |
public | function | Gets the plugin_id of the plugin instance. | 2 |
SalesforceAuthProviderInterface:: |
constant | |||
SalesforceAuthProviderInterface:: |
constant | |||
SalesforceAuthProviderInterface:: |
public static | function | Default configuration for this plugin type. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Access token for this plugin. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Access token URL for this plugin type. | 1 |
SalesforceAuthProviderInterface:: |
public | function | API Url for this plugin. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Get the globally configured API version to use. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Authorization URL for this plugin type. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Return the credentials configured for this auth provider instance. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Identify for this connection. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Instance URL for this connection. | 1 |
SalesforceAuthProviderInterface:: |
public | function | TRUE if the connection has a token, regardless of validity. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Id of this service. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Label of this service. | 1 |
SalesforceAuthProviderInterface:: |
constant | |||
SalesforceAuthProviderInterface:: |
public | function | Perform a refresh of the given token. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Given a token, fetch the SF identity. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Clear the access token for this auth provider plugin. | 1 |
SalesforceAuthProviderInterface:: |
public | function | Callback for configuration form after saving config entity. | 1 |
SalesforceAuthProviderInterface:: |
public | function | The auth provider service. | 1 |
SalesforceAuthProviderInterface:: |
constant |