Aydsko.iRacingData 2601.3.0

dotnet add package Aydsko.iRacingData --version 2601.3.0
                    
NuGet\Install-Package Aydsko.iRacingData -Version 2601.3.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="Aydsko.iRacingData" Version="2601.3.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Aydsko.iRacingData" Version="2601.3.0" />
                    
Directory.Packages.props
<PackageReference Include="Aydsko.iRacingData" />
                    
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 Aydsko.iRacingData --version 2601.3.0
                    
#r "nuget: Aydsko.iRacingData, 2601.3.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 Aydsko.iRacingData@2601.3.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=Aydsko.iRacingData&version=2601.3.0
                    
Install as a Cake Addin
#tool nuget:?package=Aydsko.iRacingData&version=2601.3.0
                    
Install as a Cake Tool

Aydsko iRacing Data API

iRacing is the leading online racing simulation for PC. During events hosted via the iRacing service there is a large amount of data created related to race results and member participation in events.

This library allows access via .NET to the iRacing "Data API". These APIs allow a properly authenticated user a supported method of accessing data from the service.

Authentication Types

Legacy Authentication (Username / Password)

This authentication is no longer supported. Legacy authentication was removed 9 Dec 2025. See: https://forums.iracing.com/discussion/84226/legacy-authentication-removal-dec-9-2025

One of the OAuth-based authentication methods is now required.

iRacing OAuth Authentication

To use this authentication method you need to contact iRacing who will allocate a "Client ID" and "Client Secret".

  • "Authorization Code Flow" is intended for interactive applications, either client apps or web-based apps. It allows users to authenticate with iRacing.
  • "Password Limited Flow" is authentication intended for scripts or back-end processes that do not need to access the details of specific users.

Full information is available from the iRacing.com Auth Service Documentation.

Getting Started

1. Install the Aydsko iRacing Data API library.

The library is distributed as the Aydsko.iRacingData NuGet package. Install using your package manager of choice.

dotnet add package Aydsko.iRacingData

2. Register the client.

Register the iRacing Data API client classes with the service provider.

Using iRacing OAuth "Authentication Code Grant" authentication:


public class MyTokenSource : IOAuthTokenSource
{
    public async Task<OAuthTokenValue> GetTokenAsync(CancellationToken cancellationToken = default)
    {
        // TODO - Implement retrieval of the iRacing authentication token
        //        via the "/authorize" and "/token" endpoints or retrieve
        //        a previous token from secure storage.
    }
}

services.AddIRacingDataApi(options =>
{
    options.UseProductUserAgent("MyApplicationName", new Version(1, 0));

    // Supply the "IOAuthTokenSource" implementation.
    options.UseOAuthTokenSource(sp => sp.GetRequiredService<MyTokenSource>());
});

OR

Using iRacing OAuth "Password Limited Grant" authentication:

services.AddIRacingDataApi(options =>
{
    options.UseProductUserAgent("MyApplicationName", new Version(1, 0));

    // Supply your iRacing username, password, client id, and client secret.
    options.UsePasswordLimitedOAuth(iRacingUsername, iRacingPassword, iRacingClientId, iRacingClientSecret);
});

3. Use the client.

Use the IDataClient from the service provider to authenticate and request data.

// Retrieve an instance from the service provider.
var dataClient = serviceProvider.GetRequiredService<IDataClient>();

// Retrieve information about our own account.
var infoResponse = await dataClient.GetMyInfoAsync(cancellationToken);

// Write that information to the console.
Console.WriteLine($"Driver name: {infoResponse.Data.DisplayName}");
Console.WriteLine($"Customer ID: {infoResponse.Data.CustomerId}");
Console.WriteLine($"Club: {infoResponse.Data.ClubName}");

Enable Caching of Results

1. Add the Microsoft memory caching package.

dotnet add package Microsoft.Extensions.Caching.Memory

2. Register the memory caching library with the service provider.

services.AddMemoryCache();

3. Register the caching client.

Register the iRacing Data API caching client classes with the service provider.

services.AddIRacingDataApiWithCaching(options =>
{
    // [... normal configuration for your chosen authentication type here]
});

Then simply use the IDataClient as before.

Versioning

