Cloud.File.Storage.Manager.Box 1.0.0

dotnet add package Cloud.File.Storage.Manager.Box --version 1.0.0
                    
NuGet\Install-Package Cloud.File.Storage.Manager.Box -Version 1.0.0
                    
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="Cloud.File.Storage.Manager.Box" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Cloud.File.Storage.Manager.Box" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="Cloud.File.Storage.Manager.Box" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Cloud.File.Storage.Manager.Box --version 1.0.0
                    
#r "nuget: Cloud.File.Storage.Manager.Box, 1.0.0"
                    
#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.
#addin nuget:?package=Cloud.File.Storage.Manager.Box&version=1.0.0
                    
Install Cloud.File.Storage.Manager.Box as a Cake Addin
#tool nuget:?package=Cloud.File.Storage.Manager.Box&version=1.0.0
                    
Install Cloud.File.Storage.Manager.Box as a Cake Tool

Cloud File Storage Manager

Provides complete implementation to handle easily cloud file storage operations like get informations about files, reading, downloadURL generation, file update, file move and delete. Primarily for Box right now.

Configuration

Let's add a section to the appsettings.json

"BoxStorageSettings": {
    "ClientId": "",
    "ClientSecret": "",
    "EnterpriseId": "",
    "PublicKeyId": "",
    "PrivateKey": "",
    "Passphrase": "",
    "RootFolderId": "0"
}

In the application, configure this settings part

services.AddSingleton<ICloudFileStorageManager, BoxFileStorageManager>(services => new BoxFileStorageManager(new BoxFileStorageManagerOptions()
{
    ClientId = config.GetSection("BoxStorageSettings").GetValue<string>("ClientId"),
    ClientSecret = config.GetSection("BoxStorageSettings").GetValue<string>("ClientSecret"),
    EnterpriseId = config.GetSection("BoxStorageSettings").GetValue<string>("EnterpriseId"),
    PublicKeyId = config.GetSection("BoxStorageSettings").GetValue<string>("PublicKeyId"),
    PrivateKey = config.GetSection("BoxStorageSettings").GetValue<string>("PrivateKey"),
    Passphrase = config.GetSection("BoxStorageSettings").GetValue<string>("Passphrase"),
    RootFolderId = config.GetSection("BoxStorageSettings").GetValue<string>("RootFolderId")
}));

Images of the Box side configuration

Let's create a Platform Application

Platform App

It is necessary to Enable the applicaiton and Authorization from administrators is required. After that, a service account is created for the Platform application with which the API interaction takes place.

JWT type application is recommended for this kind of use-cases

Auth Method

Minimal access is sufficient

Access Level

Public/Private Keypair

A Public/Private Keypair is required for the necessary configuration, which can be created with the click of a button. A config file is also downloaded here, which contains all the necessary configuration data required for the configuration. (ClientId, Keys, etc.)

Keypair

When using a Box Platform App with JWT authentication, your app acts as a service account, also called an App User. This service account is isolated from your personal Box account.

  • Files and folders uploaded using JWT don't show up in "All Files" in your personal Box account — because they are not stored in your user’s root folder, but in the service account’s storage space.

Where did your files go?

If you're using JWT to authenticate via the platform app and then uploading files:

  • The uploads are happening under the App User's account, not your personal Box user.
  • Unless you explicitly upload to a folder owned/shared by a managed user (like yourself), it goes into the App User’s own root.
Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  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.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.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.0.0 138 5/27/2025

- Box support init