DCH.IntakeAgentCore
2.1.1
dotnet add package DCH.IntakeAgentCore --version 2.1.1
NuGet\Install-Package DCH.IntakeAgentCore -Version 2.1.1
<PackageReference Include="DCH.IntakeAgentCore" Version="2.1.1" />
<PackageVersion Include="DCH.IntakeAgentCore" Version="2.1.1" />
<PackageReference Include="DCH.IntakeAgentCore" />
paket add DCH.IntakeAgentCore --version 2.1.1
#r "nuget: DCH.IntakeAgentCore, 2.1.1"
#:package DCH.IntakeAgentCore@2.1.1
#addin nuget:?package=DCH.IntakeAgentCore&version=2.1.1
#tool nuget:?package=DCH.IntakeAgentCore&version=2.1.1
Intake Agent Core
This package provides the core functionality for Intake Agents, offering the following key features:
- Implementation of the contract required by Data Context Hub
- Built-in admin functionality using a Blazor UI with Radzen components
- Keycloak integration for Single Sign-On (SSO) across a Data Context Hub instance
Environment Variables
Configuration is managed primarily through environment variables:
| Variable | Description | Default |
|---|---|---|
BASE_PATH |
The path where the intake agent will be hosted | / |
DCH_BASE_URL |
The base URL of the DCH instance (e.g., https://dch.example.com/) |
- |
DCH_KEYCLOAK_REALM |
The Keycloak realm used by the DCH instance | - |
DCH_KEYCLOAK_URL |
The Keycloak URL (e.g., https://dch.example.com/auth/) |
- |
OTEL_EXPORTER_OTLP_ENDPOINT |
OTLP endpoint (required when OpenTelemetry is activated) | - |
POSTGRES_HOST |
PostgreSQL host address | - |
POSTGRES_PORT |
PostgreSQL port number | - |
POSTGRES_USER |
PostgreSQL username | - |
POSTGRES_PASSWORD |
PostgreSQL password | - |
POSTGRES_DATABASE |
Database name used by this Intake Agent | - |
Usage
In your Program.cs add the following:
var configurator = new IntakeAgentCoreConfigurator(builder.Services, builder.Configuration)
{
AgentName = "Your Intake Agent",
ServiceName = "your-intake-agent",
Version = "0.1.0",
KeycloakClientId = "your-intake-agent"
};
configurator.AddPostgreSqlPersistence();
configurator.AddOpenTelemetry(builder);
configurator.ConfigureAdminUi(adminUiOptions =>
{
// If you want to add your own Blazor pages, reference your assembly and configure the left side menu here.
// Supported icons can be found here: https://fonts.google.com/icons?icon.set=Material+Symbols
adminUiOptions.AddAssembly(typeof(Program).Assembly);
adminUiOptions.AddConfidentialMenuItem("upload", "Upload", "./upload");
});
builder.Services.AddIntakeAgentCore(configurator);
Implementation
The core functionality is provided by the IDataProvider interface, which must be implemented by the Intake Agent.
| 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.AspNetCore.Authentication.JwtBearer (>= 10.0.1)
- Microsoft.AspNetCore.Authentication.OpenIdConnect (>= 10.0.1)
- Microsoft.AspNetCore.OpenApi (>= 10.0.1)
- Microsoft.Extensions.Http.Resilience (>= 10.1.0)
- Npgsql (>= 10.0.1)
- OpenTelemetry.Exporter.OpenTelemetryProtocol (>= 1.14.0)
- OpenTelemetry.Extensions.Hosting (>= 1.14.0)
- OpenTelemetry.Instrumentation.AspNetCore (>= 1.14.0)
- Radzen.Blazor (>= 8.5.1)
- Swashbuckle.AspNetCore (>= 10.1.0)
- Swashbuckle.AspNetCore.Swagger (>= 10.1.0)
- Swashbuckle.AspNetCore.SwaggerUI (>= 10.1.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
# Changelog (Release Notes)
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html) (SemVer).
## [Unreleased]
### Added
### Changed
### Fixed
## [2.1.1]
### Changed
- ToAlias in AliasUtil now uses Hyphens ("-") instead of Underscores ("_")
## [2.1.0]
### Added
- GetQueueJobDetails added to the GBS API contract
## [2.0.0]
### Changed
- Updated to dotnet10
## [1.2.0]
### Added
- Logic to suggest a unique Alias value
## [1.1.0]
### Added
- UpdateTargetEntity added to the GBS API contract
## [1.0.0]
### Added
- Full implementation of the GBS API contract enabling agent registration and data submission
- PostgreSQL database integration for secure storage of agent-specific data
- Policy-based authentication system protecting all API endpoints
- Intuitive Admin UI with support for custom pages and single sign-on via Keycloak integration
- Comprehensive development utilities to streamline agent creation and deployment