You are viewing limited content. For full access, please sign in.

Discussion

Discussion

An API setting that will trip you up

posted on August 27 Show version history

Working with the Cloud API, we came across a subtle problem that cost us a few hours.  Of course, with the Web API every problem is subtle, hopefully this fills in a gap.

 

We set up a service account, created an application with the service principal, and granted the account repository.Read and repository.Write permissions, and also (probably not necessary) added the service account to a group with full access to the repo.

When you create the key, it says:

 

So you go to https://signin.laserfiche.com/oauth/swagger/index.html

and set the grant type:

 

 

Good?

 

Nay, nay! 

 

When you switch to the API and run anything, you will get "Access Denied".  You need to set the scope again:

 

Then you can run the API, here just getting the Repo name:

 

Which is much better than:

 

As they say on despair.com, "It could be that the purpose of your life is only to serve as a warning to others."

 

 

2 0
replied on August 27

Bill,

Thank you for sharing this with the community.  Our documentation does mention that you need to also send the scopes in the access token request but we will see if we can make that more clear and maybe mention that in the developer console instructions for creating an app.

 

 

Best,

Andrew

3 0
replied on August 27

Thanks Andrew - indeed it does - I will edit the post.

1 0
You are not allowed to follow up in this post.

Sign in to reply to this post.