public final class TokenEndpointClient extends Object
This class provides a method to request an OAuth token from a specified token endpoint URL
using the provided HTTP client and request parameters. It handles the HTTP request and parses the
JSON response into an OAuthResponse object.
| Modifier and Type | Method and Description |
|---|---|
static OAuthResponse |
requestToken(HttpClient httpClient,
String tokenEndpointUrl,
Map<String,String> params)
Requests an OAuth token from the specified token endpoint.
|
public static OAuthResponse requestToken(HttpClient httpClient, String tokenEndpointUrl, Map<String,String> params) throws DatabricksException
httpClient - The HttpClient to use for making the request.tokenEndpointUrl - The URL of the token endpoint.params - A map of parameters to include in the token request.OAuthResponse containing the token information.DatabricksException - if an error occurs during the token request or response parsing.IllegalArgumentException - if the token endpoint URL is empty.NullPointerException - if any of the parameters are null.Copyright © 2025. All rights reserved.