Internal Server Error 500 with ShareFile API Error 401

  • 2
  • Question
  • Updated 3 months ago
I'm currently developing Excel VBA Macro to pull data form ShareFile workflows and it's been working for few days until I bumped into this error when performing GET request.

``{"code":"InternalServerError","message":{"lang":"en-US","value":"ShareFile API Error. Unknown error (401): {\"code\"=>\"Unauthorized\", \"message\"=>{\"lang\"=>\"en-US\", \"value\"=>\"[AUTH] Invalid Authentication\"}, \"reason\"=>\"NotAuthenticated\"}"},"reason":"Unspecified"}``

I found that even ShareFile API website has this problem. Please advice on this matter. Thanks
Photo of KarKeng Chan

KarKeng Chan

  • 38 Posts
  • 0 Reply Likes

Posted 3 months ago

  • 2
Photo of Nick Nicholls

Nick Nicholls, Employee

  • 21 Posts
  • 2 Reply Likes
Hi KarKeng,

Can you share a little more info about the GET request? What endpoint are you calling?
Can you also share the 'X-SFAPI-RequestID' header that comes back with that error response? You might need fiddler to view it.

Thanks

Photo of KarKeng Chan

KarKeng Chan

  • 38 Posts
  • 0 Reply Likes
Hi, I was trying to pull the list of workflows initiated and that's where the error message came in. I don't have access to the code now but since it's now working for the API website (which did not work when I posted), I supposed it's fine.
Photo of Nick Nicholls

Nick Nicholls, Employee

  • 21 Posts
  • 2 Reply Likes
Thanks for the info, I'll look into it. At the very least it should only be a 401, not a 500.
Photo of KarKeng Chan

KarKeng Chan

  • 38 Posts
  • 0 Reply Likes
It's working just fine today. So I supposed it's an individual event?
Photo of Nick Nicholls

Nick Nicholls, Employee

  • 21 Posts
  • 2 Reply Likes
Yeah, might've just been a hiccup
Photo of Andrew Batz

Andrew Batz

  • 5 Posts
  • 0 Reply Likes
The 500 error is on your end, you're not handling the 401 they're sending you. 
401 means unauthorized. Combining that with what you've said it looks like your auth token has expired. Refresh your auth token and it should be gravy. 
Photo of KarKeng Chan

KarKeng Chan

  • 38 Posts
  • 0 Reply Likes
I was trying with the ShareFile API website to perform the request and it showed similar error, but it seems fine now. Thanks anyway