CustomApiBuilder
Last updated
Was this helpful?
Last updated
Was this helpful?
The CustomApiBuilder
facilitates the configuration of the OAuth plugin for integration with less common or custom providers, including in-house solutions. This includes options for parsing and handling tokens, specifying request methods, and configuring authentication and endpoint URLs for token-related operations such as access, refresh, and revocation.
It supports methods to customize the API by enabling access token extraction, specifying token request methods, defining client authentication mechanisms, and setting up refresh and revoke token endpoints, allowing integration with a variety of OAuth implementations.
Configures the api with a token extractor which parses the concrete type of token from the response string.
The request method used for the access token endpoint (defaults to POST).
Configures the api with a client authentication method which specifies how the client credentials are sent.
Configure the api with the URL that receives the refresh token requests.
Configure the api with the URL that receives the revoke token requests.
Configures the api with a token extractor which parses the concrete type of token from the response string.
Parameters
accessTokenExtractor see plugins.oauth.OAuthTokenExtractors
The request method used for the access token endpoint (defaults to POST).
Parameters
Configures the api with a client authentication method which specifies how the client credentials are sent. They can be sent as basic Auth header or in the request body.
Parameters
Configure the api with the URL that receives the refresh token requests.
Parameters
Configure the api with the URL that receives the revoke token requests.
Parameters
Returns: the api builder for method chaining
tokenRequestMethod can be 'post' or 'get'
Returns: the api builder for method chaining
clientAuthentication see plugins.oauth.ClientAuthentication
Returns: the api builder for method chaining
refreshTokenEndpoint ;
Returns: the api builder for method chaining
revokeTokenEndpoint ;
Returns: the api builder for method chaining