Class UserFactorApi

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

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

    • UserFactorApi

      public UserFactorApi()
    • UserFactorApi

      public UserFactorApi(ApiClient apiClient)
  • Method Details

    • getApiClient

      public ApiClient getApiClient()
    • setApiClient

      public void setApiClient(ApiClient apiClient)
    • activateFactor

      public UserFactorActivateResponse activateFactor(String userId, String factorId, UserFactorActivateRequest body) throws ApiException
      Activate a Factor Activates a Factor. Some Factors (`call`, `email`, `push`, `sms`, `token:software:totp`, `u2f`, and `webauthn`) require activation to complete the enrollment process. Okta enforces a rate limit of five activation attempts within five minutes. After a user exceeds the rate limit, Okta returns an error message. > **Note**: If the user exceeds their SMS, call, or email factor activate rate limit, then an OTP resend request (`/api/v1/users/${userId}}/factors/${factorId}/resend`) isn't allowed for the same Factor.
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      body - (optional)
      Returns:
      UserFactorActivateResponse
      Throws:
      ApiException - if fails to make API call
    • activateFactor

      public UserFactorActivateResponse activateFactor(String userId, String factorId, UserFactorActivateRequest body, Map<String,String> additionalHeaders) throws ApiException
      Activate a Factor Activates a Factor. Some Factors (`call`, `email`, `push`, `sms`, `token:software:totp`, `u2f`, and `webauthn`) require activation to complete the enrollment process. Okta enforces a rate limit of five activation attempts within five minutes. After a user exceeds the rate limit, Okta returns an error message. > **Note**: If the user exceeds their SMS, call, or email factor activate rate limit, then an OTP resend request (`/api/v1/users/${userId}}/factors/${factorId}/resend`) isn't allowed for the same Factor.
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      body - (optional)
      additionalHeaders - additionalHeaders for this call
      Returns:
      UserFactorActivateResponse
      Throws:
      ApiException - if fails to make API call
    • enrollFactor

      public UserFactor enrollFactor(String userId, UserFactor body, Boolean updatePhone, String templateId, Integer tokenLifetimeSeconds, Boolean activate, String acceptLanguage) throws ApiException
      Enroll a Factor Enrolls a supported Factor for the specified user > **Note:** All responses return the enrolled Factor with a status of either `PENDING_ACTIVATION`` or `ACTIVE`. #### Additional SMS/Call Factor information * **Rate limits**: Okta may return a `429 Too Many Requests` status code if you attempt to resend an SMS or a voice call challenge (OTP) within the same time window. The current [rate limit](https://developer.okta.com/docs/reference/rate-limits/) is one SMS/CALL challenge per phone number every 30 seconds. * **Existing phone numbers**: Okta may return a `400 Bad Request` status code if a user attempts to enroll with a different phone number when the user has an existing mobile phone or has an existing phone with voice call capability. A user can enroll only one mobile phone for `sms` and enroll only one voice call capable phone for `call` factor. #### Additional WebAuthn Factor information **Enroll WebAuthn response parameters** * For detailed information on the Webauthn standard, including an up-to-date list of supported browsers, see [webauthn.me](https://a0.to/webauthnme-okta-docs). * In the enroll API response, the `response._embedded.activation` object contains properties used to help the client to create a new WebAuthn credential for use with Okta. See the [WebAuthn spec for PublicKeyCredentialCreationOptions](https://www.w3.org/TR/webauthn/#dictionary-makecredentialoptions). #### Additional Custom TOTP Factor information **Enroll Custom TOTP Factor** * The enrollment process involves passing both the `factorProfileId` and `sharedSecret` properties for a token. * A Factor Profile represents a particular configuration of the Custom TOTP factor. It includes certain properties that match the hardware token that end users possess, such as the HMAC algorithm, passcode length, and time interval. There can be multiple Custom TOTP factor profiles per org, but users can only enroll in one Custom TOTP factor. Admins can [create Custom TOTP factor profiles](https://help.okta.com/okta_help.htm?id=ext-mfa-totp) in the Admin Console. Then, copy the `factorProfileId` from the Admin Console into the API request. * <x-lifecycle class=\"oie\"></x-lifecycle> For Custom TOTP enrollment, Okta automaticaly enrolls a user with a `token:software:totp` factor and the `push` factor if the user isn't currently enrolled with these factors.
      Parameters:
      userId - ID of an existing Okta user (required)
      body - Factor (required)
      updatePhone - If `true`, indicates that you are replacing the currently registered phone number for the specified user. This parameter is ignored if the existing phone number is used by an activated Factor. (optional, default to false)
      templateId - ID of an existing custom SMS template. See the [SMS Templates API](../Template). This parameter is only used by `sms` Factors. If the provided ID doesn't exist, the default template is used instead. (optional)
      tokenLifetimeSeconds - Defines how long the token remains valid (optional, default to 300)
      activate - If `true`, the factor is immediately activated as part of the enrollment. An activation process isn't required. Currently auto-activation is supported by `sms`, `call`, `email` and `token:hotp` (Custom TOTP) Factor. (optional, default to false)
      acceptLanguage - An ISO 639-1 two-letter language code that defines a localized message to send. This parameter is only used by `sms` Factors. If a localized message doesn't exist or the `templateId` is incorrect, the default template is used instead. (optional)
      Returns:
      UserFactor
      Throws:
      ApiException - if fails to make API call
    • enrollFactor

      public UserFactor enrollFactor(String userId, UserFactor body, Boolean updatePhone, String templateId, Integer tokenLifetimeSeconds, Boolean activate, String acceptLanguage, Map<String,String> additionalHeaders) throws ApiException
      Enroll a Factor Enrolls a supported Factor for the specified user > **Note:** All responses return the enrolled Factor with a status of either `PENDING_ACTIVATION`` or `ACTIVE`. #### Additional SMS/Call Factor information * **Rate limits**: Okta may return a `429 Too Many Requests` status code if you attempt to resend an SMS or a voice call challenge (OTP) within the same time window. The current [rate limit](https://developer.okta.com/docs/reference/rate-limits/) is one SMS/CALL challenge per phone number every 30 seconds. * **Existing phone numbers**: Okta may return a `400 Bad Request` status code if a user attempts to enroll with a different phone number when the user has an existing mobile phone or has an existing phone with voice call capability. A user can enroll only one mobile phone for `sms` and enroll only one voice call capable phone for `call` factor. #### Additional WebAuthn Factor information **Enroll WebAuthn response parameters** * For detailed information on the Webauthn standard, including an up-to-date list of supported browsers, see [webauthn.me](https://a0.to/webauthnme-okta-docs). * In the enroll API response, the `response._embedded.activation` object contains properties used to help the client to create a new WebAuthn credential for use with Okta. See the [WebAuthn spec for PublicKeyCredentialCreationOptions](https://www.w3.org/TR/webauthn/#dictionary-makecredentialoptions). #### Additional Custom TOTP Factor information **Enroll Custom TOTP Factor** * The enrollment process involves passing both the `factorProfileId` and `sharedSecret` properties for a token. * A Factor Profile represents a particular configuration of the Custom TOTP factor. It includes certain properties that match the hardware token that end users possess, such as the HMAC algorithm, passcode length, and time interval. There can be multiple Custom TOTP factor profiles per org, but users can only enroll in one Custom TOTP factor. Admins can [create Custom TOTP factor profiles](https://help.okta.com/okta_help.htm?id=ext-mfa-totp) in the Admin Console. Then, copy the `factorProfileId` from the Admin Console into the API request. * <x-lifecycle class=\"oie\"></x-lifecycle> For Custom TOTP enrollment, Okta automaticaly enrolls a user with a `token:software:totp` factor and the `push` factor if the user isn't currently enrolled with these factors.
      Parameters:
      userId - ID of an existing Okta user (required)
      body - Factor (required)
      updatePhone - If `true`, indicates that you are replacing the currently registered phone number for the specified user. This parameter is ignored if the existing phone number is used by an activated Factor. (optional, default to false)
      templateId - ID of an existing custom SMS template. See the [SMS Templates API](../Template). This parameter is only used by `sms` Factors. If the provided ID doesn't exist, the default template is used instead. (optional)
      tokenLifetimeSeconds - Defines how long the token remains valid (optional, default to 300)
      activate - If `true`, the factor is immediately activated as part of the enrollment. An activation process isn't required. Currently auto-activation is supported by `sms`, `call`, `email` and `token:hotp` (Custom TOTP) Factor. (optional, default to false)
      acceptLanguage - An ISO 639-1 two-letter language code that defines a localized message to send. This parameter is only used by `sms` Factors. If a localized message doesn't exist or the `templateId` is incorrect, the default template is used instead. (optional)
      additionalHeaders - additionalHeaders for this call
      Returns:
      UserFactor
      Throws:
      ApiException - if fails to make API call
    • getFactor

      public UserFactor getFactor(String userId, String factorId) throws ApiException
      Retrieve a Factor Retrieves an existing Factor for the specified user
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      Returns:
      UserFactor
      Throws:
      ApiException - if fails to make API call
    • getFactor

      public UserFactor getFactor(String userId, String factorId, Map<String,String> additionalHeaders) throws ApiException
      Retrieve a Factor Retrieves an existing Factor for the specified user
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      additionalHeaders - additionalHeaders for this call
      Returns:
      UserFactor
      Throws:
      ApiException - if fails to make API call
    • getFactorTransactionStatus

      public UserFactorPushTransaction getFactorTransactionStatus(String userId, String factorId, String transactionId) throws ApiException
      Retrieve a Factor transaction status Retrieves the status of a `push` Factor verification transaction
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      transactionId - ID of an existing Factor verification transaction (required)
      Returns:
      UserFactorPushTransaction
      Throws:
      ApiException - if fails to make API call
    • getFactorTransactionStatus

      public UserFactorPushTransaction getFactorTransactionStatus(String userId, String factorId, String transactionId, Map<String,String> additionalHeaders) throws ApiException
      Retrieve a Factor transaction status Retrieves the status of a `push` Factor verification transaction
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      transactionId - ID of an existing Factor verification transaction (required)
      additionalHeaders - additionalHeaders for this call
      Returns:
      UserFactorPushTransaction
      Throws:
      ApiException - if fails to make API call
    • getYubikeyOtpTokenById

      public UserFactorYubikeyOtpToken getYubikeyOtpTokenById(String tokenId) throws ApiException
      Retrieve a YubiKey OTP Token Retrieves the specified YubiKey OTP Token by `id`
      Parameters:
      tokenId - ID of a Yubikey token (required)
      Returns:
      UserFactorYubikeyOtpToken
      Throws:
      ApiException - if fails to make API call
    • getYubikeyOtpTokenById

      public UserFactorYubikeyOtpToken getYubikeyOtpTokenById(String tokenId, Map<String,String> additionalHeaders) throws ApiException
      Retrieve a YubiKey OTP Token Retrieves the specified YubiKey OTP Token by `id`
      Parameters:
      tokenId - ID of a Yubikey token (required)
      additionalHeaders - additionalHeaders for this call
      Returns:
      UserFactorYubikeyOtpToken
      Throws:
      ApiException - if fails to make API call
    • listFactors

      public List<UserFactor> listFactors(String userId) throws ApiException
      List all enrolled Factors Lists all enrolled Factors for the specified user
      Parameters:
      userId - ID of an existing Okta user (required)
      Returns:
      List<UserFactor>
      Throws:
      ApiException - if fails to make API call
    • listFactors

      public List<UserFactor> listFactors(String userId, Map<String,String> additionalHeaders) throws ApiException
      List all enrolled Factors Lists all enrolled Factors for the specified user
      Parameters:
      userId - ID of an existing Okta user (required)
      additionalHeaders - additionalHeaders for this call
      Returns:
      List<UserFactor>
      Throws:
      ApiException - if fails to make API call
    • listSupportedFactors

      public List<UserFactorSupported> listSupportedFactors(String userId) throws ApiException
      List all supported Factors Lists all the supported Factors that can be enrolled for the specified user
      Parameters:
      userId - ID of an existing Okta user (required)
      Returns:
      List<UserFactorSupported>
      Throws:
      ApiException - if fails to make API call
    • listSupportedFactors

      public List<UserFactorSupported> listSupportedFactors(String userId, Map<String,String> additionalHeaders) throws ApiException
      List all supported Factors Lists all the supported Factors that can be enrolled for the specified user
      Parameters:
      userId - ID of an existing Okta user (required)
      additionalHeaders - additionalHeaders for this call
      Returns:
      List<UserFactorSupported>
      Throws:
      ApiException - if fails to make API call
    • listSupportedSecurityQuestions

      public List<UserFactorSecurityQuestionProfile> listSupportedSecurityQuestions(String userId) throws ApiException
      List all supported Security Questions Lists all available Security Questions for the specified user
      Parameters:
      userId - ID of an existing Okta user (required)
      Returns:
      List<UserFactorSecurityQuestionProfile>
      Throws:
      ApiException - if fails to make API call
    • listSupportedSecurityQuestions

      public List<UserFactorSecurityQuestionProfile> listSupportedSecurityQuestions(String userId, Map<String,String> additionalHeaders) throws ApiException
      List all supported Security Questions Lists all available Security Questions for the specified user
      Parameters:
      userId - ID of an existing Okta user (required)
      additionalHeaders - additionalHeaders for this call
      Returns:
      List<UserFactorSecurityQuestionProfile>
      Throws:
      ApiException - if fails to make API call
    • listYubikeyOtpTokens

      public List<UserFactorYubikeyOtpToken> listYubikeyOtpTokens(String after, String expand, String filter, Boolean forDownload, Integer limit, String sortBy, String sortOrder) throws ApiException
      List all YubiKey OTP Tokens Lists all YubiKey OTP Tokens
      Parameters:
      after - Specifies the pagination cursor for the next page of tokens (optional)
      expand - Embeds the [User](/openapi/okta-management/management/tag/User/) resource if the YubiKey Token is assigned to a user and `expand` is set to `user` (optional)
      filter - The expression used to filter tokens (optional)
      forDownload - Returns tokens in a CSV to download instead of in the response. When you use this query parameter, the `limit` default changes to 1000. (optional, default to false)
      limit - Specifies the number of results per page (optional, default to 20)
      sortBy - The value of how the tokens are sorted (optional)
      sortOrder - Specifies the sort order, either `ASC` or `DESC` (optional)
      Returns:
      List<UserFactorYubikeyOtpToken>
      Throws:
      ApiException - if fails to make API call
    • listYubikeyOtpTokens

      public List<UserFactorYubikeyOtpToken> listYubikeyOtpTokens(String after, String expand, String filter, Boolean forDownload, Integer limit, String sortBy, String sortOrder, Map<String,String> additionalHeaders) throws ApiException
      List all YubiKey OTP Tokens Lists all YubiKey OTP Tokens
      Parameters:
      after - Specifies the pagination cursor for the next page of tokens (optional)
      expand - Embeds the [User](/openapi/okta-management/management/tag/User/) resource if the YubiKey Token is assigned to a user and `expand` is set to `user` (optional)
      filter - The expression used to filter tokens (optional)
      forDownload - Returns tokens in a CSV to download instead of in the response. When you use this query parameter, the `limit` default changes to 1000. (optional, default to false)
      limit - Specifies the number of results per page (optional, default to 20)
      sortBy - The value of how the tokens are sorted (optional)
      sortOrder - Specifies the sort order, either `ASC` or `DESC` (optional)
      additionalHeaders - additionalHeaders for this call
      Returns:
      List<UserFactorYubikeyOtpToken>
      Throws:
      ApiException - if fails to make API call
    • resendEnrollFactor

      public ResendUserFactor resendEnrollFactor(String userId, String factorId, ResendUserFactor resendUserFactor, String templateId) throws ApiException
      Resend a Factor enrollment Resends an `sms`, `call`, or `email` factor challenge as part of an enrollment flow For `call` and `sms` factors, Okta enforces a rate limit of one OTP challenge per device every 30 seconds. You can configure your `sms` and `call` factors to use a third-party telephony provider. See the [Telephony inline hook reference](https://developer.okta.com/docs/reference/telephony-hook/). Okta round-robins between SMS providers with every resend request to help ensure delivery of an SMS and Call OTPs across different carriers. > **Note**: Resend operations aren't allowed after a factor exceeds the activation rate limit. See [Activate a Factor](./#tag/UserFactor/operation/activateFactor).
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      resendUserFactor - (required)
      templateId - ID of an existing custom SMS template. See the [SMS Templates API](../Template). This parameter is only used by `sms` Factors. (optional)
      Returns:
      ResendUserFactor
      Throws:
      ApiException - if fails to make API call
    • resendEnrollFactor

      public ResendUserFactor resendEnrollFactor(String userId, String factorId, ResendUserFactor resendUserFactor, String templateId, Map<String,String> additionalHeaders) throws ApiException
      Resend a Factor enrollment Resends an `sms`, `call`, or `email` factor challenge as part of an enrollment flow For `call` and `sms` factors, Okta enforces a rate limit of one OTP challenge per device every 30 seconds. You can configure your `sms` and `call` factors to use a third-party telephony provider. See the [Telephony inline hook reference](https://developer.okta.com/docs/reference/telephony-hook/). Okta round-robins between SMS providers with every resend request to help ensure delivery of an SMS and Call OTPs across different carriers. > **Note**: Resend operations aren't allowed after a factor exceeds the activation rate limit. See [Activate a Factor](./#tag/UserFactor/operation/activateFactor).
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      resendUserFactor - (required)
      templateId - ID of an existing custom SMS template. See the [SMS Templates API](../Template). This parameter is only used by `sms` Factors. (optional)
      additionalHeaders - additionalHeaders for this call
      Returns:
      ResendUserFactor
      Throws:
      ApiException - if fails to make API call
    • unenrollFactor

      public void unenrollFactor(String userId, String factorId, Boolean removeRecoveryEnrollment) throws ApiException
      Unenroll a Factor Unenrolls an existing Factor for the specified user. This allows the user to enroll a new Factor. > **Note**: If you unenroll the `push` or the `signed_nonce` Factors, Okta also unenrolls any other `totp`, `signed_nonce`, or Okta Verify `push` Factors associated with the user.
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      removeRecoveryEnrollment - If `true`, removes the phone number as both a recovery method and a Factor. This parameter is only used for the `sms` and `call` Factors. (optional, default to false)
      Throws:
      ApiException - if fails to make API call
    • unenrollFactor

      public void unenrollFactor(String userId, String factorId, Boolean removeRecoveryEnrollment, Map<String,String> additionalHeaders) throws ApiException
      Unenroll a Factor Unenrolls an existing Factor for the specified user. This allows the user to enroll a new Factor. > **Note**: If you unenroll the `push` or the `signed_nonce` Factors, Okta also unenrolls any other `totp`, `signed_nonce`, or Okta Verify `push` Factors associated with the user.
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      removeRecoveryEnrollment - If `true`, removes the phone number as both a recovery method and a Factor. This parameter is only used for the `sms` and `call` Factors. (optional, default to false)
      additionalHeaders - additionalHeaders for this call
      Throws:
      ApiException - if fails to make API call
    • uploadYubikeyOtpTokenSeed

      public UserFactorYubikeyOtpToken uploadYubikeyOtpTokenSeed(UploadYubikeyOtpTokenSeedRequest uploadYubikeyOtpTokenSeedRequest, String after, String expand, String filter, Boolean forDownload, Integer limit, String sortBy, String sortOrder) throws ApiException
      Upload a YubiKey OTP Seed Uploads a seed for a user to enroll a YubiKey OTP
      Parameters:
      uploadYubikeyOtpTokenSeedRequest - (required)
      after - Specifies the pagination cursor for the next page of tokens (optional)
      expand - Embeds the [User](/openapi/okta-management/management/tag/User/) resource if the YubiKey Token is assigned to a user and `expand` is set to `user` (optional)
      filter - The expression used to filter tokens (optional)
      forDownload - Returns tokens in a CSV to download instead of in the response. When you use this query parameter, the `limit` default changes to 1000. (optional, default to false)
      limit - Specifies the number of results per page (optional, default to 20)
      sortBy - The value of how the tokens are sorted (optional)
      sortOrder - Specifies the sort order, either `ASC` or `DESC` (optional)
      Returns:
      UserFactorYubikeyOtpToken
      Throws:
      ApiException - if fails to make API call
    • uploadYubikeyOtpTokenSeed

      public UserFactorYubikeyOtpToken uploadYubikeyOtpTokenSeed(UploadYubikeyOtpTokenSeedRequest uploadYubikeyOtpTokenSeedRequest, String after, String expand, String filter, Boolean forDownload, Integer limit, String sortBy, String sortOrder, Map<String,String> additionalHeaders) throws ApiException
      Upload a YubiKey OTP Seed Uploads a seed for a user to enroll a YubiKey OTP
      Parameters:
      uploadYubikeyOtpTokenSeedRequest - (required)
      after - Specifies the pagination cursor for the next page of tokens (optional)
      expand - Embeds the [User](/openapi/okta-management/management/tag/User/) resource if the YubiKey Token is assigned to a user and `expand` is set to `user` (optional)
      filter - The expression used to filter tokens (optional)
      forDownload - Returns tokens in a CSV to download instead of in the response. When you use this query parameter, the `limit` default changes to 1000. (optional, default to false)
      limit - Specifies the number of results per page (optional, default to 20)
      sortBy - The value of how the tokens are sorted (optional)
      sortOrder - Specifies the sort order, either `ASC` or `DESC` (optional)
      additionalHeaders - additionalHeaders for this call
      Returns:
      UserFactorYubikeyOtpToken
      Throws:
      ApiException - if fails to make API call
    • verifyFactor

      public UserFactorVerifyResponse verifyFactor(String userId, String factorId, String templateId, Integer tokenLifetimeSeconds, String xForwardedFor, String userAgent, String acceptLanguage, UserFactorVerifyRequest body) throws ApiException
      Verify a Factor Verifies an OTP for a Factor. Some Factors (`call`, `email`, `push`, `sms`, `u2f`, and `webauthn`) must first issue a challenge before you can verify the Factor. Do this by making a request without a body. After a challenge is issued, make another request to verify the Factor. **Note**: To verify a `push` factor, use the **poll** link returned when you issue the challenge. See [Retrieve a Factor Transaction Status](/openapi/okta-management/management/tag/UserFactor/#tag/UserFactor/operation/getFactorTransactionStatus).
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      templateId - ID of an existing custom SMS template. See the [SMS Templates API](../Template). This parameter is only used by `sms` Factors. (optional)
      tokenLifetimeSeconds - Defines how long the token remains valid (optional, default to 300)
      xForwardedFor - Public IP address for the user agent (optional)
      userAgent - Type of user agent detected when the request is made. Required to verify `push` Factors. (optional)
      acceptLanguage - An ISO 639-1 two-letter language code that defines a localized message to send. This parameter is only used by `sms` Factors. If a localized message doesn't exist or the `templateId` is incorrect, the default template is used instead. (optional)
      body - Some Factors (`call`, `email`, `push`, `sms`, `u2f`, and `webauthn`) must first issue a challenge before you can verify the Factor. Do this by making a request without a body. After a challenge is issued, make another request to verify the Factor. (optional)
      Returns:
      UserFactorVerifyResponse
      Throws:
      ApiException - if fails to make API call
    • verifyFactor

      public UserFactorVerifyResponse verifyFactor(String userId, String factorId, String templateId, Integer tokenLifetimeSeconds, String xForwardedFor, String userAgent, String acceptLanguage, UserFactorVerifyRequest body, Map<String,String> additionalHeaders) throws ApiException
      Verify a Factor Verifies an OTP for a Factor. Some Factors (`call`, `email`, `push`, `sms`, `u2f`, and `webauthn`) must first issue a challenge before you can verify the Factor. Do this by making a request without a body. After a challenge is issued, make another request to verify the Factor. **Note**: To verify a `push` factor, use the **poll** link returned when you issue the challenge. See [Retrieve a Factor Transaction Status](/openapi/okta-management/management/tag/UserFactor/#tag/UserFactor/operation/getFactorTransactionStatus).
      Parameters:
      userId - ID of an existing Okta user (required)
      factorId - ID of an existing user Factor (required)
      templateId - ID of an existing custom SMS template. See the [SMS Templates API](../Template). This parameter is only used by `sms` Factors. (optional)
      tokenLifetimeSeconds - Defines how long the token remains valid (optional, default to 300)
      xForwardedFor - Public IP address for the user agent (optional)
      userAgent - Type of user agent detected when the request is made. Required to verify `push` Factors. (optional)
      acceptLanguage - An ISO 639-1 two-letter language code that defines a localized message to send. This parameter is only used by `sms` Factors. If a localized message doesn't exist or the `templateId` is incorrect, the default template is used instead. (optional)
      body - Some Factors (`call`, `email`, `push`, `sms`, `u2f`, and `webauthn`) must first issue a challenge before you can verify the Factor. Do this by making a request without a body. After a challenge is issued, make another request to verify the Factor. (optional)
      additionalHeaders - additionalHeaders for this call
      Returns:
      UserFactorVerifyResponse
      Throws:
      ApiException - if fails to make API call
    • getObjectMapper

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