Piiano.Vault 1.1.13

dotnet add package Piiano.Vault --version 1.1.13
NuGet\Install-Package Piiano.Vault -Version 1.1.13
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Piiano.Vault" Version="1.1.13" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Piiano.Vault --version 1.1.13
#r "nuget: Piiano.Vault, 1.1.13"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Piiano.Vault as a Cake Addin
#addin nuget:?package=Piiano.Vault&version=1.1.13

// Install Piiano.Vault as a Cake Tool
#tool nuget:?package=Piiano.Vault&version=1.1.13

Piiano.Vault: a .Net SDK for Vault

vault-dotnet is a client SDK for the Vault written in C# for Microsoft .NET 7.0. The underlying implementation of the SDK is auto-generated from the Vault OpenApi document.

Note:

This package version is 1.1.13 and is compatible with Vault version 1.11.1 .

For a Vault client compatible with other versions of Vault, check other versions of this package.

vault-dotnet is a client SDK for Vault written in C# for .Net 7.0. The underlying implementation of the SDK is auto-generated from the Vault OpenAPI document.

Contents

Documentation

Refer to the API documentation at: https://docs.piiano.com/api/

Repository organization

The solution has two projects:

  • Vault: A library that provides the SDK.
  • Vault.Tests: A library containing tests of the SDK.

The Vault project

The Vault project's OpenAPI document, openapi.json, is in its root.

When built, the project generates the file generated/GeneratedClient.cs from the OpenAPI document. The Vault project defines the clients for each of the API resources. Each client is a wrapper over the generated client and provides access to API operations.

The Vault.Tests project

This project contains tests for each of the clients. The tests are organized into folders, one folder for each client.

Installation

  1. Install dot net 7.0 or later: https://docs.microsoft.com/en-us/dotnet/core/install/
  2. Install Vault Lite: https://docs.piiano.com/guides/install/
  3. Run Vault Lite.
  4. Run dotnet build in the root of the repository.
  5. Run dotnet test Vault.Tests in the root of the repository.

Using the SDK

  1. Open Vault.sln in your IDE. You can use either Visual Studio or Rider (2023.2.2).
  2. Create your project in the solution.
  3. In your code:
    • add using Vault;
    • create a client factory using: var clientFactory = new ClientFactory();
    • ClientFactory optional parameters:
      • uriString : Vault URL.
      • userKey : Bearer token.
      • defaultRequestHeaders : Dictionary of HTTP headers.
      • timeoutValue : Client timeout.
  4. Add the client factory feature you require. For example, (code snippet) to (description of what the code snippet does).
  5. Use the Generated property to access any other operations defined by the Vault OpenAPI document. For example, (code snippet) to (description of what the code snippet does).

Working with clients

The client factory provides properties that return clients for Vault resources. Each client is exposed as an interface and provides access to related operations. For example, the System property returns a client for the System resource with the ISystem interface.

Here is a list of the clients implemented in this version of the SDK. The interface it implements and a reference to the resource documentation are provided for each client.

Interface Returned by Documentation
ISystem ClientFactory.System https://docs.piiano.com/api/system/
IConfVar ClientFactory.ConfVar https://docs.piiano.com/api/config-vars/
IIAM ClientFactory.IAM https://docs.piiano.com/api/iam/
ICollections ClientFactory.Collections https://docs.piiano.com/api/collections/
ICollectionProperties ClientFactory.CollectionProperties https://docs.piiano.com/api/collection-properties/
IObjects ClientFactory.Objects https://docs.piiano.com/api/objects/

Working with a different server

The SDK is configured to work with the Vault server at http://localhost:8123 by default. To work with a different server, pass the server URL as the first argument to the constructor of the client factory.

Working with a different user

By default, the SDK is configured to work with the default token of the Vault Admin user (pvaultauth). To work with a different user, pass the user's token as the second argument to the constructor of the client factory. For more information on how to get a user's token, see https://docs.piiano.com/guides/manage-users-and-policies/regenerate-user-api-key.

Product Compatible and additional computed target framework versions.
.NET net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.1.13 94 4/15/2024
1.1.12 74 4/2/2024
1.1.11 80 3/11/2024
1.1.10 106 2/22/2024
1.1.9 94 2/7/2024
1.1.8 86 2/5/2024
1.1.7 90 1/29/2024
1.1.6 91 1/23/2024
1.1.5 442 1/1/2024
1.1.4 439 12/20/2023
1.1.3 160 12/11/2023
1.1.2 100 12/10/2023
1.1.1 127 12/8/2023
1.1.0 202 11/26/2023
1.0.6 145 11/16/2023
1.0.5 146 10/16/2023
1.0.4 140 10/11/2023
1.0.3 118 10/11/2023
1.0.2 113 10/11/2023
1.0.1 119 10/7/2023
1.0.0 119 10/7/2023