JS connector
The Passwork API allows you to retrieve, create and update passwords, folders and vaults. It is an easy way to integrate Passwork into your infrastructure. Actions performed with an API key will be executed on behalf of the user the API key belongs to.
Create a directory you will clone the repository into:
Use git to clone the connector repository:
Install the project dependencies listed in the package.json file:
Perform the following steps:
- Authorise in the desktop version of Passwork;
- Go to Settings and Users → API Settings;
- Enter your password and get the API key.

It is important to keep the API key secure. It should not be shared with any third parties. To get a temporary API token, use the login(...) method. Once received, the token is stored and automatically passed in HTTP request headers, making it easy to work with the API. This token is valid for the duration of the session, i.e. as long as requests to the API are made. When the token expires, you need to log in again to generate a new one.
The lifetime of a token can be configured in Passwork settings
See all available Passwork API methods
Open session:
The session is valid for 10 minutes (can be changed). Thus, you can perform multiple actions within one session without logging in.
Obtain a password using the ID: