SplenSoft.UexNet 0.4.4

dotnet add package SplenSoft.UexNet --version 0.4.4                
NuGet\Install-Package SplenSoft.UexNet -Version 0.4.4                
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="SplenSoft.UexNet" Version="0.4.4" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add SplenSoft.UexNet --version 0.4.4                
#r "nuget: SplenSoft.UexNet, 0.4.4"                
#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 SplenSoft.UexNet as a Cake Addin
#addin nuget:?package=SplenSoft.UexNet&version=0.4.4

// Install SplenSoft.UexNet as a Cake Tool
#tool nuget:?package=SplenSoft.UexNet&version=0.4.4                

UexNet

.NET implementation of UEXCorp's Star Citizen data API. Currently untested/early alpha and likely to not work. Use at your own risk.

NuGet Downloads

Basic usage

using SplenSoft.UexNet;

// Get api key from https://uexcorp.space/account
string uexApiToken = "xxxxxx-xxxxxxx-xxxxxx-xxxxxxx";

// Initialize the client
var client = new UexClient(uexApiToken);

// Get commodities
List<UexTerminalCommodity> commodities;
var commoditiesTask = client.GetCommodities();

await commoditiesTask;

if (commoditiesTask.Result != null && 
    commoditiesTask.Result.Success)
{
    commodities = commoditiesTask.Result.List;

    foreach (var commodity in commodities)
    {
        string? terminal = commodity.TerminalName;

        Console.WriteLine(
            $"{commodity.Name} at terminal {terminal}");
    }
}
else
{
    // Handle failure
    // read commoditiesTask.Result.RequestResult
}

// Get terminals
List<UexTerminal> terminals;
var terminalsTask = client.GetTerminals();

await terminalsTask;

if (terminalsTask.Result != null &&
    terminalsTask.Result.Success)
{
    terminals = terminalsTask.Result.List;

    foreach (var terminal in terminals)
    {
        Console.WriteLine(
            $"{terminal.Name}'s code is {terminal.Code}");
    }
}
else
{
    // Handle failure
    // read terminalsTask.Result.RequestResult
}
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. 
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.4.4 67 9/5/2024
0.4.3 75 9/5/2024
0.4.2 66 9/5/2024
0.4.1 63 9/5/2024
0.4.0 69 9/5/2024
0.3.6 72 9/5/2024
0.3.5 68 9/5/2024
0.3.3 69 9/5/2024
0.3.2 61 9/5/2024
0.3.0 65 9/5/2024
0.2.4 73 9/4/2024
0.2.3 70 9/4/2024
0.2.2 67 9/4/2024
0.2.1 67 9/4/2024
0.1.1 69 9/4/2024
0.1.0 69 9/4/2024

Pre-release.

0.4.0 - Added vehicles support
0.4.1 - Added more robust derived type support
0.4.2 - Allow public access to UexClient.ListRequest
0.4.3 - Fix unhandled types in list request
0.4.4 - Fix vehicle deserialization