Problem authenticating this user
Issue
You run a DocGen Package and see this message:
There was a problem authenticating this user. (AuthInvalid)
Cause
You might get this error if the user is generating documents in Lightning with a URL button that contains a sessionId
parameter.
Resolution
If the user is working in Lightning, look at the code in the button that generates documents for a sessionId
parameter and remove it. If the button is managed, you will have to create a new button. For more information, see Configure buttons to generate documents.
If the user is not using Lightning or there is no sessionId
parameter, then you should try revoking previous authorizations and re-authorizing the app. If none of these measures resolve the issue, contact support.
To remove sessionId
parameter from a URL button
- From Setup, take one of the following actions:
- If the URL button is on a standard object, type Buttons, Links in the Quick Find box, then click Buttons, Links, and Actions for the standard object.
- If the URL button is on a custom object.
- Type Objects in the Quick Find box, then click Objects for a list of custom objects in your organization.
- Click the custom object you want to work with, and then click Buttons, Links, and Actions.
- Find the button and take one of the following actions:
- If the button is managed (
), you have to create a new button. For more information, see Configure buttons to generate documents.
- If the button is not managed, click Edit.
- In the code window, remove
&sessionId={!$Api.Session_ID}
. - Click Save.
Revoke tokens for the app
- From your user account, click My Settings (Salesforce Classic) or Settings (Lightning).
- In the Quick Find box, type Advanced User Details then click Advanced User Details to display a list of settings for your profile.
- In OAuth Connected Apps, click Revoke for every Nintex DocGen for Salesforce token.
Authorize the app
Note: This procedure requires the SalesforceCustomize Application permission
- Click the Nintex Admin tab.
The Nintex Admin Home left navigation displays.
- On Nintex Admin, click Authorize Nintex DocGen for Salesforce.
Tip: If you want to authorize the app to run under a different account than the one you're currently using, log into the account you want the app to use and click the button again.