An unofficial Julia client for the Bitwarden Secrets Manager CLI.
This project is in alpha stage. The API is not stable and may change significantly between versions without deprecation warnings. Breaking changes will be noted in release notes.
Not recommended for production environments.
- 🔑 Access to Bitwarden Secrets Manager functionality
- 🔄 Type-safe Julia interface with automatic type conversions
- 🛠️ Support for organizations, projects, and secrets management
- 📦 Automatic CLI binary installation and management
- 🧩 Pipeline-friendly API with functional composition
- Julia 1.10 or higher
- Internet connection for initial CLI binary download
- A Bitwarden account with Secrets Manager access
- Valid Bitwarden access token (for authentication)
Since this package is not yet registered in the Julia General Registry, you’ll need to install it directly from GitHub:
using Pkg
Pkg.add(url="https://github.com/s-celles/BitwardenSecretsManagerUnofficialClient.jl")(if/when registered)
To install the package, use Julia's package manager:
using Pkg
Pkg.add("BitwardenSecretsManagerUnofficialClient")The package will automatically download and install the appropriate Bitwarden Secrets Manager CLI binary for your platform during installation.
using BitwardenSecretsManagerUnofficialClient
# Create a client
client = BitwardenClient()
# Get version information
version(client) # Returns VersionNumber("1.0.0")
# Get help
help(client) # Returns CLI help textusing BitwardenSecretsManagerUnofficialClient
# Create client with settings
settings = ClientSettings(access_token="your_access_token")
client = BitwardenClient(settings)
# Or authenticate after client creation
client = BitwardenClient()
client |> auth |> login_access_tokenusing BitwardenSecretsManagerUnofficialClient
using UUIDs
# Create a client
client = BitwardenClient()
# Define project ID and organization ID
org_id = OrganizationID("your_organization_id")
project_id = ProjectID("proj-uuid")
# Get a secrets client to perform operations on secrets
secrets_client = SecretsClient(client)
# or
secrets_client = client |> secrets
# Create secret
create!(secrets_client,
"secret-key",
"secret-value",
project_id,
note="optional note")
# Get secret
get(secrets_client, SecretID("secret-uuid"))
# Update secret
update!(secrets_client,
SecretID("secret-id"),
key="new-key",
value="new-value",
note="new note")
# List secrets
client |> secrets |> sc -> list(sc, project_id)
# Delete secrets
delete!(secrets_client, SecretID.(["secret-id-1", "secret-id-2"]))The package provides type-safe ID handling:
# Creating IDs from strings or UUIDs
org_id = OrganizationID("40f36664-5d09-4193-8445-b1c500f3d1ba")
project_id = ProjectID(UUID("57073045-0fd8-43e3-a0d5-b28c01194c7e"))
secret_id = SecretID("efb07cd0-b18a-49ce-81c9-b291f1590661")
# Converting between types as needed
uuid_value = UUID(secret_id)
string_value = string(org_id)- Authentication Errors
- Verify that your access token is valid and not expired
- Ensure environment variables are properly set if using them
- Command Execution Errors
- Check the Bitwarden CLI version with version(client)
- Try running help(client) to verify the CLI is working
- Connectivity Issues
- Ensure your firewall allows the CLI to connect to Bitwarden servers
- Verify your internet connection is working
Contributions are welcome! Please feel free to submit a Pull Request.
This Julia package is licensed under the MIT License - see the LICENSE file for details.
Note: The Bitwarden Secrets Manager CLI binary (bws) is distributed under the BITWARDEN SOFTWARE DEVELOPMENT KIT LICENSE AGREEMENT.