Fix UI types to match actual backend API
All checks were successful
CI / build (push) Successful in 1m0s
CI / docker (push) Successful in 45s
CI / deploy (push) Successful in 29s

Validated against live OpenAPI spec at /api/v1/api-docs. Fixes:
- duration → durationMs (all models)
- Remove processorCount (not in ExecutionSummary)
- Remove ProcessorNode.index and .uri (not in backend)
- ProcessorSnapshot is Record<string,string>, not structured object
- Add missing fields: endTime, diagramContentHash, exchangeId, etc.
- Save openapi.json from live server

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
hsiegeln
2026-03-13 14:23:56 +01:00
parent 1dfe53abee
commit 6f415cb017
6 changed files with 1107 additions and 38 deletions

1071
ui/src/api/openapi.json Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -1,6 +1,6 @@
/**
* Hand-written OpenAPI types matching the cameleer3 server REST API.
* Will be replaced by openapi-typescript codegen once backend is running.
* Types matching the cameleer3 server REST API (validated against live OpenAPI spec).
* Generated from: GET /api/v1/api-docs
*/
export interface paths {
@@ -88,7 +88,7 @@ export interface paths {
responses: {
200: {
content: {
'application/json': ExchangeSnapshot;
'application/json': ProcessorSnapshot;
};
};
404: { content: { 'application/json': { message: string } } };
@@ -137,45 +137,46 @@ export interface ExecutionSummary {
executionId: string;
routeId: string;
agentId: string;
status: 'COMPLETED' | 'FAILED' | 'RUNNING';
status: string;
startTime: string;
duration: number;
processorCount: number;
endTime: string | null;
durationMs: number;
correlationId: string | null;
errorMessage: string | null;
diagramContentHash: string | null;
}
export interface ExecutionDetail {
executionId: string;
routeId: string;
agentId: string;
status: 'COMPLETED' | 'FAILED' | 'RUNNING';
status: string;
startTime: string;
duration: number;
endTime: string | null;
durationMs: number;
correlationId: string | null;
exchangeId: string | null;
errorMessage: string | null;
errorStackTrace: string | null;
diagramContentHash: string | null;
processors: ProcessorNode[];
}
export interface ProcessorNode {
index: number;
processorId: string;
processorType: string;
uri: string | null;
status: 'COMPLETED' | 'FAILED' | 'RUNNING';
duration: number;
status: string;
startTime: string;
endTime: string | null;
durationMs: number;
diagramNodeId: string | null;
errorMessage: string | null;
errorStackTrace: string | null;
children: ProcessorNode[];
}
export interface ExchangeSnapshot {
exchangeId: string;
correlationId: string | null;
bodyType: string | null;
body: string | null;
headers: Record<string, string> | null;
properties: Record<string, string> | null;
}
/** Processor snapshot is a flat key-value map (Map<String, String> in Java) */
export type ProcessorSnapshot = Record<string, string>;
export interface AgentInstance {
agentId: string;