Jump to content

API Format to retrieve password

Recommended Posts

Having a hard time getting the API to work so my developers can use it in their applications. A simple retrieve in Curl should be the following no?


curl -k -sS -X GET https://<server-name>:9119/api/passwords/test-password -H "apikey=<api-key>"


I'm currently getting the following error

[{"errors":[{"message":"Invalid API Call"},{"phrase":"Error = Object reference not set to an instance of an object."}]}]

Edited by Joshua Sanders
Added error message
Link to comment
Share on other sites

Hi Joshua,


We don't have much experience with curl, but I found this post which has some reference to old API documentation which might help with the formatting - https://www.clickstudios.com.au/community/index.php?/topic/2203-retrieving-a-password-via-api-and-curl/ 


I think your issue might be the reference to 'test-password' - if you are retrieving a single password record via this controller in the API, then you must use the PasswordID value. If you are wanting to search for a password, then this is a different controller, and the format is /api/searchpasswords


If you look under the Help Menu, and Web API Documentation, we have all examples in PowerShell, but the formatting should be similar for curl.


Click Studios


Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...