TCIS.Http.RestEase 1.0.0-rc.9

This is a prerelease version of TCIS.Http.RestEase.
dotnet add package TCIS.Http.RestEase --version 1.0.0-rc.9
                    
NuGet\Install-Package TCIS.Http.RestEase -Version 1.0.0-rc.9
                    
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="TCIS.Http.RestEase" Version="1.0.0-rc.9" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="TCIS.Http.RestEase" Version="1.0.0-rc.9" />
                    
Directory.Packages.props
<PackageReference Include="TCIS.Http.RestEase" />
                    
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 TCIS.Http.RestEase --version 1.0.0-rc.9
                    
#r "nuget: TCIS.Http.RestEase, 1.0.0-rc.9"
                    
#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 TCIS.Http.RestEase@1.0.0-rc.9
                    
#: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=TCIS.Http.RestEase&version=1.0.0-rc.9&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=TCIS.Http.RestEase&version=1.0.0-rc.9&prerelease
                    
Install as a Cake Tool

TCIS.Http.RestEase

Integrates the RestEase library with the TCIS infrastructure. It provides mechanisms to create HTTP Clients via Interfaces (Typed Clients) supporting automatic serialization of nested objects (Complex Query Params), integrates Polly Resilience, and offers secure Context management (separating internal and external calls).

📦 Installation

dotnet add package TCIS.Http.RestEase

🚀 Usage

1. Call Internal API (Program.cs)

Use AddTInternalRestEaseClient when you need to call another microservice within the same TCIS system. The library will automatically attach IWorkContext information (such as TenantId, CorrelationId, User info) to the HTTP Headers to propagate the execution flow context.

using TCIS.Http.RestEase.Extensions;

var builder = WebApplication.CreateBuilder(args);

// Register internal call (Includes Context Propagation and Polly Resilience)
builder.Services.AddTInternalRestEaseClient<IMyInternalService>("http://internal-service.local");

var app = builder.Build();
app.Run();

2. Call External Partner API (Program.cs)

Use AddTExternalRestEaseClient when calling 3rd-party APIs (Zalo, Momo, VNPay, etc.). This method DOES NOT attach Context Propagation to prevent leaking sensitive system information to the outside.

using TCIS.Http.RestEase.Extensions;

var builder = WebApplication.CreateBuilder(args);

// Register external call (Only includes Polly Resilience)
builder.Services.AddTExternalRestEaseClient<IExternalPaymentApi>("https://api.vnpay.vn", client => 
{
    // Additional configuration for API Key, Custom Headers for the partner
    client.DefaultRequestHeaders.Add("X-API-KEY", "your-secret-key");
});

var app = builder.Build();
app.Run();

⚙️ Core Components

  • AddTInternalRestEaseClient<TInterface>: Used for Service-To-Service communication. Integrates TQueryParamSerializer, Polly Resilience, and Context Propagation.
  • AddTExternalRestEaseClient<TInterface>: Used for communication with 3rd-parties. Integrates TQueryParamSerializer, Polly Resilience, and secures against context information leakage.
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.  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. 
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
1.0.0-rc.9 32 7/21/2026
1.0.0-rc.8 33 7/21/2026
1.0.0-rc.7 43 7/17/2026
1.0.0-rc.6 62 7/7/2026
1.0.0-rc.5 61 7/7/2026
1.0.0-rc.4 58 6/24/2026
1.0.0-rc.2 59 5/12/2026
1.0.0-rc.1 61 5/12/2026