Class UserSessionsApi

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

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", date="2024-09-23T08:35:59.300824-05:00[America/Chicago]", comments="Generator version: 7.8.0") public class UserSessionsApi extends Object
  • Constructor Details

    • UserSessionsApi

      public UserSessionsApi()
    • UserSessionsApi

      public UserSessionsApi(ApiClient apiClient)
  • Method Details

    • getApiClient

      public ApiClient getApiClient()
    • setApiClient

      public void setApiClient(ApiClient apiClient)
    • endUserSessions

      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

      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

      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

      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

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