FortniteDotNet 2.0.3

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

// Install FortniteDotNet as a Cake Tool
#tool nuget:?package=FortniteDotNet&version=2.0.3

<div align="center">

<p><img src="https://i.ibb.co/ydk7KVc/banner.png" alt="Banner"></p> <p>FortniteDotNet is a simple and easy-to-use library used for interacting with Fortnite's HTTP and XMPP services. Features include interactions with parties and friends, general API data, and more.</p>

NuGet Release NuGet Downloads GitHub Issues GitHub Forks GitHub Stars GitHub License

</div>

Installation

You can find FortniteDotNet on any NuGet package manager. Alternatively, you can use the dotnet CLI.

dotnet add package FortniteDotNet

Features

Below is a list of some of the features FortniteDotNet includes.

  • Party and XMPP services
  • Friends services, including legacy endpoints
  • Fortnite services
    • Cloudstorage (system/user)
    • Storefront requests (shop)
    • Profile-related operations (QueryProfile, etc.)
  • Dependency injection
  • Asynchronous codebase

Usage

FortniteDotNet uses dependency injection. There are two ways to access different services within FortniteDotNet. Please ensure the package Microsoft.Extensions.DependencyInjection is installed.

MAUI app example (MauiProgram.cs):

First:

// Add the services upon creation
public static MauiApp CreateMauiApp()
{
    var builder = MauiApp.CreateBuilder().UseMauiApp<...>();    
    builder.Services.AddFortniteApi();
    
    ...
    
    return builder.Build();
}

then...

// Get a service through a constructor
private readonly IAccountService _accountService;

public ExampleClass(IAccountService accountService)
{
    _accountService = accountService;
}

or...

// Inject a service into a component
@inject IAccountService _accountService;

MVC app example (Startup.cs):

First:

public void ConfigureServices(IServiceCollection services)
{
    ...
    
    services.AddFortniteApi();
}

then...

// Get a service through a constructor
private readonly IAccountService _accountService;

public ExampleClass(IAccountService accountService)
{
    _accountService = accountService;
}

.NET app example:

var services = new ServiceCollection()
    .AddFortniteDotNet()
    .BuildServiceProvider();

...

// Get a service
var accountService = services.GetService<IAccountService>();

Example

The rewrite is yet to be completed, so I have not provided an example yet. You can see tips on usage above.

I've commented the example code so you can have some sort of understanding of what it's doing. Please also note that this is just an example, and there's plenty more that you can do with FortniteDotNet.

// TODO

Contributions

If you wish to contribute to FortniteDotNet, you can do so by cloning this repository, making your changes, and submitting a pull request. If I deem the pull request inappropriate, I will deny it.

FortniteDotNet is not entirely finished, especially due to the lack of MCP commands, so any contributions are greatly appreciated. The code structure is organised so should be easy to understand, however if you struggle, please don't hesitate to get in touch.

Contact

For any queries regarding FortniteDotNet, you can open an issue or a pull request, and I will happily reply to the thread.

Product Compatible and additional computed target framework versions.
.NET net5.0 is compatible.  net5.0-windows was computed.  net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  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. 
.NET Core netcoreapp3.1 is compatible. 
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
2.0.3 604 5/10/2022