Skip to main content
net10.0net8.0net9.0

An Aspire client integration for Bitwarden Secrets Manager.

Published
Sep 21, 2026
28d ago
Total Downloads
2.7K
2,725

Install

dotnet add package CommunityToolkit.Aspire.Bitwarden.SecretManager --version 13.5.1-beta.763
ProductVersions
.NET
net10.0net8.0net9.0

README

CommunityToolkit.Aspire.Bitwarden.SecretManager

Overview

CommunityToolkit.Aspire.Bitwarden.SecretManager registers authenticated BitwardenClient instances using structured Aspire configuration.

Installation

dotnet add package CommunityToolkit.Aspire.Bitwarden.SecretManager

Configuration

The client integration expects configuration under Aspire:Bitwarden:SecretManager:{connectionName}.

When used with the hosting integration, call WithReference(bitwarden) in the AppHost and then register the client in the consuming application:

builder.AddBitwardenSecretManagerClient("bitwarden");

The configuration section includes:

  • OrganizationId
  • ProjectId
  • AccessToken
  • ApiUrl
  • IdentityUrl
  • AuthCacheFile (optional) — path to the Bitwarden SDK auth cache file inside the app. Set via WithAuthCacheFile(...) in the AppHost. Persist the auth session to a durable storage path to avoid re-authenticating on every app restart.

Usage

builder.AddBitwardenSecretManagerClient("bitwarden");

WebApplication app = builder.Build();

app.MapGet("/sync", (Bitwarden.Sdk.BitwardenClient client, BitwardenSecretManagerClientSettings settings) =>
{
    var sync = client.Secrets.Sync(settings.OrganizationId, null);
    return Results.Ok(sync.Data.Count);
});

Use AddKeyedBitwardenSecretManagerClient(...) when you need multiple Bitwarden clients in the same application.

Changes from Previous Version

No structural changes between v13.5.1-beta.757 and v13.5.1-beta.763.

Adoption Assessment

A verified publisher signal is available. Assess fit from the package's supported frameworks, license and dependency graph rather than popularity alone.

This version is marked prerelease. Validate its API and upgrade path before production use.Compatibility metadata lists 3 target frameworks; confirm the exact target used by your application.

Related Guides & Workflows

Learn how to evaluate, integrate, or audit this package in your .NET project.