To clarify, AFTER I log in at jive, the API call can be made.
Another example is if I am not logged in at community.jivesoftware.com, this request says I'm a guest.
If I am logged out, this doesn't give user detail information.
after I've logged in at community.jivesoftware.com,
will give me user details.
This seems like basic authentication does not work?
Hey Chris Kim!
Basic Authentication isn't quite going to work the way you're imagining with your username and password in the URI. You're seeing results when you hit that API endpoint in your browser if you log into the site manually because at that point, you have an authenticated session available. If you try and use your username and password as part of the URI like you would if connecting to an FTP host for example, you won't be authenticated.
To work with an API you'd want to do so with a client where you can place your basic authentication credentials within the request headers as a base-64 string. The details don't matter too much as a client typically would take care of that for you. You could use cURL for example or PowerShell, which is my preferred method in my Windows environment (you can really create some powerful scripts and functions with PowerShell).
I'd start with a search for how to use cURL, PowerShell or another client for connecting to a server/API.
If you're interested in PowerShell, I could give you the basics on how to write a script for basic authentication access.
For those looking, exact header should be passed is Authorization: Basic xxxxxx
where xxxxxx is base64 encoded login:pass
If you try and use your username and password as part of the URI like you would if connecting to an FTP host for example, you won't be authenticated.
This is what I want to do to setup an ftp URI to update my avatar image from my ftp file path. but it is giving me 400 error in status. I have passed my credentials of the Jive instance in the header using basic Auth and ftp username and password in the URI itself.
Could you help in how to achieve this