Add workflow and document APIs, middleware, and Swagger

Introduced `CloseWorkflowRequest` for closing workflows.
Added `DocumentsController` for document downloads and
`WorkflowsController` for workflow retrieval and closing.

Implemented `ExceptionHandlingMiddleware` for global exception
handling with structured API responses.

Enhanced Swagger configuration with metadata and production
support. Added `Scalar.AspNetCore` for API reference mapping.

Updated project dependencies and improved API documentation.
This commit is contained in:
2026-10-10 13:50:26 +02:00
parent b44be4f9e2
commit 3126f025be
6 changed files with 227 additions and 2 deletions

View File

@@ -0,0 +1,22 @@
namespace DigitalData.TaskFlow.API.Contracts.Workflows;
/// <summary>
/// Represents the request payload for closing a workflow.
/// </summary>
public sealed class CloseWorkflowRequest
{
/// <summary>
/// Gets or sets the selected closing method identifier.
/// </summary>
public required int ClosingMethodId { get; init; }
/// <summary>
/// Gets or sets an optional user comment.
/// </summary>
public string? Comment { get; init; }
/// <summary>
/// Gets or sets an optional rejection reason identifier.
/// </summary>
public int? RejectionReasonId { get; init; }
}