Docusign Token Expiration after one hour

Hi Everyone,

We just lauched into production a process that creates Envelopes using Docusign activities 1.3.1 in UiPath.

Using AuthType OAuthJWT, everything work like a charm… BUT after one hour, the calls fails with “USER_AUTHENTICATION_FAILED”

My credentials and config are fine, it’s the TOKEN that expire with default value of 1h.

I can’t find any documentation on how to recreate a new one in UiPath !
There is no activities nor properties to help me out with that.

Current solution is to shut down the whole processing session, then launch a new job.
As the reboot of the system exception through ReFramework doesnt work.

Does anyone already face the same issue ?

Hi!

If the token expires how do you update it?
How does shutting down and launching a new job do that?

For now I’m not actively managing the TOKEN.
Everything was implicit in the process.

I have no idea why shutting down (vs Reboot in ReFramework) solve the issue.

My parameters for the DocusignActivities are:

One JSON file as ConfigFile for the Docusign Application Scope, connecting AuthType : OAuthJWT
{
“typ”: “JWT”,
“alg”: “RS256”,
“iss”: “xxxxxxxxxxxxx”,
“sub”: “xxxxxxxxxxxxx”,
“aud”: “account.docusign.com”,
“scope”: “impersonation signature”,
“privatekey”: "xxxxxxxxxxxxx
}

It always connect successfuly to this scope
Then it crash coming to the CreateEnvelope activity that is using one more parameter : Account ID (the API Guid)

Ok!

Could you screenshot me how you’ve built the process?

To me it sounds like you’re creating envelopes insde of the scope like this:

This means you’re using a single connection and not renewing your token

Activities - DocuSign Scope (uipath.com)

If you want the token to “last longer” I guess you have to do something on the docusign side of things.
Activities - Setup (uipath.com)

OR you could have the loop outside of the scope, this will ensure a fresh connection for each envelope:


From docusign, a token lasts for 1 hour

Thanks for those explanations !

My process is not setup like this, it’s based on Re-Framework
Each iteration is asking for ONE unique Docusign_Scope

GetTransacationData > Pick QueueItem > ProcessTransaction > DocuSign_Scope > Create_Envelope > …

Therefore the connexion should be renewed at each iteration right ?

Process part is the only part using the DocuSign activity
And I’m not using any “existing connection” property


Just to be sure, could you take a screenshot of the properties while the scope is highlighted?

Sure thing !

CREATE

SCOPE

Everything looks to be as it should.

I don’t really have any further suggestions, you should probably raise a support ticket with UiPath and have them look at it.
Get Help from UiPath Support Services | UiPath

Just to experiment, could you create a variable for the connection, add an assign before your scope and set the variable to nothing?
image

sigh

Thanks for the time and effort you’ve put into my issue !

I’ll write to UiPath and DocuSign to investigate more.
We’re losing so much processing time having to stop/launch the process every hour :confused:

I’ve added your experiment connection.nothing to our production environement.
Results in one hour to see if that’s a fix !

You could use your triggers to stop/start processes to fit your time-window.
image

You’re using a queue trigger right? Then the process will continue to start again as long as there are queue items in your queue.

That’s my current solution yes.
No QueueTrigger, just one batch of 8000 items, so my Trigger is set to be launched avery hour, and stop every 55min (just to be sure)

I’m still investigating how to manage the Token as the process would be cleaner, and we’d save some time for the processing.