Refresh Salesforce OAuth Tokens in Riva On-Premise

Evan Keefe
Evan Keefe
  • Updated

Summary

If the Salesforce OAuth access or refresh token expires, is revoked, or fails with an [invalid_grant] error, synchronization stops. To restore connectivity, you must re-authenticate and refresh the OAuth tokens for your Salesforce CRM connection in Riva Manager.


Prerequisites

  • Ensure that you run the application with administrator privileges to avoid permission issues when saving connection changes. Right-click Riva.exe and select Run as administrator.

  • Log out of any active personal Salesforce browser sessions on the server to prevent accidentally authenticating with the wrong account.
  • Ensure you have access to the credentials and Multi-Factor Authentication (MFA) verification method for your dedicated Riva service/admin account.

Step 1: Open the Salesforce Connection in Riva Manager

  1. In the Riva Manager window, locate the Salesforce CRM section in the right pane.
  2. Double-click your existing Salesforce OAuth connection (e.g., EKE-SF OAuth Connection A).

 


Step 2: Refresh the OAuth Tokens

  1. In the CRM Connection Edit window, select the OAuth Options tab in the left-hand navigation menu.
  2. Verify that the Consumer Key, Consumer Secret, and Callback URL are populated.
  3. Click the Refresh OAuth Tokens button.

  1. In the OAuth Connection - User Authentication login pop-up, enter the username and password for the dedicated Riva connection user, then click Log In.

  1. MFA Verification: If Multi-Factor Authentication (MFA) or identity verification is enabled on the Salesforce account, a Verify Your Identity prompt will appear. Enter the verification code sent to the account or approve the prompt on your authenticator, then click Verify.

  1. If prompted, select Allow to grant Riva access to the Salesforce organization.
  2. Once authenticated, a Success! dialog will appear confirming:
    "OAuth tokens are refreshed. Click on Save to continue with new tokens."
    Click OK.

  1. In the bottom-right corner of the CRM Connection Edit window, click Save to apply the updated tokens.

Step 3: Test the Connection

  1. In the CRM Connection Edit window, select the Connection Test tab.
  2. Leave the Account field blank and click Run Test >> to confirm the connection to Salesforce succeeds.
  3. Once the Test succeeded prompt appears, click OK.
  4. (Optional) Enter the username of a synced user into the Account field and click Run Test >> to verify user impersonation.

Related to