VMware Cloud Community
andrew_coder
Contributor
Contributor
Jump to solution

VCSA Authentication via rest API not working

Any idea why my Authentication not working via RESTAPI call to VCSA ? I am using VCSA 7.0.3

I created new local user with read only access. I tested via web portal login, it is working fine. But when I tested API login via postman or curl, python, I get always this error message : UNAUTHENTICATED, Authentication required." Even though, I used the same user login credentials. I tested also with my admin user, same error.

 

andrew_coder_0-1702059469372.png

 

Labels (2)
0 Kudos
2 Solutions

Accepted Solutions
andrew_coder
Contributor
Contributor
Jump to solution

Thanks for hint.

Yes, issue was wrong API endpoint. Correct is https://{api_host}/api/session

Finally working !

View solution in original post

0 Kudos
4 Replies
MerlevedeN
Enthusiast
Enthusiast
Jump to solution

Maybe this can help: https://www.vgemba.net/vmware/VCSA-API-Postman/

Can you try using the URL: https://vcenterFQDN/api/session

 

andrew_coder
Contributor
Contributor
Jump to solution

Thanks for hint.

Yes, issue was wrong API endpoint. Correct is https://{api_host}/api/session

Finally working !

0 Kudos
andrew_coder
Contributor
Contributor
Jump to solution

Btw how can I mark this case as resolved ?

0 Kudos
MerlevedeN
Enthusiast
Enthusiast
Jump to solution

Hi, you can mark my post as a solution. It will be open so other users can read the information.

0 Kudos