Desktop vault for API keys and secrets — documentation for developers.
Zentra uses Electron with a strict security-first architecture. The main process handles all cryptographic operations, database access, and system integrations. The renderer process runs a React UI with sandboxed context.
React UI ←→ Electron IPC ←→ Main Process
├── Crypto (Argon2id + AES-256-GCM)
├── SQLite (sql.js + Drizzle)
├── API Tester (Axios)
├── Key Validation
├── GitHub Secret Scanner
└── Google Calendar SyncAll communication between the renderer and main process goes through the window.vaultIPC bridge. The following operations are exposed:
init(password)Create a new vault with the given master passwordunlock(password)Unlock existing vault with master passwordlock()Lock the vault and clear encryption key from memoryisInitialized()Check if a vault has been createdgetUnlockStatus()Get failed attempts, lockout state, remaining attemptsgetProjects()List all projectscreateProject(name, color)Create a new projectupdateProject(id, data)Update project propertiesdeleteProject(id)Delete a project and its secretsgetSecrets(projectId)List secrets in a projectgetSecret(id)Get a single secret by IDcreateSecret(data)Create a new secretupdateSecret(id, data)Update secret propertiesdeleteSecret(id)Delete a secretrevealSecret(id)Decrypt and return secret valuegetTags()List all tagscreateTag(name, color)Create a new tagdeleteTag(id)Delete a taggetSecretTags(secretId)Get tags for a secretaddSecretTag(secretId, tagId)Add tag to secretremoveSecretTag(secretId, tagId)Remove tag from secretvalidateKey(secretId)Validate an API key against known patternsbatchValidateKeys(projectId)Validate all keys in a projectscanGitHubSecrets(projectId)Scan GitHub repos for exposed secretstestApiRequest(config)Test an API endpoint with stored credentialsgoogleAuth(clientId, clientSecret)Authenticate with Google CalendarsyncSecretToCalendar(secretId)Sync secret expiry to Google CalendarSecrets support the following types: api_key, bearer_token,jwt, oauth_client, username_password,ssh_key, database_url, environment_variable, webhook_secret, and custom.
Environments: development, staging, production, and all.
Argon2id configuration: time cost = 3, memory cost = 65536 KiB, parallelism = 4. AES-256-GCM with random 96-bit nonce per secret. See the security policy for the full threat model.
git clone https://github.com/vihanga-nimsara/Zentra.git cd Zentra npm install npm run dev # development npm run build # production build npm run package # packaged distributable