@work-shape/catalyst-asset-schemas 0.8.0-rc.2 → 0.8.0-rc.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/dist/index.d.ts +2580 -25
  2. package/dist/index.js +1933 -82
  3. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -4,6 +4,8 @@ import { z } from 'zod';
4
4
  * The shape of an agent and of a skill as a file holds it. These are the public half of the
5
5
  * asset model: a working copy, the command line tool and the instance read the same types.
6
6
  */
7
+ /** The configuration rights reported for an asset; publish applies to draft/published kinds. */
8
+ declare const ASSET_ACCESS_VERBS: readonly ["read", "write", "delete", "publish"];
7
9
  declare const localeCodes: readonly ["en", "de"];
8
10
  type LocaleCode = (typeof localeCodes)[number];
9
11
  type LocalizedStringConfig = string | {
@@ -23,10 +25,17 @@ interface AgentConfig {
23
25
  welcomeMessage?: LocalizedStringConfig;
24
26
  welcomeSubtitle?: LocalizedStringConfig;
25
27
  instructions: string;
28
+ /** What the instance adds after the instructions of an agent that ships with the platform. */
29
+ additionalInstructions?: string;
26
30
  modelProviderId?: string;
27
31
  modelBindingId?: string;
28
32
  reasoningEffort?: ReasoningEffortConfig;
29
33
  fastMode?: boolean;
34
+ /**
35
+ * Whether a run of the agent goes on on its model binding's `fallback` when that binding is
36
+ * rate-limited or down. Unset is on.
37
+ */
38
+ useModelFallback?: boolean;
30
39
  /** Bindings users may pick for this agent in the chat, besides its own `modelBindingId`. */
31
40
  userSelectableModelBindingIds?: string[];
32
41
  /**
@@ -36,13 +45,26 @@ interface AgentConfig {
36
45
  modelReasoningEfforts?: Record<string, ReasoningEffortConfig>;
37
46
  maxSteps?: number;
38
47
  toolNames: string[];
48
+ /**
49
+ * The other agents this agent may start as subagents with `run_agent`, besides itself. Each
50
+ * is started only where the person may use it in the conversation's workspace.
51
+ */
52
+ subagentNames?: string[];
39
53
  skillNames: string[];
40
54
  /**
41
55
  * The Knowledge Bases the agent answers from, by id. However many it lists, the agent has one
42
- * tool over all of them, `knowledge.query`. Missing means none.
56
+ * tool over those of tables, `knowledge.query`, and one over those of documents,
57
+ * `knowledge.search`. Missing means none.
43
58
  */
44
59
  knowledgeBases?: string[];
45
60
  initialPrompts: AgentInitialPromptConfig[];
61
+ /**
62
+ * An agent that ships with the platform: its fields as the release shipped them last. Only
63
+ * the release seed writes it; every other write keeps it as stored.
64
+ */
65
+ shipped?: Record<string, unknown>;
66
+ /** The shipped fields the instance changed and a release then shipped anew. */
67
+ shippedNewer?: string[];
46
68
  }
47
69
  interface SkillConfig {
48
70
  name: string;
@@ -122,6 +144,76 @@ interface SkillResourceConfig {
122
144
  mediaType: SkillResourceMediaType;
123
145
  content: string;
124
146
  }
147
+ /** Ordered from the narrowest App audience to the widest. */
148
+ declare const APP_AUDIENCES: readonly ["self", "workspace", "instance"];
149
+
150
+ /**
151
+ * The one AWS region the `aws-bedrock` model provider calls. Bedrock's data retention is set to
152
+ * `none` there and nowhere else, and the EU inference profiles route from it to EU regions only.
153
+ */
154
+ declare const BEDROCK_REGION = "eu-central-1";
155
+ /** The twelve digits of an AWS account id, the provider's `accountId`. */
156
+ declare const AWS_ACCOUNT_ID: RegExp;
157
+ /**
158
+ * Why a model id is not one the `aws-bedrock` provider calls, or undefined for an application
159
+ * inference profile of the configured account in `BEDROCK_REGION`. A profile of another account
160
+ * is refused before anything is sent: the key would be shown to a resource this instance does
161
+ * not own. Usage on Bedrock is attributed to a consumer by its application inference profile and
162
+ * the consumer's credential may call that alone, so a model id or a shared profile is refused.
163
+ * The reason never repeats the id: an ARN holds the account id. The adapter and the CLI that
164
+ * writes the entry apply the same rule.
165
+ */
166
+ declare function bedrockProfileRefusal(model: string, accountId: string): string | undefined;
167
+
168
+ /**
169
+ * How a release config file that `extends` another is read over it: objects merge key by key,
170
+ * the extending file winning; lists and values replace the base's wholesale. The instance's
171
+ * loader and the CLI that writes release config merge the same way.
172
+ */
173
+ declare function mergeConfigObjects(base: Record<string, unknown>, overrides: Record<string, unknown>): Record<string, unknown>;
174
+ /** An object a config merges into, not a list or a YAML-derived value such as a Date. */
175
+ declare function isPlainConfigObject(value: unknown): value is Record<string, unknown>;
176
+
177
+ declare const PROJECT_ACTIONS: readonly ["project.read", "project.write", "project.delete"];
178
+ /** The kind of a project's definition: a named folder of chat work in one workspace. */
179
+ declare const PROJECT_ASSET_KIND = "project";
180
+ /**
181
+ * Who reads a project, its files and every conversation in it: every member of its workspace,
182
+ * or its creator alone. The same pair a conversation's visibility holds.
183
+ */
184
+ declare const PROJECT_AUDIENCES: readonly ["workspace", "private"];
185
+ type ProjectAudience = (typeof PROJECT_AUDIENCES)[number];
186
+ /**
187
+ * What a project's deletion does with its chats (PRJ-6): they stay in the workspace, outside a
188
+ * project, or are deleted with it.
189
+ */
190
+ declare const PROJECT_DELETION_CONVERSATIONS: readonly ["keep", "delete"];
191
+ type ProjectDeletionConversations = (typeof PROJECT_DELETION_CONVERSATIONS)[number];
192
+ /** Who made a version of a project file: a person on the page, an agent in a chat, an upload. */
193
+ declare const PROJECT_FILE_ORIGINS: readonly ["person", "agent", "upload"];
194
+ /** What a change did to a project's folder (PRJ-2). */
195
+ declare const PROJECT_FILE_CHANGES: readonly ["created", "updated", "deleted", "restored", "unchanged", "conflict_copy"];
196
+ /** What a write of an agent in the folder did: it neither deletes nor restores. */
197
+ declare const PROJECT_FOLDER_WRITE_CHANGES: readonly ["created", "updated", "unchanged", "conflict_copy"];
198
+ /** The longest title of a project, in characters. */
199
+ declare const PROJECT_TITLE_MAX_LENGTH = 120;
200
+ /** The longest description of a project, in characters. */
201
+ declare const PROJECT_DESCRIPTION_MAX_LENGTH = 500;
202
+ /** The most skills a project attaches (PRJ-7). */
203
+ declare const PROJECT_SKILLS_MAX = 20;
204
+ /** The most Knowledge Bases a project attaches (PRJ-8). */
205
+ declare const PROJECT_KNOWLEDGE_BASES_MAX = 20;
206
+ /**
207
+ * Why a project's choice is greyed: the person's own, in a project others read; or a Knowledge
208
+ * Base not everyone in the project's audience may search (PRJ-8).
209
+ */
210
+ declare const PROJECT_CHOICE_REFUSALS: readonly ["own_in_shared_project", "not_everyone_may_use"];
211
+ /**
212
+ * The name the server makes of a title: lowercase words joined by hyphens, then a hyphen and a
213
+ * random suffix. A person never types it, and it never changes.
214
+ */
215
+ declare const PROJECT_NAME_PATTERN: RegExp;
216
+ declare const PROJECT_NAME_MAX_LENGTH = 64;
125
217
 
126
218
  /**
127
219
  * The values the HTTP contract of an instance is written with: scopes, actions, error codes
@@ -131,16 +223,16 @@ interface SkillResourceConfig {
131
223
  */
132
224
  declare const AUTH_SCOPE_WILDCARD: "*";
133
225
  declare const CHAT_SESSION_AUTH_SCOPES: readonly ["me:read", "me:delete", "config:read", "conversation:read", "conversation:write", "run:start", "run:observe", "run:cancel", "run:command"];
134
- declare const FIRST_PARTY_AUTH_SCOPES: readonly ["*", "me:read", "me:delete", "config:read", "conversation:read", "conversation:write", "run:start", "run:observe", "run:cancel", "run:command", "collaboration_workspace:read", "collaboration_workspace:manage", "me:write", "governance:read", "governance:write", "user_admin:read", "user_admin:write", "api_access:read", "api_access:write", "config_assets:read", "config_assets:write", "config_assets:publish", "config_assets:release", "data_store_rows:read", "data_store_rows:write"];
226
+ declare const FIRST_PARTY_AUTH_SCOPES: readonly ["*", "me:read", "me:delete", "config:read", "conversation:read", "conversation:write", "run:start", "run:observe", "run:cancel", "run:command", "collaboration_workspace:read", "collaboration_workspace:manage", "me:write", "governance:read", "governance:write", "user_admin:read", "user_admin:write", "infrastructure:check", "api_access:read", "api_access:write", "config_assets:read", "config_assets:write", "config_assets:publish", "config_assets:release", "data_store_rows:read", "data_store_rows:write"];
135
227
  type ChatSessionAuthScope = (typeof CHAT_SESSION_AUTH_SCOPES)[number];
136
228
  type FirstPartyAuthScope = (typeof FIRST_PARTY_AUTH_SCOPES)[number];
137
229
  type OperationScope = Exclude<FirstPartyAuthScope, "*">;
138
- declare const ACTIONS: readonly ["agent.read", "agent.write", "agent.delete", "skill.read", "skill.write", "skill.delete", "skill.approve", "connection.read", "connection.use", "connection.write", "connection.delete", "connection.approve", "app.read", "app.write", "app.publish", "app.approve", "app.delete", "app.use", "workflow.read", "workflow.write", "workflow.publish", "workflow.approve", "workflow.delete", "workflow.use", "workflow.read_run_data", "data_store.read", "data_store.write", "data_store.publish", "data_store.delete", "data_store.insert", "data_store.execute", "knowledge_base.read", "knowledge_base.write", "knowledge_base.publish", "knowledge_base.delete", "knowledge_base.use", "guardrail.read", "guardrail.write", "guardrail.publish", "guardrail.delete", "operations.approve", "users.manage", "usage.view", "audit.view", "api_access.manage", "service_principals.manage", "agent_models.manage", "assets.release"];
230
+ /**
231
+ * Every right of the platform, one file per domain under `contract-values/`. The order is kept:
232
+ * `GRANTABLE_ACTIONS` filters it, and the rights dialog lists rights in it.
233
+ */
234
+ declare const ACTIONS: readonly ["agent.read", "agent.write", "agent.publish", "agent.approve", "agent.delete", "agent.use", "skill.read", "skill.write", "skill.publish", "skill.delete", "skill.approve", "connection.read", "connection.use", "connection.write", "connection.delete", "connection.approve", "app.read", "app.write", "app.publish", "app.approve", "app.delete", "app.use", "workflow.read", "workflow.write", "workflow.publish", "workflow.approve", "workflow.delete", "workflow.use", "workflow.read_run_data", "data_store.read", "data_store.write", "data_store.publish", "data_store.delete", "data_store.insert", "data_store.execute", "data_store.records", "knowledge_base.read", "knowledge_base.write", "knowledge_base.ingest", "knowledge_base.publish", "knowledge_base.delete", "knowledge_base.use", "mail_sender.use", "guardrail.read", "guardrail.write", "guardrail.publish", "guardrail.delete", "operations.approve", "feedback.review", "users.manage", "users.delete", "usage.view", "limits.manage", "usage.view_users", "audit.view", "system.view", "jobs.retry", "api_access.manage", "service_principals.manage", "agent_models.manage", "roles.edit_built_in", "assets.release", "builder", "publisher", "project.read", "project.write", "project.delete"];
139
235
  type PlatformAction = (typeof ACTIONS)[number];
140
- /** A Namespace prefix: lowercase words joined by single hyphens, ending in one hyphen. */
141
- declare const NAMESPACE_PREFIX_PATTERN: RegExp;
142
- declare const NAMESPACE_PREFIX_MIN_LENGTH = 2;
143
- declare const NAMESPACE_PREFIX_MAX_LENGTH = 32;
144
236
  type AppErrorCode = (typeof APP_ERROR_CODES)[number];
145
237
  /** The HTTP status every error code answers with. */
146
238
  declare const APP_ERROR_STATUS_CODES: Record<AppErrorCode, number>;
@@ -154,11 +246,11 @@ declare const IDEMPOTENCY_KEY_MAX_LENGTH = 255;
154
246
  declare const PROVIDER_PORTS: readonly ["models", "mail", "objectStorage", "sandbox", "secrets"];
155
247
  type ProviderPort = (typeof PROVIDER_PORTS)[number];
156
248
  /**
157
- * Where a provider processes the data an instance sends it. Product-owned and closed: a vendor's
158
- * own region name is a separate field of its adapter, such as `bucketRegion`.
249
+ * Where a provider processes the data an instance sends it. Only `eu` admits personal
250
+ * Connections; other short strings describe routes outside that boundary.
159
251
  */
160
252
  declare const PROVIDER_REGIONS: readonly ["eu", "global"];
161
- type ProviderRegion = (typeof PROVIDER_REGIONS)[number];
253
+ type ProviderRegion = string;
162
254
  /**
163
255
  * Why a check failed. Product-owned and closed: it is all of a failure that reaches a log, the
164
256
  * API or a page, so a provider's own error text, which can repeat a key or an address, cannot.
@@ -167,7 +259,7 @@ declare const PROVIDER_CHECK_ERROR_CLASSES: readonly ["unreachable", "timeout",
167
259
  type ProviderCheckErrorClass = (typeof PROVIDER_CHECK_ERROR_CLASSES)[number];
168
260
  /**
169
261
  * The immutable machine name. It is part of every operation name of the Connection
170
- * (`connection.<name>.<operation>`), so it holds no dot. A Namespace prefix fits in front.
262
+ * (`connection.<name>.<operation>`), so it holds no dot.
171
263
  */
172
264
  declare const CONNECTION_NAME_PATTERN: RegExp;
173
265
  declare const CONNECTION_NAME_MAX_LENGTH = 64;
@@ -187,10 +279,33 @@ type ConnectionExposure = (typeof CONNECTION_EXPOSURES)[number];
187
279
  /** The health of a Connection as its page and its list show it. */
188
280
  declare const CONNECTION_HEALTH_STATES: readonly ["unknown", "ok", "failed", "needs_configuration", "secret_unreadable"];
189
281
  type ConnectionHealth = (typeof CONNECTION_HEALTH_STATES)[number];
282
+ /**
283
+ * Sharing an asset up the ladder (SHARE-1): its rungs, Nur ich (a Personal Workspace), Team (a
284
+ * Shared Workspace) and Alle (the instance); whether a move is made at once or as a request; how
285
+ * it ended; and who edits and uses the asset at its new owner.
286
+ */
287
+ declare const ASSET_OWNER_RUNGS: readonly ["personal", "team", "everyone"];
288
+ type AssetOwnerRung = (typeof ASSET_OWNER_RUNGS)[number];
289
+ declare const ASSET_MOVE_PATHS: readonly ["direct", "request"];
290
+ type AssetMovePath = (typeof ASSET_MOVE_PATHS)[number];
291
+ declare const ASSET_MOVE_STATUSES: readonly ["moved", "requested"];
292
+ type AssetMoveStatus = (typeof ASSET_MOVE_STATUSES)[number];
293
+ declare const ASSET_MOVE_EDITORS: readonly ["workspace_builders", "instance_builders"];
294
+ type AssetMoveEditors = (typeof ASSET_MOVE_EDITORS)[number];
295
+ declare const ASSET_MOVE_USERS: readonly ["workspace_members", "everyone_where_offered"];
296
+ type AssetMoveUsers = (typeof ASSET_MOVE_USERS)[number];
190
297
  declare const GRANT_HOLDER_KINDS: readonly ["user", "service_principal", "role", "group"];
191
298
  type GrantHolderKind = (typeof GRANT_HOLDER_KINDS)[number];
192
- declare const GRANT_SCOPE_KINDS: readonly ["instance", "workspace", "namespace", "asset"];
299
+ declare const GRANT_SCOPE_KINDS: readonly ["instance", "workspace", "asset"];
193
300
  type GrantScopeKind = (typeof GRANT_SCOPE_KINDS)[number];
301
+ /** Where a role's grant lies: the whole instance, one workspace or one asset. */
302
+ declare const ROLE_GRANT_SCOPE_KINDS: readonly ["instance", "workspace", "asset"];
303
+ type RoleGrantScopeKind = (typeof ROLE_GRANT_SCOPE_KINDS)[number];
304
+ /** What a release did to an action of a built-in role's default that waits for a decision. */
305
+ declare const ROLE_PENDING_CHANGES: readonly ["added", "removed"];
306
+ /** The decision on a pending action: apply what the release did, or dismiss it. */
307
+ declare const ROLE_PENDING_DECISIONS: readonly ["apply", "dismiss"];
308
+ type RolePendingDecision = (typeof ROLE_PENDING_DECISIONS)[number];
194
309
  declare const GRANT_EFFECTS: readonly ["allow", "deny"];
195
310
  type GrantEffect = (typeof GRANT_EFFECTS)[number];
196
311
  declare const ACCESS_SOURCES: readonly ["role", "legacy_ref", "grant", "membership"];
@@ -203,12 +318,34 @@ declare const ADMINISTERED_USER_STATUSES: readonly ["active", "disabled", "delet
203
318
  type AdministeredUserStatus = (typeof ADMINISTERED_USER_STATUSES)[number];
204
319
  declare const SERVICE_PRINCIPAL_STATUSES: readonly ["active", "disabled"];
205
320
  type ServicePrincipalStatus = (typeof SERVICE_PRINCIPAL_STATUSES)[number];
321
+ /**
322
+ * When the account a Workflow runs as needs a right its definition names. `publish`: the
323
+ * publish is refused without it. `run`: the step that needs it fails when it runs.
324
+ */
325
+ declare const WORKFLOW_RIGHT_NEEDED_FOR: readonly ["publish", "run"];
326
+ /** The revision of a publish's Workflow the rights are read from: the one published, or a live child. */
327
+ declare const WORKFLOW_RIGHTS_REVISIONS: readonly ["draft", "published"];
328
+ /** How the account a Workflow names stands: a principal's status, or no principal of the name. */
329
+ declare const WORKFLOW_RUN_ACCOUNT_STATUSES: readonly ["active", "disabled", "unknown"];
330
+ /**
331
+ * Why a reader cannot give an account a right it lacks. `not_grantable`: nobody can give it to
332
+ * an account here. `not_administrator`: giving needs someone who administers technical
333
+ * accounts. `not_held`: the reader does not hold it there. `account_unavailable`: the account
334
+ * is missing or disabled. `asset_unavailable`: no active asset of the name exists.
335
+ */
336
+ declare const WORKFLOW_RIGHT_REFUSALS: readonly ["not_grantable", "not_administrator", "not_held", "account_unavailable", "asset_unavailable", "not_visible"];
206
337
  declare const SERVICE_PRINCIPAL_PERMISSIONS: readonly ["config_assets.read", "config_assets.release"];
207
338
  type ServicePrincipalPermission = (typeof SERVICE_PRINCIPAL_PERMISSIONS)[number];
208
339
  declare const API_CREDENTIAL_SCOPES: readonly ["config_assets:read", "config_assets:release"];
209
340
  type ApiCredentialScope = (typeof API_CREDENTIAL_SCOPES)[number];
210
341
  declare const APP_ERROR_CODES: readonly ["BAD_REQUEST", "UNAUTHENTICATED", "FORBIDDEN", "NOT_FOUND", "CONFLICT", "REVISION_CONFLICT", "PRECONDITION_REQUIRED", "TIMEOUT", "VALIDATION_FAILED", "RATE_LIMITED", "POLICY_DENIED", "GUARDRAIL_BLOCKED", "DECLINED", "IDEMPOTENCY_KEY_REUSED", "OPERATION_IN_PROGRESS", "OPERATION_EXPIRED", "OUTPUT_NOT_RETAINED", "INTERNAL"];
211
342
  declare const OPERATION_EFFECTS: readonly ["reading", "changing"];
343
+ /** The parts a catalogue entry can bring: tools agents call, or a Knowledge Base source. */
344
+ declare const CATALOGUE_PARTS: readonly ["tools", "source"];
345
+ type CataloguePart = (typeof CATALOGUE_PARTS)[number];
346
+ /** The categories a catalogue entry's card is filed under. */
347
+ declare const CATALOGUE_CATEGORIES: readonly ["mail", "files", "accounting", "databases", "other"];
348
+ type CatalogueCategory = (typeof CATALOGUE_CATEGORIES)[number];
212
349
  declare const OPERATION_TARGETS: readonly ["live", "test", "dry_run"];
213
350
  type OperationTarget = (typeof OPERATION_TARGETS)[number];
214
351
  declare const OPERATION_RUN_STATUSES: readonly ["running", "pending_confirmation", "pending_approval", "done", "failed", "denied", "expired"];
@@ -225,7 +362,7 @@ declare const APPROVAL_REQUEST_STATUSES: readonly ["pending", "approved", "rejec
225
362
  type ApprovalRequestStatus = (typeof APPROVAL_REQUEST_STATUSES)[number];
226
363
  declare const APPROVAL_CHECK_STATUSES: readonly ["passed", "warned", "blocked"];
227
364
  type ApprovalCheckStatus = (typeof APPROVAL_CHECK_STATUSES)[number];
228
- declare const APPROVAL_EXECUTIONS: readonly ["queued", "done", "failed", "interrupted", "refused", "expired"];
365
+ declare const APPROVAL_EXECUTIONS: readonly ["queued", "done", "failed", "interrupted", "refused", "expired", "held"];
229
366
  type ApprovalExecution = (typeof APPROVAL_EXECUTIONS)[number];
230
367
  declare const SKILL_CHANGE_TYPES: readonly ["replace", "add", "new_resource"];
231
368
  type SkillChangeType = (typeof SKILL_CHANGE_TYPES)[number];
@@ -247,6 +384,12 @@ declare const CONFIG_ASSET_CHANGE_OPERATIONS: readonly ["create", "update", "del
247
384
  type ConfigAssetChangeOperation = (typeof CONFIG_ASSET_CHANGE_OPERATIONS)[number];
248
385
  declare const AGENT_AVAILABILITY_MODES: readonly ["all", "selected"];
249
386
  type AgentAvailabilityMode = (typeof AGENT_AVAILABILITY_MODES)[number];
387
+ /**
388
+ * Who uses an agent where it is available (AGENT-USE-1): everyone who may work there, or only
389
+ * those `agent.use` allows on it. Every agent starts at `everyone`.
390
+ */
391
+ declare const AGENT_USE_SETTINGS: readonly ["everyone", "granted"];
392
+ type AgentUse = (typeof AGENT_USE_SETTINGS)[number];
250
393
  declare const AGENT_EDITABLE_FIELDS: readonly ["displayName", "description", "welcomeMessage", "welcomeSubtitle", "instructions", "modelBindingId", "reasoningEffort", "maxSteps", "toolNames", "skillNames", "knowledgeBases", "initialPrompts"];
251
394
  type AgentEditableField = (typeof AGENT_EDITABLE_FIELDS)[number];
252
395
  declare const ASSET_REPO_BUNDLE_KINDS: readonly ["full", "incremental"];
@@ -282,6 +425,9 @@ type OpenaiCompatibleApi = (typeof OPENAI_COMPATIBLE_APIS)[number];
282
425
  declare const MODEL_PROVIDER_AUTH_MODES: readonly ["bearer", "api-key"];
283
426
  type ModelProviderAuthMode = (typeof MODEL_PROVIDER_AUTH_MODES)[number];
284
427
  declare const CONVERSATION_VISIBILITIES: readonly ["workspace", "private"];
428
+ /** A conversation a person has, or the run thread of a Child Agent Run. */
429
+ declare const CONVERSATION_KINDS: readonly ["chat", "run_thread"];
430
+ type ConversationKind = (typeof CONVERSATION_KINDS)[number];
285
431
  type ConversationVisibility = (typeof CONVERSATION_VISIBILITIES)[number];
286
432
  declare const WEB_SOURCE_PROVIDERS: readonly ["openai-native", "serper", "tavily", "firecrawl", "browserbase", "direct"];
287
433
  type WebSourceProvider = (typeof WEB_SOURCE_PROVIDERS)[number];
@@ -293,7 +439,11 @@ declare const ATTACHMENT_CREATE_OUTCOMES: readonly ["created", "already_availabl
293
439
  type AttachmentCreateOutcome = (typeof ATTACHMENT_CREATE_OUTCOMES)[number];
294
440
  declare const STRUCTURED_DATA_REVIEW_REASONS: readonly ["uncertain", "conflicting"];
295
441
  type StructuredDataReviewReason = (typeof STRUCTURED_DATA_REVIEW_REASONS)[number];
296
- declare const AGENT_RUN_STATUSES: readonly ["queued", "running", "waiting_for_decision", "cancelling", "completed", "cancelled", "failed"];
442
+ /** Queued: sent as the next turn. Steer: taken in by the author's own running turn (FU-2). */
443
+ declare const FOLLOW_UP_MODES: readonly ["queue", "steer"];
444
+ /** `consumed`: a steer the running turn took in; `dispatched`: started as a turn of its own. */
445
+ declare const FOLLOW_UP_STATUSES: readonly ["pending", "dispatched", "consumed", "cancelled"];
446
+ declare const AGENT_RUN_STATUSES: readonly ["queued", "running", "waiting_for_decision", "waiting_for_subagents", "cancelling", "completed", "cancelled", "failed"];
297
447
  type AgentRunStatus = (typeof AGENT_RUN_STATUSES)[number];
298
448
  declare const AGENT_RUN_FAILURE_CATEGORIES: readonly ["app_error", "internal_error", "runtime_interrupted", "abort_error", "unknown_error"];
299
449
  type AgentRunFailureCategory = (typeof AGENT_RUN_FAILURE_CATEGORIES)[number];
@@ -301,6 +451,10 @@ declare const TOOL_INPUT_PARSE_ERROR_CODES: readonly ["invalid_json", "invalid_t
301
451
  type ToolInputParseErrorCode = (typeof TOOL_INPUT_PARSE_ERROR_CODES)[number];
302
452
  declare const WAITING_OPERATION_RUN_STATUSES: readonly ["pending_confirmation", "pending_approval"];
303
453
  declare const OPERATION_CONFIRMATION_DECISIONS: readonly ["confirm", "decline"];
454
+ /** A person's own value for an operation (OP-6): Always allow, Ask me, Never. */
455
+ declare const PERSON_POLICY_SETTINGS: readonly ["always_allow", "ask", "never"];
456
+ /** How far a changing operation reaches. One that declares none counts as `irreversible`. */
457
+ declare const OPERATION_CHANGE_CLASSES: readonly ["reversible", "irreversible", "outward"];
304
458
  declare const TOOL_DECISION_MODES: readonly ["confirm", "approval"];
305
459
  declare const TOOL_DECISION_OUTCOMES: readonly ["confirmed", "declined", "expired", "cancelled"];
306
460
  declare const TOOL_CALL_STATES: readonly ["input_available", "waiting_for_decision", "output_available", "output_error"];
@@ -333,8 +487,39 @@ declare const CONNECTION_OPERATION_STATUSES: readonly ["ready", "awaiting_discov
333
487
  type ConnectionOperationStatus = (typeof CONNECTION_OPERATION_STATUSES)[number];
334
488
  declare const CONNECTION_SECRET_STATES: readonly ["set", "not_set", "unreadable"];
335
489
  type ConnectionSecretState = (typeof CONNECTION_SECRET_STATES)[number];
336
- declare const CONNECTOR_TEST_STATUSES: readonly ["ready", "unauthorized", "network_denied", "unavailable"];
490
+ declare const CONNECTOR_TEST_STATUSES: readonly ["ready", "unauthorized", "network_denied", "unavailable", "oauth_required"];
337
491
  type ConnectorTestStatus = (typeof CONNECTOR_TEST_STATUSES)[number];
492
+ /** Shared account, or the acting person's own account. */
493
+ declare const CONNECTION_CREDENTIAL_MODES: readonly ["shared", "user"];
494
+ type ConnectionCredentialMode = (typeof CONNECTION_CREDENTIAL_MODES)[number];
495
+ /**
496
+ * The state of a Connection's sign-in. `connected`: calls use it. `needs_reconnect`: the
497
+ * outside system refused it and a new sign-in is needed. `revoked`: someone disconnected it,
498
+ * or its Connection went away.
499
+ */
500
+ declare const CONNECTION_BINDING_STATES: readonly ["connected", "needs_reconnect", "revoked"];
501
+ type ConnectionBindingState = (typeof CONNECTION_BINDING_STATES)[number];
502
+ /** What a chat Connection proposal's card needs to start setup or sign-in. */
503
+ declare const CONNECTION_PROPOSAL_STATES: readonly ["ready", "needs_setup"];
504
+ type ConnectionProposalState = (typeof CONNECTION_PROPOSAL_STATES)[number];
505
+ declare const CONNECTION_PROPOSAL_BINDING_STATES: readonly ["connected", "needs_reconnect", "not_connected"];
506
+ type ConnectionProposalBindingState = (typeof CONNECTION_PROPOSAL_BINDING_STATES)[number];
507
+ /** What a refused call of a personal Connection needs of its person: a first or a new sign-in. */
508
+ declare const CONNECTION_SIGN_IN_NEEDS: readonly ["not_connected", "needs_reconnect"];
509
+ type ConnectionSignInNeed = (typeof CONNECTION_SIGN_IN_NEEDS)[number];
510
+ /**
511
+ * How a Connection that signs in with OAuth has its client: registered by the platform
512
+ * (Dynamic Client Registration), issued by the provider and named in the settings, or the
513
+ * operator's managed client of release config (`infrastructure.oauthClients`, MS-APP-1).
514
+ */
515
+ declare const CONNECTION_OAUTH_REGISTRATIONS: readonly ["dcr", "preregistered", "managed"];
516
+ type ConnectionOAuthRegistration = (typeof CONNECTION_OAUTH_REGISTRATIONS)[number];
517
+ /**
518
+ * What the provider answered to the revocation of a sign-in (RFC 7009): it confirmed, it
519
+ * failed or was not reached, or it lists no revocation endpoint and was sent nothing.
520
+ */
521
+ declare const CONNECTION_PROVIDER_REVOCATIONS: readonly ["confirmed", "failed", "not_offered"];
522
+ type ConnectionProviderRevocation = (typeof CONNECTION_PROVIDER_REVOCATIONS)[number];
338
523
  declare const CONNECTION_ORIGINS: readonly ["release", "runtime"];
339
524
  type ConnectionOrigin = (typeof CONNECTION_ORIGINS)[number];
340
525
  declare const CONNECTION_NETWORKS: readonly ["public", "private"];
@@ -351,19 +536,111 @@ declare const DATA_STORE_STATUSES: readonly ["provisioning", "ready", "retired"]
351
536
  type DataStoreStatus = (typeof DATA_STORE_STATUSES)[number];
352
537
  declare const DATA_STORE_MIGRATION_OUTCOMES: readonly ["none", "pending", "applied", "failed"];
353
538
  type DataStoreMigrationOutcome = (typeof DATA_STORE_MIGRATION_OUTCOMES)[number];
354
- declare const KNOWLEDGE_BASE_STATUSES: readonly ["unchecked", "ok", "needs_attention"];
539
+ /**
540
+ * `unchecked` until the first check; `preparing` while the store a Knowledge Base of documents
541
+ * owns is still being made; then `ok` or `needs_attention`.
542
+ */
543
+ declare const KNOWLEDGE_BASE_STATUSES: readonly ["unchecked", "preparing", "ok", "needs_attention"];
355
544
  type KnowledgeBaseStatus = (typeof KNOWLEDGE_BASE_STATUSES)[number];
545
+ /**
546
+ * The embedding of a Knowledge Base that searches by meaning. `current`: its index embeds with
547
+ * the model it is set to. `reindex_needed`: the index's model is gone from the instance, so
548
+ * search answers by words and titles alone. `reindex_available`: it is set to another model
549
+ * than its index uses. `reindexing`: a new index is being built beside the one search reads.
550
+ * `none`: nothing is embedded yet.
551
+ */
552
+ declare const KNOWLEDGE_EMBEDDING_STATES: readonly ["current", "reindex_needed", "reindex_available", "reindexing", "none"];
553
+ /**
554
+ * What the page of a Knowledge Base shows of one document. `pending` is added and not yet
555
+ * searchable: waiting for its index job, being indexed or waiting for extraction. `indexed` is
556
+ * found by search. `failed` carries one of `KNOWLEDGE_DOCUMENT_FAILURE_CODES`; Retry puts it
557
+ * back to `pending`.
558
+ */
559
+ declare const KNOWLEDGE_DOCUMENT_STATES: readonly ["pending", "indexed", "failed"];
560
+ type KnowledgeDocumentState = (typeof KNOWLEDGE_DOCUMENT_STATES)[number];
561
+ /**
562
+ * The largest file a Knowledge Base takes, as document processing takes it. A larger file is
563
+ * refused when it is added, with this limit named.
564
+ */
565
+ declare const KNOWLEDGE_FILE_MAX_BYTES: number;
566
+ /**
567
+ * Why a document was not indexed. The first five and `knowledge_file_too_many_pages` can also
568
+ * come from the extraction of a PDF or DOCX (`KNOWLEDGE_EXTRACTION_FAILURE_CODES` in core); the
569
+ * rest are the index job's own. The list only gains members.
570
+ */
571
+ declare const KNOWLEDGE_DOCUMENT_FAILURE_CODES: readonly ["knowledge_file_format_unsupported", "knowledge_file_over_limit", "knowledge_file_unreadable", "knowledge_file_missing", "knowledge_extraction_failed", "knowledge_file_format_unavailable", "knowledge_text_unreadable", "knowledge_text_empty", "knowledge_index_failed", "knowledge_file_too_many_pages", "knowledge_processor_output_invalid", "knowledge_conversion_timeout"];
572
+ type KnowledgeDocumentFailureCode = (typeof KNOWLEDGE_DOCUMENT_FAILURE_CODES)[number];
573
+ /**
574
+ * Why a `pending` document waits, where it waits for something other than its turn. It goes on
575
+ * by itself once the cause is gone.
576
+ */
577
+ declare const KNOWLEDGE_DOCUMENT_WAIT_CODES: readonly ["knowledge_usage_limit_reached"];
578
+ type KnowledgeDocumentWaitCode = (typeof KNOWLEDGE_DOCUMENT_WAIT_CODES)[number];
579
+ /**
580
+ * Why a synced source of a Knowledge Base, or one item of it, did not come in. Beside the
581
+ * document codes: an item over the size limit or of a format the instance does not read is
582
+ * recorded with `knowledge_file_over_limit` or `knowledge_file_format_unsupported` and never
583
+ * fetched. Spec: Synced sources, Contract freezes (SRC-0).
584
+ */
585
+ declare const KNOWLEDGE_SOURCE_FAILURE_CODES: readonly ["knowledge_source_unreachable", "knowledge_source_refused", "knowledge_fetch_failed", "knowledge_source_limit_reached", "knowledge_item_invalid", "knowledge_fetch_not_allowed", "knowledge_ingest_cancelled", "knowledge_item_removed"];
586
+ type KnowledgeSourceFailureCode = (typeof KNOWLEDGE_SOURCE_FAILURE_CODES)[number];
587
+ /** The code a failed item of a synced source carries: a source code, or one it shares with a file added by hand. */
588
+ declare const KNOWLEDGE_SOURCE_ITEM_FAILURE_CODES: readonly ["knowledge_source_unreachable", "knowledge_source_refused", "knowledge_fetch_failed", "knowledge_source_limit_reached", "knowledge_item_invalid", "knowledge_fetch_not_allowed", "knowledge_ingest_cancelled", "knowledge_item_removed", "knowledge_file_over_limit", "knowledge_file_format_unsupported"];
589
+ type KnowledgeSourceItemFailureCode = (typeof KNOWLEDGE_SOURCE_ITEM_FAILURE_CODES)[number];
590
+ /**
591
+ * The state of an item of a synced source as the sync keeps it. It ends at `fetched`: from
592
+ * then on the item shows its document's state. `withdrawn` is out of search.
593
+ */
594
+ declare const KNOWLEDGE_SOURCE_ITEM_STATES: readonly ["discovered", "fetched", "failed", "withdrawn"];
595
+ type KnowledgeSourceItemState = (typeof KNOWLEDGE_SOURCE_ITEM_STATES)[number];
596
+ /**
597
+ * How a sync of a source walks it: `initial` and `full` list every item below its folders,
598
+ * `changes` reads the source's change feed from the stored cursor, and `ingest` is one call
599
+ * of `knowledge.<id>.ingest` from a Workflow into its Workflow-fed source.
600
+ */
601
+ declare const KNOWLEDGE_SYNC_MODES: readonly ["initial", "changes", "full", "ingest"];
602
+ type KnowledgeSyncMode = (typeof KNOWLEDGE_SYNC_MODES)[number];
603
+ declare const KNOWLEDGE_SYNC_RUN_STATES: readonly ["running", "done", "failed", "superseded"];
604
+ type KnowledgeSyncRunState = (typeof KNOWLEDGE_SYNC_RUN_STATES)[number];
605
+ /** What a sync run counts, in this order wherever it shows them. */
606
+ declare const KNOWLEDGE_SYNC_COUNTS: readonly ["discovered", "added", "changed", "moved", "withdrawn", "failed", "skipped"];
607
+ type KnowledgeSyncCount = (typeof KNOWLEDGE_SYNC_COUNTS)[number];
608
+ /**
609
+ * The ranked lists a search on the built-in backend fuses: cosine distance to the query's
610
+ * embedding, German and English full text, and the words of a document's title and file name.
611
+ */
612
+ declare const KNOWLEDGE_SEARCH_SIGNALS: readonly ["semantic", "keyword", "title"];
613
+ type KnowledgeSearchSignal = (typeof KNOWLEDGE_SEARCH_SIGNALS)[number];
356
614
  declare const DATABASE_RELATION_TYPES: readonly ["table", "view", "materialized_view", "foreign_table"];
357
615
  type DatabaseRelationType = (typeof DATABASE_RELATION_TYPES)[number];
358
- declare const WORKFLOW_RUN_STATUSES: readonly ["queued", "running", "waiting", "done", "failed", "cancelled", "limit_reached"];
616
+ declare const WORKFLOW_RUN_STATUSES: readonly ["continued", "queued", "running", "waiting", "done", "failed", "cancelled", "limit_reached"];
359
617
  type WorkflowRunStatus = (typeof WORKFLOW_RUN_STATUSES)[number];
360
- declare const WORKFLOW_STEP_TYPES: readonly ["trigger", "operation", "loop", "code", "output", "agent", "notify", "workflow"];
618
+ declare const WORKFLOW_STEP_TYPES: readonly ["trigger", "operation", "loop", "code", "output", "agent", "notify", "workflow", "condition", "parallel"];
361
619
  type WorkflowStepType = (typeof WORKFLOW_STEP_TYPES)[number];
362
- declare const WORKFLOW_RESERVED_STEP_TYPES: readonly ["condition", "parallel"];
620
+ /**
621
+ * The step types this release executes. The engine accepts no definition that names another,
622
+ * and the interface offers no other in its palette (workflow-canvas 9.6). A list of its own, so
623
+ * it can be narrower than `WORKFLOW_STEP_TYPES` while a known type is not run yet.
624
+ */
625
+ declare const WORKFLOW_EXECUTED_STEP_TYPES: readonly ["trigger", "operation", "loop", "code", "output", "agent", "notify", "workflow", "condition", "parallel"];
626
+ declare const WORKFLOW_RESERVED_STEP_TYPES: readonly [];
363
627
  type WorkflowReservedStepType = (typeof WORKFLOW_RESERVED_STEP_TYPES)[number];
364
- declare const WORKFLOW_TRIGGER_KINDS: readonly ["manual", "schedule", "parent"];
628
+ declare const WORKFLOW_TRIGGER_KINDS: readonly ["manual", "schedule", "parent", "outside"];
365
629
  type WorkflowTriggerKind = (typeof WORKFLOW_TRIGGER_KINDS)[number];
366
630
  declare const NOTIFY_CHANNELS: readonly ["inbox", "mail"];
631
+ /**
632
+ * What an operation step's facts name as its source (`stepFacts`, workflow-canvas.md 9.8). A
633
+ * step on `mail.send` names its sender as `mail_sender`, with the sender's icon key as
634
+ * `service` (`MAIL_SENDER_SYSTEM_ICON`, or a Connection's service).
635
+ */
636
+ declare const WORKFLOW_STEP_SOURCE_KINDS: readonly ["connection", "data_store", "knowledge_base", "workflow", "mail_sender", "other"];
637
+ type WorkflowStepSourceKind = (typeof WORKFLOW_STEP_SOURCE_KINDS)[number];
638
+ /**
639
+ * What an operation a step may call belongs to (`operations.list_callable`, WF-EDIT-3). `other`
640
+ * is an operation of the release.
641
+ */
642
+ declare const OPERATION_SOURCE_KINDS: readonly ["connection", "data_store", "knowledge_base", "workflow", "other"];
643
+ type OperationSourceKind = (typeof OPERATION_SOURCE_KINDS)[number];
367
644
  type NotifyChannel = (typeof NOTIFY_CHANNELS)[number];
368
645
  declare const PRINCIPAL_HOLDER_KINDS: readonly ["user", "service_principal"];
369
646
  type PrincipalHolderKind = (typeof PRINCIPAL_HOLDER_KINDS)[number];
@@ -375,13 +652,19 @@ declare const CONNECTION_OPERATION_POLICIES: readonly ["deny", "approval"];
375
652
  type ConnectionOperationPolicy = (typeof CONNECTION_OPERATION_POLICIES)[number];
376
653
  declare const WORKFLOW_RUN_MODES: readonly ["live", "test"];
377
654
  type WorkflowRunMode = (typeof WORKFLOW_RUN_MODES)[number];
655
+ /**
656
+ * Which revision of a Workflow a test run an App's draft started ran (DP-1): its draft, for a
657
+ * tester who may write it, or its published revision.
658
+ */
659
+ declare const WORKFLOW_TEST_REVISIONS: readonly ["draft", "published"];
660
+ type WorkflowTestRevision = (typeof WORKFLOW_TEST_REVISIONS)[number];
378
661
  declare const APP_ACTION_CALL_STATUSES: readonly ["done", "pending_approval"];
379
662
  type AppActionCallStatus = (typeof APP_ACTION_CALL_STATUSES)[number];
380
663
  declare const OPERATIONS_AUDIENCES: readonly ["workflow", "app"];
381
664
  type OperationsAudience = (typeof OPERATIONS_AUDIENCES)[number];
382
665
  declare const DECIDED_APPROVAL_REQUEST_STATUSES: readonly ["approved", "rejected", "changes_requested", "superseded", "withdrawn", "reverted"];
383
666
  type DecidedApprovalRequestStatus = (typeof DECIDED_APPROVAL_REQUEST_STATUSES)[number];
384
- declare const ENDED_APPROVAL_EXECUTIONS: readonly ["done", "failed", "interrupted", "refused", "expired"];
667
+ declare const ENDED_APPROVAL_EXECUTIONS: readonly ["done", "failed", "interrupted", "refused", "expired", "held"];
385
668
  type EndedApprovalExecution = (typeof ENDED_APPROVAL_EXECUTIONS)[number];
386
669
  declare const GUARDRAIL_HIT_OUTCOMES: readonly ["warn", "require_approval", "block"];
387
670
  type GuardrailHitOutcome = (typeof GUARDRAIL_HIT_OUTCOMES)[number];
@@ -393,9 +676,16 @@ declare const USER_STATUSES: readonly ["active", "disabled"];
393
676
  type UserStatus = (typeof USER_STATUSES)[number];
394
677
  declare const MESSAGE_FINISH_STATUSES: readonly ["completed", "cancelled"];
395
678
  type MessageFinishStatus = (typeof MESSAGE_FINISH_STATUSES)[number];
679
+ /**
680
+ * Why a run went on with its binding's fallback, as the person reads it: the model was
681
+ * overloaded (`rate_limit`) or could not be reached (`unavailable`: a server error, a timeout or
682
+ * a lost connection).
683
+ */
684
+ declare const MODEL_FALLBACK_REASONS: readonly ["rate_limit", "unavailable"];
685
+ type ModelFallbackReason = (typeof MODEL_FALLBACK_REASONS)[number];
396
686
  declare const ENDED_AGENT_RUN_STATUSES: readonly ["completed", "cancelled", "failed"];
397
687
  type EndedAgentRunStatus = (typeof ENDED_AGENT_RUN_STATUSES)[number];
398
- declare const ACTIVE_AGENT_RUN_STATUSES: readonly ["queued", "running", "waiting_for_decision", "cancelling"];
688
+ declare const ACTIVE_AGENT_RUN_STATUSES: readonly ["queued", "running", "waiting_for_decision", "waiting_for_subagents", "cancelling"];
399
689
  type ActiveAgentRunStatus = (typeof ACTIVE_AGENT_RUN_STATUSES)[number];
400
690
  declare const ARTIFACT_PREVIEW_IMAGE_MIME_TYPES: readonly ["image/png", "image/jpeg", "image/webp"];
401
691
  type ArtifactPreviewImageMimeType = (typeof ARTIFACT_PREVIEW_IMAGE_MIME_TYPES)[number];
@@ -407,13 +697,73 @@ declare const AUDIT_EVENT_STATUSES: readonly ["success", "failed", "denied"];
407
697
  type AuditEventStatus = (typeof AUDIT_EVENT_STATUSES)[number];
408
698
  declare const LISTED_DATA_STORE_STATUSES: readonly ["provisioning", "ready"];
409
699
  type ListedDataStoreStatus = (typeof LISTED_DATA_STORE_STATUSES)[number];
410
- declare const KNOWLEDGE_CHECK_STATUSES: readonly ["ok", "needs_attention"];
700
+ declare const KNOWLEDGE_CHECK_STATUSES: readonly ["preparing", "ok", "needs_attention"];
411
701
  type KnowledgeCheckStatus = (typeof KNOWLEDGE_CHECK_STATUSES)[number];
412
702
  declare const WORKFLOW_STEP_RUN_STATUSES: readonly ["queued", "running", "waiting", "done", "failed", "cancelled"];
413
703
  type WorkflowStepRunStatus = (typeof WORKFLOW_STEP_RUN_STATUSES)[number];
414
- declare const WORKFLOW_ENDED_STATUSES: readonly ["done", "failed", "cancelled", "limit_reached"];
704
+ declare const WORKFLOW_ENDED_STATUSES: readonly ["continued", "done", "failed", "cancelled", "limit_reached"];
415
705
  type WorkflowEndedStatus = (typeof WORKFLOW_ENDED_STATUSES)[number];
706
+ /** A released Managed File keeps its identity; original bytes live at the synced source. */
707
+ declare const MANAGED_FILE_STATUSES: readonly ["available", "released", "deleted"];
708
+ /** A Workflow automates a process unless it fills or processes data. */
709
+ declare const WORKFLOW_KINDS: readonly ["process", "data"];
710
+ type WorkflowKind = (typeof WORKFLOW_KINDS)[number];
711
+ /** Wire formats for a streamed Workflow result dataset. */
712
+ declare const WORKFLOW_DATASET_DOWNLOAD_FORMATS: readonly ["jsonl", "csv"];
713
+ type WorkflowDatasetDownloadFormat = (typeof WORKFLOW_DATASET_DOWNLOAD_FORMATS)[number];
714
+ /** Instance resources whose use may be inherited through workspace availability. */
715
+ declare const WORKSPACE_USE_ASSET_KINDS: readonly ["knowledge_base", "connection"];
716
+ /** Published assets that consume Connections or stored data. Agents hold tools separately. */
717
+ declare const PUBLISHED_DATA_CONSUMER_KINDS: readonly ["app", "workflow", "knowledge_base"];
718
+ type PublishedDataConsumerKind = (typeof PUBLISHED_DATA_CONSUMER_KINDS)[number];
719
+ /** State of a scheduled prompt. */
720
+ declare const SCHEDULED_START_STATES: readonly ["active", "paused"];
721
+ /** Which revision answered an agent preview turn. */
722
+ declare const AGENT_PREVIEW_SOURCES: readonly ["draft", "live"];
723
+ /** Server capture admission and the shared request lifecycle (browser transport retained). */
724
+ declare const PREVIEW_CAPTURE_SIZES: readonly ["phone", "tablet", "desktop"];
725
+ declare const PREVIEW_CAPTURE_STATUSES: readonly ["pending", "answering", "captured", "refused"];
726
+ declare const SERVER_PREVIEW_CAPTURE_REFUSALS: readonly ["capture_busy", "capture_failed"];
727
+
728
+ /**
729
+ * The path of the interface route that shows one App to a signed-in person: the published
730
+ * revision under `/apps/`, or the draft under `/app-drafts/`. Every path below the published
731
+ * one is the App's own, so the draft stands outside it: an App may have any route, `/edit`
732
+ * among them. The server answers it from `apps.preview` and the interface builds its routes
733
+ * from it, so the two never disagree.
734
+ */
735
+ declare function appInterfacePath(input: {
736
+ workspaceId: string;
737
+ app: string;
738
+ mode: AppMode;
739
+ }): string;
740
+ /** The Studio list of each kind that has one, by the kind's id: `/build/<path>/<name>`. */
741
+ declare const STUDIO_KIND_PATHS: Readonly<Record<string, string>>;
742
+ /**
743
+ * The path of the page where a person works on an asset: its Studio page, a Workflow's canvas,
744
+ * or an App's draft. Nothing for a kind without a page, or for a Workflow or App without the
745
+ * workspace that owns it. It names only what the caller already read: kind, name and owner.
746
+ */
747
+ declare function assetPagePath(asset: {
748
+ kind: string;
749
+ name: string;
750
+ workspaceId?: string | undefined;
751
+ }): string | undefined;
752
+ /**
753
+ * The path of one conversation of a workspace: a link to it opens the conversation, so a person
754
+ * goes on there with the work it holds, such as the files of an App built in it.
755
+ */
756
+ declare function conversationInterfacePath(input: {
757
+ workspaceId: string;
758
+ conversationId: string;
759
+ }): string;
760
+ /** The path of one item of the Inbox, such as an approval request, by its id. */
761
+ declare function inboxItemPath(itemId: string): string;
762
+
763
+ declare function isRecord(value: unknown): value is Record<string, unknown>;
416
764
 
765
+ /** A short operator declaration of where a provider processes data. */
766
+ declare const providerRegionSchema: z.ZodString;
417
767
  declare const localizedStringSchema: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
418
768
  en: z.ZodOptional<z.ZodString>;
419
769
  de: z.ZodOptional<z.ZodString>;
@@ -572,6 +922,7 @@ declare const agentConfigSchema: z.ZodObject<{
572
922
  de: z.ZodOptional<z.ZodString>;
573
923
  }, z.core.$strict>]>>;
574
924
  instructions: z.ZodString;
925
+ additionalInstructions: z.ZodOptional<z.ZodString>;
575
926
  modelProviderId: z.ZodOptional<z.ZodString>;
576
927
  modelBindingId: z.ZodOptional<z.ZodString>;
577
928
  reasoningEffort: z.ZodOptional<z.ZodEnum<{
@@ -583,6 +934,7 @@ declare const agentConfigSchema: z.ZodObject<{
583
934
  max: "max";
584
935
  }>>;
585
936
  fastMode: z.ZodOptional<z.ZodBoolean>;
937
+ useModelFallback: z.ZodOptional<z.ZodBoolean>;
586
938
  userSelectableModelBindingIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
587
939
  modelReasoningEfforts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodEnum<{
588
940
  none: "none";
@@ -594,6 +946,7 @@ declare const agentConfigSchema: z.ZodObject<{
594
946
  }>>>;
595
947
  maxSteps: z.ZodOptional<z.ZodNumber>;
596
948
  toolNames: z.ZodDefault<z.ZodArray<z.ZodString>>;
949
+ subagentNames: z.ZodOptional<z.ZodArray<z.ZodString>>;
597
950
  skillNames: z.ZodDefault<z.ZodArray<z.ZodString>>;
598
951
  knowledgeBases: z.ZodOptional<z.ZodArray<z.ZodString>>;
599
952
  initialPrompts: z.ZodDefault<z.ZodArray<z.ZodObject<{
@@ -606,6 +959,8 @@ declare const agentConfigSchema: z.ZodObject<{
606
959
  de: z.ZodOptional<z.ZodString>;
607
960
  }, z.core.$strict>]>;
608
961
  }, z.core.$strip>>>;
962
+ shipped: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
963
+ shippedNewer: z.ZodOptional<z.ZodArray<z.ZodString>>;
609
964
  }, z.core.$strip>;
610
965
  /** The id of a Workflow, which is the name of its asset: part of `workflow.<id>.start`. */
611
966
  declare const WORKFLOW_NAME_PATTERN: RegExp;
@@ -632,6 +987,15 @@ declare const workflowConfigSchema: z.ZodObject<{
632
987
  }, z.core.$strict>;
633
988
  type WorkflowAssetConfig = z.infer<typeof workflowConfigSchema>;
634
989
 
990
+ /** Why a reference is refused as a secret name. It never repeats the reference. */
991
+ declare const SECRET_NAME_EXPECTATION = "expected the name of an environment variable such as MODEL_API_KEY (upper-case words joined by underscores, at most 64 characters); the value given does not read as one and looks like a credential value";
992
+ /**
993
+ * True for text that is safe to repeat as the name of a secret: it reads as an environment
994
+ * variable name and not as a credential. Anything else is refused as a name and is never put
995
+ * into a message, a log line or an error. The instance and the CLI apply the same rule.
996
+ */
997
+ declare function isSecretName(value: string): boolean;
998
+
635
999
  /**
636
1000
  * Why a frontmatter is refused before its fields are read: for an alias, for its depth, or
637
1001
  * for the size of what it holds beside the name, the title and the description.
@@ -748,6 +1112,12 @@ declare function checkStorableTexts(value: unknown, maxValues: number): "storabl
748
1112
  * aliases or holds text that cannot be stored is answered as an issue, never thrown.
749
1113
  */
750
1114
  declare function readYamlData(text: string, file: string, options?: YamlDataOptions): YamlDataResult;
1115
+ /**
1116
+ * Writes JSON data as the YAML text a server makes of a file, such as a `workflow.yaml` it
1117
+ * renders from a stored definition: keys in the order the value holds them, no anchors, no
1118
+ * folded lines. The same value gives the same bytes, and `readYamlData` reads it back as it was.
1119
+ */
1120
+ declare function writeYamlData(value: unknown): string;
751
1121
  /** A YAML file `loadYamlData` refused. `issue` says why. */
752
1122
  declare class YamlDataError extends Error {
753
1123
  readonly issue: YamlDataIssue;
@@ -756,4 +1126,2189 @@ declare class YamlDataError extends Error {
756
1126
  /** `readYamlData` for a caller that reports a refused file as an error: it throws `YamlDataError`. */
757
1127
  declare function loadYamlData(text: string, file: string): unknown;
758
1128
 
759
- export { ACCESS_SOURCES, ACTIONS, ACTIVE_AGENT_RUN_STATUSES, ADMINISTERED_USER_STATUSES, AGENT_AVAILABILITY_MODES, AGENT_EDITABLE_FIELDS, AGENT_RUN_FAILURE_CATEGORIES, AGENT_RUN_STATUSES, AGENT_STARTERS_MAX, API_CREDENTIAL_SCOPES, APPROVAL_CHECK_FAILURE_OUTCOMES, APPROVAL_CHECK_STATUSES, APPROVAL_EXECUTIONS, APPROVAL_REQUEST_STATUSES, APP_ACTION_CALL_STATUSES, APP_ERROR_CODES, APP_ERROR_STATUS_CODES, APP_MODES, ARTIFACT_PREVIEW_IMAGE_FORMATS, ARTIFACT_PREVIEW_IMAGE_MIME_TYPES, ARTIFACT_PREVIEW_STATUSES, ASSET_LIFECYCLES, ASSET_NAME_REFUSAL_REASONS, ASSET_OWNER_KINDS, ASSET_REPO_BUNDLE_KINDS, ASSET_REPRESENTATIONS, ASSET_SYNC_CHANGE_TYPES, ATTACHMENT_CREATE_OUTCOMES, AUDIT_ACTOR_KINDS, AUDIT_EVENT_STATUSES, AUDIT_OUTCOMES, AUDIT_TIERS, AUTH_PRINCIPAL_KINDS, AUTH_SCOPE_WILDCARD, type AccessSource, type ActiveAgentRunStatus, type AdministeredUserStatus, type AgentAvailabilityMode, type AgentConfig, type AgentEditableField, type AgentInitialPromptConfig, type AgentRunFailureCategory, type AgentRunStatus, type ApiCredentialScope, type AppActionCallStatus, type AppErrorCode, type AppMode, type ApprovalCheckFailureOutcome, type ApprovalCheckStatus, type ApprovalExecution, type ApprovalRequestStatus, type ArtifactPreviewImageFormat, type ArtifactPreviewImageMimeType, type ArtifactPreviewStatus, type AssetLifecycle, type AssetNameRefusalReason, type AssetOwnerKind, type AssetRepoBundleKind, type AssetRepresentation, type AssetSyncChangeType, type AttachmentCreateOutcome, type AuditActorKind, type AuditEventStatus, type AuditOutcome, type AuditTier, type AuthPrincipalKind, CHAT_MESSAGE_ROLES, CHAT_SESSION_AUTH_SCOPES, COLLABORATION_WORKSPACE_KINDS, CONFIG_ASSET_CHANGE_OPERATIONS, CONFIG_ASSET_KINDS, CONNECTION_EXPOSURES, CONNECTION_HEALTH_STATES, CONNECTION_NAME_MAX_LENGTH, CONNECTION_NAME_PATTERN, CONNECTION_NETWORKS, CONNECTION_OPERATION_POLICIES, CONNECTION_OPERATION_STATUSES, CONNECTION_ORIGINS, CONNECTION_SECRET_STATES, CONNECTOR_TEST_STATUSES, CONVERSATION_ATTACHMENT_STATUSES, CONVERSATION_VISIBILITIES, type ChatMessageRole, type ChatSessionAuthScope, type CollaborationWorkspaceKind, type ConfigAssetChangeOperation, type ConfigAssetKind, type ConnectionExposure, type ConnectionHealth, type ConnectionNetwork, type ConnectionOperationPolicy, type ConnectionOperationStatus, type ConnectionOrigin, type ConnectionSecretState, type ConnectorTestStatus, type ConversationAttachmentStatus, type ConversationVisibility, DATABASE_RELATION_TYPES, DATA_STORE_CONDITIONS, DATA_STORE_INSERT_CONFLICT_MODES, DATA_STORE_LOAD_CONFLICT_MODES, DATA_STORE_MIGRATION_OUTCOMES, DATA_STORE_SCALAR_TYPES, DATA_STORE_STATUSES, DECIDED_APPROVAL_REQUEST_STATUSES, DELETION_STATES, type DataStoreCondition, type DataStoreInsertConflictMode, type DataStoreLoadConflictMode, type DataStoreMigrationOutcome, type DataStoreScalarType, type DataStoreStatus, type DatabaseRelationType, type DecidedApprovalRequestStatus, type DeletionState, ENDED_AGENT_RUN_STATUSES, ENDED_APPROVAL_EXECUTIONS, type EndedAgentRunStatus, type EndedApprovalExecution, FAILED_JOB_STATUSES, FIRST_PARTY_AUTH_SCOPES, type FailedJobStatus, type FirstPartyAuthScope, GRANT_EFFECTS, GRANT_HOLDER_KINDS, GRANT_SCOPE_KINDS, GUARDRAIL_HIT_OUTCOMES, GUARDRAIL_NAME_MAX_LENGTH, GUARDRAIL_NAME_PATTERN, GUARDRAIL_OUTCOMES, type GrantEffect, type GrantHolderKind, type GrantScopeKind, type GuardrailHitOutcome, type GuardrailOutcome, IDEMPOTENCY_KEY_MAX_LENGTH, INFRASTRUCTURE_SECRET_STATES, INFRASTRUCTURE_WITHHELD_FIELDS, type InfrastructureSecretState, type InfrastructureWithheldField, JOB_STATUSES, type JobStatus, KNOWLEDGE_BASE_STATUSES, KNOWLEDGE_CHECK_STATUSES, type KnowledgeBaseStatus, type KnowledgeCheckStatus, LISTED_DATA_STORE_STATUSES, LIVE_JOB_STATUSES, type ListedDataStoreStatus, type LiveJobStatus, type LocaleCode, type LocalizedStringConfig, MESSAGE_FINISH_STATUSES, MODEL_PROVIDER_AUTH_MODES, MODEL_USAGE_EVENT_STATUSES, MODEL_USAGE_SOURCES, MODEL_USAGE_TIERS, type MessageFinishStatus, type ModelProviderAuthMode, type ModelUsageEventStatus, type ModelUsageSource, type ModelUsageTier, NAMESPACE_PREFIX_MAX_LENGTH, NAMESPACE_PREFIX_MIN_LENGTH, NAMESPACE_PREFIX_PATTERN, NOTIFY_CHANNELS, type NotifyChannel, OPENAI_COMPATIBLE_APIS, OPERATIONS_AUDIENCES, OPERATION_CONFIRMATION_DECISIONS, OPERATION_DENIAL_REASONS, OPERATION_EFFECTS, OPERATION_ORIGIN_KINDS, OPERATION_RUN_DECISION_MODES, OPERATION_RUN_DECISION_REASONS, OPERATION_RUN_STATUSES, OPERATION_TARGETS, type OpenaiCompatibleApi, type OperationDenialReason, type OperationEffect, type OperationOriginKind, type OperationRunDecisionMode, type OperationRunDecisionReason, type OperationRunStatus, type OperationScope, type OperationTarget, type OperationsAudience, POLICY_VALUES, PRINCIPAL_HOLDER_KINDS, PROVIDER_CHECK_ERROR_CLASSES, PROVIDER_PORTS, PROVIDER_REGIONS, type PlatformAction, type PolicyValue, type PrincipalHolderKind, type ProviderCheckErrorClass, type ProviderPort, type ProviderRegion, READING_POLICY_VALUES, REASONING_EFFORTS, type ReadingPolicyValue, type ReasoningEffortConfig, SERVICE_PRINCIPAL_PERMISSIONS, SERVICE_PRINCIPAL_STATUSES, SKILL_CHANGE_TYPES, SKILL_FRONTMATTER_FIELDS, SKILL_FRONTMATTER_MAX_BYTES, SKILL_FRONTMATTER_MAX_DEPTH, SKILL_NAME_PATTERN, SKILL_NAME_RULE, SKILL_ORIGINS, SKILL_PORTABLE_DESCRIPTION_MAX_CHARS, SKILL_PORTABLE_NAME_MAX_CHARS, SKILL_RESOURCE_MEDIA_TYPES, SKILL_STARTERS_MAX, SKILL_STARTER_LINE_MAX_LENGTH, SKILL_SUMMARY_MAX_LENGTH, STRUCTURED_DATA_REVIEW_REASONS, SUPPORTED_IMAGE_MIME_TYPES, type ServicePrincipalPermission, type ServicePrincipalStatus, type SkillChangeType, type SkillConfig, type SkillFileEntry, type SkillFrontmatterRefusal, SkillMarkdownError, type SkillOrigin, type SkillResourceConfig, type SkillResourceMediaType, type SkillStarterConfig, type StructuredDataReviewReason, type SupportedImageMimeType, THEME_MODES, THEME_MODE_PREFERENCES, TOOL_CALL_STATES, TOOL_DECISION_MODES, TOOL_DECISION_OUTCOMES, TOOL_DISPLAY_MODES, TOOL_GROUPS, TOOL_INPUT_PARSE_ERROR_CODES, type ThemeMode, type ThemeModePreference, type ToolCallState, type ToolDisplayMode, type ToolGroup, type ToolInputParseErrorCode, USAGE_COST_STATUSES, USER_STATUSES, type UsageCostStatus, type UserStatus, WAITING_OPERATION_RUN_STATUSES, WEB_SOURCE_PROVIDERS, WORKFLOW_ENDED_STATUSES, WORKFLOW_NAME_PATTERN, WORKFLOW_NAME_RULE, WORKFLOW_RESERVED_STEP_TYPES, WORKFLOW_RUN_MODES, WORKFLOW_RUN_STATUSES, WORKFLOW_STEP_RUN_STATUSES, WORKFLOW_STEP_TYPES, WORKFLOW_TRIGGER_KINDS, WORKSPACE_ACCENT_COLORS, WORKSPACE_ACCESS_STATES, WORKSPACE_COMMAND_STATUSES, WORKSPACE_FILE_KINDS, WORKSPACE_MEMBERSHIP_ROLES, WORKSPACE_SECTIONS, WORKSPACE_VISIBILITIES, type WebSourceProvider, type WorkflowAssetConfig, type WorkflowEndedStatus, type WorkflowReservedStepType, type WorkflowRunMode, type WorkflowRunStatus, type WorkflowStepRunStatus, type WorkflowStepType, type WorkflowTriggerKind, type WorkspaceAccentColor, type WorkspaceAccessState, type WorkspaceCommandStatus, type WorkspaceFileKind, type WorkspaceMembershipRole, type WorkspaceSection, type WorkspaceVisibility, YAML_DATA_MAX_VALUES, YamlDataError, type YamlDataIssue, type YamlDataIssueCode, type YamlDataOptions, type YamlDataResult, agentConfigSchema, checkStorableTexts, deriveSkillTitle, formatSkillMarkdown, isStorableText, loadYamlData, localeCodes, localizedStringSchema, parseSkillMarkdown, readYamlData, skillConfigSchema, skillFileEntrySchema, skillFileFrontmatterSchema, skillNameSchema, skillPortabilityIssues, skillResourceConfigSchema, skillResourceMediaTypeForPath, skillResourcePathSchema, skillStarterSchema, workflowConfigSchema, yamlValueIssue, yamlValueIssueSentence };
1129
+ declare const knowledgeSyncInputSchema: z.ZodObject<{
1130
+ source: z.ZodUnion<readonly [z.ZodString, z.ZodString]>;
1131
+ mode: z.ZodOptional<z.ZodEnum<{
1132
+ full: "full";
1133
+ changes: "changes";
1134
+ }>>;
1135
+ confirm: z.ZodOptional<z.ZodBoolean>;
1136
+ }, z.core.$strict>;
1137
+ type KnowledgeSyncInput = z.infer<typeof knowledgeSyncInputSchema>;
1138
+ /** What a sync run ends with: the result of its Operation Run, and a Workflow step's output. */
1139
+ declare const knowledgeSyncResultSchema: z.ZodObject<{
1140
+ syncRunId: z.ZodString;
1141
+ source: z.ZodString;
1142
+ mode: z.ZodEnum<{
1143
+ full: "full";
1144
+ initial: "initial";
1145
+ changes: "changes";
1146
+ ingest: "ingest";
1147
+ }>;
1148
+ reason: z.ZodOptional<z.ZodEnum<{
1149
+ cursor_expired: "cursor_expired";
1150
+ }>>;
1151
+ state: z.ZodEnum<{
1152
+ failed: "failed";
1153
+ running: "running";
1154
+ done: "done";
1155
+ superseded: "superseded";
1156
+ }>;
1157
+ counts: z.ZodObject<{
1158
+ discovered: z.ZodNumber;
1159
+ added: z.ZodNumber;
1160
+ changed: z.ZodNumber;
1161
+ moved: z.ZodNumber;
1162
+ withdrawn: z.ZodNumber;
1163
+ failed: z.ZodNumber;
1164
+ skipped: z.ZodNumber;
1165
+ }, z.core.$strict>;
1166
+ bytesFetched: z.ZodNumber;
1167
+ failureCode: z.ZodOptional<z.ZodEnum<{
1168
+ knowledge_source_unreachable: "knowledge_source_unreachable";
1169
+ knowledge_source_refused: "knowledge_source_refused";
1170
+ knowledge_fetch_failed: "knowledge_fetch_failed";
1171
+ knowledge_source_limit_reached: "knowledge_source_limit_reached";
1172
+ knowledge_item_invalid: "knowledge_item_invalid";
1173
+ knowledge_fetch_not_allowed: "knowledge_fetch_not_allowed";
1174
+ knowledge_ingest_cancelled: "knowledge_ingest_cancelled";
1175
+ knowledge_item_removed: "knowledge_item_removed";
1176
+ }>>;
1177
+ startedAt: z.ZodString;
1178
+ endedAt: z.ZodOptional<z.ZodString>;
1179
+ }, z.core.$strict>;
1180
+ type KnowledgeSyncResult = z.infer<typeof knowledgeSyncResultSchema>;
1181
+ /**
1182
+ * What the page shows of an item: its own state up to `fetched`, then its document's.
1183
+ * "Gefunden", "Geladen", "Durchsuchbar", "Fehlgeschlagen", "Entfernt".
1184
+ */
1185
+ declare const KNOWLEDGE_SOURCE_ITEM_SHOWN_STATES: readonly ["discovered", "fetched", "indexed", "failed", "withdrawn"];
1186
+ type KnowledgeSourceItemShownState = (typeof KNOWLEDGE_SOURCE_ITEM_SHOWN_STATES)[number];
1187
+ /**
1188
+ * A first pass that stopped at 10,000 items and waits for one confirmation (KB-ISO-1b): what the
1189
+ * whole pass holds and what it would cost, estimated from the listed sizes with a factor per
1190
+ * format. Counts and sizes only, never a name.
1191
+ */
1192
+ declare const knowledgeFirstPassConfirmationSchema: z.ZodObject<{
1193
+ syncRunId: z.ZodString;
1194
+ items: z.ZodNumber;
1195
+ bytes: z.ZodNumber;
1196
+ stop: z.ZodNumber;
1197
+ tokens: z.ZodOptional<z.ZodObject<{
1198
+ min: z.ZodNumber;
1199
+ max: z.ZodNumber;
1200
+ }, z.core.$strict>>;
1201
+ passages: z.ZodOptional<z.ZodObject<{
1202
+ min: z.ZodNumber;
1203
+ max: z.ZodNumber;
1204
+ }, z.core.$strict>>;
1205
+ model: z.ZodOptional<z.ZodString>;
1206
+ cost: z.ZodOptional<z.ZodObject<{
1207
+ min: z.ZodNumber;
1208
+ max: z.ZodNumber;
1209
+ currency: z.ZodString;
1210
+ }, z.core.$strict>>;
1211
+ room: z.ZodOptional<z.ZodBoolean>;
1212
+ storeBytes: z.ZodNumber;
1213
+ addedBytes: z.ZodOptional<z.ZodNumber>;
1214
+ limitBytes: z.ZodOptional<z.ZodNumber>;
1215
+ }, z.core.$strict>;
1216
+ type KnowledgeFirstPassConfirmation = z.infer<typeof knowledgeFirstPassConfirmationSchema>;
1217
+ declare const knowledgeSourcesOutputSchema: z.ZodObject<{
1218
+ sources: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
1219
+ id: z.ZodString;
1220
+ connection: z.ZodString;
1221
+ kind: z.ZodOptional<z.ZodLiteral<"connector">>;
1222
+ items: z.ZodObject<{
1223
+ discovered: z.ZodNumber;
1224
+ fetched: z.ZodNumber;
1225
+ indexed: z.ZodNumber;
1226
+ failed: z.ZodNumber;
1227
+ withdrawn: z.ZodNumber;
1228
+ }, z.core.$strict>;
1229
+ failures: z.ZodArray<z.ZodObject<{
1230
+ code: z.ZodUnion<readonly [z.ZodEnum<{
1231
+ knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
1232
+ knowledge_file_over_limit: "knowledge_file_over_limit";
1233
+ knowledge_source_unreachable: "knowledge_source_unreachable";
1234
+ knowledge_source_refused: "knowledge_source_refused";
1235
+ knowledge_fetch_failed: "knowledge_fetch_failed";
1236
+ knowledge_source_limit_reached: "knowledge_source_limit_reached";
1237
+ knowledge_item_invalid: "knowledge_item_invalid";
1238
+ knowledge_fetch_not_allowed: "knowledge_fetch_not_allowed";
1239
+ knowledge_ingest_cancelled: "knowledge_ingest_cancelled";
1240
+ knowledge_item_removed: "knowledge_item_removed";
1241
+ }>, z.ZodEnum<{
1242
+ knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
1243
+ knowledge_file_over_limit: "knowledge_file_over_limit";
1244
+ knowledge_file_unreadable: "knowledge_file_unreadable";
1245
+ knowledge_file_missing: "knowledge_file_missing";
1246
+ knowledge_extraction_failed: "knowledge_extraction_failed";
1247
+ knowledge_file_format_unavailable: "knowledge_file_format_unavailable";
1248
+ knowledge_text_unreadable: "knowledge_text_unreadable";
1249
+ knowledge_text_empty: "knowledge_text_empty";
1250
+ knowledge_index_failed: "knowledge_index_failed";
1251
+ knowledge_file_too_many_pages: "knowledge_file_too_many_pages";
1252
+ knowledge_processor_output_invalid: "knowledge_processor_output_invalid";
1253
+ knowledge_conversion_timeout: "knowledge_conversion_timeout";
1254
+ }>]>;
1255
+ count: z.ZodNumber;
1256
+ }, z.core.$strict>>;
1257
+ running: z.ZodOptional<z.ZodObject<{
1258
+ syncRunId: z.ZodString;
1259
+ mode: z.ZodEnum<{
1260
+ full: "full";
1261
+ initial: "initial";
1262
+ changes: "changes";
1263
+ ingest: "ingest";
1264
+ }>;
1265
+ startedAt: z.ZodString;
1266
+ itemsPerMinute: z.ZodOptional<z.ZodNumber>;
1267
+ estimatedEndAt: z.ZodOptional<z.ZodString>;
1268
+ }, z.core.$strict>>;
1269
+ last: z.ZodOptional<z.ZodObject<{
1270
+ syncRunId: z.ZodString;
1271
+ source: z.ZodString;
1272
+ mode: z.ZodEnum<{
1273
+ full: "full";
1274
+ initial: "initial";
1275
+ changes: "changes";
1276
+ ingest: "ingest";
1277
+ }>;
1278
+ reason: z.ZodOptional<z.ZodEnum<{
1279
+ cursor_expired: "cursor_expired";
1280
+ }>>;
1281
+ state: z.ZodEnum<{
1282
+ failed: "failed";
1283
+ running: "running";
1284
+ done: "done";
1285
+ superseded: "superseded";
1286
+ }>;
1287
+ counts: z.ZodObject<{
1288
+ discovered: z.ZodNumber;
1289
+ added: z.ZodNumber;
1290
+ changed: z.ZodNumber;
1291
+ moved: z.ZodNumber;
1292
+ withdrawn: z.ZodNumber;
1293
+ failed: z.ZodNumber;
1294
+ skipped: z.ZodNumber;
1295
+ }, z.core.$strict>;
1296
+ bytesFetched: z.ZodNumber;
1297
+ failureCode: z.ZodOptional<z.ZodEnum<{
1298
+ knowledge_source_unreachable: "knowledge_source_unreachable";
1299
+ knowledge_source_refused: "knowledge_source_refused";
1300
+ knowledge_fetch_failed: "knowledge_fetch_failed";
1301
+ knowledge_source_limit_reached: "knowledge_source_limit_reached";
1302
+ knowledge_item_invalid: "knowledge_item_invalid";
1303
+ knowledge_fetch_not_allowed: "knowledge_fetch_not_allowed";
1304
+ knowledge_ingest_cancelled: "knowledge_ingest_cancelled";
1305
+ knowledge_item_removed: "knowledge_item_removed";
1306
+ }>>;
1307
+ startedAt: z.ZodString;
1308
+ endedAt: z.ZodOptional<z.ZodString>;
1309
+ }, z.core.$strict>>;
1310
+ confirmation: z.ZodOptional<z.ZodObject<{
1311
+ syncRunId: z.ZodString;
1312
+ items: z.ZodNumber;
1313
+ bytes: z.ZodNumber;
1314
+ stop: z.ZodNumber;
1315
+ tokens: z.ZodOptional<z.ZodObject<{
1316
+ min: z.ZodNumber;
1317
+ max: z.ZodNumber;
1318
+ }, z.core.$strict>>;
1319
+ passages: z.ZodOptional<z.ZodObject<{
1320
+ min: z.ZodNumber;
1321
+ max: z.ZodNumber;
1322
+ }, z.core.$strict>>;
1323
+ model: z.ZodOptional<z.ZodString>;
1324
+ cost: z.ZodOptional<z.ZodObject<{
1325
+ min: z.ZodNumber;
1326
+ max: z.ZodNumber;
1327
+ currency: z.ZodString;
1328
+ }, z.core.$strict>>;
1329
+ room: z.ZodOptional<z.ZodBoolean>;
1330
+ storeBytes: z.ZodNumber;
1331
+ addedBytes: z.ZodOptional<z.ZodNumber>;
1332
+ limitBytes: z.ZodOptional<z.ZodNumber>;
1333
+ }, z.core.$strict>>;
1334
+ lastChangeAt: z.ZodOptional<z.ZodString>;
1335
+ oldestOpenChangeAt: z.ZodOptional<z.ZodString>;
1336
+ }, z.core.$strict>, z.ZodObject<{
1337
+ id: z.ZodString;
1338
+ kind: z.ZodLiteral<"workflow">;
1339
+ workflowId: z.ZodString;
1340
+ running: z.ZodOptional<z.ZodObject<{
1341
+ syncRunId: z.ZodString;
1342
+ mode: z.ZodEnum<{
1343
+ full: "full";
1344
+ initial: "initial";
1345
+ changes: "changes";
1346
+ ingest: "ingest";
1347
+ }>;
1348
+ startedAt: z.ZodString;
1349
+ itemsPerMinute: z.ZodOptional<z.ZodNumber>;
1350
+ estimatedEndAt: z.ZodOptional<z.ZodString>;
1351
+ }, z.core.$strict>>;
1352
+ failures: z.ZodArray<z.ZodObject<{
1353
+ code: z.ZodUnion<readonly [z.ZodEnum<{
1354
+ knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
1355
+ knowledge_file_over_limit: "knowledge_file_over_limit";
1356
+ knowledge_source_unreachable: "knowledge_source_unreachable";
1357
+ knowledge_source_refused: "knowledge_source_refused";
1358
+ knowledge_fetch_failed: "knowledge_fetch_failed";
1359
+ knowledge_source_limit_reached: "knowledge_source_limit_reached";
1360
+ knowledge_item_invalid: "knowledge_item_invalid";
1361
+ knowledge_fetch_not_allowed: "knowledge_fetch_not_allowed";
1362
+ knowledge_ingest_cancelled: "knowledge_ingest_cancelled";
1363
+ knowledge_item_removed: "knowledge_item_removed";
1364
+ }>, z.ZodEnum<{
1365
+ knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
1366
+ knowledge_file_over_limit: "knowledge_file_over_limit";
1367
+ knowledge_file_unreadable: "knowledge_file_unreadable";
1368
+ knowledge_file_missing: "knowledge_file_missing";
1369
+ knowledge_extraction_failed: "knowledge_extraction_failed";
1370
+ knowledge_file_format_unavailable: "knowledge_file_format_unavailable";
1371
+ knowledge_text_unreadable: "knowledge_text_unreadable";
1372
+ knowledge_text_empty: "knowledge_text_empty";
1373
+ knowledge_index_failed: "knowledge_index_failed";
1374
+ knowledge_file_too_many_pages: "knowledge_file_too_many_pages";
1375
+ knowledge_processor_output_invalid: "knowledge_processor_output_invalid";
1376
+ knowledge_conversion_timeout: "knowledge_conversion_timeout";
1377
+ }>]>;
1378
+ count: z.ZodNumber;
1379
+ }, z.core.$strict>>;
1380
+ items: z.ZodObject<{
1381
+ discovered: z.ZodNumber;
1382
+ fetched: z.ZodNumber;
1383
+ indexed: z.ZodNumber;
1384
+ failed: z.ZodNumber;
1385
+ withdrawn: z.ZodNumber;
1386
+ }, z.core.$strict>;
1387
+ last: z.ZodOptional<z.ZodObject<{
1388
+ syncRunId: z.ZodString;
1389
+ source: z.ZodString;
1390
+ mode: z.ZodEnum<{
1391
+ full: "full";
1392
+ initial: "initial";
1393
+ changes: "changes";
1394
+ ingest: "ingest";
1395
+ }>;
1396
+ reason: z.ZodOptional<z.ZodEnum<{
1397
+ cursor_expired: "cursor_expired";
1398
+ }>>;
1399
+ state: z.ZodEnum<{
1400
+ failed: "failed";
1401
+ running: "running";
1402
+ done: "done";
1403
+ superseded: "superseded";
1404
+ }>;
1405
+ counts: z.ZodObject<{
1406
+ discovered: z.ZodNumber;
1407
+ added: z.ZodNumber;
1408
+ changed: z.ZodNumber;
1409
+ moved: z.ZodNumber;
1410
+ withdrawn: z.ZodNumber;
1411
+ failed: z.ZodNumber;
1412
+ skipped: z.ZodNumber;
1413
+ }, z.core.$strict>;
1414
+ bytesFetched: z.ZodNumber;
1415
+ failureCode: z.ZodOptional<z.ZodEnum<{
1416
+ knowledge_source_unreachable: "knowledge_source_unreachable";
1417
+ knowledge_source_refused: "knowledge_source_refused";
1418
+ knowledge_fetch_failed: "knowledge_fetch_failed";
1419
+ knowledge_source_limit_reached: "knowledge_source_limit_reached";
1420
+ knowledge_item_invalid: "knowledge_item_invalid";
1421
+ knowledge_fetch_not_allowed: "knowledge_fetch_not_allowed";
1422
+ knowledge_ingest_cancelled: "knowledge_ingest_cancelled";
1423
+ knowledge_item_removed: "knowledge_item_removed";
1424
+ }>>;
1425
+ startedAt: z.ZodString;
1426
+ endedAt: z.ZodOptional<z.ZodString>;
1427
+ }, z.core.$strict>>;
1428
+ confirmation: z.ZodOptional<z.ZodObject<{
1429
+ syncRunId: z.ZodString;
1430
+ items: z.ZodNumber;
1431
+ bytes: z.ZodNumber;
1432
+ stop: z.ZodNumber;
1433
+ tokens: z.ZodOptional<z.ZodObject<{
1434
+ min: z.ZodNumber;
1435
+ max: z.ZodNumber;
1436
+ }, z.core.$strict>>;
1437
+ passages: z.ZodOptional<z.ZodObject<{
1438
+ min: z.ZodNumber;
1439
+ max: z.ZodNumber;
1440
+ }, z.core.$strict>>;
1441
+ model: z.ZodOptional<z.ZodString>;
1442
+ cost: z.ZodOptional<z.ZodObject<{
1443
+ min: z.ZodNumber;
1444
+ max: z.ZodNumber;
1445
+ currency: z.ZodString;
1446
+ }, z.core.$strict>>;
1447
+ room: z.ZodOptional<z.ZodBoolean>;
1448
+ storeBytes: z.ZodNumber;
1449
+ addedBytes: z.ZodOptional<z.ZodNumber>;
1450
+ limitBytes: z.ZodOptional<z.ZodNumber>;
1451
+ }, z.core.$strict>>;
1452
+ lastChangeAt: z.ZodOptional<z.ZodString>;
1453
+ oldestOpenChangeAt: z.ZodOptional<z.ZodString>;
1454
+ }, z.core.$strict>]>>;
1455
+ }, z.core.$strict>;
1456
+ type KnowledgeSourcesOutput = z.infer<typeof knowledgeSourcesOutputSchema>;
1457
+ declare const knowledgeSourceItemsInputSchema: z.ZodObject<{
1458
+ source: z.ZodUnion<readonly [z.ZodString, z.ZodString]>;
1459
+ state: z.ZodOptional<z.ZodEnum<{
1460
+ failed: "failed";
1461
+ withdrawn: "withdrawn";
1462
+ indexed: "indexed";
1463
+ discovered: "discovered";
1464
+ fetched: "fetched";
1465
+ }>>;
1466
+ failureCode: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
1467
+ knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
1468
+ knowledge_file_over_limit: "knowledge_file_over_limit";
1469
+ knowledge_source_unreachable: "knowledge_source_unreachable";
1470
+ knowledge_source_refused: "knowledge_source_refused";
1471
+ knowledge_fetch_failed: "knowledge_fetch_failed";
1472
+ knowledge_source_limit_reached: "knowledge_source_limit_reached";
1473
+ knowledge_item_invalid: "knowledge_item_invalid";
1474
+ knowledge_fetch_not_allowed: "knowledge_fetch_not_allowed";
1475
+ knowledge_ingest_cancelled: "knowledge_ingest_cancelled";
1476
+ knowledge_item_removed: "knowledge_item_removed";
1477
+ }>, z.ZodEnum<{
1478
+ knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
1479
+ knowledge_file_over_limit: "knowledge_file_over_limit";
1480
+ knowledge_file_unreadable: "knowledge_file_unreadable";
1481
+ knowledge_file_missing: "knowledge_file_missing";
1482
+ knowledge_extraction_failed: "knowledge_extraction_failed";
1483
+ knowledge_file_format_unavailable: "knowledge_file_format_unavailable";
1484
+ knowledge_text_unreadable: "knowledge_text_unreadable";
1485
+ knowledge_text_empty: "knowledge_text_empty";
1486
+ knowledge_index_failed: "knowledge_index_failed";
1487
+ knowledge_file_too_many_pages: "knowledge_file_too_many_pages";
1488
+ knowledge_processor_output_invalid: "knowledge_processor_output_invalid";
1489
+ knowledge_conversion_timeout: "knowledge_conversion_timeout";
1490
+ }>]>>;
1491
+ limit: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
1492
+ cursor: z.ZodOptional<z.ZodString>;
1493
+ }, z.core.$strict>;
1494
+ type KnowledgeSourceItemsInput = z.infer<typeof knowledgeSourceItemsInputSchema>;
1495
+ declare const knowledgeSourceItemsOutputSchema: z.ZodObject<{
1496
+ items: z.ZodArray<z.ZodObject<{
1497
+ id: z.ZodString;
1498
+ itemId: z.ZodString;
1499
+ name: z.ZodString;
1500
+ path: z.ZodString;
1501
+ state: z.ZodEnum<{
1502
+ failed: "failed";
1503
+ withdrawn: "withdrawn";
1504
+ indexed: "indexed";
1505
+ discovered: "discovered";
1506
+ fetched: "fetched";
1507
+ }>;
1508
+ failureCode: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
1509
+ knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
1510
+ knowledge_file_over_limit: "knowledge_file_over_limit";
1511
+ knowledge_source_unreachable: "knowledge_source_unreachable";
1512
+ knowledge_source_refused: "knowledge_source_refused";
1513
+ knowledge_fetch_failed: "knowledge_fetch_failed";
1514
+ knowledge_source_limit_reached: "knowledge_source_limit_reached";
1515
+ knowledge_item_invalid: "knowledge_item_invalid";
1516
+ knowledge_fetch_not_allowed: "knowledge_fetch_not_allowed";
1517
+ knowledge_ingest_cancelled: "knowledge_ingest_cancelled";
1518
+ knowledge_item_removed: "knowledge_item_removed";
1519
+ }>, z.ZodEnum<{
1520
+ knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
1521
+ knowledge_file_over_limit: "knowledge_file_over_limit";
1522
+ knowledge_file_unreadable: "knowledge_file_unreadable";
1523
+ knowledge_file_missing: "knowledge_file_missing";
1524
+ knowledge_extraction_failed: "knowledge_extraction_failed";
1525
+ knowledge_file_format_unavailable: "knowledge_file_format_unavailable";
1526
+ knowledge_text_unreadable: "knowledge_text_unreadable";
1527
+ knowledge_text_empty: "knowledge_text_empty";
1528
+ knowledge_index_failed: "knowledge_index_failed";
1529
+ knowledge_file_too_many_pages: "knowledge_file_too_many_pages";
1530
+ knowledge_processor_output_invalid: "knowledge_processor_output_invalid";
1531
+ knowledge_conversion_timeout: "knowledge_conversion_timeout";
1532
+ }>]>>;
1533
+ documentId: z.ZodOptional<z.ZodString>;
1534
+ originLink: z.ZodOptional<z.ZodString>;
1535
+ changedAt: z.ZodString;
1536
+ }, z.core.$strict>>;
1537
+ nextCursor: z.ZodOptional<z.ZodString>;
1538
+ }, z.core.$strict>;
1539
+ type KnowledgeSourceItemsOutput = z.infer<typeof knowledgeSourceItemsOutputSchema>;
1540
+ /**
1541
+ * KB-5c's retry, widened: documents by id, or items of a source by id, by failure code or all
1542
+ * failed ones. A failed fetch is fetched again; a failed document of a synced source is
1543
+ * fetched and indexed again, because its original is not kept.
1544
+ */
1545
+ declare const knowledgeRetryInputSchema: z.ZodUnion<readonly [z.ZodObject<{
1546
+ documentIds: z.ZodArray<z.ZodString>;
1547
+ }, z.core.$strict>, z.ZodObject<{
1548
+ source: z.ZodUnion<readonly [z.ZodString, z.ZodString]>;
1549
+ sourceItemIds: z.ZodArray<z.ZodString>;
1550
+ }, z.core.$strict>, z.ZodObject<{
1551
+ source: z.ZodUnion<readonly [z.ZodString, z.ZodString]>;
1552
+ failureCode: z.ZodUnion<readonly [z.ZodEnum<{
1553
+ knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
1554
+ knowledge_file_over_limit: "knowledge_file_over_limit";
1555
+ knowledge_source_unreachable: "knowledge_source_unreachable";
1556
+ knowledge_source_refused: "knowledge_source_refused";
1557
+ knowledge_fetch_failed: "knowledge_fetch_failed";
1558
+ knowledge_source_limit_reached: "knowledge_source_limit_reached";
1559
+ knowledge_item_invalid: "knowledge_item_invalid";
1560
+ knowledge_fetch_not_allowed: "knowledge_fetch_not_allowed";
1561
+ knowledge_ingest_cancelled: "knowledge_ingest_cancelled";
1562
+ knowledge_item_removed: "knowledge_item_removed";
1563
+ }>, z.ZodEnum<{
1564
+ knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
1565
+ knowledge_file_over_limit: "knowledge_file_over_limit";
1566
+ knowledge_file_unreadable: "knowledge_file_unreadable";
1567
+ knowledge_file_missing: "knowledge_file_missing";
1568
+ knowledge_extraction_failed: "knowledge_extraction_failed";
1569
+ knowledge_file_format_unavailable: "knowledge_file_format_unavailable";
1570
+ knowledge_text_unreadable: "knowledge_text_unreadable";
1571
+ knowledge_text_empty: "knowledge_text_empty";
1572
+ knowledge_index_failed: "knowledge_index_failed";
1573
+ knowledge_file_too_many_pages: "knowledge_file_too_many_pages";
1574
+ knowledge_processor_output_invalid: "knowledge_processor_output_invalid";
1575
+ knowledge_conversion_timeout: "knowledge_conversion_timeout";
1576
+ }>]>;
1577
+ }, z.core.$strict>, z.ZodObject<{
1578
+ source: z.ZodUnion<readonly [z.ZodString, z.ZodString]>;
1579
+ all: z.ZodLiteral<true>;
1580
+ }, z.core.$strict>]>;
1581
+ type KnowledgeRetryInput = z.infer<typeof knowledgeRetryInputSchema>;
1582
+ declare const knowledgeRetryOutputSchema: z.ZodObject<{
1583
+ documents: z.ZodOptional<z.ZodArray<z.ZodObject<{
1584
+ id: z.ZodString;
1585
+ state: z.ZodEnum<{
1586
+ failed: "failed";
1587
+ pending: "pending";
1588
+ indexed: "indexed";
1589
+ }>;
1590
+ }, z.core.$strict>>>;
1591
+ queued: z.ZodNumber;
1592
+ released: z.ZodOptional<z.ZodNumber>;
1593
+ }, z.core.$strict>;
1594
+ type KnowledgeRetryOutput = z.infer<typeof knowledgeRetryOutputSchema>;
1595
+ declare const knowledgeLocateInputSchema: z.ZodObject<{
1596
+ sourceItemId: z.ZodString;
1597
+ }, z.core.$strict>;
1598
+ type KnowledgeLocateInput = z.infer<typeof knowledgeLocateInputSchema>;
1599
+ /** An item's state and times, and no content, name or path. */
1600
+ declare const knowledgeLocateOutputSchema: z.ZodObject<{
1601
+ sourceItemId: z.ZodString;
1602
+ source: z.ZodString;
1603
+ itemId: z.ZodString;
1604
+ state: z.ZodEnum<{
1605
+ failed: "failed";
1606
+ withdrawn: "withdrawn";
1607
+ indexed: "indexed";
1608
+ discovered: "discovered";
1609
+ fetched: "fetched";
1610
+ }>;
1611
+ discoveredAt: z.ZodString;
1612
+ fetchedAt: z.ZodOptional<z.ZodString>;
1613
+ withdrawnAt: z.ZodOptional<z.ZodString>;
1614
+ purgedAt: z.ZodOptional<z.ZodString>;
1615
+ removedAt: z.ZodOptional<z.ZodString>;
1616
+ }, z.core.$strict>;
1617
+ type KnowledgeLocateOutput = z.infer<typeof knowledgeLocateOutputSchema>;
1618
+ /**
1619
+ * The delete question of a Workflow (KBW-2c): the Knowledge Bases its source feeds, each with
1620
+ * how many documents it holds there, which a delete withdraws. Those the reader may not open are
1621
+ * counted only, by number of Knowledge Bases and documents, and never named.
1622
+ */
1623
+ declare const knowledgeWorkflowSourcesOutputSchema: z.ZodObject<{
1624
+ knowledgeBases: z.ZodArray<z.ZodObject<{
1625
+ name: z.ZodString;
1626
+ title: z.ZodString;
1627
+ documents: z.ZodNumber;
1628
+ }, z.core.$strict>>;
1629
+ hidden: z.ZodObject<{
1630
+ knowledgeBases: z.ZodNumber;
1631
+ documents: z.ZodNumber;
1632
+ }, z.core.$strict>;
1633
+ }, z.core.$strict>;
1634
+ type KnowledgeWorkflowSourcesOutput = z.infer<typeof knowledgeWorkflowSourcesOutputSchema>;
1635
+
1636
+ /** Dataset checkpoints exposed in Workflow metadata; rows remain in object storage. */
1637
+ declare const WORKFLOW_DATASET_STATES: readonly ["writing", "complete", "deleted"];
1638
+ type WorkflowDatasetState = (typeof WORKFLOW_DATASET_STATES)[number];
1639
+
1640
+ /** The reference kept in step data; rows live in the owning run's dataset. */
1641
+ declare const workflowDatasetReferenceSchema: z.ZodObject<{
1642
+ $dataset: z.ZodString;
1643
+ rowCount: z.ZodNumber;
1644
+ bytes: z.ZodNumber;
1645
+ offset: z.ZodOptional<z.ZodNumber>;
1646
+ }, z.core.$strict>;
1647
+ /**
1648
+ * A file of a Workflow run as step data holds it: the id of the Managed File the run owns, its
1649
+ * name, its type and its size. The bytes stay in the run's files; no step carries them inline.
1650
+ */
1651
+ declare const workflowFileReferenceSchema: z.ZodObject<{
1652
+ $file: z.ZodString;
1653
+ name: z.ZodString;
1654
+ mimeType: z.ZodString;
1655
+ bytes: z.ZodNumber;
1656
+ }, z.core.$strict>;
1657
+ /** One row of a batch's failures dataset, preserving the input item for a retry. */
1658
+ declare const operationBatchFailureSchema: z.ZodObject<{
1659
+ item: z.ZodJSONSchema;
1660
+ code: z.ZodString;
1661
+ message: z.ZodString;
1662
+ }, z.core.$strict>;
1663
+ /** One failed item never fails the call or its neighbours. */
1664
+ declare const operationBatchResultSchema: z.ZodObject<{
1665
+ done: z.ZodNumber;
1666
+ failed: z.ZodNumber;
1667
+ failures: z.ZodObject<{
1668
+ $dataset: z.ZodString;
1669
+ rowCount: z.ZodNumber;
1670
+ bytes: z.ZodNumber;
1671
+ offset: z.ZodOptional<z.ZodNumber>;
1672
+ }, z.core.$strict>;
1673
+ }, z.core.$strict>;
1674
+ type OperationBatchResult = z.infer<typeof operationBatchResultSchema>;
1675
+ type OperationBatchFailure = z.infer<typeof operationBatchFailureSchema>;
1676
+
1677
+ /** Reserved until CONN-DL: the Workflow's account must be allowed to use this Connection. */
1678
+ declare const knowledgeIngestFetchSchema: z.ZodObject<{
1679
+ connection: z.ZodString;
1680
+ operation: z.ZodString;
1681
+ input: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
1682
+ }, z.core.$strict>;
1683
+ /** Exactly one content, in both the TypeScript type and the runtime schema. */
1684
+ declare const knowledgeIngestItemSchema: z.ZodUnion<readonly [z.ZodObject<{
1685
+ itemId: z.ZodString;
1686
+ version: z.ZodString;
1687
+ name: z.ZodString;
1688
+ path: z.ZodOptional<z.ZodString>;
1689
+ originLink: z.ZodOptional<z.ZodURL>;
1690
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
1691
+ fileId: z.ZodOptional<z.ZodNever>;
1692
+ fetch: z.ZodOptional<z.ZodNever>;
1693
+ text: z.ZodString;
1694
+ }, z.core.$strict>, z.ZodObject<{
1695
+ itemId: z.ZodString;
1696
+ version: z.ZodString;
1697
+ name: z.ZodString;
1698
+ path: z.ZodOptional<z.ZodString>;
1699
+ originLink: z.ZodOptional<z.ZodURL>;
1700
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
1701
+ text: z.ZodOptional<z.ZodNever>;
1702
+ fetch: z.ZodOptional<z.ZodNever>;
1703
+ fileId: z.ZodString;
1704
+ }, z.core.$strict>, z.ZodObject<{
1705
+ itemId: z.ZodString;
1706
+ version: z.ZodString;
1707
+ name: z.ZodString;
1708
+ path: z.ZodOptional<z.ZodString>;
1709
+ originLink: z.ZodOptional<z.ZodURL>;
1710
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
1711
+ text: z.ZodOptional<z.ZodNever>;
1712
+ fileId: z.ZodOptional<z.ZodNever>;
1713
+ fetch: z.ZodObject<{
1714
+ connection: z.ZodString;
1715
+ operation: z.ZodString;
1716
+ input: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
1717
+ }, z.core.$strict>;
1718
+ }, z.core.$strict>]>;
1719
+ type KnowledgeIngestItem = z.infer<typeof knowledgeIngestItemSchema>;
1720
+ declare const knowledgeIngestInputSchema: z.ZodUnion<readonly [z.ZodObject<{
1721
+ items: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
1722
+ itemId: z.ZodString;
1723
+ version: z.ZodString;
1724
+ name: z.ZodString;
1725
+ path: z.ZodOptional<z.ZodString>;
1726
+ originLink: z.ZodOptional<z.ZodURL>;
1727
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
1728
+ fileId: z.ZodOptional<z.ZodNever>;
1729
+ fetch: z.ZodOptional<z.ZodNever>;
1730
+ text: z.ZodString;
1731
+ }, z.core.$strict>, z.ZodObject<{
1732
+ itemId: z.ZodString;
1733
+ version: z.ZodString;
1734
+ name: z.ZodString;
1735
+ path: z.ZodOptional<z.ZodString>;
1736
+ originLink: z.ZodOptional<z.ZodURL>;
1737
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
1738
+ text: z.ZodOptional<z.ZodNever>;
1739
+ fetch: z.ZodOptional<z.ZodNever>;
1740
+ fileId: z.ZodString;
1741
+ }, z.core.$strict>, z.ZodObject<{
1742
+ itemId: z.ZodString;
1743
+ version: z.ZodString;
1744
+ name: z.ZodString;
1745
+ path: z.ZodOptional<z.ZodString>;
1746
+ originLink: z.ZodOptional<z.ZodURL>;
1747
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
1748
+ text: z.ZodOptional<z.ZodNever>;
1749
+ fileId: z.ZodOptional<z.ZodNever>;
1750
+ fetch: z.ZodObject<{
1751
+ connection: z.ZodString;
1752
+ operation: z.ZodString;
1753
+ input: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
1754
+ }, z.core.$strict>;
1755
+ }, z.core.$strict>]>>;
1756
+ complete: z.ZodOptional<z.ZodBoolean>;
1757
+ }, z.core.$strict>, z.ZodObject<{
1758
+ dataset: z.ZodObject<{
1759
+ $dataset: z.ZodString;
1760
+ rowCount: z.ZodNumber;
1761
+ bytes: z.ZodNumber;
1762
+ offset: z.ZodOptional<z.ZodNumber>;
1763
+ }, z.core.$strict>;
1764
+ complete: z.ZodOptional<z.ZodBoolean>;
1765
+ }, z.core.$strict>]>;
1766
+ declare const knowledgeIngestOutputSchema: z.ZodObject<{
1767
+ done: z.ZodNumber;
1768
+ failed: z.ZodNumber;
1769
+ failures: z.ZodObject<{
1770
+ $dataset: z.ZodString;
1771
+ rowCount: z.ZodNumber;
1772
+ bytes: z.ZodNumber;
1773
+ offset: z.ZodOptional<z.ZodNumber>;
1774
+ }, z.core.$strict>;
1775
+ accepted: z.ZodNumber;
1776
+ withdrawn: z.ZodNumber;
1777
+ }, z.core.$strict>;
1778
+ declare const knowledgeWithdrawInputSchema: z.ZodObject<{
1779
+ itemIds: z.ZodArray<z.ZodString>;
1780
+ }, z.core.$strict>;
1781
+ declare const knowledgeWithdrawOutputSchema: z.ZodObject<{
1782
+ withdrawn: z.ZodNumber;
1783
+ }, z.core.$strict>;
1784
+ declare const knowledgePendingInputSchema: z.ZodObject<{
1785
+ type: z.ZodOptional<z.ZodString>;
1786
+ since: z.ZodOptional<z.ZodISODateTime>;
1787
+ limit: z.ZodNumber;
1788
+ }, z.core.$strict>;
1789
+ declare const knowledgePendingRowSchema: z.ZodObject<{
1790
+ id: z.ZodString;
1791
+ type: z.ZodString;
1792
+ contentHash: z.ZodString;
1793
+ pages: z.ZodObject<{
1794
+ $dataset: z.ZodString;
1795
+ rowCount: z.ZodNumber;
1796
+ bytes: z.ZodNumber;
1797
+ offset: z.ZodOptional<z.ZodNumber>;
1798
+ }, z.core.$strict>;
1799
+ }, z.core.$strict>;
1800
+ declare const knowledgePendingOutputSchema: z.ZodObject<{
1801
+ documents: z.ZodObject<{
1802
+ $dataset: z.ZodString;
1803
+ rowCount: z.ZodNumber;
1804
+ bytes: z.ZodNumber;
1805
+ offset: z.ZodOptional<z.ZodNumber>;
1806
+ }, z.core.$strict>;
1807
+ }, z.core.$strict>;
1808
+ /**
1809
+ * A processor returns logical documents and page text (tables as Markdown), optional
1810
+ * section boundaries and fields. Chunking and vectors remain the platform's. This is the
1811
+ * single validator for built-ins and Workflow write-back; every refusal has the code
1812
+ * knowledge_processor_output_invalid. Fields' declared JSON Schema is checked by PROC-1.
1813
+ */
1814
+ declare const knowledgeProcessorOutputSchema: z.ZodObject<{
1815
+ documents: z.ZodArray<z.ZodObject<{
1816
+ pageFrom: z.ZodNumber;
1817
+ pageTo: z.ZodNumber;
1818
+ }, z.core.$strict>>;
1819
+ sections: z.ZodOptional<z.ZodArray<z.ZodObject<{
1820
+ pageFrom: z.ZodNumber;
1821
+ pageTo: z.ZodNumber;
1822
+ title: z.ZodString;
1823
+ }, z.core.$strict>>>;
1824
+ fields: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
1825
+ pages: z.ZodArray<z.ZodObject<{
1826
+ page: z.ZodNumber;
1827
+ text: z.ZodString;
1828
+ }, z.core.$strict>>;
1829
+ }, z.core.$strict>;
1830
+ type KnowledgeProcessorOutput = z.infer<typeof knowledgeProcessorOutputSchema>;
1831
+ declare const knowledgePutProcessedInputSchema: z.ZodObject<{
1832
+ items: z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
1833
+ documentId: z.ZodString;
1834
+ contentHash: z.ZodString;
1835
+ workflowRevision: z.ZodString;
1836
+ output: z.ZodObject<{
1837
+ documents: z.ZodArray<z.ZodObject<{
1838
+ pageFrom: z.ZodNumber;
1839
+ pageTo: z.ZodNumber;
1840
+ }, z.core.$strict>>;
1841
+ sections: z.ZodOptional<z.ZodArray<z.ZodObject<{
1842
+ pageFrom: z.ZodNumber;
1843
+ pageTo: z.ZodNumber;
1844
+ title: z.ZodString;
1845
+ }, z.core.$strict>>>;
1846
+ fields: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
1847
+ pages: z.ZodObject<{
1848
+ $dataset: z.ZodString;
1849
+ rowCount: z.ZodNumber;
1850
+ bytes: z.ZodNumber;
1851
+ offset: z.ZodOptional<z.ZodNumber>;
1852
+ }, z.core.$strict>;
1853
+ }, z.core.$strict>;
1854
+ }, z.core.$strict>>, z.ZodObject<{
1855
+ $dataset: z.ZodString;
1856
+ rowCount: z.ZodNumber;
1857
+ bytes: z.ZodNumber;
1858
+ offset: z.ZodOptional<z.ZodNumber>;
1859
+ }, z.core.$strict>]>;
1860
+ }, z.core.$strict>;
1861
+ declare const knowledgeFieldValueSchema: z.ZodJSONSchema;
1862
+ declare const knowledgeExtractFieldsInputSchema: z.ZodObject<{
1863
+ documentId: z.ZodString;
1864
+ schema: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
1865
+ }, z.core.$strict>;
1866
+ declare const knowledgeExtractFieldsOutputSchema: z.ZodObject<{
1867
+ droppedFields: z.ZodOptional<z.ZodNumber>;
1868
+ failedFields: z.ZodOptional<z.ZodNumber>;
1869
+ path: z.ZodString;
1870
+ date: z.ZodNullable<z.ZodISODate>;
1871
+ type: z.ZodString;
1872
+ fields: z.ZodRecord<z.ZodString, z.ZodObject<{
1873
+ value: z.ZodJSONSchema;
1874
+ page: z.ZodNumber;
1875
+ quote: z.ZodString;
1876
+ }, z.core.$strict>>;
1877
+ }, z.core.$strict>;
1878
+ /** Created by the first ingest, never authored in kb.yaml; the id cannot collide with a connector source. */
1879
+ declare const knowledgeWorkflowSourceSchema: z.ZodObject<{
1880
+ id: z.ZodString;
1881
+ kind: z.ZodLiteral<"workflow">;
1882
+ workflowId: z.ZodString;
1883
+ }, z.core.$strict>;
1884
+ type KnowledgeWorkflowSource = z.infer<typeof knowledgeWorkflowSourceSchema>;
1885
+ /** Contract inventory; completion, batch and dataset are present only where the table declares them. */
1886
+ declare const knowledgeWriteContracts: {
1887
+ readonly ingest: {
1888
+ readonly description: "Ingest items or a dataset into the calling data Workflow's source; complete promises a full pass, withdrawn only after the run succeeds.";
1889
+ readonly inputSchema: z.ZodUnion<readonly [z.ZodObject<{
1890
+ items: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
1891
+ itemId: z.ZodString;
1892
+ version: z.ZodString;
1893
+ name: z.ZodString;
1894
+ path: z.ZodOptional<z.ZodString>;
1895
+ originLink: z.ZodOptional<z.ZodURL>;
1896
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
1897
+ fileId: z.ZodOptional<z.ZodNever>;
1898
+ fetch: z.ZodOptional<z.ZodNever>;
1899
+ text: z.ZodString;
1900
+ }, z.core.$strict>, z.ZodObject<{
1901
+ itemId: z.ZodString;
1902
+ version: z.ZodString;
1903
+ name: z.ZodString;
1904
+ path: z.ZodOptional<z.ZodString>;
1905
+ originLink: z.ZodOptional<z.ZodURL>;
1906
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
1907
+ text: z.ZodOptional<z.ZodNever>;
1908
+ fetch: z.ZodOptional<z.ZodNever>;
1909
+ fileId: z.ZodString;
1910
+ }, z.core.$strict>, z.ZodObject<{
1911
+ itemId: z.ZodString;
1912
+ version: z.ZodString;
1913
+ name: z.ZodString;
1914
+ path: z.ZodOptional<z.ZodString>;
1915
+ originLink: z.ZodOptional<z.ZodURL>;
1916
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
1917
+ text: z.ZodOptional<z.ZodNever>;
1918
+ fileId: z.ZodOptional<z.ZodNever>;
1919
+ fetch: z.ZodObject<{
1920
+ connection: z.ZodString;
1921
+ operation: z.ZodString;
1922
+ input: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
1923
+ }, z.core.$strict>;
1924
+ }, z.core.$strict>]>>;
1925
+ complete: z.ZodOptional<z.ZodBoolean>;
1926
+ }, z.core.$strict>, z.ZodObject<{
1927
+ dataset: z.ZodObject<{
1928
+ $dataset: z.ZodString;
1929
+ rowCount: z.ZodNumber;
1930
+ bytes: z.ZodNumber;
1931
+ offset: z.ZodOptional<z.ZodNumber>;
1932
+ }, z.core.$strict>;
1933
+ complete: z.ZodOptional<z.ZodBoolean>;
1934
+ }, z.core.$strict>]>;
1935
+ readonly outputSchema: z.ZodObject<{
1936
+ done: z.ZodNumber;
1937
+ failed: z.ZodNumber;
1938
+ failures: z.ZodObject<{
1939
+ $dataset: z.ZodString;
1940
+ rowCount: z.ZodNumber;
1941
+ bytes: z.ZodNumber;
1942
+ offset: z.ZodOptional<z.ZodNumber>;
1943
+ }, z.core.$strict>;
1944
+ accepted: z.ZodNumber;
1945
+ withdrawn: z.ZodNumber;
1946
+ }, z.core.$strict>;
1947
+ readonly effect: "changing";
1948
+ readonly right: "knowledge_base.ingest";
1949
+ readonly keyLevel: "write";
1950
+ readonly completion: "async";
1951
+ readonly batch: true;
1952
+ };
1953
+ readonly withdraw: {
1954
+ readonly description: "Withdraw item ids from the calling Workflow's source; removed from search immediately.";
1955
+ readonly inputSchema: z.ZodObject<{
1956
+ itemIds: z.ZodArray<z.ZodString>;
1957
+ }, z.core.$strict>;
1958
+ readonly outputSchema: z.ZodObject<{
1959
+ withdrawn: z.ZodNumber;
1960
+ }, z.core.$strict>;
1961
+ readonly effect: "changing";
1962
+ readonly right: "knowledge_base.ingest";
1963
+ readonly keyLevel: "write";
1964
+ };
1965
+ readonly pending: {
1966
+ readonly description: "Pull pending documents by type and time as a dataset; page text is another dataset reference.";
1967
+ readonly inputSchema: z.ZodObject<{
1968
+ type: z.ZodOptional<z.ZodString>;
1969
+ since: z.ZodOptional<z.ZodISODateTime>;
1970
+ limit: z.ZodNumber;
1971
+ }, z.core.$strict>;
1972
+ readonly outputSchema: z.ZodObject<{
1973
+ documents: z.ZodObject<{
1974
+ $dataset: z.ZodString;
1975
+ rowCount: z.ZodNumber;
1976
+ bytes: z.ZodNumber;
1977
+ offset: z.ZodOptional<z.ZodNumber>;
1978
+ }, z.core.$strict>;
1979
+ }, z.core.$strict>;
1980
+ readonly rowSchema: z.ZodObject<{
1981
+ id: z.ZodString;
1982
+ type: z.ZodString;
1983
+ contentHash: z.ZodString;
1984
+ pages: z.ZodObject<{
1985
+ $dataset: z.ZodString;
1986
+ rowCount: z.ZodNumber;
1987
+ bytes: z.ZodNumber;
1988
+ offset: z.ZodOptional<z.ZodNumber>;
1989
+ }, z.core.$strict>;
1990
+ }, z.core.$strict>;
1991
+ readonly effect: "reading";
1992
+ readonly right: "knowledge_base.read";
1993
+ readonly keyLevel: "read";
1994
+ readonly dataset: true;
1995
+ };
1996
+ readonly put_processed: {
1997
+ readonly description: "Write processor output by document, content hash and Workflow revision, with pages as a dataset reference like pending; the platform validates, chunks and indexes it, with per-item outcomes.";
1998
+ readonly inputSchema: z.ZodObject<{
1999
+ items: z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
2000
+ documentId: z.ZodString;
2001
+ contentHash: z.ZodString;
2002
+ workflowRevision: z.ZodString;
2003
+ output: z.ZodObject<{
2004
+ documents: z.ZodArray<z.ZodObject<{
2005
+ pageFrom: z.ZodNumber;
2006
+ pageTo: z.ZodNumber;
2007
+ }, z.core.$strict>>;
2008
+ sections: z.ZodOptional<z.ZodArray<z.ZodObject<{
2009
+ pageFrom: z.ZodNumber;
2010
+ pageTo: z.ZodNumber;
2011
+ title: z.ZodString;
2012
+ }, z.core.$strict>>>;
2013
+ fields: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
2014
+ pages: z.ZodObject<{
2015
+ $dataset: z.ZodString;
2016
+ rowCount: z.ZodNumber;
2017
+ bytes: z.ZodNumber;
2018
+ offset: z.ZodOptional<z.ZodNumber>;
2019
+ }, z.core.$strict>;
2020
+ }, z.core.$strict>;
2021
+ }, z.core.$strict>>, z.ZodObject<{
2022
+ $dataset: z.ZodString;
2023
+ rowCount: z.ZodNumber;
2024
+ bytes: z.ZodNumber;
2025
+ offset: z.ZodOptional<z.ZodNumber>;
2026
+ }, z.core.$strict>]>;
2027
+ }, z.core.$strict>;
2028
+ readonly outputSchema: z.ZodObject<{
2029
+ done: z.ZodNumber;
2030
+ failed: z.ZodNumber;
2031
+ failures: z.ZodObject<{
2032
+ $dataset: z.ZodString;
2033
+ rowCount: z.ZodNumber;
2034
+ bytes: z.ZodNumber;
2035
+ offset: z.ZodOptional<z.ZodNumber>;
2036
+ }, z.core.$strict>;
2037
+ }, z.core.$strict>;
2038
+ readonly effect: "changing";
2039
+ readonly right: "knowledge_base.ingest";
2040
+ readonly keyLevel: "write";
2041
+ readonly batch: true;
2042
+ };
2043
+ readonly extract_fields: {
2044
+ readonly description: "Extract fields by schema through the approved model binding within the Knowledge Base budget; each value carries page and quote evidence.";
2045
+ readonly inputSchema: z.ZodObject<{
2046
+ documentId: z.ZodString;
2047
+ schema: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
2048
+ }, z.core.$strict>;
2049
+ readonly outputSchema: z.ZodObject<{
2050
+ droppedFields: z.ZodOptional<z.ZodNumber>;
2051
+ failedFields: z.ZodOptional<z.ZodNumber>;
2052
+ path: z.ZodString;
2053
+ date: z.ZodNullable<z.ZodISODate>;
2054
+ type: z.ZodString;
2055
+ fields: z.ZodRecord<z.ZodString, z.ZodObject<{
2056
+ value: z.ZodJSONSchema;
2057
+ page: z.ZodNumber;
2058
+ quote: z.ZodString;
2059
+ }, z.core.$strict>>;
2060
+ }, z.core.$strict>;
2061
+ readonly effect: "reading";
2062
+ readonly right: "knowledge_base.read";
2063
+ readonly keyLevel: "read";
2064
+ };
2065
+ };
2066
+ /** Records rules belong to the Data Store; kb.yaml must never hold them. */
2067
+ declare const knowledgeRecordsRefusalSchema: z.ZodOptional<z.ZodNever>;
2068
+ type KnowledgeIngestInput = z.infer<typeof knowledgeIngestInputSchema>;
2069
+ type KnowledgeIngestOutput = z.infer<typeof knowledgeIngestOutputSchema>;
2070
+ type KnowledgeIngestFetch = z.infer<typeof knowledgeIngestFetchSchema>;
2071
+ type KnowledgeWithdrawInput = z.infer<typeof knowledgeWithdrawInputSchema>;
2072
+ type KnowledgeWithdrawOutput = z.infer<typeof knowledgeWithdrawOutputSchema>;
2073
+ type KnowledgePendingInput = z.infer<typeof knowledgePendingInputSchema>;
2074
+ type KnowledgePendingRow = z.infer<typeof knowledgePendingRowSchema>;
2075
+ type KnowledgePendingOutput = z.infer<typeof knowledgePendingOutputSchema>;
2076
+ type KnowledgePutProcessedInput = z.infer<typeof knowledgePutProcessedInputSchema>;
2077
+ type KnowledgeExtractFieldsInput = z.infer<typeof knowledgeExtractFieldsInputSchema>;
2078
+ type KnowledgeExtractFieldsOutput = z.infer<typeof knowledgeExtractFieldsOutputSchema>;
2079
+
2080
+ /** Paging settings shared by accepted Connections and their API view. */
2081
+ declare const operationPagingSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
2082
+ by: z.ZodEnum<{
2083
+ page: "page";
2084
+ offset: "offset";
2085
+ }>;
2086
+ param: z.ZodString;
2087
+ sizeParam: z.ZodString;
2088
+ size: z.ZodNumber;
2089
+ start: z.ZodOptional<z.ZodNumber>;
2090
+ }, z.core.$strict>, z.ZodObject<{
2091
+ by: z.ZodEnum<{
2092
+ cursor: "cursor";
2093
+ next_link: "next_link";
2094
+ }>;
2095
+ param: z.ZodString;
2096
+ cursor: z.ZodString;
2097
+ }, z.core.$strict>], "by">;
2098
+ type OperationPaging = z.infer<typeof operationPagingSchema>;
2099
+
2100
+ /** Published data Workflows that fill or process an asset, with unreadable names withheld. */
2101
+ declare const workflowDataFlowsSchema: z.ZodObject<{
2102
+ fills: z.ZodArray<z.ZodObject<{
2103
+ id: z.ZodString;
2104
+ name: z.ZodString;
2105
+ title: z.ZodString;
2106
+ }, z.core.$strip>>;
2107
+ processes: z.ZodArray<z.ZodObject<{
2108
+ id: z.ZodString;
2109
+ name: z.ZodString;
2110
+ title: z.ZodString;
2111
+ }, z.core.$strip>>;
2112
+ hidden: z.ZodObject<{
2113
+ fills: z.ZodNumber;
2114
+ processes: z.ZodNumber;
2115
+ }, z.core.$strip>;
2116
+ truncated: z.ZodBoolean;
2117
+ }, z.core.$strip>;
2118
+
2119
+ declare const RECORDS_PROPOSE_MAX_ITEMS_PER_CALL = 1000;
2120
+ declare const RECORDS_PROPOSE_MAX_FIELDS_PER_ITEM = 1000;
2121
+ declare const RECORDS_FLAGGED_MAX_ITEMS_PER_PAGE = 10000;
2122
+ declare const dataStoreRecordsRuleSchema: z.ZodObject<{
2123
+ table: z.ZodString;
2124
+ key: z.ZodUnion<readonly [z.ZodObject<{
2125
+ column: z.ZodString;
2126
+ fromPath: z.ZodString;
2127
+ }, z.core.$strict>, z.ZodObject<{
2128
+ column: z.ZodString;
2129
+ fromField: z.ZodString;
2130
+ }, z.core.$strict>]>;
2131
+ precedence: z.ZodDefault<z.ZodArray<z.ZodString>>;
2132
+ review: z.ZodPrefault<z.ZodObject<{
2133
+ always: z.ZodDefault<z.ZodArray<z.ZodString>>;
2134
+ }, z.core.$strict>>;
2135
+ retainWithoutSource: z.ZodDefault<z.ZodBoolean>;
2136
+ }, z.core.$strict>;
2137
+ type DataStoreRecordsRule = z.infer<typeof dataStoreRecordsRuleSchema>;
2138
+ /** A necessary condition, never a model confidence score or proof of correctness. */
2139
+ declare const recordEvidenceResultSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
2140
+ status: z.ZodLiteral<"passed">;
2141
+ }, z.core.$strict>, z.ZodObject<{
2142
+ status: z.ZodLiteral<"failed">;
2143
+ reason: z.ZodEnum<{
2144
+ page_not_found: "page_not_found";
2145
+ quote_not_found: "quote_not_found";
2146
+ value_not_parsed: "value_not_parsed";
2147
+ }>;
2148
+ }, z.core.$strict>], "status">;
2149
+ type RecordEvidenceResult = z.infer<typeof recordEvidenceResultSchema>;
2150
+ declare const RECORD_FIELD_STATES: readonly ["extracted", "confirmed", "corrected", "conflict"];
2151
+ /** Why a field waits for a person in "Prüfen". */
2152
+ declare const RECORD_FLAG_REASONS: readonly ["conflict", "not_evidenced", "confirmation_required", "key_unresolved"];
2153
+ declare const RECORD_FIELD_FAILURE_CODES: readonly ["record_field_unknown"];
2154
+ declare const dataStoreRecordProposalItemSchema: z.ZodObject<{
2155
+ knowledgeBaseId: z.ZodString;
2156
+ documentId: z.ZodString;
2157
+ kind: z.ZodString;
2158
+ documentDate: z.ZodNullable<z.ZodISODate>;
2159
+ path: z.ZodOptional<z.ZodString>;
2160
+ fields: z.ZodArray<z.ZodObject<{
2161
+ value: z.ZodJSONSchema;
2162
+ page: z.ZodNumber;
2163
+ quote: z.ZodString;
2164
+ name: z.ZodString;
2165
+ }, z.core.$strict>>;
2166
+ }, z.core.$strict>;
2167
+ type DataStoreRecordProposalItem = z.infer<typeof dataStoreRecordProposalItemSchema>;
2168
+ declare const dataStoreRecordsProposeInputSchema: z.ZodObject<{
2169
+ table: z.ZodString;
2170
+ items: z.ZodArray<z.ZodObject<{
2171
+ knowledgeBaseId: z.ZodString;
2172
+ documentId: z.ZodString;
2173
+ kind: z.ZodString;
2174
+ documentDate: z.ZodNullable<z.ZodISODate>;
2175
+ path: z.ZodOptional<z.ZodString>;
2176
+ fields: z.ZodArray<z.ZodObject<{
2177
+ value: z.ZodJSONSchema;
2178
+ page: z.ZodNumber;
2179
+ quote: z.ZodString;
2180
+ name: z.ZodString;
2181
+ }, z.core.$strict>>;
2182
+ }, z.core.$strict>>;
2183
+ }, z.core.$strict>;
2184
+ type DataStoreRecordsProposeInput = z.infer<typeof dataStoreRecordsProposeInputSchema>;
2185
+ declare const dataStoreRecordsDecideInputSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
2186
+ table: z.ZodString;
2187
+ key: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
2188
+ field: z.ZodString;
2189
+ documentId: z.ZodOptional<z.ZodString>;
2190
+ knowledgeBaseId: z.ZodOptional<z.ZodString>;
2191
+ action: z.ZodLiteral<"confirm">;
2192
+ }, z.core.$strict>, z.ZodObject<{
2193
+ table: z.ZodString;
2194
+ key: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
2195
+ field: z.ZodString;
2196
+ documentId: z.ZodOptional<z.ZodString>;
2197
+ knowledgeBaseId: z.ZodOptional<z.ZodString>;
2198
+ action: z.ZodLiteral<"correct">;
2199
+ value: z.ZodJSONSchema;
2200
+ }, z.core.$strict>, z.ZodObject<{
2201
+ table: z.ZodString;
2202
+ key: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
2203
+ field: z.ZodString;
2204
+ action: z.ZodLiteral<"assign">;
2205
+ documentId: z.ZodString;
2206
+ knowledgeBaseId: z.ZodString;
2207
+ }, z.core.$strict>], "action">;
2208
+ type DataStoreRecordsDecideInput = z.infer<typeof dataStoreRecordsDecideInputSchema>;
2209
+ declare const dataStoreRecordsDecideOutputSchema: z.ZodObject<{
2210
+ decided: z.ZodLiteral<true>;
2211
+ }, z.core.$strict>;
2212
+ declare const dataStoreRecordsFlaggedInputSchema: z.ZodObject<{
2213
+ table: z.ZodOptional<z.ZodString>;
2214
+ cursor: z.ZodOptional<z.ZodString>;
2215
+ limit: z.ZodNumber;
2216
+ }, z.core.$strict>;
2217
+ declare const dataStoreRecordFieldSchema: z.ZodObject<{
2218
+ value: z.ZodJSONSchema;
2219
+ page: z.ZodNumber;
2220
+ quote: z.ZodString;
2221
+ name: z.ZodString;
2222
+ correctedValue: z.ZodNullable<z.ZodJSONSchema>;
2223
+ table: z.ZodString;
2224
+ key: z.ZodNullable<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
2225
+ knowledgeBaseId: z.ZodString;
2226
+ documentId: z.ZodString;
2227
+ kind: z.ZodString;
2228
+ documentDate: z.ZodNullable<z.ZodISODate>;
2229
+ extractedAt: z.ZodISODateTime;
2230
+ evidence: z.ZodDiscriminatedUnion<[z.ZodObject<{
2231
+ status: z.ZodLiteral<"passed">;
2232
+ }, z.core.$strict>, z.ZodObject<{
2233
+ status: z.ZodLiteral<"failed">;
2234
+ reason: z.ZodEnum<{
2235
+ page_not_found: "page_not_found";
2236
+ quote_not_found: "quote_not_found";
2237
+ value_not_parsed: "value_not_parsed";
2238
+ }>;
2239
+ }, z.core.$strict>], "status">;
2240
+ state: z.ZodEnum<{
2241
+ confirmed: "confirmed";
2242
+ extracted: "extracted";
2243
+ corrected: "corrected";
2244
+ conflict: "conflict";
2245
+ }>;
2246
+ decidedBy: z.ZodNullable<z.ZodString>;
2247
+ decidedAt: z.ZodNullable<z.ZodISODateTime>;
2248
+ }, z.core.$strict>;
2249
+ type DataStoreRecordField = z.infer<typeof dataStoreRecordFieldSchema>;
2250
+ declare const dataStoreRecordsFlaggedOutputSchema: z.ZodObject<{
2251
+ items: z.ZodArray<z.ZodObject<{
2252
+ value: z.ZodJSONSchema;
2253
+ page: z.ZodNumber;
2254
+ quote: z.ZodString;
2255
+ name: z.ZodString;
2256
+ correctedValue: z.ZodNullable<z.ZodJSONSchema>;
2257
+ table: z.ZodString;
2258
+ key: z.ZodNullable<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
2259
+ knowledgeBaseId: z.ZodString;
2260
+ documentId: z.ZodString;
2261
+ kind: z.ZodString;
2262
+ documentDate: z.ZodNullable<z.ZodISODate>;
2263
+ extractedAt: z.ZodISODateTime;
2264
+ evidence: z.ZodDiscriminatedUnion<[z.ZodObject<{
2265
+ status: z.ZodLiteral<"passed">;
2266
+ }, z.core.$strict>, z.ZodObject<{
2267
+ status: z.ZodLiteral<"failed">;
2268
+ reason: z.ZodEnum<{
2269
+ page_not_found: "page_not_found";
2270
+ quote_not_found: "quote_not_found";
2271
+ value_not_parsed: "value_not_parsed";
2272
+ }>;
2273
+ }, z.core.$strict>], "status">;
2274
+ state: z.ZodEnum<{
2275
+ confirmed: "confirmed";
2276
+ extracted: "extracted";
2277
+ corrected: "corrected";
2278
+ conflict: "conflict";
2279
+ }>;
2280
+ decidedBy: z.ZodNullable<z.ZodString>;
2281
+ decidedAt: z.ZodNullable<z.ZodISODateTime>;
2282
+ reason: z.ZodEnum<{
2283
+ conflict: "conflict";
2284
+ not_evidenced: "not_evidenced";
2285
+ confirmation_required: "confirmation_required";
2286
+ key_unresolved: "key_unresolved";
2287
+ }>;
2288
+ document: z.ZodOptional<z.ZodObject<{
2289
+ knowledgeBase: z.ZodString;
2290
+ fileName: z.ZodString;
2291
+ }, z.core.$strict>>;
2292
+ decidedByName: z.ZodOptional<z.ZodString>;
2293
+ }, z.core.$strict>>;
2294
+ nextCursor: z.ZodOptional<z.ZodString>;
2295
+ }, z.core.$strict>;
2296
+ type ColumnType = (typeof DATA_STORE_SCALAR_TYPES)[number];
2297
+ interface RecordColumn {
2298
+ name: string;
2299
+ type: ColumnType | `${ColumnType}[]` | "other";
2300
+ nullable: boolean;
2301
+ generated?: boolean;
2302
+ }
2303
+ /** Whether a column takes the value, as a proposal and a person's correction are checked. */
2304
+ declare function recordColumnTakes(column: RecordColumn, value: unknown): boolean;
2305
+ /**
2306
+ * Validate a whole item before any candidate or customer row is written. The batch writer
2307
+ * maps this refusal to record_field_unknown for that item and continues with other items.
2308
+ * Types come from the store catalog, never from the caller's extraction schema.
2309
+ */
2310
+ declare function proposalItemSchemaFor(columns: readonly RecordColumn[]): z.ZodObject<{
2311
+ knowledgeBaseId: z.ZodString;
2312
+ documentId: z.ZodString;
2313
+ kind: z.ZodString;
2314
+ documentDate: z.ZodNullable<z.ZodISODate>;
2315
+ path: z.ZodOptional<z.ZodString>;
2316
+ fields: z.ZodArray<z.ZodObject<{
2317
+ value: z.ZodJSONSchema;
2318
+ page: z.ZodNumber;
2319
+ quote: z.ZodString;
2320
+ name: z.ZodString;
2321
+ }, z.core.$strict>>;
2322
+ }, z.core.$strict>;
2323
+ /** Contracts only: REC-1a/1b/2 register the implementations, not REC-0. */
2324
+ declare const dataStoreRecordsContracts: {
2325
+ readonly propose: {
2326
+ readonly description: "Propose extracted fields with Knowledge Base/document/page/quote evidence. Validate each whole item against the published table before writing; failures are per item. Send at most 1000 items per call and 1000 fields per item; split larger work into batches. Merge by evidence precedence, then document date; unresolved keys and evidence go to review.";
2327
+ readonly inputSchema: z.ZodObject<{
2328
+ table: z.ZodString;
2329
+ items: z.ZodArray<z.ZodObject<{
2330
+ knowledgeBaseId: z.ZodString;
2331
+ documentId: z.ZodString;
2332
+ kind: z.ZodString;
2333
+ documentDate: z.ZodNullable<z.ZodISODate>;
2334
+ path: z.ZodOptional<z.ZodString>;
2335
+ fields: z.ZodArray<z.ZodObject<{
2336
+ value: z.ZodJSONSchema;
2337
+ page: z.ZodNumber;
2338
+ quote: z.ZodString;
2339
+ name: z.ZodString;
2340
+ }, z.core.$strict>>;
2341
+ }, z.core.$strict>>;
2342
+ }, z.core.$strict>;
2343
+ readonly outputSchema: z.ZodObject<{
2344
+ done: z.ZodNumber;
2345
+ failed: z.ZodNumber;
2346
+ failures: z.ZodObject<{
2347
+ $dataset: z.ZodString;
2348
+ rowCount: z.ZodNumber;
2349
+ bytes: z.ZodNumber;
2350
+ offset: z.ZodOptional<z.ZodNumber>;
2351
+ }, z.core.$strict>;
2352
+ }, z.core.$strict>;
2353
+ readonly itemSchemaFor: typeof proposalItemSchemaFor;
2354
+ readonly effect: "changing";
2355
+ readonly right: "data_store.records";
2356
+ readonly keyLevel: "write";
2357
+ readonly batch: true;
2358
+ };
2359
+ readonly decide: {
2360
+ readonly description: "Confirm or correct a field against its evidence, or assign a document to an object key. Decisions are pinned; audit table/field/action/actor only, never the value.";
2361
+ readonly inputSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
2362
+ table: z.ZodString;
2363
+ key: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
2364
+ field: z.ZodString;
2365
+ documentId: z.ZodOptional<z.ZodString>;
2366
+ knowledgeBaseId: z.ZodOptional<z.ZodString>;
2367
+ action: z.ZodLiteral<"confirm">;
2368
+ }, z.core.$strict>, z.ZodObject<{
2369
+ table: z.ZodString;
2370
+ key: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
2371
+ field: z.ZodString;
2372
+ documentId: z.ZodOptional<z.ZodString>;
2373
+ knowledgeBaseId: z.ZodOptional<z.ZodString>;
2374
+ action: z.ZodLiteral<"correct">;
2375
+ value: z.ZodJSONSchema;
2376
+ }, z.core.$strict>, z.ZodObject<{
2377
+ table: z.ZodString;
2378
+ key: z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>;
2379
+ field: z.ZodString;
2380
+ action: z.ZodLiteral<"assign">;
2381
+ documentId: z.ZodString;
2382
+ knowledgeBaseId: z.ZodString;
2383
+ }, z.core.$strict>], "action">;
2384
+ readonly outputSchema: z.ZodObject<{
2385
+ decided: z.ZodLiteral<true>;
2386
+ }, z.core.$strict>;
2387
+ readonly effect: "changing";
2388
+ readonly right: "data_store.records";
2389
+ readonly keyLevel: "write";
2390
+ };
2391
+ readonly flagged: {
2392
+ readonly description: "Page through fields needing review, up to 10000 per call; pass nextCursor as cursor for the next page. Check Knowledge Base access before showing any document citation; the store right alone does not grant access to source documents.";
2393
+ readonly inputSchema: z.ZodObject<{
2394
+ table: z.ZodOptional<z.ZodString>;
2395
+ cursor: z.ZodOptional<z.ZodString>;
2396
+ limit: z.ZodNumber;
2397
+ }, z.core.$strict>;
2398
+ readonly outputSchema: z.ZodObject<{
2399
+ items: z.ZodArray<z.ZodObject<{
2400
+ value: z.ZodJSONSchema;
2401
+ page: z.ZodNumber;
2402
+ quote: z.ZodString;
2403
+ name: z.ZodString;
2404
+ correctedValue: z.ZodNullable<z.ZodJSONSchema>;
2405
+ table: z.ZodString;
2406
+ key: z.ZodNullable<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>;
2407
+ knowledgeBaseId: z.ZodString;
2408
+ documentId: z.ZodString;
2409
+ kind: z.ZodString;
2410
+ documentDate: z.ZodNullable<z.ZodISODate>;
2411
+ extractedAt: z.ZodISODateTime;
2412
+ evidence: z.ZodDiscriminatedUnion<[z.ZodObject<{
2413
+ status: z.ZodLiteral<"passed">;
2414
+ }, z.core.$strict>, z.ZodObject<{
2415
+ status: z.ZodLiteral<"failed">;
2416
+ reason: z.ZodEnum<{
2417
+ page_not_found: "page_not_found";
2418
+ quote_not_found: "quote_not_found";
2419
+ value_not_parsed: "value_not_parsed";
2420
+ }>;
2421
+ }, z.core.$strict>], "status">;
2422
+ state: z.ZodEnum<{
2423
+ confirmed: "confirmed";
2424
+ extracted: "extracted";
2425
+ corrected: "corrected";
2426
+ conflict: "conflict";
2427
+ }>;
2428
+ decidedBy: z.ZodNullable<z.ZodString>;
2429
+ decidedAt: z.ZodNullable<z.ZodISODateTime>;
2430
+ reason: z.ZodEnum<{
2431
+ conflict: "conflict";
2432
+ not_evidenced: "not_evidenced";
2433
+ confirmation_required: "confirmation_required";
2434
+ key_unresolved: "key_unresolved";
2435
+ }>;
2436
+ document: z.ZodOptional<z.ZodObject<{
2437
+ knowledgeBase: z.ZodString;
2438
+ fileName: z.ZodString;
2439
+ }, z.core.$strict>>;
2440
+ decidedByName: z.ZodOptional<z.ZodString>;
2441
+ }, z.core.$strict>>;
2442
+ nextCursor: z.ZodOptional<z.ZodString>;
2443
+ }, z.core.$strict>;
2444
+ readonly effect: "reading";
2445
+ readonly right: "data_store.records";
2446
+ readonly keyLevel: "read";
2447
+ };
2448
+ };
2449
+ type DataStoreRecordsDecideOutput = z.infer<typeof dataStoreRecordsDecideOutputSchema>;
2450
+ type DataStoreRecordsFlaggedInput = z.infer<typeof dataStoreRecordsFlaggedInputSchema>;
2451
+ type DataStoreRecordsFlaggedOutput = z.infer<typeof dataStoreRecordsFlaggedOutputSchema>;
2452
+
2453
+ /** The UTC counter windows, metrics and scopes a model usage refusal may name. */
2454
+ declare const MODEL_USAGE_LIMIT_PERIODS: readonly ["day", "month"];
2455
+ declare const MODEL_USAGE_LIMIT_METRICS: readonly ["modelCallCount", "tokens", "costMicros"];
2456
+ declare const MODEL_USAGE_LIMIT_SCOPES: readonly ["instance", "user", "system", "workspace"];
2457
+ /**
2458
+ * Where an admin sets a spend limit (LU-2): the instance, one default for every shared
2459
+ * workspace and one for every user, and a value for one workspace or one user that replaces
2460
+ * that default.
2461
+ */
2462
+ declare const USAGE_SPEND_LIMIT_LEVELS: readonly ["instance", "workspace_default", "workspace", "user_default", "user"];
2463
+ /** The limit that refused a call: its period, what it counts, and whose counter it is. */
2464
+ interface ModelUsageRefusal {
2465
+ period: (typeof MODEL_USAGE_LIMIT_PERIODS)[number];
2466
+ metric: (typeof MODEL_USAGE_LIMIT_METRICS)[number];
2467
+ /**
2468
+ * `user`: the person's own calls. `system`: the calls the product makes for a person, or
2469
+ * those no person made. `workspace`: the calls inside one shared workspace. `instance`: the
2470
+ * spend budget everyone shares.
2471
+ */
2472
+ scope: (typeof MODEL_USAGE_LIMIT_SCOPES)[number];
2473
+ }
2474
+ /** The workspace key every Personal Workspace shares in the usage sums (LU-3): one row. */
2475
+ declare const PERSONAL_WORKSPACES_KEY = "personal";
2476
+ /**
2477
+ * The agent key every person's own agent ("Only me") shares in the usage of a shared workspace:
2478
+ * the team's Owners and the Usage page see that someone's own agent was used there, never which.
2479
+ * No agent the Studio names starts with a colon.
2480
+ */
2481
+ declare const PERSONAL_AGENTS_KEY = ":personal";
2482
+ /** What the Breakdown of the Usage page groups by (LU-3, limits spec 3.3, view 2). */
2483
+ declare const USAGE_BREAKDOWN_DIMENSIONS: readonly ["workspace", "agent", "app", "workflow", "model", "origin"];
2484
+ /**
2485
+ * Where usage came from (limits spec 3.2): a conversation, an App, a Workflow, Knowledge Base
2486
+ * ingestion, or a call the product made for itself, such as a title or a guardrail check.
2487
+ */
2488
+ declare const USAGE_ORIGINS: readonly ["conversation", "app", "workflow", "knowledge_base", "system"];
2489
+
2490
+ /**
2491
+ * The JSON Schema `format` of a string field that takes Markdown, such as the body of
2492
+ * `mail.send`. In such a field a referenced list of strings joins as a bulleted list and a
2493
+ * list of flat records as a table, and every referenced value is escaped as Markdown text.
2494
+ */
2495
+ declare const WORKFLOW_TEXT_FORMAT_MARKDOWN = "markdown";
2496
+ /** The most parts one joined text has. */
2497
+ declare const WORKFLOW_TEXT_MAX_PARTS = 100;
2498
+ /** A referenced list in a Markdown field joins as at most this many rows; more is refused. */
2499
+ declare const WORKFLOW_MARKDOWN_MAX_ROWS = 100;
2500
+ /** A referenced list of records joins as a table of at most this many columns. */
2501
+ declare const WORKFLOW_MARKDOWN_MAX_COLUMNS = 8;
2502
+
2503
+ /** The platform operation. It exists on an instance only while `outbound.enabled` is true. */
2504
+ declare const MAIL_SEND_OPERATION = "mail.send";
2505
+ /** The resource kind of a sender. Its right is `mail_sender.use`, on one sender. */
2506
+ declare const MAIL_SENDER_RESOURCE_KIND = "mail_sender";
2507
+ declare const MAIL_SENDER_USE_ACTION = "mail_sender.use";
2508
+ /** The instance's own mailer (`infrastructure.mail`), the only sender until MAIL-M365S. */
2509
+ declare const MAIL_SENDER_SYSTEM = "system";
2510
+ /** The prefix of a Connection sender (MAIL-M365S, MAIL-M365P): `connection.<name>`. */
2511
+ declare const MAIL_SENDER_CONNECTION_PREFIX = "connection.";
2512
+ /**
2513
+ * The icon key the step shows for the system sender. An assembly may register the instance's
2514
+ * mark under it; without one the generic mail icon stands. A Connection sender shows its
2515
+ * Connection's `service` icon. The transport (Mailjet, capture, SMTP) never has an icon.
2516
+ */
2517
+ declare const MAIL_SENDER_SYSTEM_ICON = "system-mail";
2518
+ /** The template `packages/mail` renders a mail of `mail.send` in. */
2519
+ declare const MAIL_WORKFLOW_MESSAGE_TEMPLATE = "workflow-message";
2520
+ /** Addresses of one mail once `{ workspace }` recipients are expanded, over to, cc and bcc. */
2521
+ declare const MAIL_SEND_MAX_ADDRESSES = 50;
2522
+ declare const MAIL_SUBJECT_MAX_LENGTH = 200;
2523
+ declare const MAIL_BODY_MAX_BYTES: number;
2524
+ declare const MAIL_SENDER_NAME_MAX_LENGTH = 80;
2525
+ /** The longest address RFC 5321 lets through a path. */
2526
+ declare const MAIL_ADDRESS_MAX_LENGTH = 254;
2527
+ /** `infrastructure.mail.outbound.limits` unless release config sets them; only it raises them. */
2528
+ declare const MAIL_OUTBOUND_DEFAULT_LIMITS: {
2529
+ readonly perWorkflowPerHour: 200;
2530
+ readonly perInstancePerDay: 1000;
2531
+ };
2532
+ /** One language's legal footer (§ 37a HGB company details), as plain text. */
2533
+ declare const MAIL_OUTBOUND_FOOTER_MAX_LENGTH = 2000;
2534
+ /** `mail.sent` names at most this many distinct recipient domains, then counts the rest. */
2535
+ declare const MAIL_AUDIT_MAX_DOMAINS = 10;
2536
+ /** Reserved for MAIL-4: Managed Files and datasets of the run, together. */
2537
+ declare const MAIL_ATTACHMENTS_MAX_FILES = 10;
2538
+ declare const MAIL_ATTACHMENTS_MAX_BYTES: number;
2539
+ /**
2540
+ * Why `mail.send` refused or failed a mail, as `details.reason` of a VALIDATION_FAILED and as
2541
+ * the code of a failed step. None is retried.
2542
+ * - `recipient_not_allowed`: an address outside `recipientDomains` that is not a person of the
2543
+ * instance, or such a `replyTo`. `details.domain` names its domain. Nothing is sent to any
2544
+ * recipient of the mail.
2545
+ * - `no_recipient`: `to` named people or workspaces, and none of them has an address.
2546
+ * - `workspace_not_allowed`: a `{ workspace }` recipient is not a Shared Workspace the author
2547
+ * of the mail can see: they are no member of it and no instance admin (MAIL-2). The author
2548
+ * is the person who saves, publishes or tests the Workflow, or for whom an agent calls; in a
2549
+ * published run, its publisher. Nothing is sent and no member of it is named.
2550
+ * - `mail_rejected`: the provider refused the mail before accepting it. `details.providerCode`
2551
+ * holds the provider's own code; its text is never kept.
2552
+ * A transient failure is not one of these: a refused connection is retried by the step's
2553
+ * attempts, and an answer lost after the request left is `operation_interrupted`.
2554
+ */
2555
+ declare const MAIL_SEND_ERROR_CODES: {
2556
+ readonly recipientNotAllowed: "recipient_not_allowed";
2557
+ readonly noRecipient: "no_recipient";
2558
+ readonly mailRejected: "mail_rejected";
2559
+ readonly workspaceNotAllowed: "workspace_not_allowed";
2560
+ };
2561
+ type MailSendErrorCode = (typeof MAIL_SEND_ERROR_CODES)[keyof typeof MAIL_SEND_ERROR_CODES];
2562
+ declare const MAIL_SEND_REFUSAL_REASONS: readonly ["recipient_not_allowed", "no_recipient", "mail_rejected", "workspace_not_allowed"];
2563
+ /** `details` of a refused `mail.send`: the one refused domain, or the provider's code. */
2564
+ declare const mailSendRefusalDetailsSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
2565
+ reason: z.ZodLiteral<"recipient_not_allowed">;
2566
+ domain: z.ZodString;
2567
+ }, z.core.$strict>, z.ZodObject<{
2568
+ reason: z.ZodLiteral<"no_recipient">;
2569
+ }, z.core.$strict>, z.ZodObject<{
2570
+ reason: z.ZodLiteral<"workspace_not_allowed">;
2571
+ }, z.core.$strict>, z.ZodObject<{
2572
+ reason: z.ZodLiteral<"mail_rejected">;
2573
+ providerCode: z.ZodOptional<z.ZodString>;
2574
+ }, z.core.$strict>], "reason">;
2575
+ type MailSendRefusalDetails = z.infer<typeof mailSendRefusalDetailsSchema>;
2576
+ /** A user or workspace id, as `NOTICE_ID_PATTERN` of core reads it. */
2577
+ declare const MAIL_RECIPIENT_ID_PATTERN: RegExp;
2578
+ /** One address as written. Its domain is compared without regard to case. */
2579
+ declare const mailAddressSchema: z.ZodEmail;
2580
+ /**
2581
+ * A domain of `recipientDomains`, lowercase: `kanzlei.de` matches that domain only,
2582
+ * `*.kanzlei.de` its subdomains and not the domain itself. `*` alone admits every address.
2583
+ */
2584
+ declare const MAIL_RECIPIENT_DOMAIN_PATTERN: RegExp;
2585
+ declare const MAIL_RECIPIENT_DOMAINS_ANY = "*";
2586
+ declare const mailRecipientDomainSchema: z.ZodString;
2587
+ /**
2588
+ * Which sender the mail goes out as. `system` until MAIL-M365S; `connection.<name>` is
2589
+ * reserved and refused with `not_supported_yet`.
2590
+ */
2591
+ declare const mailSenderIdSchema: z.ZodUnion<readonly [z.ZodLiteral<"system">, z.ZodTemplateLiteral<`connection.${string}`>]>;
2592
+ type MailSenderId = typeof MAIL_SENDER_SYSTEM | `connection.${string}`;
2593
+ /**
2594
+ * One recipient of a literal list: an address, a person of the instance by id, or a workspace,
2595
+ * which stands for its members. A person or member without an address is skipped and counted.
2596
+ */
2597
+ declare const mailRecipientSchema: z.ZodUnion<readonly [z.ZodObject<{
2598
+ address: z.ZodEmail;
2599
+ }, z.core.$strict>, z.ZodObject<{
2600
+ user: z.ZodString;
2601
+ }, z.core.$strict>, z.ZodObject<{
2602
+ workspace: z.ZodString;
2603
+ }, z.core.$strict>]>;
2604
+ type MailSendRecipient = z.infer<typeof mailRecipientSchema>;
2605
+ declare const mailRecipientListSchema: z.ZodUnion<readonly [z.ZodEmail, z.ZodArray<z.ZodUnion<readonly [z.ZodEmail, z.ZodUnion<readonly [z.ZodObject<{
2606
+ address: z.ZodEmail;
2607
+ }, z.core.$strict>, z.ZodObject<{
2608
+ user: z.ZodString;
2609
+ }, z.core.$strict>, z.ZodObject<{
2610
+ workspace: z.ZodString;
2611
+ }, z.core.$strict>]>, z.ZodObject<{
2612
+ email: z.ZodEmail;
2613
+ }, z.core.$loose>]>>]>;
2614
+ type MailSendRecipientList = z.infer<typeof mailRecipientListSchema>;
2615
+ /**
2616
+ * What `cc` and `bcc` take: as `to`, and an empty list too, since a referenced list of copy
2617
+ * recipients may hold nobody and the mail still goes to `to`.
2618
+ */
2619
+ declare const mailCopyRecipientListSchema: z.ZodUnion<readonly [z.ZodEmail, z.ZodArray<z.ZodUnion<readonly [z.ZodEmail, z.ZodUnion<readonly [z.ZodObject<{
2620
+ address: z.ZodEmail;
2621
+ }, z.core.$strict>, z.ZodObject<{
2622
+ user: z.ZodString;
2623
+ }, z.core.$strict>, z.ZodObject<{
2624
+ workspace: z.ZodString;
2625
+ }, z.core.$strict>]>, z.ZodObject<{
2626
+ email: z.ZodEmail;
2627
+ }, z.core.$loose>]>>]>;
2628
+ /** One address, or a person of the instance. The recipient rule applies to it as to `to`. */
2629
+ declare const mailReplyToSchema: z.ZodUnion<readonly [z.ZodEmail, z.ZodObject<{
2630
+ address: z.ZodEmail;
2631
+ }, z.core.$strict>, z.ZodObject<{
2632
+ user: z.ZodString;
2633
+ }, z.core.$strict>]>;
2634
+ /** One line of 1 to 200 characters with something besides spaces. */
2635
+ declare const mailSubjectSchema: z.ZodString;
2636
+ /**
2637
+ * The author's Markdown, rendered on the server: no raw HTML, no image, links over `https`,
2638
+ * `http` and `mailto` only. `format: markdown` is what makes a mapped field join lists and
2639
+ * tables (EW-TEXT) and escape every referenced value, and a field mapped as one reference show
2640
+ * each link's address after its label (MAIL-2).
2641
+ */
2642
+ declare const mailBodySchema: z.ZodString;
2643
+ /** The display name on the From line. The address stays the sender's. */
2644
+ declare const mailSenderNameSchema: z.ZodString;
2645
+ /**
2646
+ * The input of `mail.send`, as the operation reads it after a step's mapping is resolved. Each
2647
+ * field of a step's mapping takes a literal, a reference or, for the strings, text joined
2648
+ * from parts (EW-TEXT). `attachments` arrives with MAIL-4 and is refused until then.
2649
+ */
2650
+ declare const mailSendInputSchema: z.ZodObject<{
2651
+ sender: z.ZodDefault<z.ZodUnion<readonly [z.ZodLiteral<"system">, z.ZodTemplateLiteral<`connection.${string}`>]>>;
2652
+ to: z.ZodUnion<readonly [z.ZodEmail, z.ZodArray<z.ZodUnion<readonly [z.ZodEmail, z.ZodUnion<readonly [z.ZodObject<{
2653
+ address: z.ZodEmail;
2654
+ }, z.core.$strict>, z.ZodObject<{
2655
+ user: z.ZodString;
2656
+ }, z.core.$strict>, z.ZodObject<{
2657
+ workspace: z.ZodString;
2658
+ }, z.core.$strict>]>, z.ZodObject<{
2659
+ email: z.ZodEmail;
2660
+ }, z.core.$loose>]>>]>;
2661
+ cc: z.ZodOptional<z.ZodUnion<readonly [z.ZodEmail, z.ZodArray<z.ZodUnion<readonly [z.ZodEmail, z.ZodUnion<readonly [z.ZodObject<{
2662
+ address: z.ZodEmail;
2663
+ }, z.core.$strict>, z.ZodObject<{
2664
+ user: z.ZodString;
2665
+ }, z.core.$strict>, z.ZodObject<{
2666
+ workspace: z.ZodString;
2667
+ }, z.core.$strict>]>, z.ZodObject<{
2668
+ email: z.ZodEmail;
2669
+ }, z.core.$loose>]>>]>>;
2670
+ bcc: z.ZodOptional<z.ZodUnion<readonly [z.ZodEmail, z.ZodArray<z.ZodUnion<readonly [z.ZodEmail, z.ZodUnion<readonly [z.ZodObject<{
2671
+ address: z.ZodEmail;
2672
+ }, z.core.$strict>, z.ZodObject<{
2673
+ user: z.ZodString;
2674
+ }, z.core.$strict>, z.ZodObject<{
2675
+ workspace: z.ZodString;
2676
+ }, z.core.$strict>]>, z.ZodObject<{
2677
+ email: z.ZodEmail;
2678
+ }, z.core.$loose>]>>]>>;
2679
+ subject: z.ZodString;
2680
+ body: z.ZodString;
2681
+ senderName: z.ZodOptional<z.ZodString>;
2682
+ replyTo: z.ZodOptional<z.ZodUnion<readonly [z.ZodEmail, z.ZodObject<{
2683
+ address: z.ZodEmail;
2684
+ }, z.core.$strict>, z.ZodObject<{
2685
+ user: z.ZodString;
2686
+ }, z.core.$strict>]>>;
2687
+ locale: z.ZodOptional<z.ZodEnum<{
2688
+ en: "en";
2689
+ de: "de";
2690
+ }>>;
2691
+ }, z.core.$strict>;
2692
+ type MailSendInput = z.infer<typeof mailSendInputSchema>;
2693
+ type MailSendInputFields = z.input<typeof mailSendInputSchema>;
2694
+ /**
2695
+ * What a live or test send answers: counts and the provider's message id, never an address.
2696
+ * `skipped` counts people and members without an address. `test` marks "Run live once",
2697
+ * which sent to the tester alone.
2698
+ */
2699
+ declare const mailSendOutputSchema: z.ZodObject<{
2700
+ sentAt: z.ZodISODateTime;
2701
+ messageId: z.ZodOptional<z.ZodString>;
2702
+ recipients: z.ZodObject<{
2703
+ to: z.ZodNumber;
2704
+ cc: z.ZodNumber;
2705
+ bcc: z.ZodNumber;
2706
+ }, z.core.$strict>;
2707
+ skipped: z.ZodNumber;
2708
+ test: z.ZodOptional<z.ZodLiteral<true>>;
2709
+ }, z.core.$strict>;
2710
+ type MailSendOutput = z.infer<typeof mailSendOutputSchema>;
2711
+ /** A recipient as a preview names it: a person by name, an address as written. */
2712
+ declare const mailPreviewRecipientSchema: z.ZodObject<{
2713
+ kind: z.ZodEnum<{
2714
+ person: "person";
2715
+ address: "address";
2716
+ }>;
2717
+ label: z.ZodString;
2718
+ }, z.core.$strict>;
2719
+ type MailPreviewRecipient = z.infer<typeof mailPreviewRecipientSchema>;
2720
+ /**
2721
+ * The mail as it would go out, checked against the recipient rule. It is step data of a test
2722
+ * run and the confirmation card's content; it is never audit data.
2723
+ */
2724
+ declare const mailSendPreviewSchema: z.ZodObject<{
2725
+ from: z.ZodObject<{
2726
+ name: z.ZodString;
2727
+ address: z.ZodEmail;
2728
+ }, z.core.$strict>;
2729
+ replyTo: z.ZodOptional<z.ZodEmail>;
2730
+ to: z.ZodArray<z.ZodObject<{
2731
+ kind: z.ZodEnum<{
2732
+ person: "person";
2733
+ address: "address";
2734
+ }>;
2735
+ label: z.ZodString;
2736
+ }, z.core.$strict>>;
2737
+ cc: z.ZodArray<z.ZodObject<{
2738
+ kind: z.ZodEnum<{
2739
+ person: "person";
2740
+ address: "address";
2741
+ }>;
2742
+ label: z.ZodString;
2743
+ }, z.core.$strict>>;
2744
+ bcc: z.ZodArray<z.ZodObject<{
2745
+ kind: z.ZodEnum<{
2746
+ person: "person";
2747
+ address: "address";
2748
+ }>;
2749
+ label: z.ZodString;
2750
+ }, z.core.$strict>>;
2751
+ skipped: z.ZodNumber;
2752
+ subject: z.ZodString;
2753
+ html: z.ZodString;
2754
+ text: z.ZodString;
2755
+ }, z.core.$strict>;
2756
+ type MailSendPreview = z.infer<typeof mailSendPreviewSchema>;
2757
+ /** What a simulated call (a test run's `dry_run`, an agent preview turn) answers. */
2758
+ declare const mailSendSimulatedOutputSchema: z.ZodObject<{
2759
+ simulated: z.ZodLiteral<true>;
2760
+ preview: z.ZodObject<{
2761
+ from: z.ZodObject<{
2762
+ name: z.ZodString;
2763
+ address: z.ZodEmail;
2764
+ }, z.core.$strict>;
2765
+ replyTo: z.ZodOptional<z.ZodEmail>;
2766
+ to: z.ZodArray<z.ZodObject<{
2767
+ kind: z.ZodEnum<{
2768
+ person: "person";
2769
+ address: "address";
2770
+ }>;
2771
+ label: z.ZodString;
2772
+ }, z.core.$strict>>;
2773
+ cc: z.ZodArray<z.ZodObject<{
2774
+ kind: z.ZodEnum<{
2775
+ person: "person";
2776
+ address: "address";
2777
+ }>;
2778
+ label: z.ZodString;
2779
+ }, z.core.$strict>>;
2780
+ bcc: z.ZodArray<z.ZodObject<{
2781
+ kind: z.ZodEnum<{
2782
+ person: "person";
2783
+ address: "address";
2784
+ }>;
2785
+ label: z.ZodString;
2786
+ }, z.core.$strict>>;
2787
+ skipped: z.ZodNumber;
2788
+ subject: z.ZodString;
2789
+ html: z.ZodString;
2790
+ text: z.ZodString;
2791
+ }, z.core.$strict>;
2792
+ }, z.core.$strict>;
2793
+ type MailSendSimulatedOutput = z.infer<typeof mailSendSimulatedOutputSchema>;
2794
+ /**
2795
+ * The params of the template `workflow-message`, per mail. The frame (the instance's name,
2796
+ * embedded logo, accent colour and `outbound.footer`) is the instance's and not a param; the
2797
+ * envelope (From name, to, cc, bcc, Reply-To) is the message's and not a param either.
2798
+ * `markdown` arrives with every joined referenced value already escaped, and a body mapped as
2799
+ * one reference with each link's address shown. `test` puts "[Test]" before
2800
+ * the subject and lists whom the mail would have reached.
2801
+ */
2802
+ declare const workflowMessageMailParamsSchema: z.ZodObject<{
2803
+ subject: z.ZodString;
2804
+ markdown: z.ZodString;
2805
+ sentBy: z.ZodDiscriminatedUnion<[z.ZodObject<{
2806
+ kind: z.ZodLiteral<"workflow">;
2807
+ workflowName: z.ZodString;
2808
+ }, z.core.$strict>, z.ZodObject<{
2809
+ kind: z.ZodLiteral<"agent">;
2810
+ onBehalfOf: z.ZodString;
2811
+ }, z.core.$strict>], "kind">;
2812
+ test: z.ZodOptional<z.ZodObject<{
2813
+ intendedRecipients: z.ZodObject<{
2814
+ to: z.ZodArray<z.ZodObject<{
2815
+ kind: z.ZodEnum<{
2816
+ person: "person";
2817
+ address: "address";
2818
+ }>;
2819
+ label: z.ZodString;
2820
+ }, z.core.$strict>>;
2821
+ cc: z.ZodArray<z.ZodObject<{
2822
+ kind: z.ZodEnum<{
2823
+ person: "person";
2824
+ address: "address";
2825
+ }>;
2826
+ label: z.ZodString;
2827
+ }, z.core.$strict>>;
2828
+ bcc: z.ZodArray<z.ZodObject<{
2829
+ kind: z.ZodEnum<{
2830
+ person: "person";
2831
+ address: "address";
2832
+ }>;
2833
+ label: z.ZodString;
2834
+ }, z.core.$strict>>;
2835
+ }, z.core.$strict>;
2836
+ }, z.core.$strict>>;
2837
+ }, z.core.$strict>;
2838
+ type WorkflowMessageMailParams = z.infer<typeof workflowMessageMailParamsSchema>;
2839
+ /**
2840
+ * What the step facts of a `mail.send` step carry beside `source { kind: "mail_sender", title,
2841
+ * service }`, where `service` is the icon key: the sender's address and the instance's
2842
+ * `recipientDomains`, so the panel marks an address a run would refuse.
2843
+ */
2844
+ declare const workflowMailSenderFactSchema: z.ZodObject<{
2845
+ sender: z.ZodString;
2846
+ title: z.ZodString;
2847
+ icon: z.ZodString;
2848
+ address: z.ZodEmail;
2849
+ recipientDomains: z.ZodArray<z.ZodString>;
2850
+ }, z.core.$strict>;
2851
+ type WorkflowMailSenderFact = z.infer<typeof workflowMailSenderFactSchema>;
2852
+ /** Contract only: MAIL-1 registers the operation while `outbound.enabled` is true. */
2853
+ declare const mailSendContract: {
2854
+ readonly name: "mail.send";
2855
+ readonly description: "Send one e-mail as a sender of the instance (system unless set). Recipients are addresses, people of the instance and workspaces; an address outside the instance's recipient domains is refused. The body is Markdown in the instance's frame. A test run previews the mail and sends nothing.";
2856
+ readonly inputSchema: z.ZodObject<{
2857
+ sender: z.ZodDefault<z.ZodUnion<readonly [z.ZodLiteral<"system">, z.ZodTemplateLiteral<`connection.${string}`>]>>;
2858
+ to: z.ZodUnion<readonly [z.ZodEmail, z.ZodArray<z.ZodUnion<readonly [z.ZodEmail, z.ZodUnion<readonly [z.ZodObject<{
2859
+ address: z.ZodEmail;
2860
+ }, z.core.$strict>, z.ZodObject<{
2861
+ user: z.ZodString;
2862
+ }, z.core.$strict>, z.ZodObject<{
2863
+ workspace: z.ZodString;
2864
+ }, z.core.$strict>]>, z.ZodObject<{
2865
+ email: z.ZodEmail;
2866
+ }, z.core.$loose>]>>]>;
2867
+ cc: z.ZodOptional<z.ZodUnion<readonly [z.ZodEmail, z.ZodArray<z.ZodUnion<readonly [z.ZodEmail, z.ZodUnion<readonly [z.ZodObject<{
2868
+ address: z.ZodEmail;
2869
+ }, z.core.$strict>, z.ZodObject<{
2870
+ user: z.ZodString;
2871
+ }, z.core.$strict>, z.ZodObject<{
2872
+ workspace: z.ZodString;
2873
+ }, z.core.$strict>]>, z.ZodObject<{
2874
+ email: z.ZodEmail;
2875
+ }, z.core.$loose>]>>]>>;
2876
+ bcc: z.ZodOptional<z.ZodUnion<readonly [z.ZodEmail, z.ZodArray<z.ZodUnion<readonly [z.ZodEmail, z.ZodUnion<readonly [z.ZodObject<{
2877
+ address: z.ZodEmail;
2878
+ }, z.core.$strict>, z.ZodObject<{
2879
+ user: z.ZodString;
2880
+ }, z.core.$strict>, z.ZodObject<{
2881
+ workspace: z.ZodString;
2882
+ }, z.core.$strict>]>, z.ZodObject<{
2883
+ email: z.ZodEmail;
2884
+ }, z.core.$loose>]>>]>>;
2885
+ subject: z.ZodString;
2886
+ body: z.ZodString;
2887
+ senderName: z.ZodOptional<z.ZodString>;
2888
+ replyTo: z.ZodOptional<z.ZodUnion<readonly [z.ZodEmail, z.ZodObject<{
2889
+ address: z.ZodEmail;
2890
+ }, z.core.$strict>, z.ZodObject<{
2891
+ user: z.ZodString;
2892
+ }, z.core.$strict>]>>;
2893
+ locale: z.ZodOptional<z.ZodEnum<{
2894
+ en: "en";
2895
+ de: "de";
2896
+ }>>;
2897
+ }, z.core.$strict>;
2898
+ readonly outputSchema: z.ZodObject<{
2899
+ sentAt: z.ZodISODateTime;
2900
+ messageId: z.ZodOptional<z.ZodString>;
2901
+ recipients: z.ZodObject<{
2902
+ to: z.ZodNumber;
2903
+ cc: z.ZodNumber;
2904
+ bcc: z.ZodNumber;
2905
+ }, z.core.$strict>;
2906
+ skipped: z.ZodNumber;
2907
+ test: z.ZodOptional<z.ZodLiteral<true>>;
2908
+ }, z.core.$strict>;
2909
+ readonly simulatedOutputSchema: z.ZodObject<{
2910
+ simulated: z.ZodLiteral<true>;
2911
+ preview: z.ZodObject<{
2912
+ from: z.ZodObject<{
2913
+ name: z.ZodString;
2914
+ address: z.ZodEmail;
2915
+ }, z.core.$strict>;
2916
+ replyTo: z.ZodOptional<z.ZodEmail>;
2917
+ to: z.ZodArray<z.ZodObject<{
2918
+ kind: z.ZodEnum<{
2919
+ person: "person";
2920
+ address: "address";
2921
+ }>;
2922
+ label: z.ZodString;
2923
+ }, z.core.$strict>>;
2924
+ cc: z.ZodArray<z.ZodObject<{
2925
+ kind: z.ZodEnum<{
2926
+ person: "person";
2927
+ address: "address";
2928
+ }>;
2929
+ label: z.ZodString;
2930
+ }, z.core.$strict>>;
2931
+ bcc: z.ZodArray<z.ZodObject<{
2932
+ kind: z.ZodEnum<{
2933
+ person: "person";
2934
+ address: "address";
2935
+ }>;
2936
+ label: z.ZodString;
2937
+ }, z.core.$strict>>;
2938
+ skipped: z.ZodNumber;
2939
+ subject: z.ZodString;
2940
+ html: z.ZodString;
2941
+ text: z.ZodString;
2942
+ }, z.core.$strict>;
2943
+ }, z.core.$strict>;
2944
+ readonly effect: "changing";
2945
+ readonly changeClass: "outward";
2946
+ readonly right: "mail_sender.use";
2947
+ readonly resourceKind: "mail_sender";
2948
+ readonly events: {
2949
+ readonly after: "mail.sent";
2950
+ readonly refused: "mail.refused";
2951
+ };
2952
+ readonly errorCodes: {
2953
+ readonly recipientNotAllowed: "recipient_not_allowed";
2954
+ readonly noRecipient: "no_recipient";
2955
+ readonly mailRejected: "mail_rejected";
2956
+ readonly workspaceNotAllowed: "workspace_not_allowed";
2957
+ };
2958
+ };
2959
+
2960
+ /** One instance's data separation dimension. SCOPE-1 serves one dimension. */
2961
+ declare const dataScopeNameSchema: z.ZodString;
2962
+ declare const dataScopesSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
2963
+ label: z.ZodString;
2964
+ valueType: z.ZodLiteral<"text">;
2965
+ }, z.core.$strict>>;
2966
+ type DataScopes = z.infer<typeof dataScopesSchema>;
2967
+ declare const scopeAssignmentInputSchema: z.ZodObject<{
2968
+ dimension: z.ZodString;
2969
+ holderKind: z.ZodEnum<{
2970
+ user: "user";
2971
+ service_principal: "service_principal";
2972
+ group: "group";
2973
+ }>;
2974
+ holderId: z.ZodString;
2975
+ effect: z.ZodEnum<{
2976
+ allow: "allow";
2977
+ deny: "deny";
2978
+ }>;
2979
+ values: z.ZodUnion<readonly [z.ZodLiteral<"all">, z.ZodArray<z.ZodString>]>;
2980
+ }, z.core.$strict>;
2981
+ type ScopeAssignmentInput = z.infer<typeof scopeAssignmentInputSchema>;
2982
+ declare const scopedTablesSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
2983
+ scope: z.ZodRecord<z.ZodString, z.ZodString>;
2984
+ }, z.core.$strict>>;
2985
+ type ScopedTables = z.infer<typeof scopedTablesSchema>;
2986
+
2987
+ /** The longest comment. */
2988
+ declare const FEEDBACK_TEXT_MAX_LENGTH = 4000;
2989
+ /** The longest machine-written summary and category a workflow stores on a comment. */
2990
+ declare const FEEDBACK_SUMMARY_MAX_LENGTH = 1000;
2991
+ declare const FEEDBACK_CATEGORY_MAX_LENGTH = 60;
2992
+ /** The longest note a reviewer leaves when marking a comment handled. */
2993
+ declare const FEEDBACK_NOTE_MAX_LENGTH = 2000;
2994
+ /**
2995
+ * What a comment is about. `message` in the first version; an App and a Workflow run follow
2996
+ * (LU-6), each with a reference of its own.
2997
+ */
2998
+ declare const FEEDBACK_SUBJECT_KINDS: readonly ["message"];
2999
+ type FeedbackSubjectKind = (typeof FEEDBACK_SUBJECT_KINDS)[number];
3000
+ declare const FEEDBACK_STATES: readonly ["new", "handled"];
3001
+ type FeedbackState = (typeof FEEDBACK_STATES)[number];
3002
+
3003
+ /** The longest note a person adds to a report. It goes into the mail and is kept nowhere. */
3004
+ declare const PLATFORM_REPORT_NOTE_MAX_LENGTH = 2000;
3005
+
3006
+ /** The source of an operation. A source the caller may not read is told by its kind alone. */
3007
+ declare const operationSourceSchema: z.ZodObject<{
3008
+ kind: z.ZodEnum<{
3009
+ workflow: "workflow";
3010
+ other: "other";
3011
+ connection: "connection";
3012
+ data_store: "data_store";
3013
+ knowledge_base: "knowledge_base";
3014
+ }>;
3015
+ title: z.ZodOptional<z.ZodString>;
3016
+ service: z.ZodOptional<z.ZodString>;
3017
+ }, z.core.$strip>;
3018
+ type OperationSourceView = z.infer<typeof operationSourceSchema>;
3019
+ declare const callableOperationSchema: z.ZodObject<{
3020
+ name: z.ZodString;
3021
+ effect: z.ZodEnum<{
3022
+ reading: "reading";
3023
+ changing: "changing";
3024
+ }>;
3025
+ title: z.ZodString;
3026
+ description: z.ZodOptional<z.ZodString>;
3027
+ source: z.ZodObject<{
3028
+ kind: z.ZodEnum<{
3029
+ workflow: "workflow";
3030
+ other: "other";
3031
+ connection: "connection";
3032
+ data_store: "data_store";
3033
+ knowledge_base: "knowledge_base";
3034
+ }>;
3035
+ title: z.ZodOptional<z.ZodString>;
3036
+ service: z.ZodOptional<z.ZodString>;
3037
+ }, z.core.$strip>;
3038
+ available: z.ZodBoolean;
3039
+ inputSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3040
+ outputSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3041
+ }, z.core.$strip>;
3042
+ type CallableOperationView = z.infer<typeof callableOperationSchema>;
3043
+ /** One page of callable operations. */
3044
+ declare const callableOperationsPageSchema: z.ZodObject<{
3045
+ operations: z.ZodArray<z.ZodObject<{
3046
+ name: z.ZodString;
3047
+ effect: z.ZodEnum<{
3048
+ reading: "reading";
3049
+ changing: "changing";
3050
+ }>;
3051
+ title: z.ZodString;
3052
+ description: z.ZodOptional<z.ZodString>;
3053
+ source: z.ZodObject<{
3054
+ kind: z.ZodEnum<{
3055
+ workflow: "workflow";
3056
+ other: "other";
3057
+ connection: "connection";
3058
+ data_store: "data_store";
3059
+ knowledge_base: "knowledge_base";
3060
+ }>;
3061
+ title: z.ZodOptional<z.ZodString>;
3062
+ service: z.ZodOptional<z.ZodString>;
3063
+ }, z.core.$strip>;
3064
+ available: z.ZodBoolean;
3065
+ inputSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3066
+ outputSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3067
+ }, z.core.$strip>>;
3068
+ nextCursor: z.ZodOptional<z.ZodString>;
3069
+ truncated: z.ZodBoolean;
3070
+ }, z.core.$strip>;
3071
+ type CallableOperationsPage = z.infer<typeof callableOperationsPageSchema>;
3072
+
3073
+ /** The tool a run calls to look at the preview. */
3074
+ declare const PREVIEW_CAPTURE_TOOL_NAME = "preview.capture";
3075
+ /** The widest picture, in pixels at device pixel ratio 1. A wider preview is scaled down. */
3076
+ declare const PREVIEW_CAPTURE_MAX_WIDTH = 1280;
3077
+ /** The tallest picture. A longer page is cut there. */
3078
+ declare const PREVIEW_CAPTURE_MAX_HEIGHT = 1600;
3079
+ /** The largest picture, in bytes. */
3080
+ declare const PREVIEW_CAPTURE_MAX_BYTES = 400000;
3081
+ /** Pictures one run may take. */
3082
+ declare const PREVIEW_CAPTURES_PER_RUN = 3;
3083
+ /** Pictures one person's runs may take in an hour. */
3084
+ declare const PREVIEW_CAPTURES_PER_HOUR = 20;
3085
+ /** How long a run waits for the person's browser to answer. */
3086
+ declare const PREVIEW_CAPTURE_WAIT_MS = 10000;
3087
+ /**
3088
+ * Why no picture was taken:
3089
+ * - `capture_limit`: the run or the person took as many as they may.
3090
+ * - `capture_unavailable`: the browser cannot draw the preview into a picture, as in Safari.
3091
+ * - `preview_not_viewed`: the person has no preview of the conversation open, or it did not answer.
3092
+ * - `preview_personal_data`: the preview reaches data through a personal connection.
3093
+ */
3094
+ declare const PREVIEW_CAPTURE_REFUSALS: readonly ["capture_limit", "capture_unavailable", "preview_not_viewed", "preview_personal_data"];
3095
+ type PreviewCaptureRefusal = (typeof PREVIEW_CAPTURE_REFUSALS)[number];
3096
+ /**
3097
+ * The size of a WebP image as its header states it, or nothing when the bytes are no complete
3098
+ * WebP file: a RIFF container of type WEBP whose length is the file's, with a `VP8 `, `VP8L`
3099
+ * or still `VP8X` chunk. The image is not decoded.
3100
+ */
3101
+ declare function readWebpSize(bytes: Uint8Array): {
3102
+ width: number;
3103
+ height: number;
3104
+ } | undefined;
3105
+ /** Whether bytes are a WebP picture within the bounds of a capture. */
3106
+ declare function isPreviewCaptureWithinBounds(bytes: Uint8Array): {
3107
+ width: number;
3108
+ height: number;
3109
+ } | undefined;
3110
+
3111
+ /** Distinct entries a report lists. Repeats are counted, and entries past this are counted. */
3112
+ declare const PREVIEW_REPORT_MAX_ENTRIES = 10;
3113
+ /** The longest message an entry keeps, after scrubbing. */
3114
+ declare const PREVIEW_REPORT_MAX_MESSAGE_CHARS = 200;
3115
+ /** The longest report, as UTF-8 JSON. Entries that do not fit are counted, not listed. */
3116
+ declare const PREVIEW_REPORT_MAX_BYTES = 2048;
3117
+ /** How long a report is kept after it was last written. */
3118
+ declare const PREVIEW_REPORT_KEEP_MS: number;
3119
+ /**
3120
+ * What an entry is: an uncaught error, an unhandled rejection, a `console.error`, a content
3121
+ * policy violation, or a call of the page that failed (by action name and refusal code).
3122
+ */
3123
+ declare const PREVIEW_REPORT_ENTRY_KINDS: readonly ["error", "rejection", "console", "policy", "call"];
3124
+ type PreviewReportEntryKind = (typeof PREVIEW_REPORT_ENTRY_KINDS)[number];
3125
+ /**
3126
+ * Whether the kit greeted: within 5 seconds of the frame loading, not (yet) while the frame is
3127
+ * young, not at all, or the folder does not use the kit, which the build records.
3128
+ */
3129
+ declare const PREVIEW_REPORT_BRIDGE_STATES: readonly ["connected", "waiting", "not_connected", "not_used"];
3130
+ type PreviewReportBridge = (typeof PREVIEW_REPORT_BRIDGE_STATES)[number];
3131
+ declare const previewReportEntrySchema: z.ZodObject<{
3132
+ kind: z.ZodEnum<{
3133
+ error: "error";
3134
+ rejection: "rejection";
3135
+ console: "console";
3136
+ policy: "policy";
3137
+ call: "call";
3138
+ }>;
3139
+ message: z.ZodString;
3140
+ code: z.ZodOptional<z.ZodString>;
3141
+ file: z.ZodOptional<z.ZodString>;
3142
+ line: z.ZodOptional<z.ZodNumber>;
3143
+ column: z.ZodOptional<z.ZodNumber>;
3144
+ count: z.ZodNumber;
3145
+ }, z.core.$strict>;
3146
+ type PreviewReportEntry = z.infer<typeof previewReportEntrySchema>;
3147
+ declare const previewReportSchema: z.ZodObject<{
3148
+ settled: z.ZodBoolean;
3149
+ loaded: z.ZodBoolean;
3150
+ bridge: z.ZodEnum<{
3151
+ connected: "connected";
3152
+ not_connected: "not_connected";
3153
+ waiting: "waiting";
3154
+ not_used: "not_used";
3155
+ }>;
3156
+ empty: z.ZodOptional<z.ZodBoolean>;
3157
+ entries: z.ZodArray<z.ZodObject<{
3158
+ kind: z.ZodEnum<{
3159
+ error: "error";
3160
+ rejection: "rejection";
3161
+ console: "console";
3162
+ policy: "policy";
3163
+ call: "call";
3164
+ }>;
3165
+ message: z.ZodString;
3166
+ code: z.ZodOptional<z.ZodString>;
3167
+ file: z.ZodOptional<z.ZodString>;
3168
+ line: z.ZodOptional<z.ZodNumber>;
3169
+ column: z.ZodOptional<z.ZodNumber>;
3170
+ count: z.ZodNumber;
3171
+ }, z.core.$strict>>;
3172
+ more: z.ZodNumber;
3173
+ }, z.core.$strict>;
3174
+ type PreviewReport = z.infer<typeof previewReportSchema>;
3175
+ /** A report as it is put together, before it is scrubbed and bounded. */
3176
+ interface UnboundPreviewReport {
3177
+ settled: boolean;
3178
+ loaded: boolean;
3179
+ bridge: PreviewReportBridge;
3180
+ empty?: boolean | undefined;
3181
+ entries: readonly {
3182
+ kind: PreviewReportEntryKind;
3183
+ message: string;
3184
+ code?: string | undefined;
3185
+ file?: string | undefined;
3186
+ line?: number | undefined;
3187
+ column?: number | undefined;
3188
+ count: number;
3189
+ }[];
3190
+ more?: number | undefined;
3191
+ }
3192
+ /**
3193
+ * A message as a report may keep it: long quoted text, the query of an address, mail
3194
+ * addresses, IBANs and digit runs become `…`, and at most 200 characters remain. The same text
3195
+ * scrubbed twice reads the same.
3196
+ */
3197
+ declare function scrubPreviewText(text: string): string;
3198
+ /**
3199
+ * Where an entry came from, as a report may keep it: a path relative to the page, a kit file as
3200
+ * its path on the instance, or `inline`. Never an origin, a query or the token of the frame's
3201
+ * address. Anything else is dropped.
3202
+ */
3203
+ declare function scrubPreviewFile(file: string | undefined): string | undefined;
3204
+ /**
3205
+ * The report as it may be kept: every message and file scrubbed, entries that read the same
3206
+ * afterwards merged with their counts added, at most 10 entries, at most 2 KB. What does not
3207
+ * fit is counted in `more`.
3208
+ */
3209
+ declare function boundPreviewReport(input: UnboundPreviewReport): PreviewReport;
3210
+
3211
+ declare const DATA_STORE_DESCRIPTION_TOOL_NAME = "platform.data_stores.describe";
3212
+ declare const dataStoreDescriptionInputSchema: z.ZodObject<{
3213
+ store: z.ZodString;
3214
+ }, z.core.$strict>;
3215
+ /** Metadata only. No defaults, SQL, rows, samples or distinct values belong here. */
3216
+ declare const dataStoreDescriptionSchema: z.ZodObject<{
3217
+ name: z.ZodString;
3218
+ title: z.ZodString;
3219
+ description: z.ZodOptional<z.ZodString>;
3220
+ owner: z.ZodUnion<readonly [z.ZodObject<{
3221
+ kind: z.ZodLiteral<"instance">;
3222
+ }, z.core.$strip>, z.ZodObject<{
3223
+ kind: z.ZodLiteral<"workspace">;
3224
+ workspaceId: z.ZodString;
3225
+ }, z.core.$strip>]>;
3226
+ published: z.ZodBoolean;
3227
+ tables: z.ZodArray<z.ZodObject<{
3228
+ name: z.ZodString;
3229
+ description: z.ZodOptional<z.ZodString>;
3230
+ rowEstimate: z.ZodNullable<z.ZodNumber>;
3231
+ fields: z.ZodArray<z.ZodObject<{
3232
+ name: z.ZodString;
3233
+ type: z.ZodString;
3234
+ description: z.ZodString;
3235
+ nullable: z.ZodBoolean;
3236
+ }, z.core.$strip>>;
3237
+ }, z.core.$strip>>;
3238
+ schemaAvailable: z.ZodBoolean;
3239
+ filledBy: z.ZodArray<z.ZodObject<{
3240
+ kind: z.ZodString;
3241
+ name: z.ZodString;
3242
+ title: z.ZodString;
3243
+ }, z.core.$strip>>;
3244
+ readBy: z.ZodArray<z.ZodObject<{
3245
+ kind: z.ZodString;
3246
+ name: z.ZodString;
3247
+ title: z.ZodString;
3248
+ }, z.core.$strip>>;
3249
+ usesTruncated: z.ZodBoolean;
3250
+ rights: z.ZodObject<{
3251
+ read: z.ZodBoolean;
3252
+ add: z.ZodBoolean;
3253
+ change: z.ZodBoolean;
3254
+ }, z.core.$strip>;
3255
+ chat: z.ZodObject<{
3256
+ canReadRows: z.ZodBoolean;
3257
+ reason: z.ZodString;
3258
+ nextStep: z.ZodOptional<z.ZodString>;
3259
+ }, z.core.$strip>;
3260
+ }, z.core.$strip>;
3261
+
3262
+ declare const serverPreviewCaptureInputSchema: z.ZodObject<{
3263
+ themeColors: z.ZodObject<{
3264
+ surfaceColor: z.ZodString;
3265
+ backgroundColor: z.ZodString;
3266
+ textColor: z.ZodString;
3267
+ mutedTextColor: z.ZodString;
3268
+ borderColor: z.ZodString;
3269
+ accentColor: z.ZodString;
3270
+ accentStrongColor: z.ZodString;
3271
+ }, z.core.$strict>;
3272
+ contentPath: z.ZodString;
3273
+ session: z.ZodString;
3274
+ deadline: z.ZodNumber;
3275
+ size: z.ZodEnum<{
3276
+ phone: "phone";
3277
+ tablet: "tablet";
3278
+ desktop: "desktop";
3279
+ }>;
3280
+ theme: z.ZodEnum<{
3281
+ light: "light";
3282
+ dark: "dark";
3283
+ }>;
3284
+ locale: z.ZodEnum<{
3285
+ en: "en";
3286
+ de: "de";
3287
+ }>;
3288
+ number: z.ZodNumber;
3289
+ }, z.core.$strict>;
3290
+ declare const serverPreviewCaptureOutcomeSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
3291
+ status: z.ZodLiteral<"done">;
3292
+ image: z.ZodString;
3293
+ report: z.ZodUnknown;
3294
+ blocked: z.ZodArray<z.ZodObject<{
3295
+ method: z.ZodString;
3296
+ host: z.ZodString;
3297
+ path: z.ZodString;
3298
+ }, z.core.$strict>>;
3299
+ calls: z.ZodArray<z.ZodObject<{
3300
+ name: z.ZodString;
3301
+ code: z.ZodString;
3302
+ }, z.core.$strict>>;
3303
+ }, z.core.$strict>, z.ZodObject<{
3304
+ status: z.ZodLiteral<"refused">;
3305
+ code: z.ZodEnum<{
3306
+ capture_busy: "capture_busy";
3307
+ capture_failed: "capture_failed";
3308
+ }>;
3309
+ message: z.ZodOptional<z.ZodString>;
3310
+ }, z.core.$strict>], "status">;
3311
+ type ServerPreviewCaptureInput = z.infer<typeof serverPreviewCaptureInputSchema>;
3312
+ type ServerPreviewCaptureOutcome = z.infer<typeof serverPreviewCaptureOutcomeSchema>;
3313
+
3314
+ export { ACCESS_SOURCES, ACTIONS, ACTIVE_AGENT_RUN_STATUSES, ADMINISTERED_USER_STATUSES, AGENT_AVAILABILITY_MODES, AGENT_EDITABLE_FIELDS, AGENT_PREVIEW_SOURCES, AGENT_RUN_FAILURE_CATEGORIES, AGENT_RUN_STATUSES, AGENT_STARTERS_MAX, AGENT_USE_SETTINGS, API_CREDENTIAL_SCOPES, APPROVAL_CHECK_FAILURE_OUTCOMES, APPROVAL_CHECK_STATUSES, APPROVAL_EXECUTIONS, APPROVAL_REQUEST_STATUSES, APP_ACTION_CALL_STATUSES, APP_AUDIENCES, APP_ERROR_CODES, APP_ERROR_STATUS_CODES, APP_MODES, ARTIFACT_PREVIEW_IMAGE_FORMATS, ARTIFACT_PREVIEW_IMAGE_MIME_TYPES, ARTIFACT_PREVIEW_STATUSES, ASSET_ACCESS_VERBS, ASSET_LIFECYCLES, ASSET_MOVE_EDITORS, ASSET_MOVE_PATHS, ASSET_MOVE_STATUSES, ASSET_MOVE_USERS, ASSET_NAME_REFUSAL_REASONS, ASSET_OWNER_KINDS, ASSET_OWNER_RUNGS, ASSET_REPO_BUNDLE_KINDS, ASSET_REPRESENTATIONS, ASSET_SYNC_CHANGE_TYPES, ATTACHMENT_CREATE_OUTCOMES, AUDIT_ACTOR_KINDS, AUDIT_EVENT_STATUSES, AUDIT_OUTCOMES, AUDIT_TIERS, AUTH_PRINCIPAL_KINDS, AUTH_SCOPE_WILDCARD, AWS_ACCOUNT_ID, type AccessSource, type ActiveAgentRunStatus, type AdministeredUserStatus, type AgentAvailabilityMode, type AgentConfig, type AgentEditableField, type AgentInitialPromptConfig, type AgentRunFailureCategory, type AgentRunStatus, type AgentUse, type ApiCredentialScope, type AppActionCallStatus, type AppErrorCode, type AppMode, type ApprovalCheckFailureOutcome, type ApprovalCheckStatus, type ApprovalExecution, type ApprovalRequestStatus, type ArtifactPreviewImageFormat, type ArtifactPreviewImageMimeType, type ArtifactPreviewStatus, type AssetLifecycle, type AssetMoveEditors, type AssetMovePath, type AssetMoveStatus, type AssetMoveUsers, type AssetNameRefusalReason, type AssetOwnerKind, type AssetOwnerRung, type AssetRepoBundleKind, type AssetRepresentation, type AssetSyncChangeType, type AttachmentCreateOutcome, type AuditActorKind, type AuditEventStatus, type AuditOutcome, type AuditTier, type AuthPrincipalKind, BEDROCK_REGION, CATALOGUE_CATEGORIES, CATALOGUE_PARTS, CHAT_MESSAGE_ROLES, CHAT_SESSION_AUTH_SCOPES, COLLABORATION_WORKSPACE_KINDS, CONFIG_ASSET_CHANGE_OPERATIONS, CONFIG_ASSET_KINDS, CONNECTION_BINDING_STATES, CONNECTION_CREDENTIAL_MODES, CONNECTION_EXPOSURES, CONNECTION_HEALTH_STATES, CONNECTION_NAME_MAX_LENGTH, CONNECTION_NAME_PATTERN, CONNECTION_NETWORKS, CONNECTION_OAUTH_REGISTRATIONS, CONNECTION_OPERATION_POLICIES, CONNECTION_OPERATION_STATUSES, CONNECTION_ORIGINS, CONNECTION_PROPOSAL_BINDING_STATES, CONNECTION_PROPOSAL_STATES, CONNECTION_PROVIDER_REVOCATIONS, CONNECTION_SECRET_STATES, CONNECTION_SIGN_IN_NEEDS, CONNECTOR_TEST_STATUSES, CONVERSATION_ATTACHMENT_STATUSES, CONVERSATION_KINDS, CONVERSATION_VISIBILITIES, type CallableOperationView, type CallableOperationsPage, type CatalogueCategory, type CataloguePart, type ChatMessageRole, type ChatSessionAuthScope, type CollaborationWorkspaceKind, type ConfigAssetChangeOperation, type ConfigAssetKind, type ConnectionBindingState, type ConnectionCredentialMode, type ConnectionExposure, type ConnectionHealth, type ConnectionNetwork, type ConnectionOAuthRegistration, type ConnectionOperationPolicy, type ConnectionOperationStatus, type ConnectionOrigin, type ConnectionProposalBindingState, type ConnectionProposalState, type ConnectionProviderRevocation, type ConnectionSecretState, type ConnectionSignInNeed, type ConnectorTestStatus, type ConversationAttachmentStatus, type ConversationKind, type ConversationVisibility, DATABASE_RELATION_TYPES, DATA_STORE_CONDITIONS, DATA_STORE_DESCRIPTION_TOOL_NAME, DATA_STORE_INSERT_CONFLICT_MODES, DATA_STORE_LOAD_CONFLICT_MODES, DATA_STORE_MIGRATION_OUTCOMES, DATA_STORE_SCALAR_TYPES, DATA_STORE_STATUSES, DECIDED_APPROVAL_REQUEST_STATUSES, DELETION_STATES, type DataScopes, type DataStoreCondition, type DataStoreInsertConflictMode, type DataStoreLoadConflictMode, type DataStoreMigrationOutcome, type DataStoreRecordField, type DataStoreRecordProposalItem, type DataStoreRecordsDecideInput, type DataStoreRecordsDecideOutput, type DataStoreRecordsFlaggedInput, type DataStoreRecordsFlaggedOutput, type DataStoreRecordsProposeInput, type DataStoreRecordsRule, type DataStoreScalarType, type DataStoreStatus, type DatabaseRelationType, type DecidedApprovalRequestStatus, type DeletionState, ENDED_AGENT_RUN_STATUSES, ENDED_APPROVAL_EXECUTIONS, type EndedAgentRunStatus, type EndedApprovalExecution, FAILED_JOB_STATUSES, FEEDBACK_CATEGORY_MAX_LENGTH, FEEDBACK_NOTE_MAX_LENGTH, FEEDBACK_STATES, FEEDBACK_SUBJECT_KINDS, FEEDBACK_SUMMARY_MAX_LENGTH, FEEDBACK_TEXT_MAX_LENGTH, FIRST_PARTY_AUTH_SCOPES, FOLLOW_UP_MODES, FOLLOW_UP_STATUSES, type FailedJobStatus, type FeedbackState, type FeedbackSubjectKind, type FirstPartyAuthScope, GRANT_EFFECTS, GRANT_HOLDER_KINDS, GRANT_SCOPE_KINDS, GUARDRAIL_HIT_OUTCOMES, GUARDRAIL_NAME_MAX_LENGTH, GUARDRAIL_NAME_PATTERN, GUARDRAIL_OUTCOMES, type GrantEffect, type GrantHolderKind, type GrantScopeKind, type GuardrailHitOutcome, type GuardrailOutcome, IDEMPOTENCY_KEY_MAX_LENGTH, INFRASTRUCTURE_SECRET_STATES, INFRASTRUCTURE_WITHHELD_FIELDS, type InfrastructureSecretState, type InfrastructureWithheldField, JOB_STATUSES, type JobStatus, KNOWLEDGE_BASE_STATUSES, KNOWLEDGE_CHECK_STATUSES, KNOWLEDGE_DOCUMENT_FAILURE_CODES, KNOWLEDGE_DOCUMENT_STATES, KNOWLEDGE_DOCUMENT_WAIT_CODES, KNOWLEDGE_EMBEDDING_STATES, KNOWLEDGE_FILE_MAX_BYTES, KNOWLEDGE_SEARCH_SIGNALS, KNOWLEDGE_SOURCE_FAILURE_CODES, KNOWLEDGE_SOURCE_ITEM_FAILURE_CODES, KNOWLEDGE_SOURCE_ITEM_SHOWN_STATES, KNOWLEDGE_SOURCE_ITEM_STATES, KNOWLEDGE_SYNC_COUNTS, KNOWLEDGE_SYNC_MODES, KNOWLEDGE_SYNC_RUN_STATES, type KnowledgeBaseStatus, type KnowledgeCheckStatus, type KnowledgeDocumentFailureCode, type KnowledgeDocumentState, type KnowledgeDocumentWaitCode, type KnowledgeExtractFieldsInput, type KnowledgeExtractFieldsOutput, type KnowledgeFirstPassConfirmation, type KnowledgeIngestFetch, type KnowledgeIngestInput, type KnowledgeIngestItem, type KnowledgeIngestOutput, type KnowledgeLocateInput, type KnowledgeLocateOutput, type KnowledgePendingInput, type KnowledgePendingOutput, type KnowledgePendingRow, type KnowledgeProcessorOutput, type KnowledgePutProcessedInput, type KnowledgeRetryInput, type KnowledgeRetryOutput, type KnowledgeSearchSignal, type KnowledgeSourceFailureCode, type KnowledgeSourceItemFailureCode, type KnowledgeSourceItemShownState, type KnowledgeSourceItemState, type KnowledgeSourceItemsInput, type KnowledgeSourceItemsOutput, type KnowledgeSourcesOutput, type KnowledgeSyncCount, type KnowledgeSyncInput, type KnowledgeSyncMode, type KnowledgeSyncResult, type KnowledgeSyncRunState, type KnowledgeWithdrawInput, type KnowledgeWithdrawOutput, type KnowledgeWorkflowSource, type KnowledgeWorkflowSourcesOutput, LISTED_DATA_STORE_STATUSES, LIVE_JOB_STATUSES, type ListedDataStoreStatus, type LiveJobStatus, type LocaleCode, type LocalizedStringConfig, MAIL_ADDRESS_MAX_LENGTH, MAIL_ATTACHMENTS_MAX_BYTES, MAIL_ATTACHMENTS_MAX_FILES, MAIL_AUDIT_MAX_DOMAINS, MAIL_BODY_MAX_BYTES, MAIL_OUTBOUND_DEFAULT_LIMITS, MAIL_OUTBOUND_FOOTER_MAX_LENGTH, MAIL_RECIPIENT_DOMAINS_ANY, MAIL_RECIPIENT_DOMAIN_PATTERN, MAIL_RECIPIENT_ID_PATTERN, MAIL_SENDER_CONNECTION_PREFIX, MAIL_SENDER_NAME_MAX_LENGTH, MAIL_SENDER_RESOURCE_KIND, MAIL_SENDER_SYSTEM, MAIL_SENDER_SYSTEM_ICON, MAIL_SENDER_USE_ACTION, MAIL_SEND_ERROR_CODES, MAIL_SEND_MAX_ADDRESSES, MAIL_SEND_OPERATION, MAIL_SEND_REFUSAL_REASONS, MAIL_SUBJECT_MAX_LENGTH, MAIL_WORKFLOW_MESSAGE_TEMPLATE, MANAGED_FILE_STATUSES, MESSAGE_FINISH_STATUSES, MODEL_FALLBACK_REASONS, MODEL_PROVIDER_AUTH_MODES, MODEL_USAGE_EVENT_STATUSES, MODEL_USAGE_LIMIT_METRICS, MODEL_USAGE_LIMIT_PERIODS, MODEL_USAGE_LIMIT_SCOPES, MODEL_USAGE_SOURCES, MODEL_USAGE_TIERS, type MailPreviewRecipient, type MailSendErrorCode, type MailSendInput, type MailSendInputFields, type MailSendOutput, type MailSendPreview, type MailSendRecipient, type MailSendRecipientList, type MailSendRefusalDetails, type MailSendSimulatedOutput, type MailSenderId, type MessageFinishStatus, type ModelFallbackReason, type ModelProviderAuthMode, type ModelUsageEventStatus, type ModelUsageRefusal, type ModelUsageSource, type ModelUsageTier, NOTIFY_CHANNELS, type NotifyChannel, OPENAI_COMPATIBLE_APIS, OPERATIONS_AUDIENCES, OPERATION_CHANGE_CLASSES, OPERATION_CONFIRMATION_DECISIONS, OPERATION_DENIAL_REASONS, OPERATION_EFFECTS, OPERATION_ORIGIN_KINDS, OPERATION_RUN_DECISION_MODES, OPERATION_RUN_DECISION_REASONS, OPERATION_RUN_STATUSES, OPERATION_SOURCE_KINDS, OPERATION_TARGETS, type OpenaiCompatibleApi, type OperationBatchFailure, type OperationBatchResult, type OperationDenialReason, type OperationEffect, type OperationOriginKind, type OperationPaging, type OperationRunDecisionMode, type OperationRunDecisionReason, type OperationRunStatus, type OperationScope, type OperationSourceKind, type OperationSourceView, type OperationTarget, type OperationsAudience, PERSONAL_AGENTS_KEY, PERSONAL_WORKSPACES_KEY, PERSON_POLICY_SETTINGS, PLATFORM_REPORT_NOTE_MAX_LENGTH, POLICY_VALUES, PREVIEW_CAPTURES_PER_HOUR, PREVIEW_CAPTURES_PER_RUN, PREVIEW_CAPTURE_MAX_BYTES, PREVIEW_CAPTURE_MAX_HEIGHT, PREVIEW_CAPTURE_MAX_WIDTH, PREVIEW_CAPTURE_REFUSALS, PREVIEW_CAPTURE_SIZES, PREVIEW_CAPTURE_STATUSES, PREVIEW_CAPTURE_TOOL_NAME, PREVIEW_CAPTURE_WAIT_MS, PREVIEW_REPORT_BRIDGE_STATES, PREVIEW_REPORT_ENTRY_KINDS, PREVIEW_REPORT_KEEP_MS, PREVIEW_REPORT_MAX_BYTES, PREVIEW_REPORT_MAX_ENTRIES, PREVIEW_REPORT_MAX_MESSAGE_CHARS, PRINCIPAL_HOLDER_KINDS, PROJECT_ACTIONS, PROJECT_ASSET_KIND, PROJECT_AUDIENCES, PROJECT_CHOICE_REFUSALS, PROJECT_DELETION_CONVERSATIONS, PROJECT_DESCRIPTION_MAX_LENGTH, PROJECT_FILE_CHANGES, PROJECT_FILE_ORIGINS, PROJECT_FOLDER_WRITE_CHANGES, PROJECT_KNOWLEDGE_BASES_MAX, PROJECT_NAME_MAX_LENGTH, PROJECT_NAME_PATTERN, PROJECT_SKILLS_MAX, PROJECT_TITLE_MAX_LENGTH, PROVIDER_CHECK_ERROR_CLASSES, PROVIDER_PORTS, PROVIDER_REGIONS, PUBLISHED_DATA_CONSUMER_KINDS, type PlatformAction, type PolicyValue, type PreviewCaptureRefusal, type PreviewReport, type PreviewReportBridge, type PreviewReportEntry, type PreviewReportEntryKind, type PrincipalHolderKind, type ProjectAudience, type ProjectDeletionConversations, type ProviderCheckErrorClass, type ProviderPort, type ProviderRegion, type PublishedDataConsumerKind, READING_POLICY_VALUES, REASONING_EFFORTS, RECORDS_FLAGGED_MAX_ITEMS_PER_PAGE, RECORDS_PROPOSE_MAX_FIELDS_PER_ITEM, RECORDS_PROPOSE_MAX_ITEMS_PER_CALL, RECORD_FIELD_FAILURE_CODES, RECORD_FIELD_STATES, RECORD_FLAG_REASONS, ROLE_GRANT_SCOPE_KINDS, ROLE_PENDING_CHANGES, ROLE_PENDING_DECISIONS, type ReadingPolicyValue, type ReasoningEffortConfig, type RecordColumn, type RecordEvidenceResult, type RoleGrantScopeKind, type RolePendingDecision, SCHEDULED_START_STATES, SECRET_NAME_EXPECTATION, SERVER_PREVIEW_CAPTURE_REFUSALS, SERVICE_PRINCIPAL_PERMISSIONS, SERVICE_PRINCIPAL_STATUSES, SKILL_CHANGE_TYPES, SKILL_FRONTMATTER_FIELDS, SKILL_FRONTMATTER_MAX_BYTES, SKILL_FRONTMATTER_MAX_DEPTH, SKILL_NAME_PATTERN, SKILL_NAME_RULE, SKILL_ORIGINS, SKILL_PORTABLE_DESCRIPTION_MAX_CHARS, SKILL_PORTABLE_NAME_MAX_CHARS, SKILL_RESOURCE_MEDIA_TYPES, SKILL_STARTERS_MAX, SKILL_STARTER_LINE_MAX_LENGTH, SKILL_SUMMARY_MAX_LENGTH, STRUCTURED_DATA_REVIEW_REASONS, STUDIO_KIND_PATHS, SUPPORTED_IMAGE_MIME_TYPES, type ScopeAssignmentInput, type ScopedTables, type ServerPreviewCaptureInput, type ServerPreviewCaptureOutcome, type ServicePrincipalPermission, type ServicePrincipalStatus, type SkillChangeType, type SkillConfig, type SkillFileEntry, type SkillFrontmatterRefusal, SkillMarkdownError, type SkillOrigin, type SkillResourceConfig, type SkillResourceMediaType, type SkillStarterConfig, type StructuredDataReviewReason, type SupportedImageMimeType, THEME_MODES, THEME_MODE_PREFERENCES, TOOL_CALL_STATES, TOOL_DECISION_MODES, TOOL_DECISION_OUTCOMES, TOOL_DISPLAY_MODES, TOOL_GROUPS, TOOL_INPUT_PARSE_ERROR_CODES, type ThemeMode, type ThemeModePreference, type ToolCallState, type ToolDisplayMode, type ToolGroup, type ToolInputParseErrorCode, USAGE_BREAKDOWN_DIMENSIONS, USAGE_COST_STATUSES, USAGE_ORIGINS, USAGE_SPEND_LIMIT_LEVELS, USER_STATUSES, type UnboundPreviewReport, type UsageCostStatus, type UserStatus, WAITING_OPERATION_RUN_STATUSES, WEB_SOURCE_PROVIDERS, WORKFLOW_DATASET_DOWNLOAD_FORMATS, WORKFLOW_DATASET_STATES, WORKFLOW_ENDED_STATUSES, WORKFLOW_EXECUTED_STEP_TYPES, WORKFLOW_KINDS, WORKFLOW_MARKDOWN_MAX_COLUMNS, WORKFLOW_MARKDOWN_MAX_ROWS, WORKFLOW_NAME_PATTERN, WORKFLOW_NAME_RULE, WORKFLOW_RESERVED_STEP_TYPES, WORKFLOW_RIGHTS_REVISIONS, WORKFLOW_RIGHT_NEEDED_FOR, WORKFLOW_RIGHT_REFUSALS, WORKFLOW_RUN_ACCOUNT_STATUSES, WORKFLOW_RUN_MODES, WORKFLOW_RUN_STATUSES, WORKFLOW_STEP_RUN_STATUSES, WORKFLOW_STEP_SOURCE_KINDS, WORKFLOW_STEP_TYPES, WORKFLOW_TEST_REVISIONS, WORKFLOW_TEXT_FORMAT_MARKDOWN, WORKFLOW_TEXT_MAX_PARTS, WORKFLOW_TRIGGER_KINDS, WORKSPACE_ACCENT_COLORS, WORKSPACE_ACCESS_STATES, WORKSPACE_COMMAND_STATUSES, WORKSPACE_FILE_KINDS, WORKSPACE_MEMBERSHIP_ROLES, WORKSPACE_SECTIONS, WORKSPACE_USE_ASSET_KINDS, WORKSPACE_VISIBILITIES, type WebSourceProvider, type WorkflowAssetConfig, type WorkflowDatasetDownloadFormat, type WorkflowDatasetState, type WorkflowEndedStatus, type WorkflowKind, type WorkflowMailSenderFact, type WorkflowMessageMailParams, type WorkflowReservedStepType, type WorkflowRunMode, type WorkflowRunStatus, type WorkflowStepRunStatus, type WorkflowStepSourceKind, type WorkflowStepType, type WorkflowTestRevision, type WorkflowTriggerKind, type WorkspaceAccentColor, type WorkspaceAccessState, type WorkspaceCommandStatus, type WorkspaceFileKind, type WorkspaceMembershipRole, type WorkspaceSection, type WorkspaceVisibility, YAML_DATA_MAX_VALUES, YamlDataError, type YamlDataIssue, type YamlDataIssueCode, type YamlDataOptions, type YamlDataResult, agentConfigSchema, appInterfacePath, assetPagePath, bedrockProfileRefusal, boundPreviewReport, callableOperationSchema, callableOperationsPageSchema, checkStorableTexts, conversationInterfacePath, dataScopeNameSchema, dataScopesSchema, dataStoreDescriptionInputSchema, dataStoreDescriptionSchema, dataStoreRecordFieldSchema, dataStoreRecordProposalItemSchema, dataStoreRecordsContracts, dataStoreRecordsDecideInputSchema, dataStoreRecordsDecideOutputSchema, dataStoreRecordsFlaggedInputSchema, dataStoreRecordsFlaggedOutputSchema, dataStoreRecordsProposeInputSchema, dataStoreRecordsRuleSchema, deriveSkillTitle, formatSkillMarkdown, inboxItemPath, isPlainConfigObject, isPreviewCaptureWithinBounds, isRecord, isSecretName, isStorableText, knowledgeExtractFieldsInputSchema, knowledgeExtractFieldsOutputSchema, knowledgeFieldValueSchema, knowledgeFirstPassConfirmationSchema, knowledgeIngestFetchSchema, knowledgeIngestInputSchema, knowledgeIngestItemSchema, knowledgeIngestOutputSchema, knowledgeLocateInputSchema, knowledgeLocateOutputSchema, knowledgePendingInputSchema, knowledgePendingOutputSchema, knowledgePendingRowSchema, knowledgeProcessorOutputSchema, knowledgePutProcessedInputSchema, knowledgeRecordsRefusalSchema, knowledgeRetryInputSchema, knowledgeRetryOutputSchema, knowledgeSourceItemsInputSchema, knowledgeSourceItemsOutputSchema, knowledgeSourcesOutputSchema, knowledgeSyncInputSchema, knowledgeSyncResultSchema, knowledgeWithdrawInputSchema, knowledgeWithdrawOutputSchema, knowledgeWorkflowSourceSchema, knowledgeWorkflowSourcesOutputSchema, knowledgeWriteContracts, loadYamlData, localeCodes, localizedStringSchema, mailAddressSchema, mailBodySchema, mailCopyRecipientListSchema, mailPreviewRecipientSchema, mailRecipientDomainSchema, mailRecipientListSchema, mailRecipientSchema, mailReplyToSchema, mailSendContract, mailSendInputSchema, mailSendOutputSchema, mailSendPreviewSchema, mailSendRefusalDetailsSchema, mailSendSimulatedOutputSchema, mailSenderIdSchema, mailSenderNameSchema, mailSubjectSchema, mergeConfigObjects, operationBatchFailureSchema, operationBatchResultSchema, operationPagingSchema, operationSourceSchema, parseSkillMarkdown, previewReportEntrySchema, previewReportSchema, providerRegionSchema, readWebpSize, readYamlData, recordColumnTakes, recordEvidenceResultSchema, scopeAssignmentInputSchema, scopedTablesSchema, scrubPreviewFile, scrubPreviewText, serverPreviewCaptureInputSchema, serverPreviewCaptureOutcomeSchema, skillConfigSchema, skillFileEntrySchema, skillFileFrontmatterSchema, skillNameSchema, skillPortabilityIssues, skillResourceConfigSchema, skillResourceMediaTypeForPath, skillResourcePathSchema, skillStarterSchema, workflowConfigSchema, workflowDataFlowsSchema, workflowDatasetReferenceSchema, workflowFileReferenceSchema, workflowMailSenderFactSchema, workflowMessageMailParamsSchema, writeYamlData, yamlValueIssue, yamlValueIssueSentence };