Cirreum.Contracts
5.0.0
dotnet add package Cirreum.Contracts --version 5.0.0
NuGet\Install-Package Cirreum.Contracts -Version 5.0.0
<PackageReference Include="Cirreum.Contracts" Version="5.0.0" />
<PackageVersion Include="Cirreum.Contracts" Version="5.0.0" />
<PackageReference Include="Cirreum.Contracts" />
paket add Cirreum.Contracts --version 5.0.0
#r "nuget: Cirreum.Contracts, 5.0.0"
#:package Cirreum.Contracts@5.0.0
#addin nuget:?package=Cirreum.Contracts&version=5.0.0
#tool nuget:?package=Cirreum.Contracts&version=5.0.0
Cirreum.Contracts
The abstractions and vocabulary every Cirreum application programs against.
Overview
Cirreum.Contracts is the contract layer of the Cirreum framework — the cross-host abstractions, vocabulary, and value types a Cirreum application programs against.
Cirreum.Contracts defines:
- Conductor — the CQRS surface —
IDispatcher,IPublisher,IOperation/IOperationHandler,IIntercept, the intercept contracts (HandlerPerformance, QueryCaching, Validation), builders, and settings. (Concretes —Dispatcher,Publisher, the pipeline — ship inCirreum.Domain.) - Caching —
ICacheService(get-or-create + tag-based invalidation),CacheProvider,CacheSettings,CacheExpirationSettings - State — cross-host state abstractions (
IStateContainer,IStateManager,IStatePersistence,IScopedNotificationState,ISessionState, …) and theNotificationshape - Presence —
IUserPresenceService,IUserPresenceMonitor,UserPresence,PresenceStatus - Profile Enrichment —
IUserProfileEnrichmentBuilder,IGraphEnabledBuilder,IExternalGraphEnabledBuilder— the host-agnostic builder seam any host (server, Blazor WebAssembly, …) uses to configure post-authentication profile enrichment, independent of which (or whether any) auth scheme is active; default enricher implementations ship inCirreum.Domain - RemoteServices — the caller-side surface, in two halves. Request/response:
RemoteServiceOptions,AuthorizationHeaderSettings(theRemoteClientbase ships inCirreum.Domain). Long-lived bidirectional, in theConnectionssub-namespace:IRemoteConnection,RemoteConnectionState,RemoteConnectionStateChangedEventArgs,RemoteConnectionOptions,IRemoteConnectionFactory<TConnection>for per-session connections, andIRemoteConnectionCredentialSource— the ambient credential seam a host runtime implements so transport packages stay host-neutral, resolved with aRemoteConnectionTokenRequestdescribing the connection. A service is something you call; a connection is something you hold open, so it nests - FileSystem + CSV —
IFileSystem,ICsvFileBuilder/ICsvFileReader,CsvOptions,PathType - Invocation — the
HttpContext-free invocation seam (IInvocationContext,IInvocationContextAccessor,IInvocationConnection,IInvocationConnectionRegistry,IConnectionLifecycle,IConnectionEstablishmentContributor,DisconnectInfo, andInvocationConnectionMetadata— the endpoint marker declaring that an endpoint's invocations arrive over anIInvocationConnection, which the server spine stamps on the connection endpoints it maps).IInvocationConnectioncarries the connection-ownership surface — the immutable upgrade-timeUserplusEffectiveUser/IsUserPromoted, which reflect Two-Phase Auth promotion so every consumer agrees on who owns a connection now.IInvocationContextcarries the matching authentication read surface —AuthenticatedScheme/OriginScheme/EffectiveScheme, mirroringUser/PromotedUser/EffectiveUser— so every consumer also agrees on which scheme's declarations govern the current subject - Authorization pillar — the vocabulary (
AuthorizationPolicies,ApplicationRoles,Role,PermissionSet,DenyCodes,AuthorizationContext) and the cross-host contracts (IAuthorizer,IAuthorizationContextAccessor, the operation / grant / resource-ACL abstractions,[RequiresGrant]); default implementations and FluentValidation validators live inCirreum.Domain.AuthorizationTelemetrypublishes the pipeline's sharedActivitySourceandMeteralongside the stage / step / tag vocabulary every evaluator reports against, so a denial reads the same whichever layer produced it
Concerns with their own dedicated tracks (Messaging, Storage) live in their own packages and do NOT fold into Cirreum.Contracts. The Authentication event surface lives in Cirreum.Kernel.
Where it fits
Cirreum.Contracts is L2 — the contract surface. It builds on Cirreum.Kernel (L1) and references the foundation peer Cirreum.Result as needed; it takes no other Cirreum dependency. It is a pure-contracts package: the default implementation of everything declared here ships one layer up, in Cirreum.Domain, along with the richer dependency tree (FluentValidation, Microsoft.Extensions.Caching.Memory, …) the concretes require.
Contribution Guidelines
Be conservative with new abstractions
The API surface must remain stable and meaningful — Contracts is what every Cirreum app programs against; changes ripple through the entire ecosystem.Limit dependency expansion
Only add foundational, version-stable dependencies. Contracts is a pure-abstractions package — concrete dependencies belong inCirreum.Domain.Favor additive, non-breaking changes
Breaking changes in the contract surface cascade through every dependent package and every Cirreum app. Major version bumps are rare.Include thorough unit tests
All contracts and patterns should be independently testable.Document architectural decisions
Context and reasoning should be clear for future maintainers.Follow .NET conventions
Use established patterns fromMicrosoft.Extensions.*libraries.
Versioning
Cirreum.Contracts follows Semantic Versioning:
- Major — Breaking API changes
- Minor — New features, backward compatible
- Patch — Bug fixes, backward compatible
Given its foundational role, major version bumps are rare and carefully considered.
License
This project is licensed under the MIT License — see the LICENSE file for details.
Cirreum Foundation Framework
Layered simplicity for modern .NET
| 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
- Cirreum.Kernel (>= 2.2.0)
- Cirreum.Result (>= 2.0.0)
- CsvHelper (>= 33.1.0)
NuGet packages (3)
Showing the top 3 NuGet packages that depend on Cirreum.Contracts:
| Package | Downloads |
|---|---|
|
Cirreum.Services.Server
Service library for Cirreum ASP.NET servers. Absorbs the per-source Invocation packages (HTTP, WebSocket, SignalR) so a single package owns the framework's server-side invocation surface, including the per-server connection registry and the auth-event connection terminator (revocation / forced sign-out aborts a subject's live long-lived connections). |
|
|
Cirreum.Domain
The default implementation of Cirreum's domain-centric application model — the runtime-agnostic engine behind the contracts in Cirreum.Contracts. Provides the Conductor (Dispatcher, Publisher, intercepts, builders), the Authorization pillar's evaluators / grant cache / role scanner / FluentValidation validators, the cache services, State, Presence, Profile Enrichment, RemoteServices, and FileSystem implementations, plus the AddDomainServices registration. The cross-host triad: Cirreum.Kernel (primitives) → Cirreum.Contracts (contracts) → Cirreum.Domain (implementation). |
|
|
Cirreum.AuthenticationProvider
Authentication track abstractions for the Cirreum framework (three-pillar separation and composition surface). Defines the contracts scheme packages (ApiKey, SignedRequest, SessionTicket) implement: ISchemeSelector + SchemeCategory, CredentialTransport, ISignedRequestAlgorithm + resolver, SessionTicket primitives, IAuthenticationBoundaryResolver, IAuthenticationBuilder (whose DeclareScheme / AddScheme pair scheme registration with its claim-authority declaration). Pure abstractions plus a default impl (DefaultAuthenticationBoundaryResolver) that ships with the contracts. Host-agnostic profile enrichment (IUserProfileEnrichmentBuilder, ClaimsUserProfileEnricher) lives in Cirreum.Contracts/Cirreum.Domain, not here. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 5.0.0 | 87 | 8/25/2026 |
| 4.7.0 | 335 | 8/24/2026 |
| 4.6.0 | 74 | 8/24/2026 |
| 4.5.1 | 454 | 8/20/2026 |
| 4.5.0 | 311 | 8/18/2026 |
| 4.4.0 | 87 | 8/18/2026 |
| 4.3.0 | 306 | 8/17/2026 |
| 4.2.2 | 113 | 8/17/2026 |
| 4.2.1 | 109 | 8/17/2026 |
| 4.2.0 | 489 | 8/4/2026 |
| 4.1.0 | 133 | 8/3/2026 |
| 4.0.1 | 469 | 7/31/2026 |
| 4.0.0 | 123 | 7/31/2026 |
| 3.0.0 | 356 | 7/31/2026 |
| 2.0.1 | 112 | 7/30/2026 |
| 2.0.0 | 775 | 7/26/2026 |
| 1.4.5 | 486 | 7/24/2026 |
| 1.4.4 | 709 | 7/20/2026 |
| 1.4.3 | 1,009 | 7/7/2026 |
| 1.4.2 | 248 | 7/6/2026 |