Solved

Envelopes GetDocument responds USER_AUTHENTICATION_FAILED

  • 15 May 2024
  • 2 replies
  • 115 views

I’m using the SDK C# and when sending a request Envelopes::GetDocument (link) to get the documents, this fails with error:

"errorCode":"USER_AUTHENTICATION_FAILED","message":"One or both of Username and Password are invalid. Invalid access token"

 

All other API calls before calling GetDocument are passing OK - for example when calling Envelopes::listDocument (before the GetDocument) to get the list of documents, that returns succesfully. But then with same starting point GetDocument fails.

We do checks for token validity etc. before calling these methods and only GetDocument respons with error. What could be the cause and what should we consider?

icon

Best answer by JohnSantos 16 May 2024, 00:12

View Original

2 replies

Userlevel 5
Badge +12

@TiinaK  - The error "USER_AUTHENTICATION_FAILED" with the message "One or both of Username and Password are invalid. Invalid access token" usually indicates an issue with how authentication credentials are handled or passed in the API request, specifically for the GetDocument method. 

Verify if the token being used for GetDocument has the appropriate permissions or scope required. Sometimes, different API methods require tokens with different scopes or permissions.

Even though other API calls are working, there might be a case where the token needs to be refreshed before calling GetDocument. Tokens can have varying lifetimes and might be expiring right before this call.

I hope these tips help to troubleshoot your issue.

Thank you very much! It indeed was an expired token - the check was done in the beginning of the processing, but for this particular case the expiration had happened in the middle of it.

Reply