import { W as WorkflowPresetName, O as OkraClient } from './client-CD1UgTAe.js'; export { A as AskContextRequest, a as AskContextResponse, C as ContextAgentSimulation, b as ContextBlock, c as ContextCitation, d as ContextStructureArtifact, e as ContextStructureNode, f as ContextTraceComparison, D as DEFAULT_WORKFLOW_CAPABILITIES, g as DYNAMIC_WORKFLOW_EXAMPLES, h as DynamicWorkflowCodeStep, i as DynamicWorkflowDatasetProvider, j as DynamicWorkflowDatasetRef, k as DynamicWorkflowDefinition, l as DynamicWorkflowError, m as DynamicWorkflowEvalConfig, n as DynamicWorkflowEvalMetric, o as DynamicWorkflowExample, p as DynamicWorkflowFailureReason, q as DynamicWorkflowGateCondition, r as DynamicWorkflowGateStep, s as DynamicWorkflowOcrStep, t as DynamicWorkflowOperation, u as DynamicWorkflowOutputKind, v as DynamicWorkflowRun, w as DynamicWorkflowRunList, x as DynamicWorkflowRunListOptions, y as DynamicWorkflowRunOptions, z as DynamicWorkflowStep, B as DynamicWorkflowStepBase, E as DynamicWorkflowStepKind, F as DynamicWorkflowValidationResult, G as DynamicWorkflowVlmStep, H as GetContextRequest, I as GetContextResponse, J as HttpContextClientOptions, K as OfflineContextExample, L as OfflineContextFixture, M as OkraContextAllowanceScope, N as OkraContextClient, P as OkraContextEffectClient, Q as OkraContextError, R as OkraContextFailureReason, S as OkraContextOperation, T as OkraContextPolicy, U as OkraContextScope, V as OkraContextToolName, X as OpenSourceRequest, Y as OpenSourceResponse, Z as PreparedDynamicWorkflow, _ as ReadStructureRequest, $ as ReadStructureResponse, a0 as ResolveSourceRequest, a1 as ResolveSourceResponse, a2 as WORKFLOW_PRESETS, a3 as buildDynamicWorkflowDefinition, a4 as buildDynamicWorkflowDefinitionEffect, a5 as contextEffectClientToPromise, a6 as createHttpContextClient, a7 as createHttpContextEffectClient, a8 as createOfflineContextClient, a9 as createOfflineContextEffectClient, aa as defineDynamicWorkflow, ab as defineDynamicWorkflowEffect, ac as dynamicWorkflowErrorCause, ad as dynamicWorkflowToAgentWorkflowSource, ae as dynamicWorkflowToAgentWorkflowSourceEffect, af as dynamicWorkflowToCapabilities, ag as dynamicWorkflowToCapabilitiesEffect, ah as getDynamicWorkflowExample, ai as getOfflineContextFixture, aj as listDynamicWorkflowExamples, ak as listOfflineContextFixtures, al as offlineContextFixtures, am as okraContextErrorCause, an as prepareDynamicWorkflowEffect, ao as restoreDynamicWorkflowError, ap as restoreOkraContextError, aq as runOkraContextEffect, ar as validateDynamicWorkflow, as as workflowPreset } from './client-CD1UgTAe.js'; export { N as NormalizedStructuredSchema, S as StructuredSchemaError, a as StructuredSchemaFailureStage, b as StructuredValidationFailure, c as StructuredValidationSuccess, d as decodeStructuredDataEffect, n as normalizeStructuredSchema, e as normalizeStructuredSchemaEffect, s as structuredSchemaCacheKey, f as structuredSchemaCacheKeyEffect, v as validateStructuredData, g as validateStructuredDataEffect } from './structured-schema-BhJIWm_8.js'; import * as effect_Cause from 'effect/Cause'; import * as effect_Types from 'effect/Types'; import { O as OkraClientOptions, P as ProcessingCapabilities, a as OkraSession, C as CompletionOptions, b as CompletionEvent, S as SessionState, D as DocumentStatus, W as WaitOptions, c as Page, E as EntitiesResponse, Q as QueryResult, L as LogsOptions, d as LogEntry, e as PublishResult, f as ShareLinkOptions, g as ShareLinkResult, h as DocumentAsset, G as GenerateOptions, i as GenerateResult, j as StructuredSchema, R as RuntimeErrorCode, k as StructuredOutputErrorCode, l as PageLocationCitation } from './types-R6f5p55r.js'; export { A as ApiKeyWorkflowConfigResponse, m as ApplyWorkflowOptions, n as ApplyWorkflowResult, o as CanonicalParseBlock, p as CanonicalParseOutput, q as CanonicalParsePage, r as CitationBbox, s as Collection, t as CollectionDocument, u as CollectionExportEvent, v as CollectionExportFormat, w as CollectionExportOptions, x as CollectionMarkdownExport, y as CollectionQueryEvent, z as CollectionQueryOptions, B as CollectionQueryResult, F as CollectionQueryStream, H as CollectionSummary, I as DeleteDocumentResult, J as DeleteFileResult, K as DocUrlOptions, M as DocumentAccess, N as DocumentAccessRoleProfile, T as DocumentAction, U as DocumentAgentConfig, V as DocumentAgentContextConfig, X as DocumentAgentModelConfig, Y as DocumentAgentModelEndpoint, Z as DocumentAgentRuntimeConfig, _ as DocumentAgentSecurityConfig, $ as DocumentAgentToolPolicies, a0 as DocumentAgentToolsConfig, a1 as DocumentAnswer, a2 as DocumentAssetStatus, a3 as DocumentConfigResult, a4 as DocumentConfigUpdate, a5 as DocumentEvent, a6 as DocumentEventHandler, a7 as DocumentEventStream, a8 as DocumentEventStreamOptions, a9 as DocumentEventType, aa as DocumentExtract, ab as DocumentFeatureFlags, ac as DocumentGrant, ad as DocumentGrantConstraints, ae as DocumentListItem, af as DocumentListResponse, ag as DocumentMarkdownExport, ah as DocumentPluginSpec, ai as DocumentPluginState, aj as DocumentRuntime, ak as DocumentSpec, al as DocumentSpecDiff, am as DocumentSpecRecord, an as Entity, ao as FileListOptions, ap as FileUploadOptions, aq as FileUploadTransport, ar as InvoiceExtractionException, as as InvoiceExtractionExceptionList, at as InvoiceExtractionExceptionResolution, au as InvoiceExtractionInput, av as InvoiceExtractionQuality, aw as InvoiceExtractionResolveExceptionOptions, ax as InvoiceExtractionRun, ay as InvoiceExtractionRunList, az as InvoiceExtractionRunListOptions, aA as InvoiceExtractionRunOptions, aB as JobError, aC as JobListOptions, aD as JobListResponse, aE as JobStatus, aF as JsonSchema, aG as MarkdownPage, aH as OkraCollections, aI as OkraEvent, aJ as OkraFile, aK as OkraFileListResponse, aL as OkraFileUrls, aM as OkraFiles, aN as OkraJob, aO as PageBlock, aP as PageEntity, aQ as PageImageStrategy, aR as ParseArtifact, aS as ParseExtraction, aT as ParseJob, aU as ParseOptions, aV as ParseResult, aW as ParseUsage, aX as PrincipalRef, aY as ReadDocumentOptions, aZ as ReadDocumentResult, a_ as ReparseOptions, a$ as ReparseResult, b0 as SessionAttachOptions, b1 as SessionCreateOptions, b2 as ShareLinkCapabilities, b3 as ShareLinkLinks, b4 as StructuredOutputMeta, b5 as TocAssetData, b6 as TocItem, b7 as UploadInput, b8 as UploadOptions, b9 as UploadRedactOptions, ba as UploadRedactPiiOptions, bb as UrlBuilderOptions, bc as VerifyBbox, bd as VerifyParams, be as VerifyResult, bf as VerifyVerdict, bg as WorkflowPhase, bh as WorkflowPhaseConfig, bi as WorkflowTier } from './types-R6f5p55r.js'; import { Effect, Stream, Schema } from 'effect'; export { doc } from './url.js'; export { C as CliGenerationHints, a as ContentTypeField, b as ContentTypeFieldType, c as ContentTypeManifest, d as ContentTypeManifestError, e as ContentTypeRegistry, f as ContentTypeRegistryError, g as ContentTypeSummary, E as EvidencePolicy, h as ExportFormat, i as ExtractionConfig, R as RESERVED_NOUNS, j as ReviewConfig, S as SdkGenerationHints, k as contentTypeFieldSchema, l as contentTypeFieldTypeSchema, m as contentTypeManifestSchema, n as contentTypeManifestViolations, o as createContentTypeRegistryEffect, p as decodeContentTypeManifestEffect, q as defineContentTypeManifest, r as evidencePolicySchema, s as getContentType, t as getContentTypeEffect, u as invoiceContentType, v as isContentTypeManifest, w as listContentTypes, x as listContentTypesEffect } from './invoice-B8GYj8iT.js'; import '@okrapdf/component'; import 'zod'; type ExtractionPhase = 'ocr' | 'enhance' | 'metadata' | 'verify'; interface OkraProvider { name: string; supportedPhases: ExtractionPhase[]; } interface OkraMiddleware { name: string; config: Record; } interface CreateOkraOptions extends OkraClientOptions { providers?: Record; extraction?: Partial>; middleware?: OkraMiddleware[]; /** Legacy default BYOK keys (prefer `workflow.vendorKeys`). */ vendorKeys?: Record; /** General workflow defaults for all uploads from this client. */ workflow?: { preset?: WorkflowPresetName; capabilities?: ProcessingCapabilities; vendorKeys?: Record; }; } type ProviderConfigurationOperation = 'validate' | 'create_client'; type ProviderConfigurationFailureReason = 'provider_not_registered' | 'client_configuration'; declare const ProviderConfigurationError_base: new = {}>(args: effect_Types.VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => effect_Cause.YieldableError & { readonly _tag: "ProviderConfigurationError"; } & Readonly; /** Safe native failure: API keys, vendor keys, middleware config, and options are not retained. */ declare class ProviderConfigurationError extends ProviderConfigurationError_base<{ readonly operation: ProviderConfigurationOperation; readonly reason: ProviderConfigurationFailureReason; readonly message: string; readonly phase?: ExtractionPhase; readonly provider?: string; readonly available: readonly string[]; }> { } /** Original compatibility cause without exposing client credentials on the tagged failure. */ declare function providerConfigurationErrorCause(error: ProviderConfigurationError): unknown; declare function restoreProviderConfigurationError(program: Effect.Effect): Effect.Effect; /** * Factory function — AI SDK-style provider abstraction. * * ```ts * import { createOkra } from 'okrapdf'; * * const okra = createOkra({ * apiKey: 'okra_...', * providers: { azureDocAI }, * extraction: { ocr: 'azureDocAI' }, * }); * ``` */ declare function createOkraEffect(options: CreateOkraOptions): Effect.Effect; /** Synchronous compatibility adapter for the original provider factory. */ declare function createOkra(options: CreateOkraOptions): OkraClient; declare function withCache(opts: { by: 'pdf-hash' | 'content-hash'; }): OkraMiddleware; declare function withQualityScore(opts: { threshold: number; }): OkraMiddleware; declare function withSecret(namespace: string, opts?: { required?: boolean; }): OkraMiddleware; type ChatStreamServerEvent = { type: 'CHAT_STREAM_START'; requestId: string; } | { type: 'CHAT_STREAM_DELTA'; requestId: string; delta: string; } | { type: 'CHAT_STREAM_DONE'; requestId: string; usage?: { inputTokens: number; outputTokens: number; costUsd: number; }; model?: string; } | { type: 'CHAT_STREAM_ERROR'; requestId: string; error: string; }; /** Function that sends a JSON string over the WebSocket. Returns false if WS is closed. */ type WsSendFn = (message: string) => boolean; /** Subscribe to chat stream events. Returns unsubscribe function. */ type WsSubscribeFn = (requestId: string, handler: (event: ChatStreamServerEvent) => void) => () => void; interface WsSessionOptions { /** Send JSON string over the existing WebSocket connection */ send: WsSendFn; /** Subscribe to CHAT_STREAM_* events for a given requestId */ subscribe: WsSubscribeFn; } type WsSessionStreamOperation = 'request-id' | 'subscribe' | 'send'; declare const WsSessionStreamError_base: new = {}>(args: effect_Types.VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => effect_Cause.YieldableError & { readonly _tag: "WsSessionStreamError"; } & Readonly; declare class WsSessionStreamError extends WsSessionStreamError_base<{ readonly operation: WsSessionStreamOperation; readonly cause: unknown; }> { } /** Restore the failure caught at the Promise/async-iterator compatibility edge. */ declare function wsSessionStreamFailureCause(error: unknown): unknown; /** * Effect-native WebSocket completion stream. * * Subscription and abort resources live in the stream scope. The subscription * is installed before the request is sent so a synchronous server response * cannot be lost between those two operations. */ declare function createWsCompletionStream(wsOptions: WsSessionOptions, query: string, options?: CompletionOptions): Stream.Stream; declare class WsSession implements OkraSession { #private; readonly id: string; readonly modelEndpoint: string; readonly model?: string; constructor(inner: OkraSession, opts: WsSessionOptions); stream(query: string, options?: CompletionOptions): AsyncGenerator; state(): SessionState; setModel(model: string): Promise; status(signal?: AbortSignal): Promise; wait(options?: WaitOptions): Promise; pages(options?: { range?: string; signal?: AbortSignal; }): Promise; page(pageNumber: number, signal?: AbortSignal): Promise; entities(options?: { type?: string; limit?: number; offset?: number; signal?: AbortSignal; }): Promise; downloadUrl(): string; query(sql: string, signal?: AbortSignal): Promise; logs(options?: LogsOptions): Promise; publish(signal?: AbortSignal): Promise; shareLink(options?: ShareLinkOptions): Promise; assets(signal?: AbortSignal): Promise; asset(assetId: string, signal?: AbortSignal): Promise | null>; prompt(query: string, options?: GenerateOptions & { schema?: undefined; }): Promise; prompt(query: string, options: GenerateOptions & { schema: StructuredSchema; }): Promise>; } declare class OkraRuntimeError extends Error { readonly code: RuntimeErrorCode; readonly status: number; readonly details?: unknown; constructor(code: RuntimeErrorCode, message: string, status?: number, details?: unknown); } declare class StructuredOutputError extends OkraRuntimeError { readonly code: StructuredOutputErrorCode; constructor(code: StructuredOutputErrorCode, message: string, status: number, details?: unknown); } type LocalDocumentStatus = 'processing' | 'ready' | 'failed'; interface LocalToolAvailability { available: boolean; path: string | null; } interface LocalDocumentExtractor { pdftotext: LocalToolAvailability; pdfinfo: LocalToolAvailability; pdftoppm: LocalToolAvailability; tesseract: LocalToolAvailability; ocrUsed: boolean; } interface LocalDocumentPageRecord { pageNumber: number; textPath: string; charCount: number; excerpt: string; ocrApplied: boolean; } interface LocalDocumentRecord { documentId: string; filename: string; storedPath: string; sourcePath: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; pages: LocalDocumentPageRecord[]; } /** * Self-host citations use the same Anthropic `page_location` shape as the cloud * surfaces (M-CITE / #580) — "one citation shape everywhere". `citation_url` * points at the stored source PDF at the cited page (`file://…#page=N`), the * honest local proof; no `bbox` (the text-only local path has no element boxes). */ type LocalCitation = PageLocationCitation; interface LocalTableCandidate { page: number; preview: string; rowCount: number; score?: number; } interface LocalDoctorReport { ok: boolean; dataDir: string; tools: { pdftotext: LocalToolAvailability; pdfinfo: LocalToolAvailability; pdftoppm: LocalToolAvailability; tesseract: LocalToolAvailability; }; } declare const localDocumentStatusSchema: Schema.Literals; declare const localToolAvailabilitySchema: Schema.Struct<{ readonly available: Schema.Boolean; readonly path: Schema.NullOr; }>; declare const localDocumentExtractorSchema: Schema.Struct<{ readonly pdftotext: Schema.Struct<{ readonly available: Schema.Boolean; readonly path: Schema.NullOr; }>; readonly pdfinfo: Schema.Struct<{ readonly available: Schema.Boolean; readonly path: Schema.NullOr; }>; readonly pdftoppm: Schema.Struct<{ readonly available: Schema.Boolean; readonly path: Schema.NullOr; }>; readonly tesseract: Schema.Struct<{ readonly available: Schema.Boolean; readonly path: Schema.NullOr; }>; readonly ocrUsed: Schema.Boolean; }>; declare const localDocumentPageRecordSchema: Schema.Struct<{ readonly pageNumber: Schema.Int; readonly textPath: Schema.String; readonly charCount: Schema.Natural; readonly excerpt: Schema.String; readonly ocrApplied: Schema.Boolean; }>; /** Runtime contract for persisted `meta.json` records in the zero-cloud local harness. */ declare const localDocumentRecordSchema: Schema.Struct<{ readonly documentId: Schema.String; readonly filename: Schema.String; readonly storedPath: Schema.String; readonly sourcePath: Schema.String; readonly status: Schema.Literals; readonly pageCount: Schema.Natural; readonly charCount: Schema.Natural; readonly createdAt: Schema.String; readonly updatedAt: Schema.String; readonly error: Schema.NullOr; readonly extractor: Schema.Struct<{ readonly pdftotext: Schema.Struct<{ readonly available: Schema.Boolean; readonly path: Schema.NullOr; }>; readonly pdfinfo: Schema.Struct<{ readonly available: Schema.Boolean; readonly path: Schema.NullOr; }>; readonly pdftoppm: Schema.Struct<{ readonly available: Schema.Boolean; readonly path: Schema.NullOr; }>; readonly tesseract: Schema.Struct<{ readonly available: Schema.Boolean; readonly path: Schema.NullOr; }>; readonly ocrUsed: Schema.Boolean; }>; readonly pages: Schema.$Array>; }>; type LocalDocumentOperation = 'ingest' | 'status' | 'summary' | 'search' | 'page' | 'tables' | 'doctor'; declare const LocalDocumentHarnessError_base: new = {}>(args: effect_Types.VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => effect_Cause.YieldableError & { readonly _tag: "LocalDocumentHarnessError"; } & Readonly; declare class LocalDocumentHarnessError extends LocalDocumentHarnessError_base<{ readonly operation: LocalDocumentOperation; readonly status?: number; readonly cause: unknown; }> { } declare function ingestLocalDocumentEffect(sourcePath: string, dataDir?: string): Effect.Effect<{ storedPath: string; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }, LocalDocumentHarnessError, never>; declare function ingestLocalDocument(sourcePath: string, dataDir?: string): { storedPath: string; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }; declare function getLocalDocumentStatusEffect(documentId: string, dataDir?: string): Effect.Effect<{ pagesWithText: number; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }, LocalDocumentHarnessError, never>; declare function getLocalDocumentStatus(documentId: string, dataDir?: string): { pagesWithText: number; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }; declare function summarizeLocalDocumentEffect(documentId: string, dataDir?: string): Effect.Effect<{ summary: string; citations: PageLocationCitation[]; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }, LocalDocumentHarnessError, never>; declare function summarizeLocalDocument(documentId: string, dataDir?: string): { summary: string; citations: PageLocationCitation[]; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }; declare function searchLocalDocumentEffect(documentId: string, query: string, dataDir?: string): Effect.Effect<{ query: string; matches: { page: number; snippet: string; score: number; }[]; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }, LocalDocumentHarnessError, never>; declare function searchLocalDocument(documentId: string, query: string, dataDir?: string): { query: string; matches: { page: number; snippet: string; score: number; }[]; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }; declare function readLocalPageEffect(documentId: string, pageNumber: number, dataDir?: string): Effect.Effect<{ page: number; text: string; ocrApplied: boolean; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }, LocalDocumentHarnessError, never>; declare function readLocalPage(documentId: string, pageNumber: number, dataDir?: string): { page: number; text: string; ocrApplied: boolean; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }; declare function findLocalTablesEffect(documentId: string, query?: string, dataDir?: string): Effect.Effect<{ query: string | undefined; tables: { page: number; preview: string; rowCount: number; }[]; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }, LocalDocumentHarnessError, never>; declare function findLocalTables(documentId: string, query?: string, dataDir?: string): { query: string | undefined; tables: { page: number; preview: string; rowCount: number; }[]; documentId: string; filename: string; status: LocalDocumentStatus; pageCount: number; charCount: number; createdAt: string; updatedAt: string; error: string | null; extractor: LocalDocumentExtractor; }; declare function doctorLocalHarnessEffect(dataDir?: string): Effect.Effect; declare function doctorLocalHarness(dataDir?: string): LocalDoctorReport; export { type ChatStreamServerEvent, CompletionEvent, CompletionOptions, type CreateOkraOptions, DocumentAsset, DocumentStatus, EntitiesResponse, type ExtractionPhase, GenerateOptions, GenerateResult, type LocalCitation, type LocalDoctorReport, type LocalDocumentExtractor, LocalDocumentHarnessError, type LocalDocumentPageRecord, type LocalDocumentRecord, type LocalDocumentStatus, type LocalTableCandidate, type LocalToolAvailability, LogEntry, LogsOptions, OkraClient, OkraClientOptions, type OkraMiddleware, type OkraProvider, OkraClient as OkraRuntime, OkraRuntimeError, OkraSession, Page, PageLocationCitation, ProcessingCapabilities, ProviderConfigurationError, type ProviderConfigurationFailureReason, type ProviderConfigurationOperation, PublishResult, QueryResult, RuntimeErrorCode, SessionState, ShareLinkOptions, ShareLinkResult, StructuredOutputError, StructuredOutputErrorCode, StructuredSchema, WaitOptions, WorkflowPresetName, type WsSendFn, WsSession, type WsSessionOptions, WsSessionStreamError, type WsSessionStreamOperation, type WsSubscribeFn, createOkra, createOkraEffect, createWsCompletionStream, doctorLocalHarness, doctorLocalHarnessEffect, findLocalTables, findLocalTablesEffect, getLocalDocumentStatus, getLocalDocumentStatusEffect, ingestLocalDocument, ingestLocalDocumentEffect, localDocumentExtractorSchema, localDocumentPageRecordSchema, localDocumentRecordSchema, localDocumentStatusSchema, localToolAvailabilitySchema, providerConfigurationErrorCause, readLocalPage, readLocalPageEffect, restoreProviderConfigurationError, searchLocalDocument, searchLocalDocumentEffect, summarizeLocalDocument, summarizeLocalDocumentEffect, withCache, withQualityScore, withSecret, wsSessionStreamFailureCause };