Udap.Metadata.Server 0.7.13

There is a newer version of this package available.
See the version list below for details.
dotnet add package Udap.Metadata.Server --version 0.7.13
                    
NuGet\Install-Package Udap.Metadata.Server -Version 0.7.13
                    
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="Udap.Metadata.Server" Version="0.7.13" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Udap.Metadata.Server" Version="0.7.13" />
                    
Directory.Packages.props
<PackageReference Include="Udap.Metadata.Server" />
                    
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 Udap.Metadata.Server --version 0.7.13
                    
#r "nuget: Udap.Metadata.Server, 0.7.13"
                    
#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 Udap.Metadata.Server@0.7.13
                    
#: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=Udap.Metadata.Server&version=0.7.13
                    
Install as a Cake Addin
#tool nuget:?package=Udap.Metadata.Server&version=0.7.13
                    
Install as a Cake Tool

Udap.Metadata.Server

UDAP logo

📦 Nuget Package: Udap.Metadata.Server

This package provides the .well-known/udap metadata endpoint for FHIR resource servers and other UDAP-secured APIs. It includes an extension method for service registration, middleware for dynamic metadata serving, and a built-in FileCertificateStore implementation of ICertificateStore.

For multi-domain metadata support (serving signed metadata for multiple domains within a single community), see Multi-Domain Metadata Support.

Quick Start

Program.cs can be as simple as:

using Udap.Metadata.Server;

var builder = WebApplication.CreateBuilder(args);
builder.Services
    .AddControllers()
    .AddUdapMetadataServer(builder.Configuration);

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

You can provide your own certificate store implementation:

builder.Services.AddSingleton<ICertificateStore, MyCustomCertificateStore>();

Setup

dotnet add package Udap.Metadata.Server

Add the AddUdapMetadataServer service extension and UseUdapMetadataServer middleware to Program.cs:

builder.Services
    .AddControllers()
    .AddUdapMetadataServer(builder.Configuration);

// ...

// Place before UseRouting() and UseAuthentication() so metadata
// requests are handled anonymously
app.UseUdapMetadataServer();
app.UseRouting();
app.UseAuthentication();
app.UseAuthorization();

By default, AddUdapMetadataServer registers UdapMetadataOptionsProvider which reads the metadata options file path from AppSettings:

"UdapMetadataOptionsFile": "udap.metadata.options.json"

udap.metadata.options.json:

{
  "UdapVersionsSupported": [ "1" ],
  "UdapProfilesSupported": [ "udap_dcr", "udap_authn", "udap_authz", "udap_to" ],
  "ScopesSupported": [ "openid", "system/*.read", "user/*.read", "patient/*.read" ],
  "UdapCertificationsSupported": [ "http://MyUdapCertification", "http://MyUdapCertification2" ],
  "UdapCertificationsRequired": [ "http://MyUdapCertification" ],
  "GrantTypesSupported": [ "authorization_code", "refresh_token", "client_credentials" ],

  "UdapMetadataConfigs": [
    {
      "Community": "http://localhost",
      "SignedMetadataConfig": {
        "AuthorizationEndpoint": "https://securedcontrols.net:5001/connect/authorize",
        "TokenEndpoint": "https://securedcontrols.net:5001/connect/token",
        "RegistrationEndpoint": "https://securedcontrols.net:5001/connect/register"
      }
    }
  ]
}

UDAP Metadata Options

See Required UDAP Metadata.

The UdapMetadataOptions class defines the configurable properties:

  • UdapVersionsSupported: Array of supported UDAP versions (e.g., ["1"])
  • UdapProfilesSupported: Array of supported UDAP profiles (e.g., ["udap_dcr", "udap_authn"])
  • UdapAuthorizationExtensionsSupported: Array of supported authorization extensions (e.g., ["hl7-b2b", "tefca-ias"])
  • UdapAuthorizationExtensionsRequired: Array of required authorization extensions
  • UdapCertificationsSupported: Array of supported certifications
  • UdapCertificationsRequired: Array of required certifications
  • GrantTypesSupported: Array of supported OAuth2 grant types
  • ScopesSupported: Array of supported scopes
  • TokenEndpointAuthSigningAlgValuesSupported: Array of supported signing algorithms for the token endpoint
  • RegistrationEndpointJwtSigningAlgValuesSupported: Array of supported signing algorithms for the registration endpoint
  • UdapMetadataConfigs: Array of community-specific metadata configurations
  • CertificateResolveTimeoutSeconds: Timeout in seconds for certificate resolution (default: 10)

Extending Metadata

Any extra properties in your udap.metadata.options.json file not listed above will be loaded and made available in the published metadata via the ExtensionData dictionary.

Certificate Store

To serve UDAP metadata, certificates are loaded through an implementation of ICertificateStore. Below is the built-in file-based implementation:

builder.Services.Configure<UdapFileCertStoreManifest>(builder.Configuration.GetSection("UdapFileCertStoreManifest"));
builder.Services.AddSingleton<ICertificateStore, FileCertificateStore>();

Configure certificate paths in appsettings.json. The community name links UdapMetadataConfigs to UdapFileCertStoreManifest. Community names are constrained as a URI.

"UdapFileCertStoreManifest": {
  "Communities": [
    {
      "Name": "http://localhost",
      "IssuedCerts": [
        {
          "FilePath": "CertStore/issued/weatherApiClientLocalhostCert.pfx",
          "Password": "udap-test"
        }
      ]
    }
  ]
}

Examples


  • FHIR® is the registered trademark of HL7 and is used with the permission of HL7. Use of the FHIR trademark does not constitute endorsement of the contents of this repository by HL7.
  • UDAP® and the UDAP gear logo, ecosystem gears, and green lock designs are trademarks of UDAP.org.
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 is compatible.  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 Udap.Metadata.Server:

Package Downloads
Udap.Metadata.Vonk.Server

Package Description

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.8.0 0 5/15/2026
0.7.13 0 5/15/2026
0.7.12 265 4/1/2026
0.7.11 100 3/31/2026
0.7.10 99 3/31/2026
0.7.9 109 3/31/2026
0.7.8 104 3/30/2026
0.7.7 103 3/30/2026
0.7.6 99 3/30/2026
0.7.5 105 3/30/2026
0.7.4 101 3/29/2026
0.7.3 105 3/29/2026
0.7.2 112 3/28/2026
0.7.1 100 3/23/2026
0.7.0 102 3/22/2026
0.6.16 105 3/22/2026
0.6.14 121 3/16/2026
0.6.13 104 3/15/2026
0.6.12 109 3/14/2026
0.6.11 106 3/14/2026
Loading failed