Soenneker.Attributes.PublicOpenApiObject
4.0.64
Prefix Reserved
dotnet add package Soenneker.Attributes.PublicOpenApiObject --version 4.0.64
NuGet\Install-Package Soenneker.Attributes.PublicOpenApiObject -Version 4.0.64
<PackageReference Include="Soenneker.Attributes.PublicOpenApiObject" Version="4.0.64" />
<PackageVersion Include="Soenneker.Attributes.PublicOpenApiObject" Version="4.0.64" />
<PackageReference Include="Soenneker.Attributes.PublicOpenApiObject" />
paket add Soenneker.Attributes.PublicOpenApiObject --version 4.0.64
#r "nuget: Soenneker.Attributes.PublicOpenApiObject, 4.0.64"
#:package Soenneker.Attributes.PublicOpenApiObject@4.0.64
#addin nuget:?package=Soenneker.Attributes.PublicOpenApiObject&version=4.0.64
#tool nuget:?package=Soenneker.Attributes.PublicOpenApiObject&version=4.0.64
Soenneker.Attributes.PublicOpenApiObject
A marker attribute for contract classes whose schemas are eligible for a public OpenAPI document.
Installation
dotnet add package Soenneker.Attributes.PublicOpenApiObject
Usage
using Soenneker.Attributes.PublicOpenApiObject;
[PublicOpenApiObject]
public sealed class PublicCustomer
{
public required string Id { get; init; }
public required string DisplayName { get; init; }
}
An OpenAPI schema or document filter can select marked types:
using System.Reflection;
bool include = typeof(PublicCustomer)
.IsDefined(typeof(PublicOpenApiObjectAttribute), inherit: true);
Important behavior
- The attribute targets classes. It cannot be applied directly to structs, enums, interfaces, or individual properties.
- Derived classes observe the marker through normal inherited attribute lookup.
- The package does not add, remove, or modify OpenAPI schemas on its own; a generator integration must read the marker.
- Marking a type does not prove that every property is safe to publish. Review the complete serialized schema before including it in a public document.
| 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
- No dependencies.
NuGet packages (25)
Showing the top 5 NuGet packages that depend on Soenneker.Attributes.PublicOpenApiObject:
| Package | Downloads |
|---|---|
|
Soenneker.Enums.UnitOfTime
An enumerator for describing an interval of time |
|
|
Soenneker.Dtos.ProblemDetails
A replication of .NET's ProblemDetails (https://tools.ietf.org/html/rfc7807) that doesn't rely on Microsoft.AspNetCore.Mvc. |
|
|
Soenneker.Enums.DayOfWeek
An enumerator for describing the day of the week (Mon, Tues, ..) |
|
|
Soenneker.Dtos.IdNamePair
A minimal Record type with an Id (string), Name (string), and maximum JSON compatibility |
|
|
Soenneker.Dtos.IdPartitionPair
A minimal Record type with an Id (string), PartitionKey (string), and maximum JSON compatibility |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 4.0.64 | 3,986 | 10/14/2026 |
| 4.0.63 | 2,506 | 10/14/2026 |
| 4.0.62 | 84 | 10/14/2026 |
| 4.0.58 | 2,604 | 10/12/2026 |
| 4.0.57 | 1,959 | 10/12/2026 |
| 4.0.56 | 9,160 | 10/11/2026 |
| 4.0.55 | 40,392 | 9/24/2026 |
| 4.0.54 | 15,674 | 9/15/2026 |
| 4.0.53 | 14,847 | 9/12/2026 |
| 4.0.52 | 47,946 | 8/29/2026 |
| 4.0.50 | 285 | 8/29/2026 |
| 4.0.49 | 26,675 | 8/18/2026 |
| 4.0.48 | 29,032 | 7/27/2026 |
| 4.0.47 | 25,231 | 7/16/2026 |
| 4.0.46 | 35,820 | 6/18/2026 |
| 4.0.45 | 32,386 | 6/5/2026 |
| 4.0.44 | 41,211 | 4/22/2026 |
| 4.0.42 | 37,793 | 3/12/2026 |
| 4.0.41 | 651 | 3/12/2026 |
| 4.0.40 | 681 | 3/12/2026 |
Update dependency dotnet-sdk to v10.0.402 (#494)
Automatically merged