@work-shape/catalyst-asset-schemas 0.8.0-rc.2 → 0.8.0-rc.4
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.
- package/dist/index.d.ts +371 -10
- package/dist/index.js +261 -5
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -36,10 +36,16 @@ interface AgentConfig {
|
|
|
36
36
|
modelReasoningEfforts?: Record<string, ReasoningEffortConfig>;
|
|
37
37
|
maxSteps?: number;
|
|
38
38
|
toolNames: string[];
|
|
39
|
+
/**
|
|
40
|
+
* The other agents this agent may start as subagents with `run_agent`, besides itself. Each
|
|
41
|
+
* is started only where the person may use it in the conversation's workspace.
|
|
42
|
+
*/
|
|
43
|
+
subagentNames?: string[];
|
|
39
44
|
skillNames: string[];
|
|
40
45
|
/**
|
|
41
46
|
* The Knowledge Bases the agent answers from, by id. However many it lists, the agent has one
|
|
42
|
-
* tool over
|
|
47
|
+
* tool over those of tables, `knowledge.query`, and one over those of documents,
|
|
48
|
+
* `knowledge.search`. Missing means none.
|
|
43
49
|
*/
|
|
44
50
|
knowledgeBases?: string[];
|
|
45
51
|
initialPrompts: AgentInitialPromptConfig[];
|
|
@@ -135,7 +141,7 @@ declare const FIRST_PARTY_AUTH_SCOPES: readonly ["*", "me:read", "me:delete", "c
|
|
|
135
141
|
type ChatSessionAuthScope = (typeof CHAT_SESSION_AUTH_SCOPES)[number];
|
|
136
142
|
type FirstPartyAuthScope = (typeof FIRST_PARTY_AUTH_SCOPES)[number];
|
|
137
143
|
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"];
|
|
144
|
+
declare const ACTIONS: readonly ["agent.read", "agent.write", "agent.publish", "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"];
|
|
139
145
|
type PlatformAction = (typeof ACTIONS)[number];
|
|
140
146
|
/** A Namespace prefix: lowercase words joined by single hyphens, ending in one hyphen. */
|
|
141
147
|
declare const NAMESPACE_PREFIX_PATTERN: RegExp;
|
|
@@ -225,7 +231,7 @@ declare const APPROVAL_REQUEST_STATUSES: readonly ["pending", "approved", "rejec
|
|
|
225
231
|
type ApprovalRequestStatus = (typeof APPROVAL_REQUEST_STATUSES)[number];
|
|
226
232
|
declare const APPROVAL_CHECK_STATUSES: readonly ["passed", "warned", "blocked"];
|
|
227
233
|
type ApprovalCheckStatus = (typeof APPROVAL_CHECK_STATUSES)[number];
|
|
228
|
-
declare const APPROVAL_EXECUTIONS: readonly ["queued", "done", "failed", "interrupted", "refused", "expired"];
|
|
234
|
+
declare const APPROVAL_EXECUTIONS: readonly ["queued", "done", "failed", "interrupted", "refused", "expired", "held"];
|
|
229
235
|
type ApprovalExecution = (typeof APPROVAL_EXECUTIONS)[number];
|
|
230
236
|
declare const SKILL_CHANGE_TYPES: readonly ["replace", "add", "new_resource"];
|
|
231
237
|
type SkillChangeType = (typeof SKILL_CHANGE_TYPES)[number];
|
|
@@ -282,6 +288,9 @@ type OpenaiCompatibleApi = (typeof OPENAI_COMPATIBLE_APIS)[number];
|
|
|
282
288
|
declare const MODEL_PROVIDER_AUTH_MODES: readonly ["bearer", "api-key"];
|
|
283
289
|
type ModelProviderAuthMode = (typeof MODEL_PROVIDER_AUTH_MODES)[number];
|
|
284
290
|
declare const CONVERSATION_VISIBILITIES: readonly ["workspace", "private"];
|
|
291
|
+
/** A conversation a person has, or the run thread of a Child Agent Run. */
|
|
292
|
+
declare const CONVERSATION_KINDS: readonly ["chat", "run_thread"];
|
|
293
|
+
type ConversationKind = (typeof CONVERSATION_KINDS)[number];
|
|
285
294
|
type ConversationVisibility = (typeof CONVERSATION_VISIBILITIES)[number];
|
|
286
295
|
declare const WEB_SOURCE_PROVIDERS: readonly ["openai-native", "serper", "tavily", "firecrawl", "browserbase", "direct"];
|
|
287
296
|
type WebSourceProvider = (typeof WEB_SOURCE_PROVIDERS)[number];
|
|
@@ -293,7 +302,9 @@ declare const ATTACHMENT_CREATE_OUTCOMES: readonly ["created", "already_availabl
|
|
|
293
302
|
type AttachmentCreateOutcome = (typeof ATTACHMENT_CREATE_OUTCOMES)[number];
|
|
294
303
|
declare const STRUCTURED_DATA_REVIEW_REASONS: readonly ["uncertain", "conflicting"];
|
|
295
304
|
type StructuredDataReviewReason = (typeof STRUCTURED_DATA_REVIEW_REASONS)[number];
|
|
296
|
-
declare const
|
|
305
|
+
declare const FOLLOW_UP_MODES: readonly ["queue"];
|
|
306
|
+
declare const FOLLOW_UP_STATUSES: readonly ["pending", "dispatched", "cancelled"];
|
|
307
|
+
declare const AGENT_RUN_STATUSES: readonly ["queued", "running", "waiting_for_decision", "waiting_for_subagents", "cancelling", "completed", "cancelled", "failed"];
|
|
297
308
|
type AgentRunStatus = (typeof AGENT_RUN_STATUSES)[number];
|
|
298
309
|
declare const AGENT_RUN_FAILURE_CATEGORIES: readonly ["app_error", "internal_error", "runtime_interrupted", "abort_error", "unknown_error"];
|
|
299
310
|
type AgentRunFailureCategory = (typeof AGENT_RUN_FAILURE_CATEGORIES)[number];
|
|
@@ -333,8 +344,27 @@ declare const CONNECTION_OPERATION_STATUSES: readonly ["ready", "awaiting_discov
|
|
|
333
344
|
type ConnectionOperationStatus = (typeof CONNECTION_OPERATION_STATUSES)[number];
|
|
334
345
|
declare const CONNECTION_SECRET_STATES: readonly ["set", "not_set", "unreadable"];
|
|
335
346
|
type ConnectionSecretState = (typeof CONNECTION_SECRET_STATES)[number];
|
|
336
|
-
declare const CONNECTOR_TEST_STATUSES: readonly ["ready", "unauthorized", "network_denied", "unavailable"];
|
|
347
|
+
declare const CONNECTOR_TEST_STATUSES: readonly ["ready", "unauthorized", "network_denied", "unavailable", "oauth_required"];
|
|
337
348
|
type ConnectorTestStatus = (typeof CONNECTOR_TEST_STATUSES)[number];
|
|
349
|
+
/**
|
|
350
|
+
* The state of a Connection's sign-in. `connected`: calls use it. `needs_reconnect`: the
|
|
351
|
+
* outside system refused it and a new sign-in is needed. `revoked`: someone disconnected it,
|
|
352
|
+
* or its Connection went away.
|
|
353
|
+
*/
|
|
354
|
+
declare const CONNECTION_BINDING_STATES: readonly ["connected", "needs_reconnect", "revoked"];
|
|
355
|
+
type ConnectionBindingState = (typeof CONNECTION_BINDING_STATES)[number];
|
|
356
|
+
/**
|
|
357
|
+
* How a Connection that signs in with OAuth has its client: registered by the platform
|
|
358
|
+
* (Dynamic Client Registration) or issued by the provider and named in the settings.
|
|
359
|
+
*/
|
|
360
|
+
declare const CONNECTION_OAUTH_REGISTRATIONS: readonly ["dcr", "preregistered"];
|
|
361
|
+
type ConnectionOAuthRegistration = (typeof CONNECTION_OAUTH_REGISTRATIONS)[number];
|
|
362
|
+
/**
|
|
363
|
+
* What the provider answered to the revocation of a sign-in (RFC 7009): it confirmed, it
|
|
364
|
+
* failed or was not reached, or it lists no revocation endpoint and was sent nothing.
|
|
365
|
+
*/
|
|
366
|
+
declare const CONNECTION_PROVIDER_REVOCATIONS: readonly ["confirmed", "failed", "not_offered"];
|
|
367
|
+
type ConnectionProviderRevocation = (typeof CONNECTION_PROVIDER_REVOCATIONS)[number];
|
|
338
368
|
declare const CONNECTION_ORIGINS: readonly ["release", "runtime"];
|
|
339
369
|
type ConnectionOrigin = (typeof CONNECTION_ORIGINS)[number];
|
|
340
370
|
declare const CONNECTION_NETWORKS: readonly ["public", "private"];
|
|
@@ -351,8 +381,66 @@ declare const DATA_STORE_STATUSES: readonly ["provisioning", "ready", "retired"]
|
|
|
351
381
|
type DataStoreStatus = (typeof DATA_STORE_STATUSES)[number];
|
|
352
382
|
declare const DATA_STORE_MIGRATION_OUTCOMES: readonly ["none", "pending", "applied", "failed"];
|
|
353
383
|
type DataStoreMigrationOutcome = (typeof DATA_STORE_MIGRATION_OUTCOMES)[number];
|
|
354
|
-
|
|
384
|
+
/**
|
|
385
|
+
* `unchecked` until the first check; `preparing` while the store a Knowledge Base of documents
|
|
386
|
+
* owns is still being made; then `ok` or `needs_attention`.
|
|
387
|
+
*/
|
|
388
|
+
declare const KNOWLEDGE_BASE_STATUSES: readonly ["unchecked", "preparing", "ok", "needs_attention"];
|
|
355
389
|
type KnowledgeBaseStatus = (typeof KNOWLEDGE_BASE_STATUSES)[number];
|
|
390
|
+
/**
|
|
391
|
+
* What the page of a Knowledge Base shows of one document. `pending` is added and not yet
|
|
392
|
+
* searchable: waiting for its index job, being indexed or waiting for extraction. `indexed` is
|
|
393
|
+
* found by search. `failed` carries one of `KNOWLEDGE_DOCUMENT_FAILURE_CODES`; Retry puts it
|
|
394
|
+
* back to `pending`.
|
|
395
|
+
*/
|
|
396
|
+
declare const KNOWLEDGE_DOCUMENT_STATES: readonly ["pending", "indexed", "failed"];
|
|
397
|
+
type KnowledgeDocumentState = (typeof KNOWLEDGE_DOCUMENT_STATES)[number];
|
|
398
|
+
/**
|
|
399
|
+
* Why a document was not indexed. The first five can also come from the extraction of a PDF
|
|
400
|
+
* or DOCX (`KNOWLEDGE_EXTRACTION_FAILURE_CODES` in core); the rest are the index job's own.
|
|
401
|
+
*/
|
|
402
|
+
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"];
|
|
403
|
+
type KnowledgeDocumentFailureCode = (typeof KNOWLEDGE_DOCUMENT_FAILURE_CODES)[number];
|
|
404
|
+
/**
|
|
405
|
+
* Why a `pending` document waits, where it waits for something other than its turn. It goes on
|
|
406
|
+
* by itself once the cause is gone.
|
|
407
|
+
*/
|
|
408
|
+
declare const KNOWLEDGE_DOCUMENT_WAIT_CODES: readonly ["knowledge_usage_limit_reached"];
|
|
409
|
+
type KnowledgeDocumentWaitCode = (typeof KNOWLEDGE_DOCUMENT_WAIT_CODES)[number];
|
|
410
|
+
/**
|
|
411
|
+
* Why a synced source of a Knowledge Base, or one item of it, did not come in. Beside the
|
|
412
|
+
* document codes: an item over the size limit or of a format the instance does not read is
|
|
413
|
+
* recorded with `knowledge_file_over_limit` or `knowledge_file_format_unsupported` and never
|
|
414
|
+
* fetched. Spec: Synced sources, Contract freezes (SRC-0).
|
|
415
|
+
*/
|
|
416
|
+
declare const KNOWLEDGE_SOURCE_FAILURE_CODES: readonly ["knowledge_source_unreachable", "knowledge_source_refused", "knowledge_fetch_failed", "knowledge_source_limit_reached"];
|
|
417
|
+
type KnowledgeSourceFailureCode = (typeof KNOWLEDGE_SOURCE_FAILURE_CODES)[number];
|
|
418
|
+
/** The code a failed item of a synced source carries: a source code, or one it shares with a file added by hand. */
|
|
419
|
+
declare const KNOWLEDGE_SOURCE_ITEM_FAILURE_CODES: readonly ["knowledge_source_unreachable", "knowledge_source_refused", "knowledge_fetch_failed", "knowledge_source_limit_reached", "knowledge_file_over_limit", "knowledge_file_format_unsupported"];
|
|
420
|
+
type KnowledgeSourceItemFailureCode = (typeof KNOWLEDGE_SOURCE_ITEM_FAILURE_CODES)[number];
|
|
421
|
+
/**
|
|
422
|
+
* The state of an item of a synced source as the sync keeps it. It ends at `fetched`: from
|
|
423
|
+
* then on the item shows its document's state. `withdrawn` is out of search.
|
|
424
|
+
*/
|
|
425
|
+
declare const KNOWLEDGE_SOURCE_ITEM_STATES: readonly ["discovered", "fetched", "failed", "withdrawn"];
|
|
426
|
+
type KnowledgeSourceItemState = (typeof KNOWLEDGE_SOURCE_ITEM_STATES)[number];
|
|
427
|
+
/**
|
|
428
|
+
* How a sync of a source walks it: `initial` and `full` list every item below its folders,
|
|
429
|
+
* `changes` reads the source's change feed from the stored cursor.
|
|
430
|
+
*/
|
|
431
|
+
declare const KNOWLEDGE_SYNC_MODES: readonly ["initial", "changes", "full"];
|
|
432
|
+
type KnowledgeSyncMode = (typeof KNOWLEDGE_SYNC_MODES)[number];
|
|
433
|
+
declare const KNOWLEDGE_SYNC_RUN_STATES: readonly ["running", "done", "failed"];
|
|
434
|
+
type KnowledgeSyncRunState = (typeof KNOWLEDGE_SYNC_RUN_STATES)[number];
|
|
435
|
+
/** What a sync run counts, in this order wherever it shows them. */
|
|
436
|
+
declare const KNOWLEDGE_SYNC_COUNTS: readonly ["discovered", "added", "changed", "moved", "withdrawn", "failed", "skipped"];
|
|
437
|
+
type KnowledgeSyncCount = (typeof KNOWLEDGE_SYNC_COUNTS)[number];
|
|
438
|
+
/**
|
|
439
|
+
* The ranked lists a search on the built-in backend fuses: cosine distance to the query's
|
|
440
|
+
* embedding, German and English full text, and the words of a document's title and file name.
|
|
441
|
+
*/
|
|
442
|
+
declare const KNOWLEDGE_SEARCH_SIGNALS: readonly ["semantic", "keyword", "title"];
|
|
443
|
+
type KnowledgeSearchSignal = (typeof KNOWLEDGE_SEARCH_SIGNALS)[number];
|
|
356
444
|
declare const DATABASE_RELATION_TYPES: readonly ["table", "view", "materialized_view", "foreign_table"];
|
|
357
445
|
type DatabaseRelationType = (typeof DATABASE_RELATION_TYPES)[number];
|
|
358
446
|
declare const WORKFLOW_RUN_STATUSES: readonly ["queued", "running", "waiting", "done", "failed", "cancelled", "limit_reached"];
|
|
@@ -381,7 +469,7 @@ declare const OPERATIONS_AUDIENCES: readonly ["workflow", "app"];
|
|
|
381
469
|
type OperationsAudience = (typeof OPERATIONS_AUDIENCES)[number];
|
|
382
470
|
declare const DECIDED_APPROVAL_REQUEST_STATUSES: readonly ["approved", "rejected", "changes_requested", "superseded", "withdrawn", "reverted"];
|
|
383
471
|
type DecidedApprovalRequestStatus = (typeof DECIDED_APPROVAL_REQUEST_STATUSES)[number];
|
|
384
|
-
declare const ENDED_APPROVAL_EXECUTIONS: readonly ["done", "failed", "interrupted", "refused", "expired"];
|
|
472
|
+
declare const ENDED_APPROVAL_EXECUTIONS: readonly ["done", "failed", "interrupted", "refused", "expired", "held"];
|
|
385
473
|
type EndedApprovalExecution = (typeof ENDED_APPROVAL_EXECUTIONS)[number];
|
|
386
474
|
declare const GUARDRAIL_HIT_OUTCOMES: readonly ["warn", "require_approval", "block"];
|
|
387
475
|
type GuardrailHitOutcome = (typeof GUARDRAIL_HIT_OUTCOMES)[number];
|
|
@@ -395,7 +483,7 @@ declare const MESSAGE_FINISH_STATUSES: readonly ["completed", "cancelled"];
|
|
|
395
483
|
type MessageFinishStatus = (typeof MESSAGE_FINISH_STATUSES)[number];
|
|
396
484
|
declare const ENDED_AGENT_RUN_STATUSES: readonly ["completed", "cancelled", "failed"];
|
|
397
485
|
type EndedAgentRunStatus = (typeof ENDED_AGENT_RUN_STATUSES)[number];
|
|
398
|
-
declare const ACTIVE_AGENT_RUN_STATUSES: readonly ["queued", "running", "waiting_for_decision", "cancelling"];
|
|
486
|
+
declare const ACTIVE_AGENT_RUN_STATUSES: readonly ["queued", "running", "waiting_for_decision", "waiting_for_subagents", "cancelling"];
|
|
399
487
|
type ActiveAgentRunStatus = (typeof ACTIVE_AGENT_RUN_STATUSES)[number];
|
|
400
488
|
declare const ARTIFACT_PREVIEW_IMAGE_MIME_TYPES: readonly ["image/png", "image/jpeg", "image/webp"];
|
|
401
489
|
type ArtifactPreviewImageMimeType = (typeof ARTIFACT_PREVIEW_IMAGE_MIME_TYPES)[number];
|
|
@@ -407,12 +495,14 @@ declare const AUDIT_EVENT_STATUSES: readonly ["success", "failed", "denied"];
|
|
|
407
495
|
type AuditEventStatus = (typeof AUDIT_EVENT_STATUSES)[number];
|
|
408
496
|
declare const LISTED_DATA_STORE_STATUSES: readonly ["provisioning", "ready"];
|
|
409
497
|
type ListedDataStoreStatus = (typeof LISTED_DATA_STORE_STATUSES)[number];
|
|
410
|
-
declare const KNOWLEDGE_CHECK_STATUSES: readonly ["ok", "needs_attention"];
|
|
498
|
+
declare const KNOWLEDGE_CHECK_STATUSES: readonly ["preparing", "ok", "needs_attention"];
|
|
411
499
|
type KnowledgeCheckStatus = (typeof KNOWLEDGE_CHECK_STATUSES)[number];
|
|
412
500
|
declare const WORKFLOW_STEP_RUN_STATUSES: readonly ["queued", "running", "waiting", "done", "failed", "cancelled"];
|
|
413
501
|
type WorkflowStepRunStatus = (typeof WORKFLOW_STEP_RUN_STATUSES)[number];
|
|
414
502
|
declare const WORKFLOW_ENDED_STATUSES: readonly ["done", "failed", "cancelled", "limit_reached"];
|
|
415
503
|
type WorkflowEndedStatus = (typeof WORKFLOW_ENDED_STATUSES)[number];
|
|
504
|
+
/** A released Managed File keeps its identity; original bytes live at the synced source. */
|
|
505
|
+
declare const MANAGED_FILE_STATUSES: readonly ["available", "released", "deleted"];
|
|
416
506
|
|
|
417
507
|
declare const localizedStringSchema: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
418
508
|
en: z.ZodOptional<z.ZodString>;
|
|
@@ -594,6 +684,7 @@ declare const agentConfigSchema: z.ZodObject<{
|
|
|
594
684
|
}>>>;
|
|
595
685
|
maxSteps: z.ZodOptional<z.ZodNumber>;
|
|
596
686
|
toolNames: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
687
|
+
subagentNames: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
597
688
|
skillNames: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
598
689
|
knowledgeBases: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
599
690
|
initialPrompts: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
@@ -756,4 +847,274 @@ declare class YamlDataError extends Error {
|
|
|
756
847
|
/** `readYamlData` for a caller that reports a refused file as an error: it throws `YamlDataError`. */
|
|
757
848
|
declare function loadYamlData(text: string, file: string): unknown;
|
|
758
849
|
|
|
759
|
-
|
|
850
|
+
declare const knowledgeSyncInputSchema: z.ZodObject<{
|
|
851
|
+
source: z.ZodString;
|
|
852
|
+
mode: z.ZodOptional<z.ZodLiteral<"full">>;
|
|
853
|
+
}, z.core.$strict>;
|
|
854
|
+
type KnowledgeSyncInput = z.infer<typeof knowledgeSyncInputSchema>;
|
|
855
|
+
/** What a sync run ends with: the result of its Operation Run, and a Workflow step's output. */
|
|
856
|
+
declare const knowledgeSyncResultSchema: z.ZodObject<{
|
|
857
|
+
syncRunId: z.ZodString;
|
|
858
|
+
source: z.ZodString;
|
|
859
|
+
mode: z.ZodEnum<{
|
|
860
|
+
full: "full";
|
|
861
|
+
initial: "initial";
|
|
862
|
+
changes: "changes";
|
|
863
|
+
}>;
|
|
864
|
+
reason: z.ZodOptional<z.ZodEnum<{
|
|
865
|
+
cursor_expired: "cursor_expired";
|
|
866
|
+
}>>;
|
|
867
|
+
state: z.ZodEnum<{
|
|
868
|
+
failed: "failed";
|
|
869
|
+
running: "running";
|
|
870
|
+
done: "done";
|
|
871
|
+
}>;
|
|
872
|
+
counts: z.ZodObject<{
|
|
873
|
+
discovered: z.ZodNumber;
|
|
874
|
+
added: z.ZodNumber;
|
|
875
|
+
changed: z.ZodNumber;
|
|
876
|
+
moved: z.ZodNumber;
|
|
877
|
+
withdrawn: z.ZodNumber;
|
|
878
|
+
failed: z.ZodNumber;
|
|
879
|
+
skipped: z.ZodNumber;
|
|
880
|
+
}, z.core.$strict>;
|
|
881
|
+
bytesFetched: z.ZodNumber;
|
|
882
|
+
failureCode: z.ZodOptional<z.ZodEnum<{
|
|
883
|
+
knowledge_source_unreachable: "knowledge_source_unreachable";
|
|
884
|
+
knowledge_source_refused: "knowledge_source_refused";
|
|
885
|
+
knowledge_fetch_failed: "knowledge_fetch_failed";
|
|
886
|
+
knowledge_source_limit_reached: "knowledge_source_limit_reached";
|
|
887
|
+
}>>;
|
|
888
|
+
startedAt: z.ZodString;
|
|
889
|
+
endedAt: z.ZodOptional<z.ZodString>;
|
|
890
|
+
}, z.core.$strict>;
|
|
891
|
+
type KnowledgeSyncResult = z.infer<typeof knowledgeSyncResultSchema>;
|
|
892
|
+
/**
|
|
893
|
+
* What the page shows of an item: its own state up to `fetched`, then its document's.
|
|
894
|
+
* "Gefunden", "Geladen", "Durchsuchbar", "Fehlgeschlagen", "Entfernt".
|
|
895
|
+
*/
|
|
896
|
+
declare const KNOWLEDGE_SOURCE_ITEM_SHOWN_STATES: readonly ["discovered", "fetched", "indexed", "failed", "withdrawn"];
|
|
897
|
+
type KnowledgeSourceItemShownState = (typeof KNOWLEDGE_SOURCE_ITEM_SHOWN_STATES)[number];
|
|
898
|
+
declare const knowledgeSourcesOutputSchema: z.ZodObject<{
|
|
899
|
+
sources: z.ZodArray<z.ZodObject<{
|
|
900
|
+
id: z.ZodString;
|
|
901
|
+
connection: z.ZodString;
|
|
902
|
+
items: z.ZodObject<{
|
|
903
|
+
discovered: z.ZodNumber;
|
|
904
|
+
fetched: z.ZodNumber;
|
|
905
|
+
indexed: z.ZodNumber;
|
|
906
|
+
failed: z.ZodNumber;
|
|
907
|
+
withdrawn: z.ZodNumber;
|
|
908
|
+
}, z.core.$strict>;
|
|
909
|
+
failures: z.ZodArray<z.ZodObject<{
|
|
910
|
+
code: z.ZodUnion<readonly [z.ZodEnum<{
|
|
911
|
+
knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
|
|
912
|
+
knowledge_file_over_limit: "knowledge_file_over_limit";
|
|
913
|
+
knowledge_source_unreachable: "knowledge_source_unreachable";
|
|
914
|
+
knowledge_source_refused: "knowledge_source_refused";
|
|
915
|
+
knowledge_fetch_failed: "knowledge_fetch_failed";
|
|
916
|
+
knowledge_source_limit_reached: "knowledge_source_limit_reached";
|
|
917
|
+
}>, z.ZodEnum<{
|
|
918
|
+
knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
|
|
919
|
+
knowledge_file_over_limit: "knowledge_file_over_limit";
|
|
920
|
+
knowledge_file_unreadable: "knowledge_file_unreadable";
|
|
921
|
+
knowledge_file_missing: "knowledge_file_missing";
|
|
922
|
+
knowledge_extraction_failed: "knowledge_extraction_failed";
|
|
923
|
+
knowledge_file_format_unavailable: "knowledge_file_format_unavailable";
|
|
924
|
+
knowledge_text_unreadable: "knowledge_text_unreadable";
|
|
925
|
+
knowledge_text_empty: "knowledge_text_empty";
|
|
926
|
+
knowledge_index_failed: "knowledge_index_failed";
|
|
927
|
+
}>]>;
|
|
928
|
+
count: z.ZodNumber;
|
|
929
|
+
}, z.core.$strict>>;
|
|
930
|
+
running: z.ZodOptional<z.ZodObject<{
|
|
931
|
+
syncRunId: z.ZodString;
|
|
932
|
+
mode: z.ZodEnum<{
|
|
933
|
+
full: "full";
|
|
934
|
+
initial: "initial";
|
|
935
|
+
changes: "changes";
|
|
936
|
+
}>;
|
|
937
|
+
startedAt: z.ZodString;
|
|
938
|
+
itemsPerMinute: z.ZodOptional<z.ZodNumber>;
|
|
939
|
+
estimatedEndAt: z.ZodOptional<z.ZodString>;
|
|
940
|
+
}, z.core.$strict>>;
|
|
941
|
+
last: z.ZodOptional<z.ZodObject<{
|
|
942
|
+
syncRunId: z.ZodString;
|
|
943
|
+
source: z.ZodString;
|
|
944
|
+
mode: z.ZodEnum<{
|
|
945
|
+
full: "full";
|
|
946
|
+
initial: "initial";
|
|
947
|
+
changes: "changes";
|
|
948
|
+
}>;
|
|
949
|
+
reason: z.ZodOptional<z.ZodEnum<{
|
|
950
|
+
cursor_expired: "cursor_expired";
|
|
951
|
+
}>>;
|
|
952
|
+
state: z.ZodEnum<{
|
|
953
|
+
failed: "failed";
|
|
954
|
+
running: "running";
|
|
955
|
+
done: "done";
|
|
956
|
+
}>;
|
|
957
|
+
counts: z.ZodObject<{
|
|
958
|
+
discovered: z.ZodNumber;
|
|
959
|
+
added: z.ZodNumber;
|
|
960
|
+
changed: z.ZodNumber;
|
|
961
|
+
moved: z.ZodNumber;
|
|
962
|
+
withdrawn: z.ZodNumber;
|
|
963
|
+
failed: z.ZodNumber;
|
|
964
|
+
skipped: z.ZodNumber;
|
|
965
|
+
}, z.core.$strict>;
|
|
966
|
+
bytesFetched: z.ZodNumber;
|
|
967
|
+
failureCode: z.ZodOptional<z.ZodEnum<{
|
|
968
|
+
knowledge_source_unreachable: "knowledge_source_unreachable";
|
|
969
|
+
knowledge_source_refused: "knowledge_source_refused";
|
|
970
|
+
knowledge_fetch_failed: "knowledge_fetch_failed";
|
|
971
|
+
knowledge_source_limit_reached: "knowledge_source_limit_reached";
|
|
972
|
+
}>>;
|
|
973
|
+
startedAt: z.ZodString;
|
|
974
|
+
endedAt: z.ZodOptional<z.ZodString>;
|
|
975
|
+
}, z.core.$strict>>;
|
|
976
|
+
lastChangeAt: z.ZodOptional<z.ZodString>;
|
|
977
|
+
oldestOpenChangeAt: z.ZodOptional<z.ZodString>;
|
|
978
|
+
}, z.core.$strict>>;
|
|
979
|
+
}, z.core.$strict>;
|
|
980
|
+
type KnowledgeSourcesOutput = z.infer<typeof knowledgeSourcesOutputSchema>;
|
|
981
|
+
declare const knowledgeSourceItemsInputSchema: z.ZodObject<{
|
|
982
|
+
source: z.ZodString;
|
|
983
|
+
state: z.ZodOptional<z.ZodEnum<{
|
|
984
|
+
failed: "failed";
|
|
985
|
+
withdrawn: "withdrawn";
|
|
986
|
+
indexed: "indexed";
|
|
987
|
+
discovered: "discovered";
|
|
988
|
+
fetched: "fetched";
|
|
989
|
+
}>>;
|
|
990
|
+
failureCode: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
|
|
991
|
+
knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
|
|
992
|
+
knowledge_file_over_limit: "knowledge_file_over_limit";
|
|
993
|
+
knowledge_source_unreachable: "knowledge_source_unreachable";
|
|
994
|
+
knowledge_source_refused: "knowledge_source_refused";
|
|
995
|
+
knowledge_fetch_failed: "knowledge_fetch_failed";
|
|
996
|
+
knowledge_source_limit_reached: "knowledge_source_limit_reached";
|
|
997
|
+
}>, z.ZodEnum<{
|
|
998
|
+
knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
|
|
999
|
+
knowledge_file_over_limit: "knowledge_file_over_limit";
|
|
1000
|
+
knowledge_file_unreadable: "knowledge_file_unreadable";
|
|
1001
|
+
knowledge_file_missing: "knowledge_file_missing";
|
|
1002
|
+
knowledge_extraction_failed: "knowledge_extraction_failed";
|
|
1003
|
+
knowledge_file_format_unavailable: "knowledge_file_format_unavailable";
|
|
1004
|
+
knowledge_text_unreadable: "knowledge_text_unreadable";
|
|
1005
|
+
knowledge_text_empty: "knowledge_text_empty";
|
|
1006
|
+
knowledge_index_failed: "knowledge_index_failed";
|
|
1007
|
+
}>]>>;
|
|
1008
|
+
limit: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
1009
|
+
cursor: z.ZodOptional<z.ZodString>;
|
|
1010
|
+
}, z.core.$strict>;
|
|
1011
|
+
type KnowledgeSourceItemsInput = z.infer<typeof knowledgeSourceItemsInputSchema>;
|
|
1012
|
+
declare const knowledgeSourceItemsOutputSchema: z.ZodObject<{
|
|
1013
|
+
items: z.ZodArray<z.ZodObject<{
|
|
1014
|
+
id: z.ZodString;
|
|
1015
|
+
itemId: z.ZodString;
|
|
1016
|
+
name: z.ZodString;
|
|
1017
|
+
path: z.ZodString;
|
|
1018
|
+
state: z.ZodEnum<{
|
|
1019
|
+
failed: "failed";
|
|
1020
|
+
withdrawn: "withdrawn";
|
|
1021
|
+
indexed: "indexed";
|
|
1022
|
+
discovered: "discovered";
|
|
1023
|
+
fetched: "fetched";
|
|
1024
|
+
}>;
|
|
1025
|
+
failureCode: z.ZodOptional<z.ZodUnion<readonly [z.ZodEnum<{
|
|
1026
|
+
knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
|
|
1027
|
+
knowledge_file_over_limit: "knowledge_file_over_limit";
|
|
1028
|
+
knowledge_source_unreachable: "knowledge_source_unreachable";
|
|
1029
|
+
knowledge_source_refused: "knowledge_source_refused";
|
|
1030
|
+
knowledge_fetch_failed: "knowledge_fetch_failed";
|
|
1031
|
+
knowledge_source_limit_reached: "knowledge_source_limit_reached";
|
|
1032
|
+
}>, z.ZodEnum<{
|
|
1033
|
+
knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
|
|
1034
|
+
knowledge_file_over_limit: "knowledge_file_over_limit";
|
|
1035
|
+
knowledge_file_unreadable: "knowledge_file_unreadable";
|
|
1036
|
+
knowledge_file_missing: "knowledge_file_missing";
|
|
1037
|
+
knowledge_extraction_failed: "knowledge_extraction_failed";
|
|
1038
|
+
knowledge_file_format_unavailable: "knowledge_file_format_unavailable";
|
|
1039
|
+
knowledge_text_unreadable: "knowledge_text_unreadable";
|
|
1040
|
+
knowledge_text_empty: "knowledge_text_empty";
|
|
1041
|
+
knowledge_index_failed: "knowledge_index_failed";
|
|
1042
|
+
}>]>>;
|
|
1043
|
+
documentId: z.ZodOptional<z.ZodString>;
|
|
1044
|
+
originLink: z.ZodOptional<z.ZodString>;
|
|
1045
|
+
changedAt: z.ZodString;
|
|
1046
|
+
}, z.core.$strict>>;
|
|
1047
|
+
nextCursor: z.ZodOptional<z.ZodString>;
|
|
1048
|
+
}, z.core.$strict>;
|
|
1049
|
+
type KnowledgeSourceItemsOutput = z.infer<typeof knowledgeSourceItemsOutputSchema>;
|
|
1050
|
+
/**
|
|
1051
|
+
* KB-5c's retry, widened: documents by id, or items of a source by id, by failure code or all
|
|
1052
|
+
* failed ones. A failed fetch is fetched again; a failed document of a synced source is
|
|
1053
|
+
* fetched and indexed again, because its original is not kept.
|
|
1054
|
+
*/
|
|
1055
|
+
declare const knowledgeRetryInputSchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
1056
|
+
documentIds: z.ZodArray<z.ZodString>;
|
|
1057
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
1058
|
+
source: z.ZodString;
|
|
1059
|
+
sourceItemIds: z.ZodArray<z.ZodString>;
|
|
1060
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
1061
|
+
source: z.ZodString;
|
|
1062
|
+
failureCode: z.ZodUnion<readonly [z.ZodEnum<{
|
|
1063
|
+
knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
|
|
1064
|
+
knowledge_file_over_limit: "knowledge_file_over_limit";
|
|
1065
|
+
knowledge_source_unreachable: "knowledge_source_unreachable";
|
|
1066
|
+
knowledge_source_refused: "knowledge_source_refused";
|
|
1067
|
+
knowledge_fetch_failed: "knowledge_fetch_failed";
|
|
1068
|
+
knowledge_source_limit_reached: "knowledge_source_limit_reached";
|
|
1069
|
+
}>, z.ZodEnum<{
|
|
1070
|
+
knowledge_file_format_unsupported: "knowledge_file_format_unsupported";
|
|
1071
|
+
knowledge_file_over_limit: "knowledge_file_over_limit";
|
|
1072
|
+
knowledge_file_unreadable: "knowledge_file_unreadable";
|
|
1073
|
+
knowledge_file_missing: "knowledge_file_missing";
|
|
1074
|
+
knowledge_extraction_failed: "knowledge_extraction_failed";
|
|
1075
|
+
knowledge_file_format_unavailable: "knowledge_file_format_unavailable";
|
|
1076
|
+
knowledge_text_unreadable: "knowledge_text_unreadable";
|
|
1077
|
+
knowledge_text_empty: "knowledge_text_empty";
|
|
1078
|
+
knowledge_index_failed: "knowledge_index_failed";
|
|
1079
|
+
}>]>;
|
|
1080
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
1081
|
+
source: z.ZodString;
|
|
1082
|
+
all: z.ZodLiteral<true>;
|
|
1083
|
+
}, z.core.$strict>]>;
|
|
1084
|
+
type KnowledgeRetryInput = z.infer<typeof knowledgeRetryInputSchema>;
|
|
1085
|
+
declare const knowledgeRetryOutputSchema: z.ZodObject<{
|
|
1086
|
+
documents: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1087
|
+
id: z.ZodString;
|
|
1088
|
+
state: z.ZodEnum<{
|
|
1089
|
+
failed: "failed";
|
|
1090
|
+
pending: "pending";
|
|
1091
|
+
indexed: "indexed";
|
|
1092
|
+
}>;
|
|
1093
|
+
}, z.core.$strict>>>;
|
|
1094
|
+
queued: z.ZodNumber;
|
|
1095
|
+
}, z.core.$strict>;
|
|
1096
|
+
type KnowledgeRetryOutput = z.infer<typeof knowledgeRetryOutputSchema>;
|
|
1097
|
+
declare const knowledgeLocateInputSchema: z.ZodObject<{
|
|
1098
|
+
sourceItemId: z.ZodString;
|
|
1099
|
+
}, z.core.$strict>;
|
|
1100
|
+
type KnowledgeLocateInput = z.infer<typeof knowledgeLocateInputSchema>;
|
|
1101
|
+
/** An item's state and times, and no content, name or path. */
|
|
1102
|
+
declare const knowledgeLocateOutputSchema: z.ZodObject<{
|
|
1103
|
+
sourceItemId: z.ZodString;
|
|
1104
|
+
source: z.ZodString;
|
|
1105
|
+
itemId: z.ZodString;
|
|
1106
|
+
state: z.ZodEnum<{
|
|
1107
|
+
failed: "failed";
|
|
1108
|
+
withdrawn: "withdrawn";
|
|
1109
|
+
indexed: "indexed";
|
|
1110
|
+
discovered: "discovered";
|
|
1111
|
+
fetched: "fetched";
|
|
1112
|
+
}>;
|
|
1113
|
+
discoveredAt: z.ZodString;
|
|
1114
|
+
fetchedAt: z.ZodOptional<z.ZodString>;
|
|
1115
|
+
withdrawnAt: z.ZodOptional<z.ZodString>;
|
|
1116
|
+
purgedAt: z.ZodOptional<z.ZodString>;
|
|
1117
|
+
}, z.core.$strict>;
|
|
1118
|
+
type KnowledgeLocateOutput = z.infer<typeof knowledgeLocateOutputSchema>;
|
|
1119
|
+
|
|
1120
|
+
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_BINDING_STATES, 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_PROVIDER_REVOCATIONS, CONNECTION_SECRET_STATES, CONNECTOR_TEST_STATUSES, CONVERSATION_ATTACHMENT_STATUSES, CONVERSATION_KINDS, CONVERSATION_VISIBILITIES, type ChatMessageRole, type ChatSessionAuthScope, type CollaborationWorkspaceKind, type ConfigAssetChangeOperation, type ConfigAssetKind, type ConnectionBindingState, type ConnectionExposure, type ConnectionHealth, type ConnectionNetwork, type ConnectionOAuthRegistration, type ConnectionOperationPolicy, type ConnectionOperationStatus, type ConnectionOrigin, type ConnectionProviderRevocation, type ConnectionSecretState, type ConnectorTestStatus, type ConversationAttachmentStatus, type ConversationKind, 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, FOLLOW_UP_MODES, FOLLOW_UP_STATUSES, 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, KNOWLEDGE_DOCUMENT_FAILURE_CODES, KNOWLEDGE_DOCUMENT_STATES, KNOWLEDGE_DOCUMENT_WAIT_CODES, 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 KnowledgeLocateInput, type KnowledgeLocateOutput, 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, LISTED_DATA_STORE_STATUSES, LIVE_JOB_STATUSES, type ListedDataStoreStatus, type LiveJobStatus, type LocaleCode, type LocalizedStringConfig, MANAGED_FILE_STATUSES, 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, knowledgeLocateInputSchema, knowledgeLocateOutputSchema, knowledgeRetryInputSchema, knowledgeRetryOutputSchema, knowledgeSourceItemsInputSchema, knowledgeSourceItemsOutputSchema, knowledgeSourcesOutputSchema, knowledgeSyncInputSchema, knowledgeSyncResultSchema, loadYamlData, localeCodes, localizedStringSchema, parseSkillMarkdown, readYamlData, skillConfigSchema, skillFileEntrySchema, skillFileFrontmatterSchema, skillNameSchema, skillPortabilityIssues, skillResourceConfigSchema, skillResourceMediaTypeForPath, skillResourcePathSchema, skillStarterSchema, workflowConfigSchema, yamlValueIssue, yamlValueIssueSentence };
|
package/dist/index.js
CHANGED
|
@@ -53,6 +53,7 @@ var FIRST_PARTY_AUTH_SCOPES = [
|
|
|
53
53
|
var ACTIONS = [
|
|
54
54
|
"agent.read",
|
|
55
55
|
"agent.write",
|
|
56
|
+
"agent.publish",
|
|
56
57
|
"agent.delete",
|
|
57
58
|
"skill.read",
|
|
58
59
|
"skill.write",
|
|
@@ -242,7 +243,10 @@ var APPROVAL_EXECUTIONS = [
|
|
|
242
243
|
"failed",
|
|
243
244
|
"interrupted",
|
|
244
245
|
"refused",
|
|
245
|
-
"expired"
|
|
246
|
+
"expired",
|
|
247
|
+
// A confirmation in the Inbox whose Allow left the call waiting for an approver: it ended
|
|
248
|
+
// here, and the call waits as the approval request `approvalRequestId` of `applyResult`.
|
|
249
|
+
"held"
|
|
246
250
|
];
|
|
247
251
|
var SKILL_CHANGE_TYPES = ["replace", "add", "new_resource"];
|
|
248
252
|
var GUARDRAIL_OUTCOMES = ["allow", "warn", "require_approval", "block"];
|
|
@@ -319,6 +323,7 @@ var INFRASTRUCTURE_WITHHELD_FIELDS = ["endpointHost", "bucket"];
|
|
|
319
323
|
var OPENAI_COMPATIBLE_APIS = ["chat_completions", "responses"];
|
|
320
324
|
var MODEL_PROVIDER_AUTH_MODES = ["bearer", "api-key"];
|
|
321
325
|
var CONVERSATION_VISIBILITIES = ["workspace", "private"];
|
|
326
|
+
var CONVERSATION_KINDS = ["chat", "run_thread"];
|
|
322
327
|
var WEB_SOURCE_PROVIDERS = [
|
|
323
328
|
"openai-native",
|
|
324
329
|
"serper",
|
|
@@ -338,10 +343,13 @@ var CONVERSATION_ATTACHMENT_STATUSES = [
|
|
|
338
343
|
];
|
|
339
344
|
var ATTACHMENT_CREATE_OUTCOMES = ["created", "already_available"];
|
|
340
345
|
var STRUCTURED_DATA_REVIEW_REASONS = ["uncertain", "conflicting"];
|
|
346
|
+
var FOLLOW_UP_MODES = ["queue"];
|
|
347
|
+
var FOLLOW_UP_STATUSES = ["pending", "dispatched", "cancelled"];
|
|
341
348
|
var AGENT_RUN_STATUSES = [
|
|
342
349
|
"queued",
|
|
343
350
|
"running",
|
|
344
351
|
"waiting_for_decision",
|
|
352
|
+
"waiting_for_subagents",
|
|
345
353
|
"cancelling",
|
|
346
354
|
"completed",
|
|
347
355
|
"cancelled",
|
|
@@ -401,8 +409,11 @@ var MODEL_USAGE_SOURCES = ["provider_reported", "not_reported", "estimated"];
|
|
|
401
409
|
var USAGE_COST_STATUSES = ["settled", "incomplete", "unpriced"];
|
|
402
410
|
var CONNECTION_OPERATION_STATUSES = [
|
|
403
411
|
"ready",
|
|
412
|
+
/** Accepted, a discovering type, and no discovery has pinned it yet. */
|
|
404
413
|
"awaiting_discovery",
|
|
414
|
+
/** The catalog's fingerprint differs from the accepted one. */
|
|
405
415
|
"needs_review",
|
|
416
|
+
/** Accepted, and the last discovery did not list it or listed a schema nothing can check. */
|
|
406
417
|
"unknown",
|
|
407
418
|
"disabled"
|
|
408
419
|
];
|
|
@@ -411,8 +422,13 @@ var CONNECTOR_TEST_STATUSES = [
|
|
|
411
422
|
"ready",
|
|
412
423
|
"unauthorized",
|
|
413
424
|
"network_denied",
|
|
414
|
-
"unavailable"
|
|
425
|
+
"unavailable",
|
|
426
|
+
/** The server asks for an OAuth sign-in, or the Connection signs in and nobody has. */
|
|
427
|
+
"oauth_required"
|
|
415
428
|
];
|
|
429
|
+
var CONNECTION_BINDING_STATES = ["connected", "needs_reconnect", "revoked"];
|
|
430
|
+
var CONNECTION_OAUTH_REGISTRATIONS = ["dcr", "preregistered"];
|
|
431
|
+
var CONNECTION_PROVIDER_REVOCATIONS = ["confirmed", "failed", "not_offered"];
|
|
416
432
|
var CONNECTION_ORIGINS = ["release", "runtime"];
|
|
417
433
|
var CONNECTION_NETWORKS = ["public", "private"];
|
|
418
434
|
var DATA_STORE_SCALAR_TYPES = [
|
|
@@ -435,7 +451,66 @@ var DATA_STORE_CONDITIONS = [
|
|
|
435
451
|
];
|
|
436
452
|
var DATA_STORE_STATUSES = ["provisioning", "ready", "retired"];
|
|
437
453
|
var DATA_STORE_MIGRATION_OUTCOMES = ["none", "pending", "applied", "failed"];
|
|
438
|
-
var KNOWLEDGE_BASE_STATUSES = ["unchecked", "ok", "needs_attention"];
|
|
454
|
+
var KNOWLEDGE_BASE_STATUSES = ["unchecked", "preparing", "ok", "needs_attention"];
|
|
455
|
+
var KNOWLEDGE_DOCUMENT_STATES = ["pending", "indexed", "failed"];
|
|
456
|
+
var KNOWLEDGE_DOCUMENT_FAILURE_CODES = [
|
|
457
|
+
// The extractor does not read the file's format.
|
|
458
|
+
"knowledge_file_format_unsupported",
|
|
459
|
+
// The file is over a limit of the extraction: size, pages or time.
|
|
460
|
+
"knowledge_file_over_limit",
|
|
461
|
+
// The file is corrupt, encrypted, or not the format it claims.
|
|
462
|
+
"knowledge_file_unreadable",
|
|
463
|
+
// The copy the Knowledge Base owns, or its bytes, are gone.
|
|
464
|
+
"knowledge_file_missing",
|
|
465
|
+
// Extraction failed on every attempt.
|
|
466
|
+
"knowledge_extraction_failed",
|
|
467
|
+
// A PDF or DOCX on an instance without document processing.
|
|
468
|
+
"knowledge_file_format_unavailable",
|
|
469
|
+
// A text file whose bytes are not text.
|
|
470
|
+
"knowledge_text_unreadable",
|
|
471
|
+
// No text to search, such as a scanned PDF without a text layer.
|
|
472
|
+
"knowledge_text_empty",
|
|
473
|
+
// Indexing failed on every attempt.
|
|
474
|
+
"knowledge_index_failed"
|
|
475
|
+
];
|
|
476
|
+
var KNOWLEDGE_DOCUMENT_WAIT_CODES = [
|
|
477
|
+
// A usage limit of the instance or the workspace refuses the embedding calls. Indexing goes
|
|
478
|
+
// on when the limit resets or is raised.
|
|
479
|
+
"knowledge_usage_limit_reached"
|
|
480
|
+
];
|
|
481
|
+
var KNOWLEDGE_SOURCE_FAILURE_CODES = [
|
|
482
|
+
// The source did not answer.
|
|
483
|
+
"knowledge_source_unreachable",
|
|
484
|
+
// The credential or the account's access was refused for the whole source.
|
|
485
|
+
"knowledge_source_refused",
|
|
486
|
+
// A fetch failed on every attempt.
|
|
487
|
+
"knowledge_fetch_failed",
|
|
488
|
+
// The Knowledge Base holds its document limit; the listing stopped discovering there.
|
|
489
|
+
"knowledge_source_limit_reached"
|
|
490
|
+
];
|
|
491
|
+
var KNOWLEDGE_SOURCE_ITEM_FAILURE_CODES = [
|
|
492
|
+
...KNOWLEDGE_SOURCE_FAILURE_CODES,
|
|
493
|
+
"knowledge_file_over_limit",
|
|
494
|
+
"knowledge_file_format_unsupported"
|
|
495
|
+
];
|
|
496
|
+
var KNOWLEDGE_SOURCE_ITEM_STATES = [
|
|
497
|
+
"discovered",
|
|
498
|
+
"fetched",
|
|
499
|
+
"failed",
|
|
500
|
+
"withdrawn"
|
|
501
|
+
];
|
|
502
|
+
var KNOWLEDGE_SYNC_MODES = ["initial", "changes", "full"];
|
|
503
|
+
var KNOWLEDGE_SYNC_RUN_STATES = ["running", "done", "failed"];
|
|
504
|
+
var KNOWLEDGE_SYNC_COUNTS = [
|
|
505
|
+
"discovered",
|
|
506
|
+
"added",
|
|
507
|
+
"changed",
|
|
508
|
+
"moved",
|
|
509
|
+
"withdrawn",
|
|
510
|
+
"failed",
|
|
511
|
+
"skipped"
|
|
512
|
+
];
|
|
513
|
+
var KNOWLEDGE_SEARCH_SIGNALS = ["semantic", "keyword", "title"];
|
|
439
514
|
var DATABASE_RELATION_TYPES = [
|
|
440
515
|
"table",
|
|
441
516
|
"view",
|
|
@@ -459,9 +534,14 @@ var WORKFLOW_STEP_TYPES = [
|
|
|
459
534
|
"output",
|
|
460
535
|
"agent",
|
|
461
536
|
"notify",
|
|
537
|
+
/** Starts another Workflow as a child run and waits for it. */
|
|
462
538
|
"workflow"
|
|
463
539
|
];
|
|
464
|
-
var WORKFLOW_RESERVED_STEP_TYPES = [
|
|
540
|
+
var WORKFLOW_RESERVED_STEP_TYPES = [
|
|
541
|
+
/** Reserved in the contract: drawn, and run by no engine yet. */
|
|
542
|
+
"condition",
|
|
543
|
+
"parallel"
|
|
544
|
+
];
|
|
465
545
|
var WORKFLOW_TRIGGER_KINDS = ["manual", "schedule", "parent"];
|
|
466
546
|
var NOTIFY_CHANNELS = ["inbox", "mail"];
|
|
467
547
|
var PRINCIPAL_HOLDER_KINDS = [
|
|
@@ -499,7 +579,8 @@ var ENDED_APPROVAL_EXECUTIONS = [
|
|
|
499
579
|
"failed",
|
|
500
580
|
"interrupted",
|
|
501
581
|
"refused",
|
|
502
|
-
"expired"
|
|
582
|
+
"expired",
|
|
583
|
+
"held"
|
|
503
584
|
];
|
|
504
585
|
var GUARDRAIL_HIT_OUTCOMES = [
|
|
505
586
|
"warn",
|
|
@@ -528,6 +609,7 @@ var ACTIVE_AGENT_RUN_STATUSES = [
|
|
|
528
609
|
"queued",
|
|
529
610
|
"running",
|
|
530
611
|
"waiting_for_decision",
|
|
612
|
+
"waiting_for_subagents",
|
|
531
613
|
"cancelling"
|
|
532
614
|
];
|
|
533
615
|
var ARTIFACT_PREVIEW_IMAGE_MIME_TYPES = [
|
|
@@ -547,6 +629,7 @@ var LISTED_DATA_STORE_STATUSES = [
|
|
|
547
629
|
"ready"
|
|
548
630
|
];
|
|
549
631
|
var KNOWLEDGE_CHECK_STATUSES = [
|
|
632
|
+
"preparing",
|
|
550
633
|
"ok",
|
|
551
634
|
"needs_attention"
|
|
552
635
|
];
|
|
@@ -564,6 +647,7 @@ var WORKFLOW_ENDED_STATUSES = [
|
|
|
564
647
|
"cancelled",
|
|
565
648
|
"limit_reached"
|
|
566
649
|
];
|
|
650
|
+
var MANAGED_FILE_STATUSES = ["available", "released", "deleted"];
|
|
567
651
|
|
|
568
652
|
// src/schemas.ts
|
|
569
653
|
import { z } from "zod";
|
|
@@ -779,6 +863,13 @@ var agentConfigSchema = z.object({
|
|
|
779
863
|
modelReasoningEfforts: z.record(z.string().min(1), z.enum(REASONING_EFFORTS)).optional(),
|
|
780
864
|
maxSteps: z.number().int().positive().optional(),
|
|
781
865
|
toolNames: z.array(z.string().min(1)).default([]),
|
|
866
|
+
/**
|
|
867
|
+
* The agents this agent may start as subagents through `run_agent`, beside itself. Only an
|
|
868
|
+
* agent whose `toolNames` lists `run_agent` starts any.
|
|
869
|
+
*/
|
|
870
|
+
subagentNames: z.array(agentNameSchema).refine((names) => new Set(names).size === names.length, {
|
|
871
|
+
message: "A subagent is listed once"
|
|
872
|
+
}).optional(),
|
|
782
873
|
skillNames: z.array(skillNameSchema).default([]),
|
|
783
874
|
knowledgeBases: z.array(z.string().min(1)).refine((names) => new Set(names).size === names.length, {
|
|
784
875
|
message: "A Knowledge Base is listed once"
|
|
@@ -1021,6 +1112,144 @@ function withoutExtension(filename) {
|
|
|
1021
1112
|
const dot = filename.lastIndexOf(".");
|
|
1022
1113
|
return dot > 0 ? filename.slice(0, dot) : filename;
|
|
1023
1114
|
}
|
|
1115
|
+
|
|
1116
|
+
// src/knowledge-sources.ts
|
|
1117
|
+
import { z as z2 } from "zod";
|
|
1118
|
+
var sourceIdSchema = z2.string().min(1).max(63);
|
|
1119
|
+
var countSchema = z2.number().int().min(0);
|
|
1120
|
+
var countsSchema = z2.strictObject({
|
|
1121
|
+
discovered: countSchema,
|
|
1122
|
+
added: countSchema,
|
|
1123
|
+
changed: countSchema,
|
|
1124
|
+
moved: countSchema,
|
|
1125
|
+
withdrawn: countSchema,
|
|
1126
|
+
failed: countSchema,
|
|
1127
|
+
skipped: countSchema
|
|
1128
|
+
});
|
|
1129
|
+
var knowledgeSyncInputSchema = z2.strictObject({
|
|
1130
|
+
/** The `id` of the source in the definition. */
|
|
1131
|
+
source: sourceIdSchema,
|
|
1132
|
+
/** `changes` unless `full`. The initial import is started by publish, not by this call. */
|
|
1133
|
+
mode: z2.literal("full", {
|
|
1134
|
+
// Keep SRC-0's accepted values frozen while explaining the deferred mode.
|
|
1135
|
+
error: (issue) => issue.input === "changes" ? "not_supported_yet: Change-feed sync is not supported yet; request mode full." : void 0
|
|
1136
|
+
}).optional()
|
|
1137
|
+
});
|
|
1138
|
+
var knowledgeSyncResultSchema = z2.strictObject({
|
|
1139
|
+
syncRunId: z2.string(),
|
|
1140
|
+
source: z2.string(),
|
|
1141
|
+
mode: z2.enum(KNOWLEDGE_SYNC_MODES),
|
|
1142
|
+
/** Why a run is of another mode than asked, such as a cursor the source refused. */
|
|
1143
|
+
reason: z2.enum(["cursor_expired"]).optional(),
|
|
1144
|
+
state: z2.enum(KNOWLEDGE_SYNC_RUN_STATES),
|
|
1145
|
+
counts: countsSchema,
|
|
1146
|
+
bytesFetched: z2.number().int().min(0),
|
|
1147
|
+
/** Why the whole sync failed, for a run in state `failed`. */
|
|
1148
|
+
failureCode: z2.enum(KNOWLEDGE_SOURCE_FAILURE_CODES).optional(),
|
|
1149
|
+
startedAt: z2.string(),
|
|
1150
|
+
endedAt: z2.string().optional()
|
|
1151
|
+
});
|
|
1152
|
+
var KNOWLEDGE_SOURCE_ITEM_SHOWN_STATES = [
|
|
1153
|
+
"discovered",
|
|
1154
|
+
"fetched",
|
|
1155
|
+
"indexed",
|
|
1156
|
+
"failed",
|
|
1157
|
+
"withdrawn"
|
|
1158
|
+
];
|
|
1159
|
+
var itemFailureCodeSchema = z2.union([
|
|
1160
|
+
z2.enum(KNOWLEDGE_SOURCE_ITEM_FAILURE_CODES),
|
|
1161
|
+
z2.enum(KNOWLEDGE_DOCUMENT_FAILURE_CODES)
|
|
1162
|
+
]);
|
|
1163
|
+
var knowledgeSourcesOutputSchema = z2.strictObject({
|
|
1164
|
+
sources: z2.array(
|
|
1165
|
+
z2.strictObject({
|
|
1166
|
+
id: z2.string(),
|
|
1167
|
+
/** The name of the Connection it reads through. */
|
|
1168
|
+
connection: z2.string(),
|
|
1169
|
+
/** Items by the state the page shows. */
|
|
1170
|
+
items: z2.strictObject({
|
|
1171
|
+
discovered: countSchema,
|
|
1172
|
+
fetched: countSchema,
|
|
1173
|
+
indexed: countSchema,
|
|
1174
|
+
failed: countSchema,
|
|
1175
|
+
withdrawn: countSchema
|
|
1176
|
+
}),
|
|
1177
|
+
/** Failed items per code. */
|
|
1178
|
+
failures: z2.array(z2.strictObject({ code: itemFailureCodeSchema, count: countSchema })),
|
|
1179
|
+
/** The sync that runs now, with its rate in items per minute and its estimated end. */
|
|
1180
|
+
running: z2.strictObject({
|
|
1181
|
+
syncRunId: z2.string(),
|
|
1182
|
+
mode: z2.enum(KNOWLEDGE_SYNC_MODES),
|
|
1183
|
+
startedAt: z2.string(),
|
|
1184
|
+
itemsPerMinute: z2.number().min(0).optional(),
|
|
1185
|
+
estimatedEndAt: z2.string().optional()
|
|
1186
|
+
}).optional(),
|
|
1187
|
+
/** The last sync that ended. */
|
|
1188
|
+
last: knowledgeSyncResultSchema.optional(),
|
|
1189
|
+
/** "Letzte Änderung verarbeitet". */
|
|
1190
|
+
lastChangeAt: z2.string().optional(),
|
|
1191
|
+
/** "Älteste offene Änderung". */
|
|
1192
|
+
oldestOpenChangeAt: z2.string().optional()
|
|
1193
|
+
})
|
|
1194
|
+
)
|
|
1195
|
+
});
|
|
1196
|
+
var knowledgeSourceItemsInputSchema = z2.strictObject({
|
|
1197
|
+
source: sourceIdSchema,
|
|
1198
|
+
state: z2.enum(KNOWLEDGE_SOURCE_ITEM_SHOWN_STATES).optional(),
|
|
1199
|
+
failureCode: itemFailureCodeSchema.optional(),
|
|
1200
|
+
/** Items per page: 50 by default, at most 200. */
|
|
1201
|
+
limit: z2.coerce.number().int().min(1).max(200).optional(),
|
|
1202
|
+
cursor: z2.string().min(1).max(1e3).optional()
|
|
1203
|
+
});
|
|
1204
|
+
var knowledgeSourceItemsOutputSchema = z2.strictObject({
|
|
1205
|
+
/** Newest change first. */
|
|
1206
|
+
items: z2.array(
|
|
1207
|
+
z2.strictObject({
|
|
1208
|
+
/** The row in `source_items`: what `retry` and `locate` name. */
|
|
1209
|
+
id: z2.string(),
|
|
1210
|
+
/** The id of the item at the source. */
|
|
1211
|
+
itemId: z2.string(),
|
|
1212
|
+
name: z2.string(),
|
|
1213
|
+
path: z2.string(),
|
|
1214
|
+
state: z2.enum(KNOWLEDGE_SOURCE_ITEM_SHOWN_STATES),
|
|
1215
|
+
failureCode: itemFailureCodeSchema.optional(),
|
|
1216
|
+
documentId: z2.string().optional(),
|
|
1217
|
+
originLink: z2.string().optional(),
|
|
1218
|
+
changedAt: z2.string()
|
|
1219
|
+
})
|
|
1220
|
+
),
|
|
1221
|
+
nextCursor: z2.string().optional()
|
|
1222
|
+
});
|
|
1223
|
+
var RETRY_MAX = 100;
|
|
1224
|
+
var knowledgeRetryInputSchema = z2.union([
|
|
1225
|
+
z2.strictObject({ documentIds: z2.array(z2.string().min(1).max(200)).min(1).max(RETRY_MAX) }),
|
|
1226
|
+
z2.strictObject({
|
|
1227
|
+
source: sourceIdSchema,
|
|
1228
|
+
sourceItemIds: z2.array(z2.string().min(1).max(200)).min(1).max(RETRY_MAX)
|
|
1229
|
+
}),
|
|
1230
|
+
z2.strictObject({ source: sourceIdSchema, failureCode: itemFailureCodeSchema }),
|
|
1231
|
+
z2.strictObject({ source: sourceIdSchema, all: z2.literal(true) })
|
|
1232
|
+
]);
|
|
1233
|
+
var knowledgeRetryOutputSchema = z2.strictObject({
|
|
1234
|
+
/** For a retry by document ids: each named document, with its state after the retry. */
|
|
1235
|
+
documents: z2.array(z2.strictObject({ id: z2.string(), state: z2.enum(KNOWLEDGE_DOCUMENT_STATES) })).optional(),
|
|
1236
|
+
/** How many contents or items were queued again. */
|
|
1237
|
+
queued: z2.number().int()
|
|
1238
|
+
});
|
|
1239
|
+
var knowledgeLocateInputSchema = z2.strictObject({
|
|
1240
|
+
/** The row in `source_items`. */
|
|
1241
|
+
sourceItemId: z2.string().min(1).max(200)
|
|
1242
|
+
});
|
|
1243
|
+
var knowledgeLocateOutputSchema = z2.strictObject({
|
|
1244
|
+
sourceItemId: z2.string(),
|
|
1245
|
+
source: z2.string(),
|
|
1246
|
+
itemId: z2.string(),
|
|
1247
|
+
state: z2.enum(KNOWLEDGE_SOURCE_ITEM_SHOWN_STATES),
|
|
1248
|
+
discoveredAt: z2.string(),
|
|
1249
|
+
fetchedAt: z2.string().optional(),
|
|
1250
|
+
withdrawnAt: z2.string().optional(),
|
|
1251
|
+
purgedAt: z2.string().optional()
|
|
1252
|
+
});
|
|
1024
1253
|
export {
|
|
1025
1254
|
ACCESS_SOURCES,
|
|
1026
1255
|
ACTIONS,
|
|
@@ -1061,17 +1290,21 @@ export {
|
|
|
1061
1290
|
COLLABORATION_WORKSPACE_KINDS,
|
|
1062
1291
|
CONFIG_ASSET_CHANGE_OPERATIONS,
|
|
1063
1292
|
CONFIG_ASSET_KINDS,
|
|
1293
|
+
CONNECTION_BINDING_STATES,
|
|
1064
1294
|
CONNECTION_EXPOSURES,
|
|
1065
1295
|
CONNECTION_HEALTH_STATES,
|
|
1066
1296
|
CONNECTION_NAME_MAX_LENGTH,
|
|
1067
1297
|
CONNECTION_NAME_PATTERN,
|
|
1068
1298
|
CONNECTION_NETWORKS,
|
|
1299
|
+
CONNECTION_OAUTH_REGISTRATIONS,
|
|
1069
1300
|
CONNECTION_OPERATION_POLICIES,
|
|
1070
1301
|
CONNECTION_OPERATION_STATUSES,
|
|
1071
1302
|
CONNECTION_ORIGINS,
|
|
1303
|
+
CONNECTION_PROVIDER_REVOCATIONS,
|
|
1072
1304
|
CONNECTION_SECRET_STATES,
|
|
1073
1305
|
CONNECTOR_TEST_STATUSES,
|
|
1074
1306
|
CONVERSATION_ATTACHMENT_STATUSES,
|
|
1307
|
+
CONVERSATION_KINDS,
|
|
1075
1308
|
CONVERSATION_VISIBILITIES,
|
|
1076
1309
|
DATABASE_RELATION_TYPES,
|
|
1077
1310
|
DATA_STORE_CONDITIONS,
|
|
@@ -1086,6 +1319,8 @@ export {
|
|
|
1086
1319
|
ENDED_APPROVAL_EXECUTIONS,
|
|
1087
1320
|
FAILED_JOB_STATUSES,
|
|
1088
1321
|
FIRST_PARTY_AUTH_SCOPES,
|
|
1322
|
+
FOLLOW_UP_MODES,
|
|
1323
|
+
FOLLOW_UP_STATUSES,
|
|
1089
1324
|
GRANT_EFFECTS,
|
|
1090
1325
|
GRANT_HOLDER_KINDS,
|
|
1091
1326
|
GRANT_SCOPE_KINDS,
|
|
@@ -1099,8 +1334,20 @@ export {
|
|
|
1099
1334
|
JOB_STATUSES,
|
|
1100
1335
|
KNOWLEDGE_BASE_STATUSES,
|
|
1101
1336
|
KNOWLEDGE_CHECK_STATUSES,
|
|
1337
|
+
KNOWLEDGE_DOCUMENT_FAILURE_CODES,
|
|
1338
|
+
KNOWLEDGE_DOCUMENT_STATES,
|
|
1339
|
+
KNOWLEDGE_DOCUMENT_WAIT_CODES,
|
|
1340
|
+
KNOWLEDGE_SEARCH_SIGNALS,
|
|
1341
|
+
KNOWLEDGE_SOURCE_FAILURE_CODES,
|
|
1342
|
+
KNOWLEDGE_SOURCE_ITEM_FAILURE_CODES,
|
|
1343
|
+
KNOWLEDGE_SOURCE_ITEM_SHOWN_STATES,
|
|
1344
|
+
KNOWLEDGE_SOURCE_ITEM_STATES,
|
|
1345
|
+
KNOWLEDGE_SYNC_COUNTS,
|
|
1346
|
+
KNOWLEDGE_SYNC_MODES,
|
|
1347
|
+
KNOWLEDGE_SYNC_RUN_STATES,
|
|
1102
1348
|
LISTED_DATA_STORE_STATUSES,
|
|
1103
1349
|
LIVE_JOB_STATUSES,
|
|
1350
|
+
MANAGED_FILE_STATUSES,
|
|
1104
1351
|
MESSAGE_FINISH_STATUSES,
|
|
1105
1352
|
MODEL_PROVIDER_AUTH_MODES,
|
|
1106
1353
|
MODEL_USAGE_EVENT_STATUSES,
|
|
@@ -1180,6 +1427,15 @@ export {
|
|
|
1180
1427
|
deriveSkillTitle,
|
|
1181
1428
|
formatSkillMarkdown,
|
|
1182
1429
|
isStorableText,
|
|
1430
|
+
knowledgeLocateInputSchema,
|
|
1431
|
+
knowledgeLocateOutputSchema,
|
|
1432
|
+
knowledgeRetryInputSchema,
|
|
1433
|
+
knowledgeRetryOutputSchema,
|
|
1434
|
+
knowledgeSourceItemsInputSchema,
|
|
1435
|
+
knowledgeSourceItemsOutputSchema,
|
|
1436
|
+
knowledgeSourcesOutputSchema,
|
|
1437
|
+
knowledgeSyncInputSchema,
|
|
1438
|
+
knowledgeSyncResultSchema,
|
|
1183
1439
|
loadYamlData,
|
|
1184
1440
|
localeCodes,
|
|
1185
1441
|
localizedStringSchema,
|