Expand my Community achievements bar.

AEM Cloud Oauth access token is not working

Avatar

Level 2

Hello,

 

On AEM Cloud instance I set up Oauth client, got the access token and tried it to access /bin/querybuilder.json

The response is 'unauthorized' status.

 

I did the same on AEM 6.5 on prem and I was able to access /bin/querybuilder.json and also the example website: 'we-retail'

 

The scope I used is 'offline_access'

 

Can you advise on how to make it working the same as on the AEM on prem or if not how to debug the problem?

There's no error message. What I get is only 401 status.

 

2 Replies

Avatar

Community Advisor

Hi @dwid1 ,

Where are you trying to test this, if it is on dispatcher then try to include below rules before accessing it

/0100 { /type "allow" /url "/bin/querybuilder.json"}

/0304 { /type "allow" /url "/apps/*" }
/0305 { /type "allow" /url "/bin/*" }

 

If you are testing it directly from publish instance with ip then add /bin under configuration

Apache Sling Servlet/Script Resolver and Error Handler.

Thanks
Tarun

Avatar

Level 2

I'm just trying to call author service: <AUTHOR_SERVICE>/bin/querybuilder.json

That works for AEM 6.5 on prem.

 

Not sure about any dispatcher. I just created dev instance in cloud manager and didn't set any dispatcher.