Jump to content

Adding a AD account which is set up for automatic resets


Recommended Posts

This post describes how to set up an Active Directory account in Passwordstate, configured for Automatic Resets:


Powershell Script:


$PasswordstateAPIURL = "https://fabrikam.com/api/passwords"
    $jsonString = '
    "Title":"SCCM Service Account",
Invoke-Restmethod -Method POST -Uri $PasswordstateAPIURL -ContentType "application/json" -Body $jsonString



Pre-Requisites to get this script working:


An API key needs to be set on a Password List.  This can be achieved when adding or editing a Password List:



You'll need to find the PasswordListID value, by toggling the Visibility of the Web API IDs:



Next you'll need to find the AccountTypeID for Active Directory under Administration -> Images and Account Types:




Next find the Validation ScriptID for Active Directory Accounts under Administration -> Powershell Scripts -> Password Validation:



And the ID of your Privileged account, which has permissions in AD to reset Accounts:




If you insert these values into your script, along with any other string values like the Title or username, it will add a record in to the system as expected.






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...