PouryaKit.Web
0.1.0-preview.2
dotnet add package PouryaKit.Web --version 0.1.0-preview.2
NuGet\Install-Package PouryaKit.Web -Version 0.1.0-preview.2
<PackageReference Include="PouryaKit.Web" Version="0.1.0-preview.2" />
<PackageVersion Include="PouryaKit.Web" Version="0.1.0-preview.2" />
<PackageReference Include="PouryaKit.Web" />
paket add PouryaKit.Web --version 0.1.0-preview.2
#r "nuget: PouryaKit.Web, 0.1.0-preview.2"
#:package PouryaKit.Web@0.1.0-preview.2
#addin nuget:?package=PouryaKit.Web&version=0.1.0-preview.2&prerelease
#tool nuget:?package=PouryaKit.Web&version=0.1.0-preview.2&prerelease

PouryaKit.Web
The Kit's HTTP boundary. Each Feature has its own endpoint, a small IEndpoint class beside its command or query, which a Module's Composition Root maps under its route prefix. The Kit authenticates each request and begins its Operation with an Operation Context built from the verified claims, and the endpoint turns the Result into a response with ToHttpResult().
Install
dotnet add package PouryaKit.Web --prerelease
When to use it
- You are writing an endpoint, or composing the Host's HTTP pipeline.
- You choose a response's shape, or bind page, sort and filter parameters from the query string.
- An endpoint must be public, or a repeatable write must require an idempotency key.
- You read the verified claims into the Operation Context, or call another Host with it.
- You configure CORS policies, response compression or the rate limit per Actor.
It pairs with PouryaKit.Security.JwtBearer for bearer tokens, PouryaKit.Web.OpenApi for versions and documents, and PouryaKit.Modularity for the Gateway its endpoints call.
Quick start
Compose the Host's pipeline:
builder.Services.AddPouryaKitWeb();
app.UseExceptionHandler();
app.UseRouting();
app.UseAuthentication();
app.UseAuthorization();
app.MapPouryaKitModuleEndpoints();
CORS and the rate limit each take a middleware of their own: UseCors between UseRouting and UseAuthentication, and UseRateLimiter after UseAuthorization. Compression needs no call.
Find the Module's endpoints in its Composition Root:
module.AddPouryaKitEndpoints("/inventory");
Map one endpoint per Feature, as the Proving Sample does:
internal sealed class GetStockItemEndpoint : IEndpoint
{
public void Map(IEndpointRouteBuilder routes) =>
routes.MapGet(
"/stock-items/{productId}",
async (
Guid productId,
OperationContext context,
IGatewayProcessor<InventoryModule> inventory,
CancellationToken cancellationToken
) =>
(
await inventory.QueryAsync(
new GetStockItemQuery(productId),
context,
cancellationToken
)
).ToHttpResult()
);
}
What you get
- Authenticated access by default: a public endpoint says so, and names the system Actor it runs as.
- One problem response for every failure, chosen by the Errors' kinds.
- An
OperationContextbuilt from the verified claims. - Outgoing HTTP that carries the Operation Context, with the standard retry for safe methods.
- A Page bound from the query string, and an idempotency key required on a repeatable write.
Every endpoint is authenticated unless it says otherwise, and a tenant-scoped Module maps no public endpoint, since an anonymous request has no tenant.
Learn more
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. 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. |
-
net10.0
- Microsoft.Extensions.Http.Resilience (>= 10.11.0)
- PouryaKit.Core (>= 0.1.0-preview.2)
- PouryaKit.Cqrs (>= 0.1.0-preview.2)
NuGet packages (4)
Showing the top 4 NuGet packages that depend on PouryaKit.Web:
| Package | Downloads |
|---|---|
|
PouryaKit.Reporting.Module
The Kit's report Module: report jobs generated in the background, stored through the Host's file storage and served to their requester by a time-limited link. |
|
|
PouryaKit.Web.OpenApi
API versions a Module declares, served by URL segment and by header, with a configured sunset, one ASP.NET Core OpenAPI document per version and the Scalar reference. |
|
|
PouryaKit.Grpc
gRPC services and clients on the Kit's Web conventions: each call runs through a Module's Gateway, and a failed Result answers a gRPC status with every Error in a trailer. |
|
|
PouryaKit.Realtime
Server-sent events pushed from Notification Handlers, carried between a Host's instances by PostgreSQL notifications, only within the delivery's tenant. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.1.0-preview.2 | 85 | 11/1/2026 |
| 0.1.0-preview.1 | 84 | 10/31/2026 |
| 0.1.0-preview.0.28 | 94 | 10/26/2026 |