I am new to Solarwinds. i am trying to authenticate sonarwind rest api using basic auth from my java code. But getting 401 error. I am using my Ldap username and pwd for authentication. I also used OrionSDk from https://github.com/solarwinds/OrionSDK/ ,but did not work.
I found another observation during chrome rest client. if I call the api with authorization then i am getting 302 error. But if I logged in to solarwind from the chrome browser and then call the rest api from chrome client then it is working as expected.
Please tell me is there need any special permission for my ldap account to connect from my java code? please help me regarding this. it will be better if you provide sample code also.
Before going in to too much detail, can you confirm what you mean by 'used Orion SDK', are you referring to the SWQL Studio or some of the code samples?
A 401 error is an authentication issue, which as you have recreated this in elsewhere would indicate this is an account problem. You say LDAP, but I am presuming this is as part of the AD account integration
1. Review your account settings in Orion and confirm you can log in to Orions web interface. To interact with the API, the permissions level on your account will reflect what you are then allowed to action against the API
2. Try authenticating using an internal Orion user account to rule out account issues
SolarWinds solutions are rooted in our deep connection to our user base in the THWACK® online community. More than 150,000 members are here to solve problems, share technology and best practices, and directly contribute to our product development process. Learn more today by joining now.