Class JwtFetchApiKeyApiRequest
java.lang.Object
com.github.jamesnetherton.zulip.client.api.core.ZulipApiRequest
com.github.jamesnetherton.zulip.client.api.server.request.JwtFetchApiKeyApiRequest
- All Implemented Interfaces:
ExecutableApiRequest<JwtFetchApiKeyResponse>
public class JwtFetchApiKeyApiRequest
extends ZulipApiRequest
implements ExecutableApiRequest<JwtFetchApiKeyResponse>
Zulip API request builder for fetching an API key using a JWT token.
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionJwtFetchApiKeyApiRequest(ZulipHttpClient client, String token) Constructs aJwtFetchApiKeyApiRequest. -
Method Summary
Modifier and TypeMethodDescriptionexecute()Executes the Zulip API request for fetching an API key using a JWT token.withIncludeProfile(boolean includeProfile) Sets whether to include the user profile data in the response.Methods inherited from class com.github.jamesnetherton.zulip.client.api.core.ZulipApiRequest
client, getParam, getParam, getParams, putParam, putParamAsJsonString, putParamAsWrappedObject
-
Field Details
-
TOKEN
- See Also:
-
INCLUDE_PROFILE
- See Also:
-
-
Constructor Details
-
JwtFetchApiKeyApiRequest
Constructs aJwtFetchApiKeyApiRequest.- Parameters:
client- The Zulip HTTP clienttoken- The JWT token
-
-
Method Details
-
withIncludeProfile
Sets whether to include the user profile data in the response.- Parameters:
includeProfile-trueto include the user profile data in the response.falseto not include the user profile data in the response- Returns:
- This
JwtFetchApiKeyApiRequestinstance
-
execute
Executes the Zulip API request for fetching an API key using a JWT token.- Specified by:
executein interfaceExecutableApiRequest<JwtFetchApiKeyResponse>- Returns:
JwtFetchApiKeyResponsecontaining the API key, email and optionally user data- Throws:
ZulipClientException- if the request was not successful
-