All URIs are relative to http://localhost/api/v1
Method | HTTP request | Description |
---|---|---|
createToken | POST /auth/token | |
deleteToken | DELETE /auth/token | |
me | GET /auth/me |
TokenResponse createToken(credential)
Creates a new token
// Import classes:
//import io.github.triglav_dataflow.client.ApiException;
//import io.github.triglav_dataflow.client.api.AuthApi;
AuthApi apiInstance = new AuthApi();
Credential credential = new Credential(); // Credential |
try {
TokenResponse result = apiInstance.createToken(credential);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling AuthApi#createToken");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
credential | Credential |
No authorization required
- Content-Type: application/json
- Accept: application/json
deleteToken()
Deletes (Expires) a token of header
// Import classes:
//import io.github.triglav_dataflow.client.ApiClient;
//import io.github.triglav_dataflow.client.ApiException;
//import io.github.triglav_dataflow.client.Configuration;
//import io.github.triglav_dataflow.client.auth.*;
//import io.github.triglav_dataflow.client.api.AuthApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure API key authorization: api_key
ApiKeyAuth api_key = (ApiKeyAuth) defaultClient.getAuthentication("api_key");
api_key.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//api_key.setApiKeyPrefix("Token");
AuthApi apiInstance = new AuthApi();
try {
apiInstance.deleteToken();
} catch (ApiException e) {
System.err.println("Exception when calling AuthApi#deleteToken");
e.printStackTrace();
}
This endpoint does not need any parameter.
null (empty response body)
- Content-Type: application/json
- Accept: application/json
UserResponse me()
Returns a user property of the access_token
// Import classes:
//import io.github.triglav_dataflow.client.ApiClient;
//import io.github.triglav_dataflow.client.ApiException;
//import io.github.triglav_dataflow.client.Configuration;
//import io.github.triglav_dataflow.client.auth.*;
//import io.github.triglav_dataflow.client.api.AuthApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure API key authorization: api_key
ApiKeyAuth api_key = (ApiKeyAuth) defaultClient.getAuthentication("api_key");
api_key.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//api_key.setApiKeyPrefix("Token");
AuthApi apiInstance = new AuthApi();
try {
UserResponse result = apiInstance.me();
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling AuthApi#me");
e.printStackTrace();
}
This endpoint does not need any parameter.
- Content-Type: application/json
- Accept: application/json