import type { ConfigSchemaDescriptor } from "../contracts/config.js"; import { type ServiceConfigAction, type ServiceConfigManagementMode, type ServiceConfigState, type ServiceConfigTicketClaims } from "../contracts/serviceConfig.js"; import { type BetterPortalEvent, type BetterPortalH3App } from "./h3.js"; export interface ServiceConfigAccessContext { ticket: ServiceConfigTicketClaims; action: ServiceConfigAction; } export interface ServiceConfigRouteOptions { app: BetterPortalH3App; serviceId: string; configSchemas: ConfigSchemaDescriptor[]; mode: ServiceConfigManagementMode; supportsCustomUi?: boolean; customUiPath?: string; basePath?: string; validateTicket?: (ticketValue: string | null, event: BetterPortalEvent, action: ServiceConfigAction) => Promise | ServiceConfigTicketClaims | null; validateScope?: (scope: { tenantId: string; appId?: string; action: ServiceConfigAction; ticket: ServiceConfigTicketClaims; }, event: BetterPortalEvent) => Promise | boolean; readConfig?: (context: ServiceConfigAccessContext, event: BetterPortalEvent) => Promise | ServiceConfigState | null; writeConfig?: (values: { tenantId: string; appId?: string; values: Record; }, context: ServiceConfigAccessContext, event: BetterPortalEvent) => Promise | ServiceConfigState | null; clearConfigKey?: (values: { tenantId: string; appId?: string; key: string; }, context: ServiceConfigAccessContext, event: BetterPortalEvent) => Promise | ServiceConfigState | null; /** Extra response headers added to successful write responses (e.g., HX-Trigger). */ writeSuccessHeaders?: Record; } export declare function registerServiceConfigRoutes(options: ServiceConfigRouteOptions): void; //# sourceMappingURL=serviceConfig.d.ts.map