OptimaJet.Workflow.Api.RealTimeTrackingPlugin
23.0.0
dotnet add package OptimaJet.Workflow.Api.RealTimeTrackingPlugin --version 23.0.0
NuGet\Install-Package OptimaJet.Workflow.Api.RealTimeTrackingPlugin -Version 23.0.0
<PackageReference Include="OptimaJet.Workflow.Api.RealTimeTrackingPlugin" Version="23.0.0" />
<PackageVersion Include="OptimaJet.Workflow.Api.RealTimeTrackingPlugin" Version="23.0.0" />
<PackageReference Include="OptimaJet.Workflow.Api.RealTimeTrackingPlugin" />
paket add OptimaJet.Workflow.Api.RealTimeTrackingPlugin --version 23.0.0
#r "nuget: OptimaJet.Workflow.Api.RealTimeTrackingPlugin, 23.0.0"
#:package OptimaJet.Workflow.Api.RealTimeTrackingPlugin@23.0.0
#addin nuget:?package=OptimaJet.Workflow.Api.RealTimeTrackingPlugin&version=23.0.0
#tool nuget:?package=OptimaJet.Workflow.Api.RealTimeTrackingPlugin&version=23.0.0
OptimaJet.Workflow.Api.RealTimeTrackingPlugin
OptimaJet.Workflow.Api.RealTimeTrackingPlugin adds tenant-aware real-time process tracking to the HTTP API for Workflow Engine by Optimajet. The package registers a SignalR hub and attaches the tracking plugin to API-created runtime instances.
Install
Install this package and one HTTP API database provider. SQLite provides an evaluation setup and is not recommended for production:
dotnet add package OptimaJet.Workflow.Api.RealTimeTrackingPlugin
dotnet add package OptimaJet.Workflow.Api.Sqlite
dotnet add package Microsoft.AspNetCore.Authentication.JwtBearer
Register real-time tracking
For this JWT example, use a JwtBearer package version matching your target .NET version.
Configure Authentication:Authority and Authentication:Audience for your JWT issuer, and WorkflowApi:LicenseKey for your application.
The issuer must include the existing WorkflowApiPermissions claim in access tokens. The example uses the default single tenant.
using Microsoft.AspNetCore.Authentication.JwtBearer;
using OptimaJet.Workflow.Api;
using OptimaJet.Workflow.Api.Configuration;
using OptimaJet.Workflow.Api.RealTimeTrackingPlugin;
using OptimaJet.Workflow.Api.Sqlite;
using OptimaJet.Workflow.Core.Runtime;
var builder = WebApplication.CreateBuilder(args);
builder.Services.AddAuthentication(JwtBearerDefaults.AuthenticationScheme)
.AddJwtBearer(options =>
{
options.Authority = builder.Configuration["Authentication:Authority"];
options.Audience = builder.Configuration["Authentication:Audience"];
options.Events.OnMessageReceived = context =>
{
var operation = context.HttpContext.GetEndpoint()?.Metadata
.GetMetadata<HubOperation>();
var tokens = context.Request.Query["access_token"];
if (operation?.Id == RealTimeTrackingApiOperationId.RealTimeTracking &&
!context.Request.Headers.ContainsKey("Authorization") &&
tokens.Count == 1 && !String.IsNullOrEmpty(tokens[0]))
{
context.Token = tokens[0];
}
return Task.CompletedTask;
};
});
builder.Services.AddAuthorization();
builder.Services.AddWorkflowApiCore(options =>
{
options.LicenseKey = builder.Configuration["WorkflowApi:LicenseKey"] ?? String.Empty;
});
builder.Services.AddWorkflowApiSecurity();
builder.Services.AddWorkflowApiSqlite();
builder.Services.AddWorkflowRuntime(options =>
{
options.ConnectionString = "Data Source=workflow.db";
options.WorkflowRuntimeCreationOptions.ConfigureWorkflowRuntime =
runtime => runtime.AsSingleServer();
});
builder.Services.AddRealTimeTrackingPlugin();
var app = builder.Build();
app.UseRouting();
app.UseAuthentication();
app.UseAuthorization();
app.MapWorkflowApi();
app.Run();
MapWorkflowApi() publishes the hub at /workflow-api/realtime-tracking with the default BasePath.
If you change BasePath, update the client URL too. Grant callers permission for workflow-api.realtime-tracking.
In multi-tenant mode, also grant access to their tenant.
Register AddRealTimeTrackingPlugin() once per host. It adds tracking to each runtime created by the API;
do not add the core tracking plugin separately. The default setup does not require the ApiConfigurator license feature.
Connect the Designer
Set the Designer's realTimeTrackingUrl to the mapped hub URL and load a process.
The Designer manages the connection, subscriptions and state updates; your application does not need to call the hub directly.
The plugin uses the authentication configured by your host. The JWT handler above accepts query tokens for the tracking hub; if your host already handles JWT events, add this check to that handler.
In multi-tenant mode, append ?workflowApiTenantId=TenantA to both the Designer API URL and the tracking hub URL.
Clients that can send custom headers may use Workflow-Api-Tenant-ID instead. If both are supplied, their values must match exactly.
When neither is supplied, the configured default tenant applies. Selecting a tenant does not grant permission to access it.
Dependencies and requirements
- .NET 8 or .NET 10 with an ASP.NET Core host.
- Direct dependencies:
OptimaJet.Workflow.ApiandWorkflowEngine.NETCore-RealTimeTrackingPlugin. - An HTTP API database provider and configured runtimes or tenants.
- Authentication and authorization configured in the host. JWT bearer and cookies are both supported.
- CORS configured in the host when the browser client uses a different origin.
Documentation
License and support
This package is part of Workflow Engine and is governed by the Workflow Engine EULA. Existing HTTP API feature licensing applies. Host-side API configurator overrides require the ApiConfigurator feature.
Contact support@optimajet.com or open an issue.
| Product | Versions 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. |
-
net10.0
- OptimaJet.Workflow.Api (>= 23.0.0)
- WorkflowEngine.NETCore-RealTimeTrackingPlugin (>= 23.0.0)
-
net8.0
- OptimaJet.Workflow.Api (>= 23.0.0)
- WorkflowEngine.NETCore-RealTimeTrackingPlugin (>= 23.0.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 23.0.0 | 0 | 10/27/2026 |