I am getting this error message “org.apache.http.client.HttpResponseException: status code: 401, reason phrase: Unauthorized” while trying to hit the api of this url “https://author-p69802-e616155.adobeaemcloud.com”. I have implemented SSL certification also but still getting the same error message.
Could you please help to resolve this issue.
Solved! Go to Solution.
Views
Replies
Total Likes
What password are you using? You cannot do a POST of your AEM credentials (which you enter either at IMS or at the SSO solution of your company) to AEM, that won't work.
Hi.
Do I understand correctly, that you have java code, which tries to connect to the mentioned URL? What approach do you use for authentication?
I am trying to hit api through postman and getting unauthorized exception.
What type of authentication (and therefor: credentials) are you using? JWT token? Username/password as basic auth?
(Remember, that in AEM as a Cloud Service the authentication normally works using IMS and tokens, unlike the "classic" way of using username/password).
Ok, I am using username/password.
What password are you using? You cannot do a POST of your AEM credentials (which you enter either at IMS or at the SSO solution of your company) to AEM, that won't work.
@vandana_ratnaparkhi Did you try hitting api through postman?
Yes, but getting access denied.
@vandana_ratnaparkhi That means you will have to pass the credentials to access it.
Already passing the credentials and also implemented SSL certificate but still getting access denied.
Make sure you are using a bearer token that you generate from AEM development console:
And there when you sign in and click on integrations:
You can generate a developer token which you could use to make a call and perform requests.
Can you share screenshot of your postman window?
Views
Likes
Replies