Class UserSessionsApi

java.lang.Object
com.okta.sdk.resource.api.UserSessionsApi

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", date="2024-09-23T16:19:57.008753975Z[Etc/UTC]", comments="Generator version: 7.8.0") public class UserSessionsApi extends Object
  • Constructor Details Link icon

    • UserSessionsApi Link icon

      public UserSessionsApi()
    • UserSessionsApi Link icon

      public UserSessionsApi(ApiClient apiClient)
  • Method Details Link icon

    • getApiClient Link icon

      public ApiClient getApiClient()
    • setApiClient Link icon

      public void setApiClient(ApiClient apiClient)
    • endUserSessions Link icon

      public void endUserSessions(KeepCurrent keepCurrent) throws ApiException
      End a current User session Ends Okta sessions for the currently signed in User. By default, the current session remains active. Use this method in a browser-based app. > **Note:** This operation requires a session cookie for the User. The API token isn't allowed for this operation.
      Parameters:
      keepCurrent - (optional)
      Throws:
      ApiException - if fails to make API call
    • endUserSessions Link icon

      public void endUserSessions(KeepCurrent keepCurrent, Map<String,String> additionalHeaders) throws ApiException
      End a current User session Ends Okta sessions for the currently signed in User. By default, the current session remains active. Use this method in a browser-based app. > **Note:** This operation requires a session cookie for the User. The API token isn't allowed for this operation.
      Parameters:
      keepCurrent - (optional)
      additionalHeaders - additionalHeaders for this call
      Throws:
      ApiException - if fails to make API call
    • revokeUserSessions Link icon

      public void revokeUserSessions(String userId, Boolean oauthTokens) throws ApiException
      Revoke all User sessions Revokes all active Identity Provider sessions of the User. This forces the user to authenticate on the next operation. Optionally revokes OpenID Connect and OAuth refresh and access tokens issued to the User. > **Note:** This operation doesn't clear the sessions created for web or native apps.
      Parameters:
      userId - ID of an existing Okta user (required)
      oauthTokens - Revoke issued OpenID Connect and OAuth refresh and access tokens (optional, default to false)
      Throws:
      ApiException - if fails to make API call
    • revokeUserSessions Link icon

      public void revokeUserSessions(String userId, Boolean oauthTokens, Map<String,String> additionalHeaders) throws ApiException
      Revoke all User sessions Revokes all active Identity Provider sessions of the User. This forces the user to authenticate on the next operation. Optionally revokes OpenID Connect and OAuth refresh and access tokens issued to the User. > **Note:** This operation doesn't clear the sessions created for web or native apps.
      Parameters:
      userId - ID of an existing Okta user (required)
      oauthTokens - Revoke issued OpenID Connect and OAuth refresh and access tokens (optional, default to false)
      additionalHeaders - additionalHeaders for this call
      Throws:
      ApiException - if fails to make API call
    • getObjectMapper Link icon

      protected static com.fasterxml.jackson.databind.ObjectMapper getObjectMapper()