Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
/*
* ORY Hydra
* Welcome to the ORY Hydra HTTP API documentation. You will find documentation for all HTTP APIs here.
*
* The version of the OpenAPI document: latest
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package sh.ory.hydra.api;
import sh.ory.hydra.ApiCallback;
import sh.ory.hydra.ApiClient;
import sh.ory.hydra.ApiException;
import sh.ory.hydra.ApiResponse;
import sh.ory.hydra.Configuration;
import sh.ory.hydra.Pair;
import sh.ory.hydra.ProgressRequestBody;
import sh.ory.hydra.ProgressResponseBody;
import com.google.gson.reflect.TypeToken;
import java.io.IOException;
import sh.ory.hydra.model.AcceptConsentRequest;
import sh.ory.hydra.model.AcceptLoginRequest;
import sh.ory.hydra.model.CompletedRequest;
import sh.ory.hydra.model.ConsentRequest;
import sh.ory.hydra.model.FlushInactiveOAuth2TokensRequest;
import sh.ory.hydra.model.GenericError;
import sh.ory.hydra.model.HealthStatus;
import sh.ory.hydra.model.JSONWebKey;
import sh.ory.hydra.model.JSONWebKeySet;
import sh.ory.hydra.model.JsonWebKeySetGeneratorRequest;
import sh.ory.hydra.model.LoginRequest;
import sh.ory.hydra.model.LogoutRequest;
import sh.ory.hydra.model.OAuth2Client;
import sh.ory.hydra.model.OAuth2TokenIntrospection;
import sh.ory.hydra.model.PreviousConsentSession;
import sh.ory.hydra.model.RejectRequest;
import sh.ory.hydra.model.Version;
import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class AdminApi {
private ApiClient localVarApiClient;
public AdminApi() {
this(Configuration.getDefaultApiClient());
}
public AdminApi(ApiClient apiClient) {
this.localVarApiClient = apiClient;
}
public ApiClient getApiClient() {
return localVarApiClient;
}
public void setApiClient(ApiClient apiClient) {
this.localVarApiClient = apiClient;
}
/**
* Build call for acceptConsentRequest
* @param consentChallenge (required)
* @param body (optional)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call acceptConsentRequestCall(String consentChallenge, AcceptConsentRequest body, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/oauth2/auth/requests/consent/accept";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
if (consentChallenge != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("consent_challenge", consentChallenge));
}
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call acceptConsentRequestValidateBeforeCall(String consentChallenge, AcceptConsentRequest body, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'consentChallenge' is set
if (consentChallenge == null) {
throw new ApiException("Missing the required parameter 'consentChallenge' when calling acceptConsentRequest(Async)");
}
okhttp3.Call localVarCall = acceptConsentRequestCall(consentChallenge, body, _callback);
return localVarCall;
}
/**
* Accept a consent request
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider to authenticate the subject and then tell ORY Hydra now about it. If the subject authenticated, he/she must now be asked if the OAuth 2.0 Client which initiated the flow should be allowed to access the resources on the subject's behalf. The consent provider which handles this request and is a web app implemented and hosted by you. It shows a subject interface which asks the subject to grant or deny the client access to the requested scope (\"Application my-dropbox-app wants write access to all your private files\"). The consent challenge is appended to the consent provider's URL to which the subject's user-agent (browser) is redirected to. The consent provider uses that challenge to fetch information on the OAuth2 request and then tells ORY Hydra if the subject accepted or rejected the request. This endpoint tells ORY Hydra that the subject has authorized the OAuth 2.0 client to access resources on his/her behalf. The consent provider includes additional information, such as session data for access and ID tokens, and if the consent request should be used as basis for future requests. The response contains a redirect URL which the consent provider should redirect the user-agent to.
* @param consentChallenge (required)
* @param body (optional)
* @return CompletedRequest
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
404
genericError
-
500
genericError
-
*/
public CompletedRequest acceptConsentRequest(String consentChallenge, AcceptConsentRequest body) throws ApiException {
ApiResponse localVarResp = acceptConsentRequestWithHttpInfo(consentChallenge, body);
return localVarResp.getData();
}
/**
* Accept a consent request
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider to authenticate the subject and then tell ORY Hydra now about it. If the subject authenticated, he/she must now be asked if the OAuth 2.0 Client which initiated the flow should be allowed to access the resources on the subject's behalf. The consent provider which handles this request and is a web app implemented and hosted by you. It shows a subject interface which asks the subject to grant or deny the client access to the requested scope (\"Application my-dropbox-app wants write access to all your private files\"). The consent challenge is appended to the consent provider's URL to which the subject's user-agent (browser) is redirected to. The consent provider uses that challenge to fetch information on the OAuth2 request and then tells ORY Hydra if the subject accepted or rejected the request. This endpoint tells ORY Hydra that the subject has authorized the OAuth 2.0 client to access resources on his/her behalf. The consent provider includes additional information, such as session data for access and ID tokens, and if the consent request should be used as basis for future requests. The response contains a redirect URL which the consent provider should redirect the user-agent to.
* @param consentChallenge (required)
* @param body (optional)
* @return ApiResponse<CompletedRequest>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
404
genericError
-
500
genericError
-
*/
public ApiResponse acceptConsentRequestWithHttpInfo(String consentChallenge, AcceptConsentRequest body) throws ApiException {
okhttp3.Call localVarCall = acceptConsentRequestValidateBeforeCall(consentChallenge, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Accept a consent request (asynchronously)
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider to authenticate the subject and then tell ORY Hydra now about it. If the subject authenticated, he/she must now be asked if the OAuth 2.0 Client which initiated the flow should be allowed to access the resources on the subject's behalf. The consent provider which handles this request and is a web app implemented and hosted by you. It shows a subject interface which asks the subject to grant or deny the client access to the requested scope (\"Application my-dropbox-app wants write access to all your private files\"). The consent challenge is appended to the consent provider's URL to which the subject's user-agent (browser) is redirected to. The consent provider uses that challenge to fetch information on the OAuth2 request and then tells ORY Hydra if the subject accepted or rejected the request. This endpoint tells ORY Hydra that the subject has authorized the OAuth 2.0 client to access resources on his/her behalf. The consent provider includes additional information, such as session data for access and ID tokens, and if the consent request should be used as basis for future requests. The response contains a redirect URL which the consent provider should redirect the user-agent to.
* @param consentChallenge (required)
* @param body (optional)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call acceptConsentRequestAsync(String consentChallenge, AcceptConsentRequest body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = acceptConsentRequestValidateBeforeCall(consentChallenge, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for acceptLoginRequest
* @param loginChallenge (required)
* @param body (optional)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
401
genericError
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call acceptLoginRequestCall(String loginChallenge, AcceptLoginRequest body, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/oauth2/auth/requests/login/accept";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
if (loginChallenge != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("login_challenge", loginChallenge));
}
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call acceptLoginRequestValidateBeforeCall(String loginChallenge, AcceptLoginRequest body, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'loginChallenge' is set
if (loginChallenge == null) {
throw new ApiException("Missing the required parameter 'loginChallenge' when calling acceptLoginRequest(Async)");
}
okhttp3.Call localVarCall = acceptLoginRequestCall(loginChallenge, body, _callback);
return localVarCall;
}
/**
* Accept a login request
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider (sometimes called \"identity provider\") to authenticate the subject and then tell ORY Hydra now about it. The login provider is an web-app you write and host, and it must be able to authenticate (\"show the subject a login screen\") a subject (in OAuth2 the proper name for subject is \"resource owner\"). The authentication challenge is appended to the login provider URL to which the subject's user-agent (browser) is redirected to. The login provider uses that challenge to fetch information on the OAuth2 request and then accept or reject the requested authentication process. This endpoint tells ORY Hydra that the subject has successfully authenticated and includes additional information such as the subject's ID and if ORY Hydra should remember the subject's subject agent for future authentication attempts by setting a cookie. The response contains a redirect URL which the login provider should redirect the user-agent to.
* @param loginChallenge (required)
* @param body (optional)
* @return CompletedRequest
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
401
genericError
-
404
genericError
-
500
genericError
-
*/
public CompletedRequest acceptLoginRequest(String loginChallenge, AcceptLoginRequest body) throws ApiException {
ApiResponse localVarResp = acceptLoginRequestWithHttpInfo(loginChallenge, body);
return localVarResp.getData();
}
/**
* Accept a login request
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider (sometimes called \"identity provider\") to authenticate the subject and then tell ORY Hydra now about it. The login provider is an web-app you write and host, and it must be able to authenticate (\"show the subject a login screen\") a subject (in OAuth2 the proper name for subject is \"resource owner\"). The authentication challenge is appended to the login provider URL to which the subject's user-agent (browser) is redirected to. The login provider uses that challenge to fetch information on the OAuth2 request and then accept or reject the requested authentication process. This endpoint tells ORY Hydra that the subject has successfully authenticated and includes additional information such as the subject's ID and if ORY Hydra should remember the subject's subject agent for future authentication attempts by setting a cookie. The response contains a redirect URL which the login provider should redirect the user-agent to.
* @param loginChallenge (required)
* @param body (optional)
* @return ApiResponse<CompletedRequest>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
401
genericError
-
404
genericError
-
500
genericError
-
*/
public ApiResponse acceptLoginRequestWithHttpInfo(String loginChallenge, AcceptLoginRequest body) throws ApiException {
okhttp3.Call localVarCall = acceptLoginRequestValidateBeforeCall(loginChallenge, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Accept a login request (asynchronously)
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider (sometimes called \"identity provider\") to authenticate the subject and then tell ORY Hydra now about it. The login provider is an web-app you write and host, and it must be able to authenticate (\"show the subject a login screen\") a subject (in OAuth2 the proper name for subject is \"resource owner\"). The authentication challenge is appended to the login provider URL to which the subject's user-agent (browser) is redirected to. The login provider uses that challenge to fetch information on the OAuth2 request and then accept or reject the requested authentication process. This endpoint tells ORY Hydra that the subject has successfully authenticated and includes additional information such as the subject's ID and if ORY Hydra should remember the subject's subject agent for future authentication attempts by setting a cookie. The response contains a redirect URL which the login provider should redirect the user-agent to.
* @param loginChallenge (required)
* @param body (optional)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
401
genericError
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call acceptLoginRequestAsync(String loginChallenge, AcceptLoginRequest body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = acceptLoginRequestValidateBeforeCall(loginChallenge, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for acceptLogoutRequest
* @param logoutChallenge (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call acceptLogoutRequestCall(String logoutChallenge, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/oauth2/auth/requests/logout/accept";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
if (logoutChallenge != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("logout_challenge", logoutChallenge));
}
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call acceptLogoutRequestValidateBeforeCall(String logoutChallenge, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'logoutChallenge' is set
if (logoutChallenge == null) {
throw new ApiException("Missing the required parameter 'logoutChallenge' when calling acceptLogoutRequest(Async)");
}
okhttp3.Call localVarCall = acceptLogoutRequestCall(logoutChallenge, _callback);
return localVarCall;
}
/**
* Accept a logout request
* When a user or an application requests ORY Hydra to log out a user, this endpoint is used to confirm that logout request. No body is required. The response contains a redirect URL which the consent provider should redirect the user-agent to.
* @param logoutChallenge (required)
* @return CompletedRequest
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
404
genericError
-
500
genericError
-
*/
public CompletedRequest acceptLogoutRequest(String logoutChallenge) throws ApiException {
ApiResponse localVarResp = acceptLogoutRequestWithHttpInfo(logoutChallenge);
return localVarResp.getData();
}
/**
* Accept a logout request
* When a user or an application requests ORY Hydra to log out a user, this endpoint is used to confirm that logout request. No body is required. The response contains a redirect URL which the consent provider should redirect the user-agent to.
* @param logoutChallenge (required)
* @return ApiResponse<CompletedRequest>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
404
genericError
-
500
genericError
-
*/
public ApiResponse acceptLogoutRequestWithHttpInfo(String logoutChallenge) throws ApiException {
okhttp3.Call localVarCall = acceptLogoutRequestValidateBeforeCall(logoutChallenge, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Accept a logout request (asynchronously)
* When a user or an application requests ORY Hydra to log out a user, this endpoint is used to confirm that logout request. No body is required. The response contains a redirect URL which the consent provider should redirect the user-agent to.
* @param logoutChallenge (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
completedRequest
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call acceptLogoutRequestAsync(String logoutChallenge, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = acceptLogoutRequestValidateBeforeCall(logoutChallenge, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for createJsonWebKeySet
* @param set The set (required)
* @param body (optional)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
201
JSONWebKeySet
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public okhttp3.Call createJsonWebKeySetCall(String set, JsonWebKeySetGeneratorRequest body, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/keys/{set}"
.replaceAll("\\{" + "set" + "\\}", localVarApiClient.escapeString(set.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call createJsonWebKeySetValidateBeforeCall(String set, JsonWebKeySetGeneratorRequest body, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'set' is set
if (set == null) {
throw new ApiException("Missing the required parameter 'set' when calling createJsonWebKeySet(Async)");
}
okhttp3.Call localVarCall = createJsonWebKeySetCall(set, body, _callback);
return localVarCall;
}
/**
* Generate a new JSON Web Key
* This endpoint is capable of generating JSON Web Key Sets for you. There a different strategies available, such as symmetric cryptographic keys (HS256, HS512) and asymetric cryptographic keys (RS256, ECDSA). If the specified JSON Web Key Set does not exist, it will be created. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param set The set (required)
* @param body (optional)
* @return JSONWebKeySet
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
201
JSONWebKeySet
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public JSONWebKeySet createJsonWebKeySet(String set, JsonWebKeySetGeneratorRequest body) throws ApiException {
ApiResponse localVarResp = createJsonWebKeySetWithHttpInfo(set, body);
return localVarResp.getData();
}
/**
* Generate a new JSON Web Key
* This endpoint is capable of generating JSON Web Key Sets for you. There a different strategies available, such as symmetric cryptographic keys (HS256, HS512) and asymetric cryptographic keys (RS256, ECDSA). If the specified JSON Web Key Set does not exist, it will be created. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param set The set (required)
* @param body (optional)
* @return ApiResponse<JSONWebKeySet>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
201
JSONWebKeySet
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public ApiResponse createJsonWebKeySetWithHttpInfo(String set, JsonWebKeySetGeneratorRequest body) throws ApiException {
okhttp3.Call localVarCall = createJsonWebKeySetValidateBeforeCall(set, body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Generate a new JSON Web Key (asynchronously)
* This endpoint is capable of generating JSON Web Key Sets for you. There a different strategies available, such as symmetric cryptographic keys (HS256, HS512) and asymetric cryptographic keys (RS256, ECDSA). If the specified JSON Web Key Set does not exist, it will be created. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param set The set (required)
* @param body (optional)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
201
JSONWebKeySet
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public okhttp3.Call createJsonWebKeySetAsync(String set, JsonWebKeySetGeneratorRequest body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = createJsonWebKeySetValidateBeforeCall(set, body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for createOAuth2Client
* @param body (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
201
oAuth2Client
-
400
genericError
-
409
genericError
-
500
genericError
-
*/
public okhttp3.Call createOAuth2ClientCall(OAuth2Client body, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/clients";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call createOAuth2ClientValidateBeforeCall(OAuth2Client body, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'body' is set
if (body == null) {
throw new ApiException("Missing the required parameter 'body' when calling createOAuth2Client(Async)");
}
okhttp3.Call localVarCall = createOAuth2ClientCall(body, _callback);
return localVarCall;
}
/**
* Create an OAuth 2.0 client
* Create a new OAuth 2.0 client If you pass `client_secret` the secret will be used, otherwise a random secret will be generated. The secret will be returned in the response and you will not be able to retrieve it later on. Write the secret down and keep it somwhere safe. OAuth 2.0 clients are used to perform OAuth 2.0 and OpenID Connect flows. Usually, OAuth 2.0 clients are generated for applications which want to consume your OAuth 2.0 or OpenID Connect capabilities. To manage ORY Hydra, you will need an OAuth 2.0 Client as well. Make sure that this endpoint is well protected and only callable by first-party components.
* @param body (required)
* @return OAuth2Client
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
201
oAuth2Client
-
400
genericError
-
409
genericError
-
500
genericError
-
*/
public OAuth2Client createOAuth2Client(OAuth2Client body) throws ApiException {
ApiResponse localVarResp = createOAuth2ClientWithHttpInfo(body);
return localVarResp.getData();
}
/**
* Create an OAuth 2.0 client
* Create a new OAuth 2.0 client If you pass `client_secret` the secret will be used, otherwise a random secret will be generated. The secret will be returned in the response and you will not be able to retrieve it later on. Write the secret down and keep it somwhere safe. OAuth 2.0 clients are used to perform OAuth 2.0 and OpenID Connect flows. Usually, OAuth 2.0 clients are generated for applications which want to consume your OAuth 2.0 or OpenID Connect capabilities. To manage ORY Hydra, you will need an OAuth 2.0 Client as well. Make sure that this endpoint is well protected and only callable by first-party components.
* @param body (required)
* @return ApiResponse<OAuth2Client>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
201
oAuth2Client
-
400
genericError
-
409
genericError
-
500
genericError
-
*/
public ApiResponse createOAuth2ClientWithHttpInfo(OAuth2Client body) throws ApiException {
okhttp3.Call localVarCall = createOAuth2ClientValidateBeforeCall(body, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Create an OAuth 2.0 client (asynchronously)
* Create a new OAuth 2.0 client If you pass `client_secret` the secret will be used, otherwise a random secret will be generated. The secret will be returned in the response and you will not be able to retrieve it later on. Write the secret down and keep it somwhere safe. OAuth 2.0 clients are used to perform OAuth 2.0 and OpenID Connect flows. Usually, OAuth 2.0 clients are generated for applications which want to consume your OAuth 2.0 or OpenID Connect capabilities. To manage ORY Hydra, you will need an OAuth 2.0 Client as well. Make sure that this endpoint is well protected and only callable by first-party components.
* @param body (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
201
oAuth2Client
-
400
genericError
-
409
genericError
-
500
genericError
-
*/
public okhttp3.Call createOAuth2ClientAsync(OAuth2Client body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = createOAuth2ClientValidateBeforeCall(body, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for deleteJsonWebKey
* @param kid The kid of the desired key (required)
* @param set The set (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public okhttp3.Call deleteJsonWebKeyCall(String kid, String set, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/keys/{set}/{kid}"
.replaceAll("\\{" + "kid" + "\\}", localVarApiClient.escapeString(kid.toString()))
.replaceAll("\\{" + "set" + "\\}", localVarApiClient.escapeString(set.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteJsonWebKeyValidateBeforeCall(String kid, String set, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'kid' is set
if (kid == null) {
throw new ApiException("Missing the required parameter 'kid' when calling deleteJsonWebKey(Async)");
}
// verify the required parameter 'set' is set
if (set == null) {
throw new ApiException("Missing the required parameter 'set' when calling deleteJsonWebKey(Async)");
}
okhttp3.Call localVarCall = deleteJsonWebKeyCall(kid, set, _callback);
return localVarCall;
}
/**
* Delete a JSON Web Key
* Use this endpoint to delete a single JSON Web Key. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param kid The kid of the desired key (required)
* @param set The set (required)
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public void deleteJsonWebKey(String kid, String set) throws ApiException {
deleteJsonWebKeyWithHttpInfo(kid, set);
}
/**
* Delete a JSON Web Key
* Use this endpoint to delete a single JSON Web Key. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param kid The kid of the desired key (required)
* @param set The set (required)
* @return ApiResponse<Void>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public ApiResponse deleteJsonWebKeyWithHttpInfo(String kid, String set) throws ApiException {
okhttp3.Call localVarCall = deleteJsonWebKeyValidateBeforeCall(kid, set, null);
return localVarApiClient.execute(localVarCall);
}
/**
* Delete a JSON Web Key (asynchronously)
* Use this endpoint to delete a single JSON Web Key. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param kid The kid of the desired key (required)
* @param set The set (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public okhttp3.Call deleteJsonWebKeyAsync(String kid, String set, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteJsonWebKeyValidateBeforeCall(kid, set, _callback);
localVarApiClient.executeAsync(localVarCall, _callback);
return localVarCall;
}
/**
* Build call for deleteJsonWebKeySet
* @param set The set (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public okhttp3.Call deleteJsonWebKeySetCall(String set, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/keys/{set}"
.replaceAll("\\{" + "set" + "\\}", localVarApiClient.escapeString(set.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteJsonWebKeySetValidateBeforeCall(String set, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'set' is set
if (set == null) {
throw new ApiException("Missing the required parameter 'set' when calling deleteJsonWebKeySet(Async)");
}
okhttp3.Call localVarCall = deleteJsonWebKeySetCall(set, _callback);
return localVarCall;
}
/**
* Delete a JSON Web Key Set
* Use this endpoint to delete a complete JSON Web Key Set and all the keys in that set. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param set The set (required)
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public void deleteJsonWebKeySet(String set) throws ApiException {
deleteJsonWebKeySetWithHttpInfo(set);
}
/**
* Delete a JSON Web Key Set
* Use this endpoint to delete a complete JSON Web Key Set and all the keys in that set. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param set The set (required)
* @return ApiResponse<Void>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public ApiResponse deleteJsonWebKeySetWithHttpInfo(String set) throws ApiException {
okhttp3.Call localVarCall = deleteJsonWebKeySetValidateBeforeCall(set, null);
return localVarApiClient.execute(localVarCall);
}
/**
* Delete a JSON Web Key Set (asynchronously)
* Use this endpoint to delete a complete JSON Web Key Set and all the keys in that set. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param set The set (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public okhttp3.Call deleteJsonWebKeySetAsync(String set, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteJsonWebKeySetValidateBeforeCall(set, _callback);
localVarApiClient.executeAsync(localVarCall, _callback);
return localVarCall;
}
/**
* Build call for deleteOAuth2Client
* @param id The id of the OAuth 2.0 Client. (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call deleteOAuth2ClientCall(String id, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/clients/{id}"
.replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call deleteOAuth2ClientValidateBeforeCall(String id, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'id' is set
if (id == null) {
throw new ApiException("Missing the required parameter 'id' when calling deleteOAuth2Client(Async)");
}
okhttp3.Call localVarCall = deleteOAuth2ClientCall(id, _callback);
return localVarCall;
}
/**
* Deletes an OAuth 2.0 Client
* Delete an existing OAuth 2.0 Client by its ID. OAuth 2.0 clients are used to perform OAuth 2.0 and OpenID Connect flows. Usually, OAuth 2.0 clients are generated for applications which want to consume your OAuth 2.0 or OpenID Connect capabilities. To manage ORY Hydra, you will need an OAuth 2.0 Client as well. Make sure that this endpoint is well protected and only callable by first-party components.
* @param id The id of the OAuth 2.0 Client. (required)
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
404
genericError
-
500
genericError
-
*/
public void deleteOAuth2Client(String id) throws ApiException {
deleteOAuth2ClientWithHttpInfo(id);
}
/**
* Deletes an OAuth 2.0 Client
* Delete an existing OAuth 2.0 Client by its ID. OAuth 2.0 clients are used to perform OAuth 2.0 and OpenID Connect flows. Usually, OAuth 2.0 clients are generated for applications which want to consume your OAuth 2.0 or OpenID Connect capabilities. To manage ORY Hydra, you will need an OAuth 2.0 Client as well. Make sure that this endpoint is well protected and only callable by first-party components.
* @param id The id of the OAuth 2.0 Client. (required)
* @return ApiResponse<Void>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
404
genericError
-
500
genericError
-
*/
public ApiResponse deleteOAuth2ClientWithHttpInfo(String id) throws ApiException {
okhttp3.Call localVarCall = deleteOAuth2ClientValidateBeforeCall(id, null);
return localVarApiClient.execute(localVarCall);
}
/**
* Deletes an OAuth 2.0 Client (asynchronously)
* Delete an existing OAuth 2.0 Client by its ID. OAuth 2.0 clients are used to perform OAuth 2.0 and OpenID Connect flows. Usually, OAuth 2.0 clients are generated for applications which want to consume your OAuth 2.0 or OpenID Connect capabilities. To manage ORY Hydra, you will need an OAuth 2.0 Client as well. Make sure that this endpoint is well protected and only callable by first-party components.
* @param id The id of the OAuth 2.0 Client. (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call deleteOAuth2ClientAsync(String id, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = deleteOAuth2ClientValidateBeforeCall(id, _callback);
localVarApiClient.executeAsync(localVarCall, _callback);
return localVarCall;
}
/**
* Build call for flushInactiveOAuth2Tokens
* @param body (optional)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
500
genericError
-
*/
public okhttp3.Call flushInactiveOAuth2TokensCall(FlushInactiveOAuth2TokensRequest body, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/oauth2/flush";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call flushInactiveOAuth2TokensValidateBeforeCall(FlushInactiveOAuth2TokensRequest body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = flushInactiveOAuth2TokensCall(body, _callback);
return localVarCall;
}
/**
* Flush Expired OAuth2 Access Tokens
* This endpoint flushes expired OAuth2 access tokens from the database. You can set a time after which no tokens will be not be touched, in case you want to keep recent tokens for auditing. Refresh tokens can not be flushed as they are deleted automatically when performing the refresh flow.
* @param body (optional)
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
500
genericError
-
*/
public void flushInactiveOAuth2Tokens(FlushInactiveOAuth2TokensRequest body) throws ApiException {
flushInactiveOAuth2TokensWithHttpInfo(body);
}
/**
* Flush Expired OAuth2 Access Tokens
* This endpoint flushes expired OAuth2 access tokens from the database. You can set a time after which no tokens will be not be touched, in case you want to keep recent tokens for auditing. Refresh tokens can not be flushed as they are deleted automatically when performing the refresh flow.
* @param body (optional)
* @return ApiResponse<Void>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
500
genericError
-
*/
public ApiResponse flushInactiveOAuth2TokensWithHttpInfo(FlushInactiveOAuth2TokensRequest body) throws ApiException {
okhttp3.Call localVarCall = flushInactiveOAuth2TokensValidateBeforeCall(body, null);
return localVarApiClient.execute(localVarCall);
}
/**
* Flush Expired OAuth2 Access Tokens (asynchronously)
* This endpoint flushes expired OAuth2 access tokens from the database. You can set a time after which no tokens will be not be touched, in case you want to keep recent tokens for auditing. Refresh tokens can not be flushed as they are deleted automatically when performing the refresh flow.
* @param body (optional)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
204
Empty responses are sent when, for example, resources are deleted. The HTTP status code for empty responses is typically 201.
-
401
genericError
-
500
genericError
-
*/
public okhttp3.Call flushInactiveOAuth2TokensAsync(FlushInactiveOAuth2TokensRequest body, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = flushInactiveOAuth2TokensValidateBeforeCall(body, _callback);
localVarApiClient.executeAsync(localVarCall, _callback);
return localVarCall;
}
/**
* Build call for getConsentRequest
* @param consentChallenge (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
consentRequest
-
404
genericError
-
409
genericError
-
500
genericError
-
*/
public okhttp3.Call getConsentRequestCall(String consentChallenge, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/oauth2/auth/requests/consent";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
if (consentChallenge != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("consent_challenge", consentChallenge));
}
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call getConsentRequestValidateBeforeCall(String consentChallenge, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'consentChallenge' is set
if (consentChallenge == null) {
throw new ApiException("Missing the required parameter 'consentChallenge' when calling getConsentRequest(Async)");
}
okhttp3.Call localVarCall = getConsentRequestCall(consentChallenge, _callback);
return localVarCall;
}
/**
* Get consent request information
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider to authenticate the subject and then tell ORY Hydra now about it. If the subject authenticated, he/she must now be asked if the OAuth 2.0 Client which initiated the flow should be allowed to access the resources on the subject's behalf. The consent provider which handles this request and is a web app implemented and hosted by you. It shows a subject interface which asks the subject to grant or deny the client access to the requested scope (\"Application my-dropbox-app wants write access to all your private files\"). The consent challenge is appended to the consent provider's URL to which the subject's user-agent (browser) is redirected to. The consent provider uses that challenge to fetch information on the OAuth2 request and then tells ORY Hydra if the subject accepted or rejected the request.
* @param consentChallenge (required)
* @return ConsentRequest
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
consentRequest
-
404
genericError
-
409
genericError
-
500
genericError
-
*/
public ConsentRequest getConsentRequest(String consentChallenge) throws ApiException {
ApiResponse localVarResp = getConsentRequestWithHttpInfo(consentChallenge);
return localVarResp.getData();
}
/**
* Get consent request information
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider to authenticate the subject and then tell ORY Hydra now about it. If the subject authenticated, he/she must now be asked if the OAuth 2.0 Client which initiated the flow should be allowed to access the resources on the subject's behalf. The consent provider which handles this request and is a web app implemented and hosted by you. It shows a subject interface which asks the subject to grant or deny the client access to the requested scope (\"Application my-dropbox-app wants write access to all your private files\"). The consent challenge is appended to the consent provider's URL to which the subject's user-agent (browser) is redirected to. The consent provider uses that challenge to fetch information on the OAuth2 request and then tells ORY Hydra if the subject accepted or rejected the request.
* @param consentChallenge (required)
* @return ApiResponse<ConsentRequest>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
consentRequest
-
404
genericError
-
409
genericError
-
500
genericError
-
*/
public ApiResponse getConsentRequestWithHttpInfo(String consentChallenge) throws ApiException {
okhttp3.Call localVarCall = getConsentRequestValidateBeforeCall(consentChallenge, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Get consent request information (asynchronously)
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider to authenticate the subject and then tell ORY Hydra now about it. If the subject authenticated, he/she must now be asked if the OAuth 2.0 Client which initiated the flow should be allowed to access the resources on the subject's behalf. The consent provider which handles this request and is a web app implemented and hosted by you. It shows a subject interface which asks the subject to grant or deny the client access to the requested scope (\"Application my-dropbox-app wants write access to all your private files\"). The consent challenge is appended to the consent provider's URL to which the subject's user-agent (browser) is redirected to. The consent provider uses that challenge to fetch information on the OAuth2 request and then tells ORY Hydra if the subject accepted or rejected the request.
* @param consentChallenge (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
consentRequest
-
404
genericError
-
409
genericError
-
500
genericError
-
*/
public okhttp3.Call getConsentRequestAsync(String consentChallenge, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getConsentRequestValidateBeforeCall(consentChallenge, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for getJsonWebKey
* @param kid The kid of the desired key (required)
* @param set The set (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
JSONWebKeySet
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call getJsonWebKeyCall(String kid, String set, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/keys/{set}/{kid}"
.replaceAll("\\{" + "kid" + "\\}", localVarApiClient.escapeString(kid.toString()))
.replaceAll("\\{" + "set" + "\\}", localVarApiClient.escapeString(set.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call getJsonWebKeyValidateBeforeCall(String kid, String set, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'kid' is set
if (kid == null) {
throw new ApiException("Missing the required parameter 'kid' when calling getJsonWebKey(Async)");
}
// verify the required parameter 'set' is set
if (set == null) {
throw new ApiException("Missing the required parameter 'set' when calling getJsonWebKey(Async)");
}
okhttp3.Call localVarCall = getJsonWebKeyCall(kid, set, _callback);
return localVarCall;
}
/**
* Fetch a JSON Web Key
* This endpoint returns a singular JSON Web Key, identified by the set and the specific key ID (kid).
* @param kid The kid of the desired key (required)
* @param set The set (required)
* @return JSONWebKeySet
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
JSONWebKeySet
-
404
genericError
-
500
genericError
-
*/
public JSONWebKeySet getJsonWebKey(String kid, String set) throws ApiException {
ApiResponse localVarResp = getJsonWebKeyWithHttpInfo(kid, set);
return localVarResp.getData();
}
/**
* Fetch a JSON Web Key
* This endpoint returns a singular JSON Web Key, identified by the set and the specific key ID (kid).
* @param kid The kid of the desired key (required)
* @param set The set (required)
* @return ApiResponse<JSONWebKeySet>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
JSONWebKeySet
-
404
genericError
-
500
genericError
-
*/
public ApiResponse getJsonWebKeyWithHttpInfo(String kid, String set) throws ApiException {
okhttp3.Call localVarCall = getJsonWebKeyValidateBeforeCall(kid, set, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Fetch a JSON Web Key (asynchronously)
* This endpoint returns a singular JSON Web Key, identified by the set and the specific key ID (kid).
* @param kid The kid of the desired key (required)
* @param set The set (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
JSONWebKeySet
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call getJsonWebKeyAsync(String kid, String set, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getJsonWebKeyValidateBeforeCall(kid, set, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for getJsonWebKeySet
* @param set The set (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
JSONWebKeySet
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public okhttp3.Call getJsonWebKeySetCall(String set, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/keys/{set}"
.replaceAll("\\{" + "set" + "\\}", localVarApiClient.escapeString(set.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call getJsonWebKeySetValidateBeforeCall(String set, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'set' is set
if (set == null) {
throw new ApiException("Missing the required parameter 'set' when calling getJsonWebKeySet(Async)");
}
okhttp3.Call localVarCall = getJsonWebKeySetCall(set, _callback);
return localVarCall;
}
/**
* Retrieve a JSON Web Key Set
* This endpoint can be used to retrieve JWK Sets stored in ORY Hydra. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param set The set (required)
* @return JSONWebKeySet
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
JSONWebKeySet
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public JSONWebKeySet getJsonWebKeySet(String set) throws ApiException {
ApiResponse localVarResp = getJsonWebKeySetWithHttpInfo(set);
return localVarResp.getData();
}
/**
* Retrieve a JSON Web Key Set
* This endpoint can be used to retrieve JWK Sets stored in ORY Hydra. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param set The set (required)
* @return ApiResponse<JSONWebKeySet>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
JSONWebKeySet
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public ApiResponse getJsonWebKeySetWithHttpInfo(String set) throws ApiException {
okhttp3.Call localVarCall = getJsonWebKeySetValidateBeforeCall(set, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Retrieve a JSON Web Key Set (asynchronously)
* This endpoint can be used to retrieve JWK Sets stored in ORY Hydra. A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key. A JWK Set is a JSON data structure that represents a set of JWKs. A JSON Web Key is identified by its set and key id. ORY Hydra uses this functionality to store cryptographic keys used for TLS and JSON Web Tokens (such as OpenID Connect ID tokens), and allows storing user-defined keys as well.
* @param set The set (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
JSONWebKeySet
-
401
genericError
-
403
genericError
-
500
genericError
-
*/
public okhttp3.Call getJsonWebKeySetAsync(String set, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getJsonWebKeySetValidateBeforeCall(set, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for getLoginRequest
* @param loginChallenge (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
loginRequest
-
400
genericError
-
404
genericError
-
409
genericError
-
500
genericError
-
*/
public okhttp3.Call getLoginRequestCall(String loginChallenge, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/oauth2/auth/requests/login";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
if (loginChallenge != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("login_challenge", loginChallenge));
}
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call getLoginRequestValidateBeforeCall(String loginChallenge, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'loginChallenge' is set
if (loginChallenge == null) {
throw new ApiException("Missing the required parameter 'loginChallenge' when calling getLoginRequest(Async)");
}
okhttp3.Call localVarCall = getLoginRequestCall(loginChallenge, _callback);
return localVarCall;
}
/**
* Get a login request
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider (sometimes called \"identity provider\") to authenticate the subject and then tell ORY Hydra now about it. The login provider is an web-app you write and host, and it must be able to authenticate (\"show the subject a login screen\") a subject (in OAuth2 the proper name for subject is \"resource owner\"). The authentication challenge is appended to the login provider URL to which the subject's user-agent (browser) is redirected to. The login provider uses that challenge to fetch information on the OAuth2 request and then accept or reject the requested authentication process.
* @param loginChallenge (required)
* @return LoginRequest
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
loginRequest
-
400
genericError
-
404
genericError
-
409
genericError
-
500
genericError
-
*/
public LoginRequest getLoginRequest(String loginChallenge) throws ApiException {
ApiResponse localVarResp = getLoginRequestWithHttpInfo(loginChallenge);
return localVarResp.getData();
}
/**
* Get a login request
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider (sometimes called \"identity provider\") to authenticate the subject and then tell ORY Hydra now about it. The login provider is an web-app you write and host, and it must be able to authenticate (\"show the subject a login screen\") a subject (in OAuth2 the proper name for subject is \"resource owner\"). The authentication challenge is appended to the login provider URL to which the subject's user-agent (browser) is redirected to. The login provider uses that challenge to fetch information on the OAuth2 request and then accept or reject the requested authentication process.
* @param loginChallenge (required)
* @return ApiResponse<LoginRequest>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
loginRequest
-
400
genericError
-
404
genericError
-
409
genericError
-
500
genericError
-
*/
public ApiResponse getLoginRequestWithHttpInfo(String loginChallenge) throws ApiException {
okhttp3.Call localVarCall = getLoginRequestValidateBeforeCall(loginChallenge, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Get a login request (asynchronously)
* When an authorization code, hybrid, or implicit OAuth 2.0 Flow is initiated, ORY Hydra asks the login provider (sometimes called \"identity provider\") to authenticate the subject and then tell ORY Hydra now about it. The login provider is an web-app you write and host, and it must be able to authenticate (\"show the subject a login screen\") a subject (in OAuth2 the proper name for subject is \"resource owner\"). The authentication challenge is appended to the login provider URL to which the subject's user-agent (browser) is redirected to. The login provider uses that challenge to fetch information on the OAuth2 request and then accept or reject the requested authentication process.
* @param loginChallenge (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
loginRequest
-
400
genericError
-
404
genericError
-
409
genericError
-
500
genericError
-
*/
public okhttp3.Call getLoginRequestAsync(String loginChallenge, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getLoginRequestValidateBeforeCall(loginChallenge, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for getLogoutRequest
* @param logoutChallenge (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
logoutRequest
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call getLogoutRequestCall(String logoutChallenge, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/oauth2/auth/requests/logout";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
if (logoutChallenge != null) {
localVarQueryParams.addAll(localVarApiClient.parameterToPair("logout_challenge", logoutChallenge));
}
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call getLogoutRequestValidateBeforeCall(String logoutChallenge, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'logoutChallenge' is set
if (logoutChallenge == null) {
throw new ApiException("Missing the required parameter 'logoutChallenge' when calling getLogoutRequest(Async)");
}
okhttp3.Call localVarCall = getLogoutRequestCall(logoutChallenge, _callback);
return localVarCall;
}
/**
* Get a logout request
* Use this endpoint to fetch a logout request.
* @param logoutChallenge (required)
* @return LogoutRequest
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
logoutRequest
-
404
genericError
-
500
genericError
-
*/
public LogoutRequest getLogoutRequest(String logoutChallenge) throws ApiException {
ApiResponse localVarResp = getLogoutRequestWithHttpInfo(logoutChallenge);
return localVarResp.getData();
}
/**
* Get a logout request
* Use this endpoint to fetch a logout request.
* @param logoutChallenge (required)
* @return ApiResponse<LogoutRequest>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
logoutRequest
-
404
genericError
-
500
genericError
-
*/
public ApiResponse getLogoutRequestWithHttpInfo(String logoutChallenge) throws ApiException {
okhttp3.Call localVarCall = getLogoutRequestValidateBeforeCall(logoutChallenge, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Get a logout request (asynchronously)
* Use this endpoint to fetch a logout request.
* @param logoutChallenge (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
logoutRequest
-
404
genericError
-
500
genericError
-
*/
public okhttp3.Call getLogoutRequestAsync(String logoutChallenge, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getLogoutRequestValidateBeforeCall(logoutChallenge, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for getOAuth2Client
* @param id The id of the OAuth 2.0 Client. (required)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
oAuth2Client
-
401
genericError
-
500
genericError
-
*/
public okhttp3.Call getOAuth2ClientCall(String id, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/clients/{id}"
.replaceAll("\\{" + "id" + "\\}", localVarApiClient.escapeString(id.toString()));
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call getOAuth2ClientValidateBeforeCall(String id, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'id' is set
if (id == null) {
throw new ApiException("Missing the required parameter 'id' when calling getOAuth2Client(Async)");
}
okhttp3.Call localVarCall = getOAuth2ClientCall(id, _callback);
return localVarCall;
}
/**
* Get an OAuth 2.0 Client.
* Get an OAUth 2.0 client by its ID. This endpoint never returns passwords. OAuth 2.0 clients are used to perform OAuth 2.0 and OpenID Connect flows. Usually, OAuth 2.0 clients are generated for applications which want to consume your OAuth 2.0 or OpenID Connect capabilities. To manage ORY Hydra, you will need an OAuth 2.0 Client as well. Make sure that this endpoint is well protected and only callable by first-party components.
* @param id The id of the OAuth 2.0 Client. (required)
* @return OAuth2Client
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
oAuth2Client
-
401
genericError
-
500
genericError
-
*/
public OAuth2Client getOAuth2Client(String id) throws ApiException {
ApiResponse localVarResp = getOAuth2ClientWithHttpInfo(id);
return localVarResp.getData();
}
/**
* Get an OAuth 2.0 Client.
* Get an OAUth 2.0 client by its ID. This endpoint never returns passwords. OAuth 2.0 clients are used to perform OAuth 2.0 and OpenID Connect flows. Usually, OAuth 2.0 clients are generated for applications which want to consume your OAuth 2.0 or OpenID Connect capabilities. To manage ORY Hydra, you will need an OAuth 2.0 Client as well. Make sure that this endpoint is well protected and only callable by first-party components.
* @param id The id of the OAuth 2.0 Client. (required)
* @return ApiResponse<OAuth2Client>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
oAuth2Client
-
401
genericError
-
500
genericError
-
*/
public ApiResponse getOAuth2ClientWithHttpInfo(String id) throws ApiException {
okhttp3.Call localVarCall = getOAuth2ClientValidateBeforeCall(id, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Get an OAuth 2.0 Client. (asynchronously)
* Get an OAUth 2.0 client by its ID. This endpoint never returns passwords. OAuth 2.0 clients are used to perform OAuth 2.0 and OpenID Connect flows. Usually, OAuth 2.0 clients are generated for applications which want to consume your OAuth 2.0 or OpenID Connect capabilities. To manage ORY Hydra, you will need an OAuth 2.0 Client as well. Make sure that this endpoint is well protected and only callable by first-party components.
* @param id The id of the OAuth 2.0 Client. (required)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
oAuth2Client
-
401
genericError
-
500
genericError
-
*/
public okhttp3.Call getOAuth2ClientAsync(String id, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getOAuth2ClientValidateBeforeCall(id, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for getVersion
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
version
-
*/
public okhttp3.Call getVersionCall(final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/version";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { };
return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call getVersionValidateBeforeCall(final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getVersionCall(_callback);
return localVarCall;
}
/**
* Get service version
* This endpoint returns the service version typically notated using semantic versioning. If the service supports TLS Edge Termination, this endpoint does not require the `X-Forwarded-Proto` header to be set.
* @return Version
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
version
-
*/
public Version getVersion() throws ApiException {
ApiResponse localVarResp = getVersionWithHttpInfo();
return localVarResp.getData();
}
/**
* Get service version
* This endpoint returns the service version typically notated using semantic versioning. If the service supports TLS Edge Termination, this endpoint does not require the `X-Forwarded-Proto` header to be set.
* @return ApiResponse<Version>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
version
-
*/
public ApiResponse getVersionWithHttpInfo() throws ApiException {
okhttp3.Call localVarCall = getVersionValidateBeforeCall(null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Get service version (asynchronously)
* This endpoint returns the service version typically notated using semantic versioning. If the service supports TLS Edge Termination, this endpoint does not require the `X-Forwarded-Proto` header to be set.
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
version
-
*/
public okhttp3.Call getVersionAsync(final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = getVersionValidateBeforeCall(_callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for introspectOAuth2Token
* @param token The string value of the token. For access tokens, this is the \\\"access_token\\\" value returned from the token endpoint defined in OAuth 2.0. For refresh tokens, this is the \\\"refresh_token\\\" value returned. (required)
* @param scope An optional, space separated list of required scopes. If the access token was not granted one of the scopes, the result of active will be false. (optional)
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
oAuth2TokenIntrospection
-
401
genericError
-
500
genericError
-
*/
public okhttp3.Call introspectOAuth2TokenCall(String token, String scope, final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/oauth2/introspect";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map localVarFormParams = new HashMap();
if (token != null) {
localVarFormParams.put("token", token);
}
if (scope != null) {
localVarFormParams.put("scope", scope);
}
final String[] localVarAccepts = {
"application/json"
};
final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) {
localVarHeaderParams.put("Accept", localVarAccept);
}
final String[] localVarContentTypes = {
"application/x-www-form-urlencoded"
};
final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
String[] localVarAuthNames = new String[] { "basic", "oauth2" };
return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback);
}
@SuppressWarnings("rawtypes")
private okhttp3.Call introspectOAuth2TokenValidateBeforeCall(String token, String scope, final ApiCallback _callback) throws ApiException {
// verify the required parameter 'token' is set
if (token == null) {
throw new ApiException("Missing the required parameter 'token' when calling introspectOAuth2Token(Async)");
}
okhttp3.Call localVarCall = introspectOAuth2TokenCall(token, scope, _callback);
return localVarCall;
}
/**
* Introspect OAuth2 tokens
* The introspection endpoint allows to check if a token (both refresh and access) is active or not. An active token is neither expired nor revoked. If a token is active, additional information on the token will be included. You can set additional data for a token by setting `accessTokenExtra` during the consent flow. For more information [read this blog post](https://www.oauth.com/oauth2-servers/token-introspection-endpoint/).
* @param token The string value of the token. For access tokens, this is the \\\"access_token\\\" value returned from the token endpoint defined in OAuth 2.0. For refresh tokens, this is the \\\"refresh_token\\\" value returned. (required)
* @param scope An optional, space separated list of required scopes. If the access token was not granted one of the scopes, the result of active will be false. (optional)
* @return OAuth2TokenIntrospection
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
oAuth2TokenIntrospection
-
401
genericError
-
500
genericError
-
*/
public OAuth2TokenIntrospection introspectOAuth2Token(String token, String scope) throws ApiException {
ApiResponse localVarResp = introspectOAuth2TokenWithHttpInfo(token, scope);
return localVarResp.getData();
}
/**
* Introspect OAuth2 tokens
* The introspection endpoint allows to check if a token (both refresh and access) is active or not. An active token is neither expired nor revoked. If a token is active, additional information on the token will be included. You can set additional data for a token by setting `accessTokenExtra` during the consent flow. For more information [read this blog post](https://www.oauth.com/oauth2-servers/token-introspection-endpoint/).
* @param token The string value of the token. For access tokens, this is the \\\"access_token\\\" value returned from the token endpoint defined in OAuth 2.0. For refresh tokens, this is the \\\"refresh_token\\\" value returned. (required)
* @param scope An optional, space separated list of required scopes. If the access token was not granted one of the scopes, the result of active will be false. (optional)
* @return ApiResponse<OAuth2TokenIntrospection>
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @http.response.details
Status Code
Description
Response Headers
200
oAuth2TokenIntrospection
-
401
genericError
-
500
genericError
-
*/
public ApiResponse introspectOAuth2TokenWithHttpInfo(String token, String scope) throws ApiException {
okhttp3.Call localVarCall = introspectOAuth2TokenValidateBeforeCall(token, scope, null);
Type localVarReturnType = new TypeToken(){}.getType();
return localVarApiClient.execute(localVarCall, localVarReturnType);
}
/**
* Introspect OAuth2 tokens (asynchronously)
* The introspection endpoint allows to check if a token (both refresh and access) is active or not. An active token is neither expired nor revoked. If a token is active, additional information on the token will be included. You can set additional data for a token by setting `accessTokenExtra` during the consent flow. For more information [read this blog post](https://www.oauth.com/oauth2-servers/token-introspection-endpoint/).
* @param token The string value of the token. For access tokens, this is the \\\"access_token\\\" value returned from the token endpoint defined in OAuth 2.0. For refresh tokens, this is the \\\"refresh_token\\\" value returned. (required)
* @param scope An optional, space separated list of required scopes. If the access token was not granted one of the scopes, the result of active will be false. (optional)
* @param _callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @http.response.details
Status Code
Description
Response Headers
200
oAuth2TokenIntrospection
-
401
genericError
-
500
genericError
-
*/
public okhttp3.Call introspectOAuth2TokenAsync(String token, String scope, final ApiCallback _callback) throws ApiException {
okhttp3.Call localVarCall = introspectOAuth2TokenValidateBeforeCall(token, scope, _callback);
Type localVarReturnType = new TypeToken(){}.getType();
localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback);
return localVarCall;
}
/**
* Build call for isInstanceAlive
* @param _callback Callback for upload/download progress
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @http.response.details
Status Code
Description
Response Headers
200
healthStatus
-
500
genericError
-
*/
public okhttp3.Call isInstanceAliveCall(final ApiCallback _callback) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/health/alive";
List localVarQueryParams = new ArrayList();
List localVarCollectionQueryParams = new ArrayList();
Map localVarHeaderParams = new HashMap();
Map localVarCookieParams = new HashMap();
Map