uplink.NET.new 0.9.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package uplink.NET.new --version 0.9.0
                    
NuGet\Install-Package uplink.NET.new -Version 0.9.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="uplink.NET.new" Version="0.9.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="uplink.NET.new" Version="0.9.0" />
                    
Directory.Packages.props
<PackageReference Include="uplink.NET.new" />
                    
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 uplink.NET.new --version 0.9.0
                    
#r "nuget: uplink.NET.new, 0.9.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.
#:package uplink.NET.new@0.9.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=uplink.NET.new&version=0.9.0
                    
Install as a Cake Addin
#tool nuget:?package=uplink.NET.new&version=0.9.0
                    
Install as a Cake Tool

uplink.NET

A modern .NET 10+ wrapper library around the storj/uplink-c C library, providing idiomatic async .NET access to the Storj decentralized cloud storage network.

Features

  • Modern P/Invoke – uses LibraryImport (source-generated, AOT-compatible) instead of SWIG
  • Async-first API – all I/O operations are Task-returning
  • Multipart upload – full support for begin/upload-part/commit/abort/list
  • Upload queue – persistent SQLite-backed upload queue with background processing
  • Cross-platform – Windows, Linux (x64 + ARM64), macOS (x64 + ARM64), Android ARM64
  • NuGet ready – builds a self-contained NuGet package containing all native runtimes

Quick start

using uplink.NET.Models;
using uplink.NET.Services;

// Parse the access grant and open a project connection
using var access = new Access("your-access-grant-here");

// TempDirectory is optional. By default the library uses the platform temp directory.
// var access = new Access("your-access-grant-here", new Config { TempDirectory = "/custom/temp" });

var buckets = new BucketService(access);
var objects = new ObjectService(access);

// Create or ensure a bucket exists
var bucket = await buckets.EnsureBucketAsync("my-bucket");

// Upload a file
byte[] data = File.ReadAllBytes("photo.jpg");
var upload = await objects.UploadObjectAsync(access, "my-bucket", "photos/photo.jpg", data);
// upload.StartUploadAsync() is called automatically (startImmediately defaults to true)

// List objects
var list = await objects.ListObjectsAsync(access, "my-bucket");
foreach (var obj in list.Items)
    Console.WriteLine($"{obj.Key} ({obj.ContentLength} bytes)");

// Download
var download = await objects.DownloadObjectAsync(access, "my-bucket", "photos/photo.jpg", startImmediately: true);
download.DownloadOperationEnded += op =>
{
    if (op.Completed)
        File.WriteAllBytes("downloaded.jpg", op.DownloadedBytes);
};

Project structure

src/
└── uplink.NET/
    ├── Native/            # LibraryImport P/Invoke declarations (UplinkInterop.cs)
    ├── Models/            # Access, Bucket, StorjObject, upload/download operations, …
    ├── Interfaces/        # IBucketService, IObjectService, IMultipartUploadService, IUploadQueueService
    ├── Services/          # Concrete implementations
    └── Exceptions/        # Typed exceptions for every failure mode

Building

The .NET wrapper builds without the native library present. The native storj_uplink shared library is built by the CI pipeline (see .github/workflows/build.yml) and placed under src/uplink.NET/runtimes/<rid>/native/ before packing the NuGet package.

To build locally:

dotnet build src/uplink.NET/uplink.NET.csproj

NuGet publishing

The package metadata needed for NuGet.org is defined in src/uplink.NET/uplink.NET.csproj. That includes the package version, author, description, tags, license, README, and repository links.

Requirements

  • A NuGet.org account
  • A NuGet.org API key
  • The NUGET_API_KEY repository secret for GitHub Actions publishing

An image is not required for publishing. A package icon can be added later, and README images are optional if they are hosted publicly.

Create a local package

dotnet build src/uplink.NET/uplink.NET.csproj -c Release
dotnet pack src/uplink.NET/uplink.NET.csproj -c Release -o nupkgs/

Publish manually

dotnet nuget push nupkgs/*.nupkg \
  --api-key <YOUR_NUGET_API_KEY> \
  --source https://api.nuget.org/v3/index.json

Publish with GitHub Actions

The workflow in .github/workflows/build.yml will publish automatically when you publish a GitHub Release whose tag matches v*.

Recommended release flow:

  1. Create or choose a Git tag in the format v1.0.0
  2. Create a GitHub Release for that tag and publish it
  3. GitHub Actions fetches the release metadata, derives the NuGet version from the tag, and uses the release title/body as NuGet release notes
  4. GitHub Actions builds the native runtimes, packs the NuGet package, and publishes it using NUGET_API_KEY

Local dotnet pack is useful for validation, but the GitHub Actions release path is the one that bundles the native runtime artifacts before publishing. Local packages keep the version defined in src/uplink.NET/uplink.NET.csproj, while release packages use the GitHub Release tag.

License

MIT

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  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
0.9.4 94 4/2/2026
0.9.3 84 4/2/2026
0.9.2 85 4/2/2026
0.9.1 80 4/1/2026
0.9.0 81 4/1/2026

First release

Initial release to test the library