How to resync the API credfile for the PSM

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
PAM Self-Hosted Articles
2 min read
L0 Member
No ratings
The executable 'apikeymanager.exe' is used to manage the credential file that is needed for the PSM. The file is located in your PSM installation directory, by default it is:
C:\Program Files (x86)\CyberArk\PSM\Vault

The PSMApp username can be found in the psmapp.cred file, located in the same vault directory mentioned above.

Steps

1) Stop the service "Cyber-Ark Privileged Session Manager"

2) Navigate to your PSM installation directory, vault folder as described in the introduction above and open an administrative command prompt window to this folder. the commands below will be run in this CMDwindow.

Revoke API key:
apikeymanager.exe revoke -t <PSMApp username> -u <vault administrator username> -a "<https://<PVWA_FQDN>/PasswordVault/api/>"
 
For example:
ApiKeyManager.exe revoke -t PSMAppxxxxxxx -u administrator -a "https://xxx.xxx/passwordVault/api"
(NOTE: change relevant values where required)
 
 
Create a new API key:
ApiKeyManager.exe add -f "<PSM installation folder path>\Vault\apigw.cred>" -t <PSMApp username> -u <vault username> -a "<https://<pvwa hostname>/passwordVault/api>"
 
For example:
ApiKeyManager.exe add -f "C:\Program Files (x86)\CyberArk\PSM\Vault\apigw.cred" -t PSMAppxxxxxx -u administrator -a "https://xxx.xxx/passwordVault/api"
(NOTE: change relevant values where required).
 
 
vault.ini configuration:
Update/Ensure the Addresses and ApiKeyPath parameters in the vault.ini file exist and are accurate. If either are missing, add them. They need to be at the bottom of the vault.ini file under a header [API], don't put these entries anywhere else.

[API]
Addresses="<PVWA url>/api"
ApiKeyPath="<PSM installation folder path>\Vault\apigw.cred"

 

3) You may now start the PSM service again.

Final note, if the need arises you can also update the existing key pair with the following command:
 
ApiKeyManager.exe update -f "<PSM installation folder path>\Vault\apigw.cred"> -t <PSMApp username> -u <vault username> -a "https://<pvwa hostname>/passwordVault/api"
Rate this article:
  • 9756 Views
  • 0 comments
  • 0 Likes
Article Dashboard
Version history
Last Updated:
‎11-11-2025 09:01 PM
Updated by: