MudraX.Blazor.OData 9.0.0.2

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

MudraX.Blazor.OData

Overview

MudraX.Blazor.OData is a library for interacting with OData APIs, providing robust support for CRUD operations and advanced query capabilities.

Features

  • Simplified OData client for .NET applications.
  • Support for CRUD operations and navigation properties.
  • JSON serialization and deserialization for seamless data handling.

Installation

To install the library, use the following NuGet command:

Install-Package MudraX.Blazor.OData

Prerequisites

  • Visual Studio 2022 with the following workloads installed:
    • ASP.NET and web development
  • .NET 9 SDK or later.

Blazor Server

appsettings.json

"ODataConnect": {
    "Setting1": {
      "Authority": "https://localhost:5001"
    }
  }

Program.cs

builder.Services.AddODataConnect(builder.Configuration);

MAUI

MauiProgram.cs

#if ANDROID
    ...
    builder.Services.AddODataConnect(() => new Dictionary<string, ODataConfig>
    {
        { "Setting1", new ODataConfig { Authority = "https://10.0.2.2:5001"} }
    },
    httpMessageHandler: HttpMessageHandler.GetMessageHandler);
#else
    ...
    builder.Services.AddODataConnect(() => new Dictionary<string, ODataConfig>
    {
        { "Setting1", new ODataConfig { Authority = "https://localhost:5001"} }
    });
#endif

Usage

[Inject] public required ODataClientProvider factory { get; set; }

var token = await SecureStorage.GetValueAsync(SecureStorageSchema.AccessToken);
if (!string.IsNullOrEmpty(token))
{
    oDataClient = factory.CreateClient("Setting1", token);
}

Refer to the ODataClient class for more methods and usage examples.

Product Compatible and additional computed target framework versions.
.NET net9.0 is compatible.  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
9.0.0.2 129 5/7/2025
9.0.0.1 125 5/6/2025