Ideally you should always use the latest version of the library that is available. This is because iRacing will sometimes introduce API changes during a release which make the old code incompatible.

This library will use version numbers will be in the format:

[YY][SS].[R]

Where:

  • YY = two digit year
  • SS = the iRacing season the library release was made in as a zero-padded number (i.e. 01, 02, 03, 04)
  • R = release number, which increments when changes are made although it may not be sequential

Example:

  • 2303.1 = changes compatible with iRacing 2023 Season 3 or later, and is release 1 during this season
Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  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 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. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos 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
2601.3.0 1,113 1/28/2026
2601.2.1 123 1/27/2026
2601.1.0 216 1/1/2026
2601.0.0 204 12/31/2025
2504.1.0-beta 187 10/5/2025
2504.0.1 726 9/24/2025
2504.0.0 233 9/24/2025
2502.0.0 729 3/30/2025
2501.0.0 521 12/14/2024
2404.5.0 1,261 11/9/2024
2404.5.0-beta 257 11/2/2024
2404.4.0 440 10/15/2024
2404.3.0 217 10/10/2024
2404.2.1 217 9/29/2024
2404.2.0 190 9/29/2024
2404.0.0 343 9/9/2024
2403.3.0 282 9/3/2024
2403.2.0 362 8/4/2024
2403.1.0 322 7/2/2024
2403.0.0 307 6/13/2024
Loading failed

============================
Release Notes for 2601.3.0
============================

FIXES / NEW IMPLEMENTATIONS:
- "/data/results/get" handler is missing flair properties (Issue #257)
   Thanks to Kevin Verbruggen (https://github.com/KVerbruggen) for contributing this item.
- Implement "Flair" fields in various places (SeasonTimeTrialResult, SeasonTimeTrialStandings, MemberProfileInfo, Result)

============================
Release Notes for 2601.2.1
============================

FIXES / NEW IMPLEMENTATIONS:
- Implement Current Season Lookup (Issue #255)

============================
Release Notes for 2601.1.0
============================

FIXES / NEW IMPLEMENTATIONS:
- Changed detection order so the internal "Password Limited Grant" implementation doesn't override a "UseOAuthTokenSource(...)" call when both "ClientId" and "ClientSecret" are defined on the options.

============================
Release Notes for 2601.0.0
============================

BREAKING CHANGES:
- Username & password authentication has been removed. OAuth authentication using "Authorization Code Grant" or "Password Limited Grant" now required (see https://forums.iracing.com/discussion/84226/legacy-authentication-removal-dec-9-2025).
- "IDataClient.GetMemberChartData" method was removed. Use "IDataClient.GetMemberChartDataAsync" instead.
- The "TrackScreenshotService" class has been removed. Use "IDataClient.GetTrackAssetScreenshotUris\" or "IDataClient.GetTrackAssetScreenshotUrisAsync" instead.
- The "AddIRacingDataApi(IServiceCollection)" extension method has been removed. Use "AddIRacingDataApi(IServiceCollection, Action<iRacingDataClientOptions>)" and use the callback to configure the client options.
- The "AddIRacingDataApiWithCaching(IServiceCollection)" extension method has been removed. Use "AddIRacingDataApiWithCaching(IServiceCollection, Action<iRacingDataClientOptions>)" and use the callback to configure the client options.



NEW FEATURE: iRacing OAuth "Authorization Code Grant" Authentication
- Allows authentication using the "/authorize" endpoint via a callback.
- Implement the "IOAuthTokenSource" interface then configure via "iRacingDataClientOptions.UseOAuthTokenSource(...)" method.
- This authentication, or "Password Limited Grant", is now required (see https://forums.iracing.com/discussion/84226/legacy-authentication-removal-dec-9-2025).
- See https://oauth.iracing.com/oauth2/book/token_endpoint.html#authorization-code-grant for more information.



FIXES / NEW IMPLEMENTATIONS:
- Implement "/data/session/reg_drivers_list" to retrieve drivers registered for an active session. (Issue #248)
- Add ability to change iRacing "Data API" base URL (e.g. if you have access to one of iRacing's test environments) via the "ApiBaseUrl" property. (Issue #243)
- Implement the "/data/series/season_list" and "/data/series/season_schedule" endpoints. (Issue #239)