Add OIDC logout, fix OpenAPI schema types, expose end_session_endpoint
All checks were successful
CI / build (push) Successful in 1m8s
CI / docker (push) Successful in 51s
CI / deploy (push) Successful in 29s

Backend:
- Expose end_session_endpoint from OIDC provider metadata in /auth/oidc/config
- Add getEndSessionEndpoint() to OidcTokenExchanger

Frontend:
- On OIDC logout, redirect to provider's end_session_endpoint to clear SSO session
- Strip /api/v1 prefix from OpenAPI paths to match client baseUrl convention
- Add schema-types.ts with convenience type re-exports from generated schema
- Fix all type imports to use schema-types instead of raw generated schema
- Fix optional field access (processors, children, duration) with proper typing
- Fix AgentInstance.state → status field name

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
hsiegeln
2026-03-14 14:43:18 +01:00
parent 0d82304cf0
commit 50bb22d6f6
15 changed files with 1755 additions and 53 deletions

View File

@@ -1,6 +1,12 @@
import { useQuery } from '@tanstack/react-query';
import { api } from '../client';
import type { SearchRequest } from '../schema';
import type {
SearchRequest,
ExecutionStats,
ExecutionSummary,
StatsTimeseries,
ExecutionDetail,
} from '../schema-types';
export function useExecutionStats(timeFrom: string | undefined, timeTo: string | undefined) {
return useQuery({
@@ -15,7 +21,7 @@ export function useExecutionStats(timeFrom: string | undefined, timeTo: string |
},
});
if (error) throw new Error('Failed to load stats');
return data!;
return data as unknown as ExecutionStats;
},
enabled: !!timeFrom,
placeholderData: (prev) => prev,
@@ -31,7 +37,7 @@ export function useSearchExecutions(filters: SearchRequest, live = false) {
body: filters,
});
if (error) throw new Error('Search failed');
return data!;
return data as unknown as { data: ExecutionSummary[]; total: number; offset: number; limit: number };
},
placeholderData: (prev) => prev,
refetchInterval: live ? 5_000 : false,
@@ -52,7 +58,7 @@ export function useStatsTimeseries(timeFrom: string | undefined, timeTo: string
},
});
if (error) throw new Error('Failed to load timeseries');
return data!;
return data as unknown as StatsTimeseries;
},
enabled: !!timeFrom,
placeholderData: (prev) => prev,
@@ -68,7 +74,7 @@ export function useExecutionDetail(executionId: string | null) {
params: { path: { executionId: executionId! } },
});
if (error) throw new Error('Failed to load execution detail');
return data!;
return data as unknown as ExecutionDetail;
},
enabled: !!executionId,
});
@@ -90,7 +96,7 @@ export function useProcessorSnapshot(
},
);
if (error) throw new Error('Failed to load snapshot');
return data!;
return data as unknown as Record<string, string>;
},
enabled: !!executionId && index !== null,
});