Goldpath.ApiDefaults 0.1.0-preview.8

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

Goldpath.ApiDefaults

API surface conventions of the Goldpath golden path: URL-segment versioning, the keyset cursor-pagination primitive, JSON wire defaults, and deterministic OpenAPI export (net10).

Getting started

builder.AddGoldpathApiDefaults();

var app = builder.Build();
var api = app.MapGoldpathApi();            // /api/v1/... — versioned root group
api.MapGet("/orders", ...);           // → GET /api/v1/orders
api.MapMediantEndpoints();            // Mediant [HttpEndpoint] commands/queries attach here

Configuration

Deliberately minimal — the conventions ARE the configuration. Page size bounds are constants of the wire contract (PageRequest.DefaultSize = 50, MaxSize = 200).

Advanced

Cursor pagination (executor ships with Goldpath.Data; the contract lives here):

api.MapGet("/orders", async (string? cursor, int size, OrdersDb db) =>
{
    var request = new PageRequest(cursor, size);
    // Goldpath.Data: keyset ToPageAsync reads/writes GoldpathCursor — no Skip/Take, ever.
    Page<OrderDto> page = await db.Orders.OrderBy(...).ToPageAsync(request);
    return page;                       // { "items": [...], "nextCursor": "…", "size": 50 }
});
  • Cursors are opaque: base64url keyset payloads; a tampered cursor fails GoldpathCursor.TryDecode → return 400. No total count by design (RFC D2) — expose an explicit aggregate endpoint if a consumer truly needs one.
  • JSON wire: camelCase, enums as strings, nulls not written.
  • OpenAPI: interactive endpoint in Development only; CI consumes the build-time export as the Spec Engine drift input (net10 targets only — net8 consumers keep their setup).

Providers

Not applicable.

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 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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Goldpath.ApiDefaults:

Package Downloads
Goldpath.Data

Data-path floor of the Goldpath enterprise asset: keyset cursor-pagination executor, the save-contributor seam for Ring B modules, and model conventions (UTC temporal policy, precision/length defaults, TenantId conversion). Provider-neutral on EF Core Relational.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.1.0-preview.8 170 9/7/2026
0.1.0-preview.7 137 9/1/2026
0.1.0-preview.6 416 8/4/2026
0.1.0-preview.5 123 7/28/2026
0.1.0-preview.4 117 7/27/2026
0.1.0-preview.3 101 7/25/2026
0.1.0-preview.2 110 7/13/2026
0.1.0-preview.1 279 7/13/2026