openmeld 0.3.197 → 0.3.199
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/{add-me-membership-C9uxzH84.js → add-me-membership-DU044FOl.js} +2 -2
- package/dist/{add-me-membership-C9uxzH84.js.map → add-me-membership-DU044FOl.js.map} +1 -1
- package/dist/{api-client-foundation-HPh7nYGY.js → api-client-foundation-7_VqA9rB.js} +3 -3
- package/dist/{api-client-foundation-HPh7nYGY.js.map → api-client-foundation-7_VqA9rB.js.map} +1 -1
- package/dist/{api-client-foundation-Cb6QKgs-.js → api-client-foundation-CLs3fDt5.js} +1 -1
- package/dist/auth-session-lbATRqNG.js +4 -0
- package/dist/{auth-session-nklLwM9D.js → auth-session-xz8ddkam.js} +2 -2
- package/dist/{auth-session-nklLwM9D.js.map → auth-session-xz8ddkam.js.map} +1 -1
- package/dist/{command-Wx88DamN.js → command-B9TcrbXM.js} +36 -30
- package/dist/command-B9TcrbXM.js.map +1 -0
- package/dist/dist-C6YkYkyj.js +4 -0
- package/dist/{dist-Dec5o82m.js → dist-DMOtlPEO.js} +926 -451
- package/dist/dist-DMOtlPEO.js.map +1 -0
- package/dist/dist-o3UL1EGQ.js.map +1 -1
- package/dist/{elapsed-time-B3vpOQS9.js → elapsed-time-B3D9iBeu.js} +3 -3
- package/dist/{elapsed-time-B3vpOQS9.js.map → elapsed-time-B3D9iBeu.js.map} +1 -1
- package/dist/{installer-BPW3ruIA.js → installer-C8qUYLs5.js} +3 -3
- package/dist/{installer-BPW3ruIA.js.map → installer-C8qUYLs5.js.map} +1 -1
- package/dist/{openmeld-B-BIkyIh.js → openmeld-B1xX2ts7.js} +174 -23
- package/dist/openmeld-B1xX2ts7.js.map +1 -0
- package/dist/{openmeld-maintenance-worker-BhBB6171.js → openmeld-maintenance-worker-CnaF70_P.js} +3 -3
- package/dist/{openmeld-maintenance-worker-BhBB6171.js.map → openmeld-maintenance-worker-CnaF70_P.js.map} +1 -1
- package/dist/{openmeld-tools-update-coordinator-ClR_mpUt.js → openmeld-tools-update-coordinator-CU5OrEIa.js} +11 -11
- package/dist/openmeld-tools-update-coordinator-CU5OrEIa.js.map +1 -0
- package/dist/openmeld.js +3 -3
- package/dist/{runtime-transport-4qeDrtxw.js → runtime-transport-B1Tdf6Rf.js} +48 -11
- package/dist/runtime-transport-B1Tdf6Rf.js.map +1 -0
- package/dist/upgrade-bZCdWP8h.js +4 -0
- package/dist/{upgrade-ClCCv6Hb.js → upgrade-zPnNCuSr.js} +4 -4
- package/dist/{upgrade-ClCCv6Hb.js.map → upgrade-zPnNCuSr.js.map} +1 -1
- package/package.json +3 -3
- package/skills/openmeld-cli/SKILL.md +1 -0
- package/skills/openmeld-cli/playbooks/plugins.md +26 -0
- package/dist/auth-session-CF4NC2v0.js +0 -4
- package/dist/command-Wx88DamN.js.map +0 -1
- package/dist/dist-B76WJQhX.js +0 -4
- package/dist/dist-Dec5o82m.js.map +0 -1
- package/dist/openmeld-B-BIkyIh.js.map +0 -1
- package/dist/openmeld-tools-update-coordinator-ClR_mpUt.js.map +0 -1
- package/dist/runtime-transport-4qeDrtxw.js.map +0 -1
- package/dist/upgrade-BnhBDhux.js +0 -4
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { C as resolveBuiltinAgentControllerConversationCapability, S as agentControllerConversationCapabilitySchema, b as normalizeKnownBuiltinAgentControllerId, h as agentControllerRefSchema, s as runtimeTransportModeSchema } from "./controller-contract-pe3_Re-c.js";
|
|
4
|
-
import { $ as localFolderPickerRequestSchema, $n as
|
|
4
|
+
import { $ as localFolderPickerRequestSchema, $n as spaceMentionLabelSchema, $r as clientMessageIdSchema$1, $t as runtimeCoordinatorExecutionCreationDiagnosticSchema, An as signalSystemNoticeDataSchema, Ar as array, At as agentInteractionPendingSummarySchema, B as openMeldDaemonOriginalErrorSchema, Bn as spaceMessageAttachmentsSchema, Br as neverFactory, Bt as localComponentUpdatePolicySchema, Ci as optionalBooleanQuerySchema, Ct as spaceAllowedActionsSchema, Dr as updateSpaceFileEntryResponseSchema, Dt as workingLanguageTagSchema, Er as trashSpaceFileEntryResponseSchema, Et as workingLanguageGuidanceSchema, Fn as spaceAttachmentDimensionSchema, Fr as enumFactory, Gn as messageEnvelopeSchema, Gr as record, Gt as openMeldToolsMaintenanceProjectionSchema, Hr as number, Ht as localComponentUpdateStatusSchema, I as runtimeTransportRuntimeCoordinatorRespondInteractionResponseSchema, In as spaceAttachmentFileNameSchema, Ir as int, Jn as conversationCompactionMarkerSchema, Jr as tuple, Jt as openMeldToolsUpdateOperationSchema, K as openMeldDaemonTaskResultProjectFailureContextSchema, Kr as strictObject, Ln as spaceAttachmentMimeTypeSchema, Lr as iso, Mi as openMeldNavigationTargetSchema, Mn as signalTextSchema, Mr as coerce, Ni as openMeldWebUrlSchema, Nn as wakeDeviceWaitTargetSchema, Nr as discriminatedUnion, Nt as agentInteractionResponseSchema, Or as uploadSpaceFileResponseSchema, Ot as targetWakeLifecycleIdentitySchema, Pn as spaceAttachmentDescriptorSchema, Pr as email, Qr as url, Qt as postSpaceWakeStopResponseSchema, Rn as spaceAttachmentSizeBytesSchema, Rr as lazySchema, Si as nonEmptyTrimmedStringFromUnknown, Sr as spaceFileNameSchema, St as resultArchivePolicySchema, Ti as MAX_TEXT_LENGTH$1, Tr as stageSpaceComposerUploadResponseSchema, Tt as spaceDispatchPolicySchema, Ur as object, V as openMeldDaemonProviderAccessEvidenceProviderSchema, Vr as nullFactory, Vt as localComponentUpdateProjectionSchema, Wr as preprocess, Wt as openMeldToolsMaintenanceMutationResultSchema, Xr as union, Yn as centerAgentInteractionSourceSchema, Yr as undefinedFactory, Yt as openMeldToolsUpdateRequestResultSchema, Zr as unknown, Zt as postSpaceWakeStopBodySchema, _i as profileSchema, _r as spaceFileActorSchema, ai as spaceAgentStreamPresenceSchema, an as SPACE_PASSWORD_RATE_LIMITED_ERROR_CODE, ar as discardSpaceComposerUploadResponseSchema, at as agentTaskCompletionObservationSchema, bi as uuidProfileIdSchema, br as spaceFileEntryIdSchema, ci as spaceThreadContextSchema, cn as organizationInformationProtectionPolicyResponseSchema, cr as listSpaceFileRevisionsResponseSchema, ct as areAgentTaskTerminalOutcomesEqual, di as spaceThreadSignalPlacementSchema, dn as executeExecutionRecoveryBodySchema, dt as spaceWakeAgentTaskHandleSchema, en as runtimeCoordinatorExecutionEventSchema, er as spaceMentionLabelSourceSchema, et as localFolderPickerResultSchema, fn as executeExecutionRecoveryResponseSchema, ft as localAgentInstallationOptionSchema, gi as profileKindSchema, gn as agentProfileWorkRecoveryActionKindSchema, gr as spaceComposerUploadIdSchema, hi as openMeldRuntimeProfileIdSchema, hn as openMeldRequestContextSchema, hr as spaceComposerUploadDescriptorSchema, ht as openMeldDaemonSyncRouteCatalogPayloadSchema, ii as spaceAgentStreamPartFrameSchema, in as spaceTraceExecutionIdentityProjectionSchema, ir as createSpaceFolderResponseSchema, it as agentTaskCompletionConditionSchema, ji as computerSetupModeSchema, jn as signalTextDataSchema, jr as boolean, kn as signalStatusDataSchema, kr as NEVER, li as spaceThreadEventSchema, ln as organizationProtectedInformationSchema, lr as listSpaceFilesResponseSchema, lt as buildAgentTaskKey, mr as restoreSpaceFileRevisionResponseSchema, n as daemonExecutionCompatibilitySchema, ni as agentStreamToolPartSchema, nr as SPACE_FILE_MAX_SIZE_BYTES, nt as spaceCallerContextSchema, oi as spaceAgentStreamSnapshotSchema, on as normalizeSpacePasswordText, or as getSpaceFileResponseSchema, ot as agentTaskHandleSchema, pi as agentProfileIdSchema, pn as inspectExecutionRecoveryResponseSchema, pr as restoreSpaceFileEntryResponseSchema, qr as string, ri as spaceAgentStreamDeltaFrameSchema, rt as agentDelegationSnapshotSchema, si as spaceAgentStreamTerminalFrameSchema, sn as spacePasswordSchema, st as agentTaskTerminalOutcomeSchema, t as CURRENT_DAEMON_EXECUTION_CONTRACT_EPOCH, ti as AGENT_STREAM_SNAPSHOT_MAX_CHARS, tn as runtimeCoordinatorExecutionRecordSchema, tr as SPACE_FILE_ERROR_CODES, tt as localFolderPathSchema, ui as spaceThreadSchema, un as updateOrganizationInformationProtectionPolicyBodySchema, ur as publishSpaceComposerUploadResponseSchema, ut as controllerAgentTaskHandleSchema, vi as profileWorkingDirectorySchema, vr as spaceFileClientMutationIdSchema, wi as trimmedStringFromUnknown, wr as spaceMessageFileReferencesSchema, wt as spacePublicationModeSchema, xi as finiteIntegerNumber, xr as spaceFileMimeTypeSchema, yi as profileWorkspaceModeSchema, yr as spaceFileDescriptorSchema, yt as dispatchExecutionSchema, zn as spaceMessageAttachmentSchema, zr as literal } from "./runtime-transport-B1Tdf6Rf.js";
|
|
5
5
|
import { r as daemonServiceLaneSchema } from "./service-contract-CRyDcIIf.js";
|
|
6
6
|
import { n as toErrorMessage$3 } from "./dist-o3UL1EGQ.js";
|
|
7
7
|
import * as z$1 from "zod/v4";
|
|
@@ -93,6 +93,36 @@ function omitJsonField(value, fieldName) {
|
|
|
93
93
|
return Object.fromEntries(Object.entries(value).filter(([key]) => key !== fieldName));
|
|
94
94
|
}
|
|
95
95
|
//#endregion
|
|
96
|
+
//#region ../../packages/schemas/dist/schemas/http/space-link-previews.js
|
|
97
|
+
const previewUrlSchema = z$1.url().max(4096).refine((value) => {
|
|
98
|
+
const url = new URL(value);
|
|
99
|
+
return ["https:", "http:"].includes(url.protocol) && !url.username && !url.password;
|
|
100
|
+
});
|
|
101
|
+
const previewImageSchema = z$1.string().max(35e4).regex(/^data:image\/(?:png|jpeg|webp|gif|x-icon|vnd\.microsoft\.icon);base64,[A-Za-z0-9+/=]+$/).nullable();
|
|
102
|
+
z$1.object({
|
|
103
|
+
spaceId: z$1.string().regex(/^[0-9a-f]{64}$/),
|
|
104
|
+
signalId: z$1.string().min(1).max(256)
|
|
105
|
+
}).strict();
|
|
106
|
+
z$1.object({
|
|
107
|
+
signalId: z$1.string(),
|
|
108
|
+
revision: z$1.number().int().nonnegative(),
|
|
109
|
+
urls: z$1.array(previewUrlSchema).max(12)
|
|
110
|
+
}).strict();
|
|
111
|
+
const linkPreviewSchema = z$1.object({
|
|
112
|
+
url: previewUrlSchema,
|
|
113
|
+
title: z$1.string().max(300).nullable(),
|
|
114
|
+
description: z$1.string().max(500).nullable(),
|
|
115
|
+
siteName: z$1.string().max(100).nullable(),
|
|
116
|
+
image: previewImageSchema,
|
|
117
|
+
icon: previewImageSchema,
|
|
118
|
+
status: z$1.enum(["available", "unavailable"])
|
|
119
|
+
}).strict();
|
|
120
|
+
const getSpaceLinkPreviewsResponseSchema = z$1.object({
|
|
121
|
+
signalId: z$1.string(),
|
|
122
|
+
revision: z$1.number().int().nonnegative(),
|
|
123
|
+
previews: z$1.array(linkPreviewSchema).max(12)
|
|
124
|
+
}).strict();
|
|
125
|
+
//#endregion
|
|
96
126
|
//#region ../../packages/schemas/dist/schemas/space-mesh/message-reaction.js
|
|
97
127
|
const spaceReactionActorSchema = z$1.object({
|
|
98
128
|
profileId: z$1.string().min(1),
|
|
@@ -230,7 +260,9 @@ const spaceMessageMutationBodySchema = z$1.discriminatedUnion("action", [
|
|
|
230
260
|
expectedRevision: z$1.number().int().nonnegative(),
|
|
231
261
|
text: z$1.string().max(MAX_TEXT_LENGTH$1),
|
|
232
262
|
retainedFileIds: z$1.array(z$1.string().min(1)).optional(),
|
|
233
|
-
retainedAttachmentIds: z$1.array(z$1.string().min(1)).optional()
|
|
263
|
+
retainedAttachmentIds: z$1.array(z$1.string().min(1)).optional(),
|
|
264
|
+
messageEnvelope: messageEnvelopeSchema.optional(),
|
|
265
|
+
addedFiles: spaceMessageFileReferencesSchema.optional()
|
|
234
266
|
}),
|
|
235
267
|
z$1.strictObject({
|
|
236
268
|
action: z$1.literal("recall"),
|
|
@@ -239,6 +271,59 @@ const spaceMessageMutationBodySchema = z$1.discriminatedUnion("action", [
|
|
|
239
271
|
z$1.strictObject({ action: z$1.literal("restore_draft") })
|
|
240
272
|
]);
|
|
241
273
|
const spaceMessageMutationResponseSchema = z$1.strictObject({ message: signalTextEnvelopeSchema });
|
|
274
|
+
//#endregion
|
|
275
|
+
//#region ../../packages/schemas/dist/schemas/http/space-file-upload.js
|
|
276
|
+
const SPACE_FILE_UPLOAD_PART_BYTES = 8 * 1024 * 1024;
|
|
277
|
+
const spaceFileUploadMetadataSchema = object({
|
|
278
|
+
mimeType: spaceFileMimeTypeSchema,
|
|
279
|
+
sizeBytes: number().int().min(1).max(SPACE_FILE_MAX_SIZE_BYTES),
|
|
280
|
+
partDigests: array(string().regex(/^[a-f0-9]{64}$/u)).min(1).max(32),
|
|
281
|
+
target: discriminatedUnion("kind", [
|
|
282
|
+
object({
|
|
283
|
+
kind: literal("composer"),
|
|
284
|
+
name: spaceFileNameSchema
|
|
285
|
+
}),
|
|
286
|
+
object({
|
|
287
|
+
kind: literal("file"),
|
|
288
|
+
clientMutationId: spaceFileClientMutationIdSchema,
|
|
289
|
+
name: spaceFileNameSchema,
|
|
290
|
+
parentId: spaceFileEntryIdSchema.nullable()
|
|
291
|
+
}),
|
|
292
|
+
object({
|
|
293
|
+
kind: literal("revision"),
|
|
294
|
+
clientMutationId: spaceFileClientMutationIdSchema,
|
|
295
|
+
fileId: spaceFileEntryIdSchema,
|
|
296
|
+
baseRevision: number().int().min(1)
|
|
297
|
+
})
|
|
298
|
+
])
|
|
299
|
+
});
|
|
300
|
+
discriminatedUnion("action", [
|
|
301
|
+
object({
|
|
302
|
+
action: literal("start"),
|
|
303
|
+
metadata: spaceFileUploadMetadataSchema
|
|
304
|
+
}),
|
|
305
|
+
object({ action: literal("status") }),
|
|
306
|
+
object({
|
|
307
|
+
action: literal("part"),
|
|
308
|
+
partNumber: number().int().min(1).max(32)
|
|
309
|
+
}),
|
|
310
|
+
object({ action: literal("complete") }),
|
|
311
|
+
object({ action: literal("cancel") })
|
|
312
|
+
]);
|
|
313
|
+
const spaceFileUploadPartSchema = object({
|
|
314
|
+
partNumber: number().int().min(1).max(32),
|
|
315
|
+
etag: string().min(1),
|
|
316
|
+
sizeBytes: number().int().min(1).max(SPACE_FILE_UPLOAD_PART_BYTES)
|
|
317
|
+
});
|
|
318
|
+
const spaceFileUploadResponseSchema = object({
|
|
319
|
+
uploadId: spaceComposerUploadIdSchema,
|
|
320
|
+
expiresAt: string().datetime(),
|
|
321
|
+
partSizeBytes: literal(SPACE_FILE_UPLOAD_PART_BYTES),
|
|
322
|
+
parts: array(spaceFileUploadPartSchema),
|
|
323
|
+
file: spaceFileDescriptorSchema.optional(),
|
|
324
|
+
upload: spaceComposerUploadDescriptorSchema.optional(),
|
|
325
|
+
cancelled: boolean().optional()
|
|
326
|
+
});
|
|
242
327
|
z$1.strictObject({
|
|
243
328
|
startSignalId: z$1.string().min(1).max(200).optional(),
|
|
244
329
|
endSignalId: z$1.string().min(1).max(200).optional()
|
|
@@ -572,8 +657,8 @@ const MESSAGE_CHANNEL_MENTION_TYPES = [
|
|
|
572
657
|
"none"
|
|
573
658
|
];
|
|
574
659
|
const MESSAGE_CHANNEL_EVENT_TEXT_MAX_CHARS = 4e3;
|
|
575
|
-
const nonEmptyStringSchema$
|
|
576
|
-
const providerIdSchema = nonEmptyStringSchema$
|
|
660
|
+
const nonEmptyStringSchema$5 = string().trim().min(1);
|
|
661
|
+
const providerIdSchema = nonEmptyStringSchema$5.max(512);
|
|
577
662
|
const SLACK_MESSAGE_TIMESTAMP_PATTERN = /^\d+\.\d+$/u;
|
|
578
663
|
const SLACK_THREAD_PERMALINK_PATH_PATTERN = /^\/archives\/([A-Za-z0-9_-]+)\/p(\d{10})(\d{1,6})\/?$/u;
|
|
579
664
|
const timestampMsSchema$7 = number().int().nonnegative().max(Number.MAX_SAFE_INTEGER);
|
|
@@ -642,8 +727,8 @@ const messageChannelConversationLocatorSchema = discriminatedUnion("provider", [
|
|
|
642
727
|
const messageChannelResourceDescriptorSchema = strictObject({
|
|
643
728
|
type: messageChannelResourceTypeSchema,
|
|
644
729
|
fileKey: providerIdSchema,
|
|
645
|
-
fileName: nonEmptyStringSchema$
|
|
646
|
-
mimeType: nonEmptyStringSchema$
|
|
730
|
+
fileName: nonEmptyStringSchema$5.max(512).nullable(),
|
|
731
|
+
mimeType: nonEmptyStringSchema$5.max(256).nullable(),
|
|
647
732
|
sizeBytes: number().int().nonnegative().max(Number.MAX_SAFE_INTEGER).nullable()
|
|
648
733
|
});
|
|
649
734
|
const messageChannelConversationEventShape = { locator: messageChannelConversationLocatorSchema };
|
|
@@ -652,10 +737,10 @@ const normalizedMessageChannelMessageEventSchema = strictObject({
|
|
|
652
737
|
messageId: providerIdSchema,
|
|
653
738
|
sentAtMs: timestampMsSchema$7,
|
|
654
739
|
senderId: providerIdSchema,
|
|
655
|
-
senderDisplayName: nonEmptyStringSchema$
|
|
740
|
+
senderDisplayName: nonEmptyStringSchema$5.max(256).optional(),
|
|
656
741
|
senderTenantKey: providerIdSchema.optional(),
|
|
657
742
|
...messageChannelConversationEventShape,
|
|
658
|
-
text: nonEmptyStringSchema$
|
|
743
|
+
text: nonEmptyStringSchema$5.max(MESSAGE_CHANNEL_EVENT_TEXT_MAX_CHARS),
|
|
659
744
|
mention: messageChannelMentionTypeSchema,
|
|
660
745
|
resources: array(messageChannelResourceDescriptorSchema).max(10)
|
|
661
746
|
});
|
|
@@ -665,8 +750,8 @@ const normalizedMessageChannelCardActionEventSchema = strictObject({
|
|
|
665
750
|
occurredAtMs: timestampMsSchema$7,
|
|
666
751
|
senderId: providerIdSchema,
|
|
667
752
|
...messageChannelConversationEventShape,
|
|
668
|
-
actionName: nonEmptyStringSchema$
|
|
669
|
-
actionValue: nonEmptyStringSchema$
|
|
753
|
+
actionName: nonEmptyStringSchema$5.max(128),
|
|
754
|
+
actionValue: nonEmptyStringSchema$5.max(8192).nullable()
|
|
670
755
|
});
|
|
671
756
|
discriminatedUnion("action", [strictObject({
|
|
672
757
|
v: literal(1),
|
|
@@ -693,7 +778,7 @@ const normalizedMessageChannelEventSchema = discriminatedUnion("kind", [
|
|
|
693
778
|
occurredAtMs: timestampMsSchema$7,
|
|
694
779
|
senderId: providerIdSchema,
|
|
695
780
|
...messageChannelConversationEventShape,
|
|
696
|
-
reaction: nonEmptyStringSchema$
|
|
781
|
+
reaction: nonEmptyStringSchema$5.max(128),
|
|
697
782
|
operation: enumFactory(["add", "remove"])
|
|
698
783
|
}),
|
|
699
784
|
strictObject({
|
|
@@ -703,7 +788,7 @@ const normalizedMessageChannelEventSchema = discriminatedUnion("kind", [
|
|
|
703
788
|
occurredAtMs: timestampMsSchema$7,
|
|
704
789
|
senderId: providerIdSchema,
|
|
705
790
|
...messageChannelConversationEventShape,
|
|
706
|
-
text: nonEmptyStringSchema$
|
|
791
|
+
text: nonEmptyStringSchema$5.max(MESSAGE_CHANNEL_EVENT_TEXT_MAX_CHARS)
|
|
707
792
|
})
|
|
708
793
|
]);
|
|
709
794
|
const messageChannelIngressEnvelopeSchema = strictObject({
|
|
@@ -4357,6 +4442,7 @@ const organizationDirectoryAgentProfileIdentitySchema = strictObject({
|
|
|
4357
4442
|
createdByUserId: nullableTrimmedStringSchema$7,
|
|
4358
4443
|
creatorProfileId: nullableTrimmedStringSchema$7,
|
|
4359
4444
|
lastUsedAt: union([ISO_DATE_TIME_SCHEMA$10, nullFactory()]),
|
|
4445
|
+
lastTaskActivityAt: ISO_DATE_TIME_SCHEMA$10.nullable().optional(),
|
|
4360
4446
|
createdAt: ISO_DATE_TIME_SCHEMA$10,
|
|
4361
4447
|
updatedAt: ISO_DATE_TIME_SCHEMA$10
|
|
4362
4448
|
});
|
|
@@ -4367,22 +4453,32 @@ const organizationDirectoryAgentProfileSchema = organizationDirectoryAgentProfil
|
|
|
4367
4453
|
});
|
|
4368
4454
|
const organizationProfileDirectoryAgentProfileSchema = organizationDirectoryAgentProfileIdentitySchema.extend({
|
|
4369
4455
|
agentControllerRef: nullableTrimmedStringSchema$7,
|
|
4456
|
+
modelSelection: agentProfileBindingModelSelectionSchema.nullable().optional(),
|
|
4370
4457
|
isCenterAgent: boolean().optional()
|
|
4371
4458
|
});
|
|
4372
4459
|
strictObject({
|
|
4460
|
+
includeTaskActivity: boolean().optional(),
|
|
4461
|
+
includeMemberLastActiveAt: boolean().optional(),
|
|
4462
|
+
includeModelSelection: boolean().optional()
|
|
4463
|
+
});
|
|
4464
|
+
strictObject({
|
|
4465
|
+
taskActivitySince: ISO_DATE_TIME_SCHEMA$10.optional(),
|
|
4373
4466
|
organizationId: trimmedNonEmptyStringSchema$14,
|
|
4374
4467
|
generatedAt: ISO_DATE_TIME_SCHEMA$10,
|
|
4375
4468
|
members: array(organizationDirectoryMemberSchema),
|
|
4376
4469
|
agentProfiles: array(organizationProfileDirectoryAgentProfileSchema)
|
|
4377
4470
|
});
|
|
4471
|
+
const organizationAgentRuntimeOverviewItemSchema = strictObject({
|
|
4472
|
+
profileId: agentProfileIdSchema,
|
|
4473
|
+
lastTaskActivityAt: ISO_DATE_TIME_SCHEMA$10.nullable().optional(),
|
|
4474
|
+
operationalContext: organizationDirectoryAgentProfileOperationalContextSchema.optional(),
|
|
4475
|
+
readiness: getAgentExecutionReadinessResponseSchema
|
|
4476
|
+
});
|
|
4378
4477
|
strictObject({
|
|
4379
4478
|
organizationId: trimmedNonEmptyStringSchema$14,
|
|
4380
4479
|
generatedAt: ISO_DATE_TIME_SCHEMA$10,
|
|
4381
|
-
|
|
4382
|
-
|
|
4383
|
-
operationalContext: organizationDirectoryAgentProfileOperationalContextSchema.optional(),
|
|
4384
|
-
readiness: getAgentExecutionReadinessResponseSchema
|
|
4385
|
-
}))
|
|
4480
|
+
taskActivitySince: ISO_DATE_TIME_SCHEMA$10.optional(),
|
|
4481
|
+
agentProfiles: array(organizationAgentRuntimeOverviewItemSchema)
|
|
4386
4482
|
});
|
|
4387
4483
|
const organizationDirectoryResponseSchema = strictObject({
|
|
4388
4484
|
organizationId: trimmedNonEmptyStringSchema$14,
|
|
@@ -4809,8 +4905,8 @@ const trimmedNonEmptyStringSchema$13 = z$1.string().trim().min(1);
|
|
|
4809
4905
|
const isoDateTimeSchema$6 = z$1.iso.datetime({ offset: true });
|
|
4810
4906
|
const MAX_SPACE_GUIDE_LENGTH = 4e3;
|
|
4811
4907
|
const spaceOrganizationVisibilitySchema = z$1.enum(["public", "private"]);
|
|
4812
|
-
function resolveInitialSpaceAccessMode(
|
|
4813
|
-
return
|
|
4908
|
+
function resolveInitialSpaceAccessMode(_visibility) {
|
|
4909
|
+
return "members_only";
|
|
4814
4910
|
}
|
|
4815
4911
|
const spaceCreatorSchema = z$1.strictObject({
|
|
4816
4912
|
profileId: openMeldRuntimeProfileIdSchema,
|
|
@@ -4845,6 +4941,8 @@ const spaceMetaSchema = z$1.strictObject({
|
|
|
4845
4941
|
purpose: trimmedNonEmptyStringSchema$13.optional(),
|
|
4846
4942
|
directMessage: spaceDirectMessageMetaSchema.optional(),
|
|
4847
4943
|
creator: spaceCreatorSchema.optional(),
|
|
4944
|
+
ownerUserIds: z$1.array(trimmedNonEmptyStringSchema$13).optional(),
|
|
4945
|
+
allowGuests: z$1.boolean().optional(),
|
|
4848
4946
|
guide: trimmedNonEmptyStringSchema$13.optional(),
|
|
4849
4947
|
accessMode: spaceAccessModeSchema.optional(),
|
|
4850
4948
|
passwordProtected: z$1.boolean().optional(),
|
|
@@ -4855,16 +4953,23 @@ const spaceMetaSchema = z$1.strictObject({
|
|
|
4855
4953
|
const patchSpaceMetaResponseSchema = spaceMetaSchema;
|
|
4856
4954
|
const patchSpaceMetaBodySchema = z$1.strictObject({
|
|
4857
4955
|
visibility: spaceOrganizationVisibilitySchema.optional(),
|
|
4956
|
+
allowGuests: z$1.boolean().optional(),
|
|
4957
|
+
ownership: z$1.strictObject({
|
|
4958
|
+
userId: trimmedNonEmptyStringSchema$13,
|
|
4959
|
+
role: z$1.enum(["owner", "member"])
|
|
4960
|
+
}).optional(),
|
|
4858
4961
|
name: spaceNameSchema.optional(),
|
|
4859
4962
|
purpose: z$1.string().optional(),
|
|
4860
4963
|
guide: z$1.string().max(MAX_SPACE_GUIDE_LENGTH).optional()
|
|
4861
4964
|
}).superRefine((value, ctx) => {
|
|
4862
|
-
if (value.name !== void 0 || value.visibility !== void 0 || value.purpose !== void 0 || value.guide !== void 0) return;
|
|
4965
|
+
if (value.ownership !== void 0 || value.allowGuests !== void 0 || value.name !== void 0 || value.visibility !== void 0 || value.purpose !== void 0 || value.guide !== void 0) return;
|
|
4863
4966
|
ctx.addIssue({
|
|
4864
4967
|
code: "custom",
|
|
4865
4968
|
message: "Expected name, purpose, guide or visibility"
|
|
4866
4969
|
});
|
|
4867
4970
|
}).transform((value) => ({
|
|
4971
|
+
...value.allowGuests === void 0 ? {} : { allowGuests: value.allowGuests },
|
|
4972
|
+
...value.ownership === void 0 ? {} : { ownership: value.ownership },
|
|
4868
4973
|
...value.visibility === void 0 ? {} : { visibility: value.visibility },
|
|
4869
4974
|
...value.name === void 0 ? {} : { name: value.name },
|
|
4870
4975
|
...value.purpose === void 0 ? {} : { purpose: value.purpose },
|
|
@@ -5430,19 +5535,19 @@ const MESSAGE_CHANNEL_ERROR_CODES = [
|
|
|
5430
5535
|
"message_channel.setup_request_recipient_unavailable"
|
|
5431
5536
|
];
|
|
5432
5537
|
const LARK_PLATFORM_WEBHOOK_RAW_BODY_MAX_CHARS = 262144;
|
|
5433
|
-
const nonEmptyStringSchema$
|
|
5434
|
-
const capabilityGroupSchema = nonEmptyStringSchema$
|
|
5435
|
-
const reasonCodeSchema$2 = nonEmptyStringSchema$
|
|
5538
|
+
const nonEmptyStringSchema$4 = string().trim().min(1);
|
|
5539
|
+
const capabilityGroupSchema = nonEmptyStringSchema$4.max(64).regex(/^[a-z0-9][a-z0-9._-]*$/u);
|
|
5540
|
+
const reasonCodeSchema$2 = nonEmptyStringSchema$4.max(128).regex(/^[a-z0-9][a-z0-9._-]*$/u);
|
|
5436
5541
|
const messageChannelConnectionStatusSchema = enumFactory(MESSAGE_CHANNEL_CONNECTION_STATUSES);
|
|
5437
5542
|
const messageChannelSetupRequestBodySchema = strictObject({ provider: messageChannelProviderSchema });
|
|
5438
5543
|
const messageChannelSetupRequestResponseSchema = strictObject({
|
|
5439
|
-
organizationId: nonEmptyStringSchema$
|
|
5544
|
+
organizationId: nonEmptyStringSchema$4.max(256),
|
|
5440
5545
|
provider: messageChannelProviderSchema,
|
|
5441
5546
|
recipientCount: number().int().positive(),
|
|
5442
|
-
requestId: nonEmptyStringSchema$
|
|
5547
|
+
requestId: nonEmptyStringSchema$4.max(256),
|
|
5443
5548
|
status: enumFactory(["created", "already_requested"])
|
|
5444
5549
|
});
|
|
5445
|
-
const messageChannelIdentityLinkIdSchema = nonEmptyStringSchema$
|
|
5550
|
+
const messageChannelIdentityLinkIdSchema = nonEmptyStringSchema$4.max(82).regex(/^channel_identity_[0-9a-f]{64}$/u);
|
|
5446
5551
|
const larkPlatformProviderSchema = enumFactory(["lark", "feishu"]);
|
|
5447
5552
|
const larkPlatformRegistrationBeginModeSchema = enumFactory([
|
|
5448
5553
|
"resume",
|
|
@@ -5451,13 +5556,13 @@ const larkPlatformRegistrationBeginModeSchema = enumFactory([
|
|
|
5451
5556
|
"reauthorize"
|
|
5452
5557
|
]);
|
|
5453
5558
|
const messageChannelConnectionProjectionSchema = strictObject({
|
|
5454
|
-
id: nonEmptyStringSchema$
|
|
5559
|
+
id: nonEmptyStringSchema$4.max(256),
|
|
5455
5560
|
provider: messageChannelProviderSchema,
|
|
5456
5561
|
transport: messageChannelTransportSchema,
|
|
5457
5562
|
status: messageChannelConnectionStatusSchema,
|
|
5458
|
-
externalAccountId: nonEmptyStringSchema$
|
|
5459
|
-
externalAccountName: nonEmptyStringSchema$
|
|
5460
|
-
permissionBundleVersion: nonEmptyStringSchema$
|
|
5563
|
+
externalAccountId: nonEmptyStringSchema$4.max(512).nullable(),
|
|
5564
|
+
externalAccountName: nonEmptyStringSchema$4.max(256).nullable(),
|
|
5565
|
+
permissionBundleVersion: nonEmptyStringSchema$4.max(128).nullable(),
|
|
5461
5566
|
grantedCapabilityGroups: array(capabilityGroupSchema).max(32),
|
|
5462
5567
|
lastVerifiedAt: iso.datetime({ offset: true }).nullable(),
|
|
5463
5568
|
reasonCode: reasonCodeSchema$2.nullable()
|
|
@@ -5471,13 +5576,13 @@ const messageChannelConnectionProjectionSchema = strictObject({
|
|
|
5471
5576
|
const messageChannelIdentityLinkProjectionSchema = strictObject({
|
|
5472
5577
|
connectedAt: iso.datetime({ offset: true }),
|
|
5473
5578
|
id: messageChannelIdentityLinkIdSchema,
|
|
5474
|
-
openMeldUserId: nonEmptyStringSchema$
|
|
5579
|
+
openMeldUserId: nonEmptyStringSchema$4.max(256),
|
|
5475
5580
|
provider: messageChannelProviderSchema,
|
|
5476
5581
|
providerAccountEmail: email().max(320).nullable().default(null),
|
|
5477
|
-
providerAccountName: nonEmptyStringSchema$
|
|
5582
|
+
providerAccountName: nonEmptyStringSchema$4.max(256).nullable()
|
|
5478
5583
|
});
|
|
5479
5584
|
const messageChannelConnectionListResponseSchema = strictObject({
|
|
5480
|
-
organizationId: nonEmptyStringSchema$
|
|
5585
|
+
organizationId: nonEmptyStringSchema$4.max(256),
|
|
5481
5586
|
availableLarkPlatformProviders: array(larkPlatformProviderSchema).max(2),
|
|
5482
5587
|
connections: array(messageChannelConnectionProjectionSchema).max(MESSAGE_CHANNEL_PROVIDERS.length),
|
|
5483
5588
|
identityLinks: array(messageChannelIdentityLinkProjectionSchema).max(1e4).default([])
|
|
@@ -5501,7 +5606,7 @@ const messageChannelConnectionListResponseSchema = strictObject({
|
|
|
5501
5606
|
providers.add(connection.provider);
|
|
5502
5607
|
}
|
|
5503
5608
|
});
|
|
5504
|
-
const larkPlatformRegistrationAttemptIdSchema = nonEmptyStringSchema$
|
|
5609
|
+
const larkPlatformRegistrationAttemptIdSchema = nonEmptyStringSchema$4.max(256);
|
|
5505
5610
|
const larkPlatformActiveRegistrationProjectionSchema = strictObject({
|
|
5506
5611
|
canResume: boolean(),
|
|
5507
5612
|
expiresAt: iso.datetime({ offset: true }),
|
|
@@ -5516,7 +5621,7 @@ const larkPlatformActiveRegistrationProjectionSchema = strictObject({
|
|
|
5516
5621
|
])
|
|
5517
5622
|
});
|
|
5518
5623
|
const larkPlatformActiveRegistrationListResponseSchema = strictObject({
|
|
5519
|
-
organizationId: nonEmptyStringSchema$
|
|
5624
|
+
organizationId: nonEmptyStringSchema$4.max(256),
|
|
5520
5625
|
registrations: array(larkPlatformActiveRegistrationProjectionSchema).max(2)
|
|
5521
5626
|
}).superRefine((response, context) => {
|
|
5522
5627
|
const providers = /* @__PURE__ */ new Set();
|
|
@@ -5557,7 +5662,7 @@ const larkPlatformRegistrationAttemptProjectionSchema = strictObject({
|
|
|
5557
5662
|
}
|
|
5558
5663
|
});
|
|
5559
5664
|
const larkPlatformRegistrationResponseSchema = strictObject({
|
|
5560
|
-
organizationId: nonEmptyStringSchema$
|
|
5665
|
+
organizationId: nonEmptyStringSchema$4.max(256),
|
|
5561
5666
|
attempt: larkPlatformRegistrationAttemptProjectionSchema,
|
|
5562
5667
|
connection: messageChannelConnectionProjectionSchema.nullable()
|
|
5563
5668
|
}).superRefine((response, context) => {
|
|
@@ -5569,21 +5674,21 @@ const larkPlatformRegistrationResponseSchema = strictObject({
|
|
|
5569
5674
|
});
|
|
5570
5675
|
strictObject({
|
|
5571
5676
|
provider: larkPlatformProviderSchema,
|
|
5572
|
-
connectionId: nonEmptyStringSchema$
|
|
5677
|
+
connectionId: nonEmptyStringSchema$4.max(256),
|
|
5573
5678
|
surface: enumFactory(["events", "callbacks"]),
|
|
5574
5679
|
rawBody: string().min(2).max(LARK_PLATFORM_WEBHOOK_RAW_BODY_MAX_CHARS),
|
|
5575
5680
|
headers: strictObject({
|
|
5576
|
-
timestamp: nonEmptyStringSchema$
|
|
5577
|
-
nonce: nonEmptyStringSchema$
|
|
5578
|
-
signature: nonEmptyStringSchema$
|
|
5681
|
+
timestamp: nonEmptyStringSchema$4.max(64).nullable(),
|
|
5682
|
+
nonce: nonEmptyStringSchema$4.max(256).nullable(),
|
|
5683
|
+
signature: nonEmptyStringSchema$4.max(256).nullable()
|
|
5579
5684
|
}),
|
|
5580
5685
|
receivedAtMs: number().int().nonnegative().max(Number.MAX_SAFE_INTEGER),
|
|
5581
|
-
gatewayRequestId: nonEmptyStringSchema$
|
|
5686
|
+
gatewayRequestId: nonEmptyStringSchema$4.max(256)
|
|
5582
5687
|
});
|
|
5583
5688
|
discriminatedUnion("status", [
|
|
5584
5689
|
strictObject({
|
|
5585
5690
|
status: literal("challenge"),
|
|
5586
|
-
challenge: nonEmptyStringSchema$
|
|
5691
|
+
challenge: nonEmptyStringSchema$4.max(2048)
|
|
5587
5692
|
}),
|
|
5588
5693
|
strictObject({
|
|
5589
5694
|
status: literal("enqueue"),
|
|
@@ -5604,12 +5709,12 @@ const messageChannelIdentityLinkPreviewResponseSchema = strictObject({
|
|
|
5604
5709
|
alreadyMember: boolean().default(true),
|
|
5605
5710
|
continuesRequest: boolean().default(false),
|
|
5606
5711
|
expiresAt: iso.datetime({ offset: true }),
|
|
5607
|
-
organizationId: nonEmptyStringSchema$
|
|
5608
|
-
organizationName: nonEmptyStringSchema$
|
|
5712
|
+
organizationId: nonEmptyStringSchema$4.max(256),
|
|
5713
|
+
organizationName: nonEmptyStringSchema$4.max(256),
|
|
5609
5714
|
provider: larkPlatformProviderSchema,
|
|
5610
|
-
providerUserDisplayName: nonEmptyStringSchema$
|
|
5611
|
-
providerUserId: nonEmptyStringSchema$
|
|
5612
|
-
openMeldAccountEmail: nonEmptyStringSchema$
|
|
5715
|
+
providerUserDisplayName: nonEmptyStringSchema$4.max(256),
|
|
5716
|
+
providerUserId: nonEmptyStringSchema$4.max(512),
|
|
5717
|
+
openMeldAccountEmail: nonEmptyStringSchema$4.max(320),
|
|
5613
5718
|
replacesExistingLink: boolean().default(false)
|
|
5614
5719
|
});
|
|
5615
5720
|
const messageChannelIdentityLinkConsumeBodySchema = strictObject({ token: messageChannelIdentityLinkTokenSchema });
|
|
@@ -5619,13 +5724,13 @@ const messageChannelIdentityLinkConsumeResponseSchema = strictObject({
|
|
|
5619
5724
|
continuesRequest: boolean().default(false),
|
|
5620
5725
|
joinedOrganization: boolean().default(false),
|
|
5621
5726
|
linked: literal(true),
|
|
5622
|
-
organizationId: nonEmptyStringSchema$
|
|
5623
|
-
organizationName: nonEmptyStringSchema$
|
|
5727
|
+
organizationId: nonEmptyStringSchema$4.max(256),
|
|
5728
|
+
organizationName: nonEmptyStringSchema$4.max(256),
|
|
5624
5729
|
provider: larkPlatformProviderSchema,
|
|
5625
|
-
providerUserDisplayName: nonEmptyStringSchema$
|
|
5626
|
-
providerUserId: nonEmptyStringSchema$
|
|
5730
|
+
providerUserDisplayName: nonEmptyStringSchema$4.max(256),
|
|
5731
|
+
providerUserId: nonEmptyStringSchema$4.max(512),
|
|
5627
5732
|
replacedExistingLink: boolean().default(false),
|
|
5628
|
-
openMeldUserId: nonEmptyStringSchema$
|
|
5733
|
+
openMeldUserId: nonEmptyStringSchema$4.max(256)
|
|
5629
5734
|
});
|
|
5630
5735
|
//#endregion
|
|
5631
5736
|
//#region ../../packages/schemas/dist/schemas/http/center-agent-member-research.js
|
|
@@ -6243,9 +6348,252 @@ function validateCenterAgentDraftTarget(value, context) {
|
|
|
6243
6348
|
...value.title ? { title: value.title } : {}
|
|
6244
6349
|
}, context);
|
|
6245
6350
|
}
|
|
6351
|
+
const CONNECTOR_SERVICES = ["github", ...[
|
|
6352
|
+
"feishu",
|
|
6353
|
+
"lark",
|
|
6354
|
+
"gmail",
|
|
6355
|
+
"googlecalendar",
|
|
6356
|
+
"googledrive",
|
|
6357
|
+
"notion",
|
|
6358
|
+
"linear",
|
|
6359
|
+
"figma",
|
|
6360
|
+
"posthog",
|
|
6361
|
+
"cloudflare_browser_rendering",
|
|
6362
|
+
"cloudflare_dns",
|
|
6363
|
+
"cloudflare_r2",
|
|
6364
|
+
"cloudflare_worker"
|
|
6365
|
+
]];
|
|
6366
|
+
const CONNECTOR_CONNECTION_STATUSES = [
|
|
6367
|
+
"pending",
|
|
6368
|
+
"active",
|
|
6369
|
+
"disconnected"
|
|
6370
|
+
];
|
|
6371
|
+
const CONNECTOR_CONNECTION_SCOPES = ["member", "shared"];
|
|
6372
|
+
const CONNECTOR_CONNECTION_PREFERENCES = [
|
|
6373
|
+
"automatic",
|
|
6374
|
+
"requester",
|
|
6375
|
+
"shared"
|
|
6376
|
+
];
|
|
6377
|
+
const CONNECTOR_APP_REQUEST_SOURCES = ["openconnector_catalog", "freeform"];
|
|
6378
|
+
const CONNECTOR_APP_REQUEST_STATUSES = [
|
|
6379
|
+
"requested",
|
|
6380
|
+
"available",
|
|
6381
|
+
"declined"
|
|
6382
|
+
];
|
|
6383
|
+
const trimmedNonEmptyStringSchema$8 = string().trim().min(1);
|
|
6384
|
+
const timestampMsSchema$1 = number().int().nonnegative();
|
|
6385
|
+
const connectorCredentialValueSchema = string().min(1).max(8192);
|
|
6386
|
+
const connectorAppRequestOptionalTextSchema = string().trim().min(1).max(2e3).nullable();
|
|
6387
|
+
const connectorAppRequestedCapabilitiesSchema = array(string().trim().min(1).max(80)).max(12);
|
|
6388
|
+
const connectorServiceSchema = enumFactory(CONNECTOR_SERVICES);
|
|
6389
|
+
const connectorConnectionStatusSchema = enumFactory(CONNECTOR_CONNECTION_STATUSES);
|
|
6390
|
+
const connectorConnectionScopeSchema = enumFactory(CONNECTOR_CONNECTION_SCOPES);
|
|
6391
|
+
const connectorConnectionPreferenceSchema = enumFactory(CONNECTOR_CONNECTION_PREFERENCES);
|
|
6392
|
+
const connectorAppRequestSourceSchema = enumFactory(CONNECTOR_APP_REQUEST_SOURCES);
|
|
6393
|
+
const connectorAppRequestStatusSchema = enumFactory(CONNECTOR_APP_REQUEST_STATUSES);
|
|
6394
|
+
const connectorConnectionNameSchema = string().regex(/^[a-zA-Z0-9][a-zA-Z0-9_-]{0,63}$/u);
|
|
6395
|
+
const githubAppInstallationStateSchema = string().regex(/^githubapp_[0-9a-f]{64}$/u);
|
|
6396
|
+
const githubAppInstallationIdSchema = string().regex(/^[1-9][0-9]*$/u);
|
|
6397
|
+
const connectorConnectionSchema = strictObject({
|
|
6398
|
+
canDisconnect: boolean(),
|
|
6399
|
+
connectionName: connectorConnectionNameSchema,
|
|
6400
|
+
createdAtMs: timestampMsSchema$1,
|
|
6401
|
+
disconnectedAtMs: timestampMsSchema$1.nullable(),
|
|
6402
|
+
organizationId: trimmedNonEmptyStringSchema$8,
|
|
6403
|
+
ownerDisplayName: trimmedNonEmptyStringSchema$8,
|
|
6404
|
+
scope: connectorConnectionScopeSchema.default("member"),
|
|
6405
|
+
service: connectorServiceSchema,
|
|
6406
|
+
status: connectorConnectionStatusSchema,
|
|
6407
|
+
updatedAtMs: timestampMsSchema$1,
|
|
6408
|
+
userId: trimmedNonEmptyStringSchema$8
|
|
6409
|
+
});
|
|
6410
|
+
strictObject({
|
|
6411
|
+
connections: array(connectorConnectionSchema),
|
|
6412
|
+
currentUserId: trimmedNonEmptyStringSchema$8,
|
|
6413
|
+
organizationId: trimmedNonEmptyStringSchema$8
|
|
6414
|
+
});
|
|
6415
|
+
const connectorAppRequestSchema = strictObject({
|
|
6416
|
+
availableAtMs: timestampMsSchema$1.nullable(),
|
|
6417
|
+
createdAtMs: timestampMsSchema$1,
|
|
6418
|
+
id: string().trim().min(1).max(128),
|
|
6419
|
+
notifiedAtMs: timestampMsSchema$1.nullable(),
|
|
6420
|
+
organizationId: trimmedNonEmptyStringSchema$8,
|
|
6421
|
+
providerId: string().trim().min(1).max(160).nullable(),
|
|
6422
|
+
providerName: string().trim().min(1).max(120),
|
|
6423
|
+
requestedCapabilities: connectorAppRequestedCapabilitiesSchema,
|
|
6424
|
+
requesterMemberId: trimmedNonEmptyStringSchema$8.nullable(),
|
|
6425
|
+
requesterUserId: trimmedNonEmptyStringSchema$8.nullable(),
|
|
6426
|
+
source: connectorAppRequestSourceSchema,
|
|
6427
|
+
status: connectorAppRequestStatusSchema,
|
|
6428
|
+
updatedAtMs: timestampMsSchema$1,
|
|
6429
|
+
useCase: connectorAppRequestOptionalTextSchema
|
|
6430
|
+
});
|
|
6431
|
+
strictObject({
|
|
6432
|
+
providerId: string().trim().min(1).max(160).nullable().optional(),
|
|
6433
|
+
providerName: string().trim().min(1).max(120),
|
|
6434
|
+
requestedCapabilities: connectorAppRequestedCapabilitiesSchema.optional(),
|
|
6435
|
+
source: connectorAppRequestSourceSchema,
|
|
6436
|
+
useCase: connectorAppRequestOptionalTextSchema.optional()
|
|
6437
|
+
}).superRefine((input, context) => {
|
|
6438
|
+
if (input.source === "openconnector_catalog" && !input.providerId?.trim()) context.addIssue({
|
|
6439
|
+
code: "custom",
|
|
6440
|
+
message: "A catalog Plugin request requires its OpenConnector provider ID.",
|
|
6441
|
+
path: ["providerId"]
|
|
6442
|
+
});
|
|
6443
|
+
if (input.source === "freeform" && input.providerId != null) context.addIssue({
|
|
6444
|
+
code: "custom",
|
|
6445
|
+
message: "A freeform Plugin request cannot include a provider ID.",
|
|
6446
|
+
path: ["providerId"]
|
|
6447
|
+
});
|
|
6448
|
+
});
|
|
6449
|
+
strictObject({ request: connectorAppRequestSchema });
|
|
6450
|
+
strictObject({
|
|
6451
|
+
currentUserId: trimmedNonEmptyStringSchema$8,
|
|
6452
|
+
organizationId: trimmedNonEmptyStringSchema$8,
|
|
6453
|
+
requests: array(connectorAppRequestSchema).max(500)
|
|
6454
|
+
});
|
|
6455
|
+
strictObject({
|
|
6456
|
+
organizationId: trimmedNonEmptyStringSchema$8,
|
|
6457
|
+
providers: array(strictObject({
|
|
6458
|
+
authTypes: array(string().trim().min(1).max(80)).max(12),
|
|
6459
|
+
categories: array(strictObject({
|
|
6460
|
+
displayName: string().trim().min(1).max(120),
|
|
6461
|
+
id: string().trim().min(1).max(120)
|
|
6462
|
+
})).max(12),
|
|
6463
|
+
displayName: string().trim().min(1).max(120),
|
|
6464
|
+
homepageUrl: url().nullable(),
|
|
6465
|
+
iconUrl: url().nullable(),
|
|
6466
|
+
service: string().trim().min(1).max(160)
|
|
6467
|
+
})).max(5e3)
|
|
6468
|
+
});
|
|
6469
|
+
strictObject({
|
|
6470
|
+
authorizationUrl: url(),
|
|
6471
|
+
connection: connectorConnectionSchema,
|
|
6472
|
+
expiresAtMs: timestampMsSchema$1.optional()
|
|
6473
|
+
});
|
|
6474
|
+
strictObject({
|
|
6475
|
+
connection: connectorConnectionSchema,
|
|
6476
|
+
expiresAtMs: timestampMsSchema$1,
|
|
6477
|
+
state: githubAppInstallationStateSchema
|
|
6478
|
+
});
|
|
6479
|
+
strictObject({
|
|
6480
|
+
installation_id: githubAppInstallationIdSchema,
|
|
6481
|
+
setup_action: string().trim().min(1).max(64).optional(),
|
|
6482
|
+
state: githubAppInstallationStateSchema
|
|
6483
|
+
});
|
|
6484
|
+
discriminatedUnion("status", [
|
|
6485
|
+
strictObject({
|
|
6486
|
+
actorProfileId: trimmedNonEmptyStringSchema$8,
|
|
6487
|
+
installationId: githubAppInstallationIdSchema,
|
|
6488
|
+
organizationId: trimmedNonEmptyStringSchema$8,
|
|
6489
|
+
status: literal("valid"),
|
|
6490
|
+
targetConnectionName: connectorConnectionNameSchema,
|
|
6491
|
+
userId: trimmedNonEmptyStringSchema$8,
|
|
6492
|
+
verificationConnectionName: connectorConnectionNameSchema
|
|
6493
|
+
}),
|
|
6494
|
+
strictObject({ status: literal("expired") }),
|
|
6495
|
+
strictObject({ status: literal("invalid") })
|
|
6496
|
+
]);
|
|
6497
|
+
strictObject({
|
|
6498
|
+
installationId: githubAppInstallationIdSchema,
|
|
6499
|
+
organizationId: trimmedNonEmptyStringSchema$8,
|
|
6500
|
+
status: literal("verifying"),
|
|
6501
|
+
targetConnectionName: connectorConnectionNameSchema,
|
|
6502
|
+
userId: trimmedNonEmptyStringSchema$8,
|
|
6503
|
+
verificationConnectionName: connectorConnectionNameSchema
|
|
6504
|
+
}).nullable();
|
|
6505
|
+
strictObject({
|
|
6506
|
+
authType: enumFactory(["api_key", "custom_credential"]),
|
|
6507
|
+
values: record(string().regex(/^[a-zA-Z][a-zA-Z0-9_]{0,63}$/u), connectorCredentialValueSchema).refine((values) => Object.keys(values).length > 0, { message: "At least one credential value is required." }).refine((values) => Object.keys(values).length <= 16, { message: "Too many credential values." })
|
|
6508
|
+
});
|
|
6509
|
+
strictObject({ connection: connectorConnectionSchema });
|
|
6510
|
+
strictObject({
|
|
6511
|
+
expectedOrganizationId: trimmedNonEmptyStringSchema$8,
|
|
6512
|
+
includeAuthorizationExpiry: literal("true").optional()
|
|
6513
|
+
});
|
|
6514
|
+
strictObject({ userId: trimmedNonEmptyStringSchema$8 });
|
|
6515
|
+
strictObject({ connection: connectorConnectionSchema });
|
|
6516
|
+
strictObject({
|
|
6517
|
+
availableConnectionNames: array(connectorConnectionNameSchema).max(500),
|
|
6518
|
+
service: connectorServiceSchema
|
|
6519
|
+
});
|
|
6520
|
+
strictObject({
|
|
6521
|
+
permission: enumFactory(["read", "write"]).optional(),
|
|
6522
|
+
connection: connectorConnectionSchema.nullable(),
|
|
6523
|
+
selection: enumFactory(["requester", "shared"]).nullable()
|
|
6524
|
+
});
|
|
6525
|
+
strictObject({
|
|
6526
|
+
connectionPreference: connectorConnectionPreferenceSchema.optional(),
|
|
6527
|
+
includeAccessPolicy: literal(true).optional(),
|
|
6528
|
+
requesterUserId: string().nullable(),
|
|
6529
|
+
service: connectorServiceSchema
|
|
6530
|
+
});
|
|
6531
|
+
//#endregion
|
|
6532
|
+
//#region ../../packages/schemas/dist/schemas/http/plugin-access.js
|
|
6533
|
+
const PLUGIN_ERROR_CODES = [
|
|
6534
|
+
"plugin.access_changed",
|
|
6535
|
+
"plugin.access_invalid",
|
|
6536
|
+
"plugin.access_manage_forbidden",
|
|
6537
|
+
"plugin.action_forbidden",
|
|
6538
|
+
"plugin.action_unavailable",
|
|
6539
|
+
"plugin.caller_forbidden",
|
|
6540
|
+
"plugin.catalog_unavailable",
|
|
6541
|
+
"plugin.confirmation_invalid",
|
|
6542
|
+
"plugin.connection_not_found",
|
|
6543
|
+
"plugin.connection_owner_unavailable",
|
|
6544
|
+
"plugin.connection_required",
|
|
6545
|
+
"plugin.connection_unavailable",
|
|
6546
|
+
"plugin.human_required",
|
|
6547
|
+
"plugin.identity_unavailable",
|
|
6548
|
+
"plugin.operation_identity_unavailable",
|
|
6549
|
+
"plugin.operation_unavailable",
|
|
6550
|
+
"plugin.personal_request_required",
|
|
6551
|
+
"plugin.request_invalid",
|
|
6552
|
+
"plugin.request_provenance_unavailable",
|
|
6553
|
+
"plugin.runtime_invalid",
|
|
6554
|
+
"plugin.runtime_unavailable",
|
|
6555
|
+
"plugin.state_unavailable"
|
|
6556
|
+
];
|
|
6557
|
+
enumFactory([
|
|
6558
|
+
"center_agent",
|
|
6559
|
+
"local_agent",
|
|
6560
|
+
"remote_agent"
|
|
6561
|
+
]);
|
|
6562
|
+
const pluginPermissionSchema = enumFactory([
|
|
6563
|
+
"none",
|
|
6564
|
+
"read",
|
|
6565
|
+
"write"
|
|
6566
|
+
]);
|
|
6567
|
+
const pluginAccessPolicySchema = strictObject({
|
|
6568
|
+
center_agent: pluginPermissionSchema,
|
|
6569
|
+
local_agent: pluginPermissionSchema,
|
|
6570
|
+
remote_agent: pluginPermissionSchema
|
|
6571
|
+
});
|
|
6572
|
+
const pluginAccessSchema = strictObject({
|
|
6573
|
+
canManage: boolean(),
|
|
6574
|
+
connectionName: connectorConnectionNameSchema,
|
|
6575
|
+
scope: enumFactory(["member", "shared"]),
|
|
6576
|
+
policy: pluginAccessPolicySchema,
|
|
6577
|
+
revision: number().int().nonnegative()
|
|
6578
|
+
});
|
|
6579
|
+
strictObject({
|
|
6580
|
+
organizationId: string().trim().min(1),
|
|
6581
|
+
connections: array(pluginAccessSchema)
|
|
6582
|
+
});
|
|
6583
|
+
const pluginAccessListRpcInputSchema = strictObject({
|
|
6584
|
+
context: openMeldRequestContextSchema,
|
|
6585
|
+
expectedOrganizationId: string().trim().min(1),
|
|
6586
|
+
service: connectorServiceSchema
|
|
6587
|
+
});
|
|
6588
|
+
const pluginAccessUpdateBodySchema = strictObject({
|
|
6589
|
+
connectionName: connectorConnectionNameSchema,
|
|
6590
|
+
expectedRevision: number().int().nonnegative(),
|
|
6591
|
+
policy: pluginAccessPolicySchema
|
|
6592
|
+
});
|
|
6593
|
+
pluginAccessListRpcInputSchema.extend({ ...pluginAccessUpdateBodySchema.shape });
|
|
6246
6594
|
//#endregion
|
|
6247
6595
|
//#region ../../packages/schemas/dist/schemas/http/gateway-error.js
|
|
6248
|
-
const trimmedNonEmptyStringSchema$
|
|
6596
|
+
const trimmedNonEmptyStringSchema$7 = z$1.string().trim().min(1);
|
|
6249
6597
|
const SPACE_ADDRESSING_TARGET_INVALID_ERROR_CODE = "space.addressing.target_invalid";
|
|
6250
6598
|
const gatewayErrorCodeSchema = z$1.enum([
|
|
6251
6599
|
"bad_request",
|
|
@@ -6278,6 +6626,7 @@ const gatewayErrorCodeSchema = z$1.enum([
|
|
|
6278
6626
|
...MESSAGE_CHANNEL_ERROR_CODES,
|
|
6279
6627
|
...ORGANIZATION_DOCUMENT_ERROR_CODES,
|
|
6280
6628
|
...ORGANIZATION_SKILL_ERROR_CODES,
|
|
6629
|
+
...PLUGIN_ERROR_CODES,
|
|
6281
6630
|
"connector.organization_context_changed",
|
|
6282
6631
|
"organization.logo.conflict",
|
|
6283
6632
|
"organization.logo.content_mismatch",
|
|
@@ -6365,8 +6714,8 @@ const gatewayErrorCodeSchema = z$1.enum([
|
|
|
6365
6714
|
]);
|
|
6366
6715
|
const gatewayErrorSchema = commonErrorSchema.extend({
|
|
6367
6716
|
code: gatewayErrorCodeSchema,
|
|
6368
|
-
requestId: trimmedNonEmptyStringSchema$
|
|
6369
|
-
upstreamCode: trimmedNonEmptyStringSchema$
|
|
6717
|
+
requestId: trimmedNonEmptyStringSchema$7,
|
|
6718
|
+
upstreamCode: trimmedNonEmptyStringSchema$7.optional()
|
|
6370
6719
|
});
|
|
6371
6720
|
const gatewayErrorEnvelopeSchema = z$1.strictObject({
|
|
6372
6721
|
ok: z$1.literal(false),
|
|
@@ -6387,8 +6736,8 @@ const GATEWAY_HOST_MAX_LENGTH = 255;
|
|
|
6387
6736
|
const PROFILE_SPACE_HISTORY_MAX_LIMIT = 500;
|
|
6388
6737
|
const NON_NEGATIVE_INT_RE$2 = /^\d+$/;
|
|
6389
6738
|
const GATEWAY_HOST_PATH_CHARS_RE = /[/?#]/;
|
|
6390
|
-
const trimmedNonEmptyStringSchema$
|
|
6391
|
-
const nullableTrimmedStringSchema$6 = z$1.union([trimmedNonEmptyStringSchema$
|
|
6739
|
+
const trimmedNonEmptyStringSchema$6 = z$1.string().trim().min(1);
|
|
6740
|
+
const nullableTrimmedStringSchema$6 = z$1.union([trimmedNonEmptyStringSchema$6, z$1.null()]);
|
|
6392
6741
|
const nullableNonNegativeIntSchema$1 = z$1.union([z$1.number().int().min(0), z$1.null()]);
|
|
6393
6742
|
const nullableIsoDateTimeSchema$4 = z$1.union([ISO_DATE_TIME_SCHEMA$6, z$1.null()]);
|
|
6394
6743
|
const profileSpaceHistoryGatewayHostSchema = z$1.string().transform((value, ctx) => {
|
|
@@ -6459,9 +6808,9 @@ const profileSpaceHistoryStatusListSchema = z$1.union([profileSpaceHistoryStatus
|
|
|
6459
6808
|
return Array.isArray(value) ? value : [value];
|
|
6460
6809
|
});
|
|
6461
6810
|
const profileSpaceHistoryRecordSchema = z$1.strictObject({
|
|
6462
|
-
profileId: trimmedNonEmptyStringSchema$
|
|
6811
|
+
profileId: trimmedNonEmptyStringSchema$6,
|
|
6463
6812
|
gatewayHost: profileSpaceHistoryGatewayHostSchema,
|
|
6464
|
-
spaceId: trimmedNonEmptyStringSchema$
|
|
6813
|
+
spaceId: trimmedNonEmptyStringSchema$6,
|
|
6465
6814
|
spaceName: nullableTrimmedStringSchema$6,
|
|
6466
6815
|
creatorProfileId: nullableTrimmedStringSchema$6,
|
|
6467
6816
|
creatorKind: z$1.union([profileSpaceCreatorKindSchema, z$1.null()]),
|
|
@@ -6512,17 +6861,17 @@ z$1.strictObject({
|
|
|
6512
6861
|
reason: z$1.string().trim().min(1).max(500).optional()
|
|
6513
6862
|
});
|
|
6514
6863
|
const patchProfileSpaceHistoryStatusResponseSchema = z$1.strictObject({
|
|
6515
|
-
profileId: trimmedNonEmptyStringSchema$
|
|
6864
|
+
profileId: trimmedNonEmptyStringSchema$6,
|
|
6516
6865
|
gatewayHost: profileSpaceHistoryGatewayHostSchema,
|
|
6517
|
-
spaceId: trimmedNonEmptyStringSchema$
|
|
6866
|
+
spaceId: trimmedNonEmptyStringSchema$6,
|
|
6518
6867
|
status: profileSpaceHistoryStatusSchema,
|
|
6519
6868
|
updatedAt: ISO_DATE_TIME_SCHEMA$6
|
|
6520
6869
|
});
|
|
6521
6870
|
//#endregion
|
|
6522
6871
|
//#region ../../packages/schemas/dist/schemas/http/account-space-index.js
|
|
6523
6872
|
const ISO_DATE_TIME_SCHEMA$5 = z$1.iso.datetime({ offset: true });
|
|
6524
|
-
const trimmedNonEmptyStringSchema$
|
|
6525
|
-
const nullableTrimmedStringSchema$5 = z$1.union([trimmedNonEmptyStringSchema$
|
|
6873
|
+
const trimmedNonEmptyStringSchema$5 = z$1.string().trim().min(1);
|
|
6874
|
+
const nullableTrimmedStringSchema$5 = z$1.union([trimmedNonEmptyStringSchema$5, z$1.null()]);
|
|
6526
6875
|
const nullableNonNegativeIntSchema = z$1.union([z$1.number().int().min(0), z$1.null()]);
|
|
6527
6876
|
const nullableIsoDateTimeSchema$3 = z$1.union([ISO_DATE_TIME_SCHEMA$5, z$1.null()]);
|
|
6528
6877
|
const ACCOUNT_SPACE_INDEX_MAX_LIMIT = 500;
|
|
@@ -6556,24 +6905,24 @@ z$1.strictObject({
|
|
|
6556
6905
|
includePurposes: accountSpaceIndexIncludePurposesSchema,
|
|
6557
6906
|
limit: accountSpaceIndexLimitSchema,
|
|
6558
6907
|
scope: accountSpaceIndexScopeSchema.default("account"),
|
|
6559
|
-
selectedProfileId: trimmedNonEmptyStringSchema$
|
|
6908
|
+
selectedProfileId: trimmedNonEmptyStringSchema$5
|
|
6560
6909
|
});
|
|
6561
6910
|
const accountSpaceIndexJoinedProfileSchema = z$1.strictObject({
|
|
6562
6911
|
lastJoinedAt: ISO_DATE_TIME_SCHEMA$5,
|
|
6563
6912
|
pinnedAt: nullableIsoDateTimeSchema$3,
|
|
6564
|
-
profileId: trimmedNonEmptyStringSchema$
|
|
6565
|
-
profileName: trimmedNonEmptyStringSchema$
|
|
6913
|
+
profileId: trimmedNonEmptyStringSchema$5,
|
|
6914
|
+
profileName: trimmedNonEmptyStringSchema$5
|
|
6566
6915
|
});
|
|
6567
6916
|
const accountSpaceIndexItemSchema = z$1.strictObject({
|
|
6568
6917
|
messagePreview: z$1.strictObject({
|
|
6569
|
-
signalId: trimmedNonEmptyStringSchema$
|
|
6570
|
-
profileId: trimmedNonEmptyStringSchema$
|
|
6918
|
+
signalId: trimmedNonEmptyStringSchema$5,
|
|
6919
|
+
profileId: trimmedNonEmptyStringSchema$5,
|
|
6571
6920
|
timestamp: z$1.number().int().nonnegative(),
|
|
6572
6921
|
text: z$1.string().max(240)
|
|
6573
6922
|
}).nullable().optional(),
|
|
6574
6923
|
memberPreviews: z$1.array(z$1.strictObject({
|
|
6575
|
-
profileId: trimmedNonEmptyStringSchema$
|
|
6576
|
-
profileName: trimmedNonEmptyStringSchema$
|
|
6924
|
+
profileId: trimmedNonEmptyStringSchema$5,
|
|
6925
|
+
profileName: trimmedNonEmptyStringSchema$5,
|
|
6577
6926
|
profileKind: z$1.enum(["human", "agent"]),
|
|
6578
6927
|
agentControllerRef: nullableTrimmedStringSchema$5
|
|
6579
6928
|
})).max(3).optional(),
|
|
@@ -6585,29 +6934,29 @@ const accountSpaceIndexItemSchema = z$1.strictObject({
|
|
|
6585
6934
|
joinedProfiles: z$1.array(accountSpaceIndexJoinedProfileSchema),
|
|
6586
6935
|
lastJoinedAt: ISO_DATE_TIME_SCHEMA$5,
|
|
6587
6936
|
lastSeenTs: nullableNonNegativeIntSchema,
|
|
6588
|
-
openProfileId: trimmedNonEmptyStringSchema$
|
|
6589
|
-
openProfileName: trimmedNonEmptyStringSchema$
|
|
6590
|
-
organizationId: trimmedNonEmptyStringSchema$
|
|
6937
|
+
openProfileId: trimmedNonEmptyStringSchema$5,
|
|
6938
|
+
openProfileName: trimmedNonEmptyStringSchema$5,
|
|
6939
|
+
organizationId: trimmedNonEmptyStringSchema$5,
|
|
6591
6940
|
pinnedAt: nullableIsoDateTimeSchema$3,
|
|
6592
|
-
pinnedProfileIds: z$1.array(trimmedNonEmptyStringSchema$
|
|
6941
|
+
pinnedProfileIds: z$1.array(trimmedNonEmptyStringSchema$5),
|
|
6593
6942
|
spaceCreatedAt: nullableIsoDateTimeSchema$3,
|
|
6594
|
-
spaceId: trimmedNonEmptyStringSchema$
|
|
6595
|
-
spaceName: trimmedNonEmptyStringSchema$
|
|
6943
|
+
spaceId: trimmedNonEmptyStringSchema$5,
|
|
6944
|
+
spaceName: trimmedNonEmptyStringSchema$5,
|
|
6596
6945
|
activeAgentCount: nullableNonNegativeIntSchema.optional(),
|
|
6597
6946
|
activeHumanCount: nullableNonNegativeIntSchema.optional(),
|
|
6598
6947
|
activeMemberCount: nullableNonNegativeIntSchema.optional(),
|
|
6599
6948
|
directMessageConvertedAt: nullableIsoDateTimeSchema$3.optional(),
|
|
6600
|
-
directMessageProfileIds: z$1.union([z$1.tuple([trimmedNonEmptyStringSchema$
|
|
6949
|
+
directMessageProfileIds: z$1.union([z$1.tuple([trimmedNonEmptyStringSchema$5, trimmedNonEmptyStringSchema$5]), z$1.null()]).optional(),
|
|
6601
6950
|
spacePurpose: nullableTrimmedStringSchema$5.optional(),
|
|
6602
6951
|
spaceUpdatedAt: nullableIsoDateTimeSchema$3,
|
|
6603
|
-
status: trimmedNonEmptyStringSchema$
|
|
6952
|
+
status: trimmedNonEmptyStringSchema$5,
|
|
6604
6953
|
updatedAt: ISO_DATE_TIME_SCHEMA$5,
|
|
6605
6954
|
visibility: spaceOrganizationVisibilitySchema
|
|
6606
6955
|
});
|
|
6607
6956
|
const accountSpaceIndexDeletedItemSchema = z$1.strictObject({
|
|
6608
6957
|
deletedAt: ISO_DATE_TIME_SCHEMA$5,
|
|
6609
6958
|
deletedByProfileName: nullableTrimmedStringSchema$5,
|
|
6610
|
-
spaceId: trimmedNonEmptyStringSchema$
|
|
6959
|
+
spaceId: trimmedNonEmptyStringSchema$5,
|
|
6611
6960
|
spaceName: nullableTrimmedStringSchema$5
|
|
6612
6961
|
});
|
|
6613
6962
|
const accountSpaceIndexResponseSchema = z$1.strictObject({
|
|
@@ -6926,7 +7275,7 @@ const centerAgentModelRouteSchema = z$1.strictObject({
|
|
|
6926
7275
|
//#endregion
|
|
6927
7276
|
//#region ../../packages/schemas/dist/schemas/runtime/channel-context.js
|
|
6928
7277
|
const CHANNEL_CONTEXT_MESSAGE_TEXT_MAX_CHARS = 4e3;
|
|
6929
|
-
const nonEmptyStringSchema$
|
|
7278
|
+
const nonEmptyStringSchema$3 = z$1.string().trim().min(1);
|
|
6930
7279
|
const channelContextAuthorSchema = z$1.strictObject({
|
|
6931
7280
|
kind: z$1.enum([
|
|
6932
7281
|
"human",
|
|
@@ -6935,14 +7284,14 @@ const channelContextAuthorSchema = z$1.strictObject({
|
|
|
6935
7284
|
"system",
|
|
6936
7285
|
"unknown"
|
|
6937
7286
|
]),
|
|
6938
|
-
id: nonEmptyStringSchema$
|
|
6939
|
-
displayName: nonEmptyStringSchema$
|
|
7287
|
+
id: nonEmptyStringSchema$3.max(256).optional(),
|
|
7288
|
+
displayName: nonEmptyStringSchema$3.max(256).optional()
|
|
6940
7289
|
});
|
|
6941
7290
|
const channelContextMessageSchema = z$1.strictObject({
|
|
6942
|
-
id: nonEmptyStringSchema$
|
|
7291
|
+
id: nonEmptyStringSchema$3.max(256),
|
|
6943
7292
|
author: channelContextAuthorSchema,
|
|
6944
7293
|
sentAtMs: z$1.number().int().nonnegative().max(Number.MAX_SAFE_INTEGER),
|
|
6945
|
-
text: nonEmptyStringSchema$
|
|
7294
|
+
text: nonEmptyStringSchema$3.max(CHANNEL_CONTEXT_MESSAGE_TEXT_MAX_CHARS)
|
|
6946
7295
|
});
|
|
6947
7296
|
const channelContextSyncSchema = z$1.strictObject({
|
|
6948
7297
|
mode: z$1.enum(["snapshot", "delta"]),
|
|
@@ -6956,8 +7305,8 @@ const channelContextSyncSchema = z$1.strictObject({
|
|
|
6956
7305
|
});
|
|
6957
7306
|
const channelContextSchema = z$1.strictObject({
|
|
6958
7307
|
provider: messageChannelProviderSchema,
|
|
6959
|
-
conversationId: nonEmptyStringSchema$
|
|
6960
|
-
currentMessageId: nonEmptyStringSchema$
|
|
7308
|
+
conversationId: nonEmptyStringSchema$3.max(512),
|
|
7309
|
+
currentMessageId: nonEmptyStringSchema$3.max(256),
|
|
6961
7310
|
sync: channelContextSyncSchema,
|
|
6962
7311
|
messages: z$1.array(channelContextMessageSchema).max(20)
|
|
6963
7312
|
}).superRefine((context, refinement) => {
|
|
@@ -7009,7 +7358,7 @@ const channelContextSchema = z$1.strictObject({
|
|
|
7009
7358
|
});
|
|
7010
7359
|
//#endregion
|
|
7011
7360
|
//#region ../../packages/schemas/dist/schemas/runtime/remote-agent-turn-envelope.js
|
|
7012
|
-
const nonEmptyStringSchema$
|
|
7361
|
+
const nonEmptyStringSchema$2 = string().trim().min(1);
|
|
7013
7362
|
const REMOTE_AGENT_TURN_ENVELOPE_MEMORY_ITEM_TEXT_MAX_CHARS = 1200;
|
|
7014
7363
|
const remoteAgentWorkLoopCheckpointSchema = strictObject({
|
|
7015
7364
|
reason: literal("tool_call_budget_exhausted"),
|
|
@@ -7018,7 +7367,7 @@ const remoteAgentWorkLoopCheckpointSchema = strictObject({
|
|
|
7018
7367
|
});
|
|
7019
7368
|
const remoteAgentWorkLoopContinuationSchema = strictObject({
|
|
7020
7369
|
attempt: number().int().positive().max(8),
|
|
7021
|
-
previousSubmissionId: nonEmptyStringSchema$
|
|
7370
|
+
previousSubmissionId: nonEmptyStringSchema$2,
|
|
7022
7371
|
reason: literal("tool_call_budget_exhausted"),
|
|
7023
7372
|
v: literal(1)
|
|
7024
7373
|
});
|
|
@@ -7058,11 +7407,12 @@ const centerAgentContextScopePlanSchema = strictObject({
|
|
|
7058
7407
|
v: literal(1)
|
|
7059
7408
|
});
|
|
7060
7409
|
const remoteAgentTurnEnvelopePersonSenderShape = {
|
|
7061
|
-
|
|
7062
|
-
|
|
7063
|
-
|
|
7064
|
-
|
|
7065
|
-
|
|
7410
|
+
callerContext: spaceCallerContextSchema.optional(),
|
|
7411
|
+
id: nonEmptyStringSchema$2,
|
|
7412
|
+
displayName: nonEmptyStringSchema$2,
|
|
7413
|
+
ownerUserId: nonEmptyStringSchema$2.optional(),
|
|
7414
|
+
profileId: nonEmptyStringSchema$2.optional(),
|
|
7415
|
+
role: nonEmptyStringSchema$2.optional(),
|
|
7066
7416
|
messageChannelIdentity: messageChannelParticipantIdentitySchema.optional(),
|
|
7067
7417
|
verified: boolean()
|
|
7068
7418
|
};
|
|
@@ -7077,38 +7427,38 @@ const remoteAgentTurnEnvelopeSenderSchema = discriminatedUnion("kind", [
|
|
|
7077
7427
|
}),
|
|
7078
7428
|
strictObject({
|
|
7079
7429
|
kind: literal("routine"),
|
|
7080
|
-
routineId: nonEmptyStringSchema$
|
|
7081
|
-
createdByUserId: nonEmptyStringSchema$
|
|
7430
|
+
routineId: nonEmptyStringSchema$2,
|
|
7431
|
+
createdByUserId: nonEmptyStringSchema$2,
|
|
7082
7432
|
delegatedBy: strictObject({
|
|
7083
|
-
id: nonEmptyStringSchema$
|
|
7084
|
-
displayName: nonEmptyStringSchema$
|
|
7085
|
-
ownerUserId: nonEmptyStringSchema$
|
|
7086
|
-
profileId: nonEmptyStringSchema$
|
|
7087
|
-
role: nonEmptyStringSchema$
|
|
7433
|
+
id: nonEmptyStringSchema$2,
|
|
7434
|
+
displayName: nonEmptyStringSchema$2,
|
|
7435
|
+
ownerUserId: nonEmptyStringSchema$2,
|
|
7436
|
+
profileId: nonEmptyStringSchema$2.optional(),
|
|
7437
|
+
role: nonEmptyStringSchema$2.optional(),
|
|
7088
7438
|
verified: literal(true)
|
|
7089
7439
|
})
|
|
7090
7440
|
})
|
|
7091
7441
|
]);
|
|
7092
7442
|
const remoteAgentTurnEnvelopeSpaceSchema = strictObject({
|
|
7093
|
-
id: nonEmptyStringSchema$
|
|
7094
|
-
name: nonEmptyStringSchema$
|
|
7443
|
+
id: nonEmptyStringSchema$2,
|
|
7444
|
+
name: nonEmptyStringSchema$2,
|
|
7095
7445
|
kind: enumFactory(["dm", "space"]),
|
|
7096
7446
|
isCenterAgentDm: boolean(),
|
|
7097
|
-
guide: nonEmptyStringSchema$
|
|
7447
|
+
guide: nonEmptyStringSchema$2.max(MAX_SPACE_GUIDE_LENGTH).optional()
|
|
7098
7448
|
});
|
|
7099
7449
|
const remoteAgentTurnEnvelopeOrganizationSchema = strictObject({
|
|
7100
|
-
id: nonEmptyStringSchema$
|
|
7101
|
-
name: nonEmptyStringSchema$
|
|
7450
|
+
id: nonEmptyStringSchema$2,
|
|
7451
|
+
name: nonEmptyStringSchema$2,
|
|
7102
7452
|
personal: boolean(),
|
|
7103
7453
|
memberCount: number().int().nonnegative(),
|
|
7104
7454
|
webUrl: openMeldWebUrlSchema.optional(),
|
|
7105
7455
|
workingLanguage: workingLanguageGuidanceSchema.optional()
|
|
7106
7456
|
});
|
|
7107
7457
|
const remoteAgentTurnEnvelopeCenterAgentSchema = strictObject({
|
|
7108
|
-
profileName: nonEmptyStringSchema$
|
|
7109
|
-
profileHandle: nonEmptyStringSchema$
|
|
7458
|
+
profileName: nonEmptyStringSchema$2,
|
|
7459
|
+
profileHandle: nonEmptyStringSchema$2
|
|
7110
7460
|
});
|
|
7111
|
-
const remoteAgentSlackSearchAuthorizationSchema = strictObject({ encryptedAuthorization: nonEmptyStringSchema$
|
|
7461
|
+
const remoteAgentSlackSearchAuthorizationSchema = strictObject({ encryptedAuthorization: nonEmptyStringSchema$2.max(8192) });
|
|
7112
7462
|
const remoteAgentRoutineDestinationSchema = discriminatedUnion("kind", [
|
|
7113
7463
|
strictObject({
|
|
7114
7464
|
kind: literal("message_channel"),
|
|
@@ -7116,22 +7466,22 @@ const remoteAgentRoutineDestinationSchema = discriminatedUnion("kind", [
|
|
|
7116
7466
|
}),
|
|
7117
7467
|
strictObject({
|
|
7118
7468
|
kind: literal("space"),
|
|
7119
|
-
spaceId: nonEmptyStringSchema$
|
|
7469
|
+
spaceId: nonEmptyStringSchema$2
|
|
7120
7470
|
}),
|
|
7121
7471
|
strictObject({
|
|
7122
|
-
channelId: nonEmptyStringSchema$
|
|
7123
|
-
conversationId: nonEmptyStringSchema$
|
|
7472
|
+
channelId: nonEmptyStringSchema$2,
|
|
7473
|
+
conversationId: nonEmptyStringSchema$2,
|
|
7124
7474
|
kind: literal("slack_thread"),
|
|
7125
|
-
label: nonEmptyStringSchema$
|
|
7126
|
-
teamId: nonEmptyStringSchema$
|
|
7127
|
-
threadTs: nonEmptyStringSchema$
|
|
7475
|
+
label: nonEmptyStringSchema$2.optional(),
|
|
7476
|
+
teamId: nonEmptyStringSchema$2,
|
|
7477
|
+
threadTs: nonEmptyStringSchema$2
|
|
7128
7478
|
})
|
|
7129
7479
|
]);
|
|
7130
7480
|
const remoteAgentRoutineContinuationSchema = strictObject({
|
|
7131
7481
|
delegation: agentDelegationSnapshotSchema,
|
|
7132
|
-
delegationId: nonEmptyStringSchema$
|
|
7482
|
+
delegationId: nonEmptyStringSchema$2,
|
|
7133
7483
|
outcome: agentTaskTerminalOutcomeSchema,
|
|
7134
|
-
subscriptionId: nonEmptyStringSchema$
|
|
7484
|
+
subscriptionId: nonEmptyStringSchema$2,
|
|
7135
7485
|
watchedTask: agentTaskHandleSchema
|
|
7136
7486
|
});
|
|
7137
7487
|
const remoteAgentTurnEnvelopeTriggerSchema = discriminatedUnion("source", [
|
|
@@ -7139,11 +7489,11 @@ const remoteAgentTurnEnvelopeTriggerSchema = discriminatedUnion("source", [
|
|
|
7139
7489
|
strictObject({ source: literal("space_wake") }),
|
|
7140
7490
|
strictObject({
|
|
7141
7491
|
source: literal("slack"),
|
|
7142
|
-
teamId: nonEmptyStringSchema$
|
|
7143
|
-
channelId: nonEmptyStringSchema$
|
|
7144
|
-
threadTs: nonEmptyStringSchema$
|
|
7145
|
-
conversationId: nonEmptyStringSchema$
|
|
7146
|
-
channelName: nonEmptyStringSchema$
|
|
7492
|
+
teamId: nonEmptyStringSchema$2.optional(),
|
|
7493
|
+
channelId: nonEmptyStringSchema$2.optional(),
|
|
7494
|
+
threadTs: nonEmptyStringSchema$2.optional(),
|
|
7495
|
+
conversationId: nonEmptyStringSchema$2.optional(),
|
|
7496
|
+
channelName: nonEmptyStringSchema$2.optional(),
|
|
7147
7497
|
replyPlacement: enumFactory(["conversation", "thread"]).optional(),
|
|
7148
7498
|
searchAuthorization: remoteAgentSlackSearchAuthorizationSchema.optional()
|
|
7149
7499
|
}),
|
|
@@ -7151,8 +7501,8 @@ const remoteAgentTurnEnvelopeTriggerSchema = discriminatedUnion("source", [
|
|
|
7151
7501
|
source: literal("message_channel"),
|
|
7152
7502
|
routineLocator: messageChannelConversationLocatorSchema.optional(),
|
|
7153
7503
|
provider: messageChannelProviderSchema,
|
|
7154
|
-
connectionId: nonEmptyStringSchema$
|
|
7155
|
-
conversationId: nonEmptyStringSchema$
|
|
7504
|
+
connectionId: nonEmptyStringSchema$2,
|
|
7505
|
+
conversationId: nonEmptyStringSchema$2,
|
|
7156
7506
|
filePublicationSupported: literal(true).optional(),
|
|
7157
7507
|
resources: array(messageChannelResourceDescriptorSchema).max(10).optional()
|
|
7158
7508
|
}),
|
|
@@ -7160,33 +7510,33 @@ const remoteAgentTurnEnvelopeTriggerSchema = discriminatedUnion("source", [
|
|
|
7160
7510
|
authorizedActions: centerAgentRoutineAuthorizedActionsSchema.default([]),
|
|
7161
7511
|
externalActionPolicy: centerAgentRoutineExternalActionPolicySchema.optional(),
|
|
7162
7512
|
source: literal("routine"),
|
|
7163
|
-
routineId: nonEmptyStringSchema$
|
|
7164
|
-
runId: nonEmptyStringSchema$
|
|
7513
|
+
routineId: nonEmptyStringSchema$2,
|
|
7514
|
+
runId: nonEmptyStringSchema$2,
|
|
7165
7515
|
scheduledFor: number().int().nonnegative(),
|
|
7166
|
-
routineName: nonEmptyStringSchema$
|
|
7516
|
+
routineName: nonEmptyStringSchema$2.max(120),
|
|
7167
7517
|
destination: remoteAgentRoutineDestinationSchema.optional(),
|
|
7168
7518
|
continuation: remoteAgentRoutineContinuationSchema.optional()
|
|
7169
7519
|
}),
|
|
7170
7520
|
strictObject({
|
|
7171
7521
|
source: literal("member_research"),
|
|
7172
|
-
taskId: nonEmptyStringSchema$
|
|
7173
|
-
subjectUserId: nonEmptyStringSchema$
|
|
7174
|
-
subjectDisplayName: nonEmptyStringSchema$
|
|
7522
|
+
taskId: nonEmptyStringSchema$2,
|
|
7523
|
+
subjectUserId: nonEmptyStringSchema$2,
|
|
7524
|
+
subjectDisplayName: nonEmptyStringSchema$2
|
|
7175
7525
|
}),
|
|
7176
7526
|
strictObject({
|
|
7177
7527
|
delegation: agentDelegationSnapshotSchema.optional(),
|
|
7178
|
-
delegationId: nonEmptyStringSchema$
|
|
7528
|
+
delegationId: nonEmptyStringSchema$2,
|
|
7179
7529
|
outcome: agentTaskTerminalOutcomeSchema,
|
|
7180
7530
|
source: literal("task_continuation"),
|
|
7181
|
-
subscriptionId: nonEmptyStringSchema$
|
|
7531
|
+
subscriptionId: nonEmptyStringSchema$2,
|
|
7182
7532
|
watchedTask: agentTaskHandleSchema
|
|
7183
7533
|
}),
|
|
7184
7534
|
strictObject({
|
|
7185
7535
|
outcome: agentTaskCompletionObservationSchema,
|
|
7186
7536
|
source: literal("task_watch_continuation"),
|
|
7187
|
-
subscriptionId: nonEmptyStringSchema$
|
|
7537
|
+
subscriptionId: nonEmptyStringSchema$2,
|
|
7188
7538
|
watchedTask: agentTaskHandleSchema,
|
|
7189
|
-
watchId: nonEmptyStringSchema$
|
|
7539
|
+
watchId: nonEmptyStringSchema$2
|
|
7190
7540
|
})
|
|
7191
7541
|
]);
|
|
7192
7542
|
enumFactory([
|
|
@@ -7197,7 +7547,7 @@ enumFactory([
|
|
|
7197
7547
|
"message_channel_conversation"
|
|
7198
7548
|
]);
|
|
7199
7549
|
const remoteAgentTurnEnvelopeMemorySubjectSchema = enumFactory(["member", "organization"]);
|
|
7200
|
-
const remoteAgentTurnEnvelopeMemoryItemTextSchema = nonEmptyStringSchema$
|
|
7550
|
+
const remoteAgentTurnEnvelopeMemoryItemTextSchema = nonEmptyStringSchema$2.max(REMOTE_AGENT_TURN_ENVELOPE_MEMORY_ITEM_TEXT_MAX_CHARS);
|
|
7201
7551
|
const remoteAgentTurnEnvelopeMemorySchema = strictObject({
|
|
7202
7552
|
items: array(discriminatedUnion("source", [strictObject({
|
|
7203
7553
|
source: enumFactory([
|
|
@@ -7341,179 +7691,6 @@ function validateTaskContinuationTrigger(trigger, context) {
|
|
|
7341
7691
|
path: ["trigger", "outcome"]
|
|
7342
7692
|
});
|
|
7343
7693
|
}
|
|
7344
|
-
const CONNECTOR_SERVICES = ["github", ...[
|
|
7345
|
-
"feishu",
|
|
7346
|
-
"lark",
|
|
7347
|
-
"gmail",
|
|
7348
|
-
"googlecalendar",
|
|
7349
|
-
"googledrive",
|
|
7350
|
-
"notion",
|
|
7351
|
-
"linear",
|
|
7352
|
-
"figma",
|
|
7353
|
-
"posthog",
|
|
7354
|
-
"cloudflare_browser_rendering",
|
|
7355
|
-
"cloudflare_dns",
|
|
7356
|
-
"cloudflare_r2",
|
|
7357
|
-
"cloudflare_worker"
|
|
7358
|
-
]];
|
|
7359
|
-
const CONNECTOR_CONNECTION_STATUSES = [
|
|
7360
|
-
"pending",
|
|
7361
|
-
"active",
|
|
7362
|
-
"disconnected"
|
|
7363
|
-
];
|
|
7364
|
-
const CONNECTOR_CONNECTION_SCOPES = ["member", "shared"];
|
|
7365
|
-
const CONNECTOR_CONNECTION_PREFERENCES = [
|
|
7366
|
-
"automatic",
|
|
7367
|
-
"requester",
|
|
7368
|
-
"shared"
|
|
7369
|
-
];
|
|
7370
|
-
const CONNECTOR_APP_REQUEST_SOURCES = ["openconnector_catalog", "freeform"];
|
|
7371
|
-
const CONNECTOR_APP_REQUEST_STATUSES = [
|
|
7372
|
-
"requested",
|
|
7373
|
-
"available",
|
|
7374
|
-
"declined"
|
|
7375
|
-
];
|
|
7376
|
-
const trimmedNonEmptyStringSchema$5 = string().trim().min(1);
|
|
7377
|
-
const timestampMsSchema$1 = number().int().nonnegative();
|
|
7378
|
-
const connectorCredentialValueSchema = string().min(1).max(8192);
|
|
7379
|
-
const connectorAppRequestOptionalTextSchema = string().trim().min(1).max(2e3).nullable();
|
|
7380
|
-
const connectorAppRequestedCapabilitiesSchema = array(string().trim().min(1).max(80)).max(12);
|
|
7381
|
-
const connectorServiceSchema = enumFactory(CONNECTOR_SERVICES);
|
|
7382
|
-
const connectorConnectionStatusSchema = enumFactory(CONNECTOR_CONNECTION_STATUSES);
|
|
7383
|
-
const connectorConnectionScopeSchema = enumFactory(CONNECTOR_CONNECTION_SCOPES);
|
|
7384
|
-
enumFactory(CONNECTOR_CONNECTION_PREFERENCES);
|
|
7385
|
-
const connectorAppRequestSourceSchema = enumFactory(CONNECTOR_APP_REQUEST_SOURCES);
|
|
7386
|
-
const connectorAppRequestStatusSchema = enumFactory(CONNECTOR_APP_REQUEST_STATUSES);
|
|
7387
|
-
const connectorConnectionNameSchema = string().regex(/^[a-zA-Z0-9][a-zA-Z0-9_-]{0,63}$/u);
|
|
7388
|
-
const githubAppInstallationStateSchema = string().regex(/^githubapp_[0-9a-f]{64}$/u);
|
|
7389
|
-
const githubAppInstallationIdSchema = string().regex(/^[1-9][0-9]*$/u);
|
|
7390
|
-
const connectorConnectionSchema = strictObject({
|
|
7391
|
-
canDisconnect: boolean(),
|
|
7392
|
-
connectionName: connectorConnectionNameSchema,
|
|
7393
|
-
createdAtMs: timestampMsSchema$1,
|
|
7394
|
-
disconnectedAtMs: timestampMsSchema$1.nullable(),
|
|
7395
|
-
organizationId: trimmedNonEmptyStringSchema$5,
|
|
7396
|
-
ownerDisplayName: trimmedNonEmptyStringSchema$5,
|
|
7397
|
-
scope: connectorConnectionScopeSchema.default("member"),
|
|
7398
|
-
service: connectorServiceSchema,
|
|
7399
|
-
status: connectorConnectionStatusSchema,
|
|
7400
|
-
updatedAtMs: timestampMsSchema$1,
|
|
7401
|
-
userId: trimmedNonEmptyStringSchema$5
|
|
7402
|
-
});
|
|
7403
|
-
strictObject({
|
|
7404
|
-
connections: array(connectorConnectionSchema),
|
|
7405
|
-
currentUserId: trimmedNonEmptyStringSchema$5,
|
|
7406
|
-
organizationId: trimmedNonEmptyStringSchema$5
|
|
7407
|
-
});
|
|
7408
|
-
const connectorAppRequestSchema = strictObject({
|
|
7409
|
-
availableAtMs: timestampMsSchema$1.nullable(),
|
|
7410
|
-
createdAtMs: timestampMsSchema$1,
|
|
7411
|
-
id: string().trim().min(1).max(128),
|
|
7412
|
-
notifiedAtMs: timestampMsSchema$1.nullable(),
|
|
7413
|
-
organizationId: trimmedNonEmptyStringSchema$5,
|
|
7414
|
-
providerId: string().trim().min(1).max(160).nullable(),
|
|
7415
|
-
providerName: string().trim().min(1).max(120),
|
|
7416
|
-
requestedCapabilities: connectorAppRequestedCapabilitiesSchema,
|
|
7417
|
-
requesterMemberId: trimmedNonEmptyStringSchema$5.nullable(),
|
|
7418
|
-
requesterUserId: trimmedNonEmptyStringSchema$5.nullable(),
|
|
7419
|
-
source: connectorAppRequestSourceSchema,
|
|
7420
|
-
status: connectorAppRequestStatusSchema,
|
|
7421
|
-
updatedAtMs: timestampMsSchema$1,
|
|
7422
|
-
useCase: connectorAppRequestOptionalTextSchema
|
|
7423
|
-
});
|
|
7424
|
-
strictObject({
|
|
7425
|
-
providerId: string().trim().min(1).max(160).nullable().optional(),
|
|
7426
|
-
providerName: string().trim().min(1).max(120),
|
|
7427
|
-
requestedCapabilities: connectorAppRequestedCapabilitiesSchema.optional(),
|
|
7428
|
-
source: connectorAppRequestSourceSchema,
|
|
7429
|
-
useCase: connectorAppRequestOptionalTextSchema.optional()
|
|
7430
|
-
}).superRefine((input, context) => {
|
|
7431
|
-
if (input.source === "openconnector_catalog" && !input.providerId?.trim()) context.addIssue({
|
|
7432
|
-
code: "custom",
|
|
7433
|
-
message: "A catalog Plugin request requires its OpenConnector provider ID.",
|
|
7434
|
-
path: ["providerId"]
|
|
7435
|
-
});
|
|
7436
|
-
if (input.source === "freeform" && input.providerId != null) context.addIssue({
|
|
7437
|
-
code: "custom",
|
|
7438
|
-
message: "A freeform Plugin request cannot include a provider ID.",
|
|
7439
|
-
path: ["providerId"]
|
|
7440
|
-
});
|
|
7441
|
-
});
|
|
7442
|
-
strictObject({ request: connectorAppRequestSchema });
|
|
7443
|
-
strictObject({
|
|
7444
|
-
currentUserId: trimmedNonEmptyStringSchema$5,
|
|
7445
|
-
organizationId: trimmedNonEmptyStringSchema$5,
|
|
7446
|
-
requests: array(connectorAppRequestSchema).max(500)
|
|
7447
|
-
});
|
|
7448
|
-
strictObject({
|
|
7449
|
-
organizationId: trimmedNonEmptyStringSchema$5,
|
|
7450
|
-
providers: array(strictObject({
|
|
7451
|
-
authTypes: array(string().trim().min(1).max(80)).max(12),
|
|
7452
|
-
categories: array(strictObject({
|
|
7453
|
-
displayName: string().trim().min(1).max(120),
|
|
7454
|
-
id: string().trim().min(1).max(120)
|
|
7455
|
-
})).max(12),
|
|
7456
|
-
displayName: string().trim().min(1).max(120),
|
|
7457
|
-
homepageUrl: url().nullable(),
|
|
7458
|
-
iconUrl: url().nullable(),
|
|
7459
|
-
service: string().trim().min(1).max(160)
|
|
7460
|
-
})).max(5e3)
|
|
7461
|
-
});
|
|
7462
|
-
strictObject({
|
|
7463
|
-
authorizationUrl: url(),
|
|
7464
|
-
connection: connectorConnectionSchema,
|
|
7465
|
-
expiresAtMs: timestampMsSchema$1.optional()
|
|
7466
|
-
});
|
|
7467
|
-
strictObject({
|
|
7468
|
-
connection: connectorConnectionSchema,
|
|
7469
|
-
expiresAtMs: timestampMsSchema$1,
|
|
7470
|
-
state: githubAppInstallationStateSchema
|
|
7471
|
-
});
|
|
7472
|
-
strictObject({
|
|
7473
|
-
installation_id: githubAppInstallationIdSchema,
|
|
7474
|
-
setup_action: string().trim().min(1).max(64).optional(),
|
|
7475
|
-
state: githubAppInstallationStateSchema
|
|
7476
|
-
});
|
|
7477
|
-
discriminatedUnion("status", [
|
|
7478
|
-
strictObject({
|
|
7479
|
-
actorProfileId: trimmedNonEmptyStringSchema$5,
|
|
7480
|
-
installationId: githubAppInstallationIdSchema,
|
|
7481
|
-
organizationId: trimmedNonEmptyStringSchema$5,
|
|
7482
|
-
status: literal("valid"),
|
|
7483
|
-
targetConnectionName: connectorConnectionNameSchema,
|
|
7484
|
-
userId: trimmedNonEmptyStringSchema$5,
|
|
7485
|
-
verificationConnectionName: connectorConnectionNameSchema
|
|
7486
|
-
}),
|
|
7487
|
-
strictObject({ status: literal("expired") }),
|
|
7488
|
-
strictObject({ status: literal("invalid") })
|
|
7489
|
-
]);
|
|
7490
|
-
strictObject({
|
|
7491
|
-
installationId: githubAppInstallationIdSchema,
|
|
7492
|
-
organizationId: trimmedNonEmptyStringSchema$5,
|
|
7493
|
-
status: literal("verifying"),
|
|
7494
|
-
targetConnectionName: connectorConnectionNameSchema,
|
|
7495
|
-
userId: trimmedNonEmptyStringSchema$5,
|
|
7496
|
-
verificationConnectionName: connectorConnectionNameSchema
|
|
7497
|
-
}).nullable();
|
|
7498
|
-
strictObject({
|
|
7499
|
-
authType: enumFactory(["api_key", "custom_credential"]),
|
|
7500
|
-
values: record(string().regex(/^[a-zA-Z][a-zA-Z0-9_]{0,63}$/u), connectorCredentialValueSchema).refine((values) => Object.keys(values).length > 0, { message: "At least one credential value is required." }).refine((values) => Object.keys(values).length <= 16, { message: "Too many credential values." })
|
|
7501
|
-
});
|
|
7502
|
-
strictObject({ connection: connectorConnectionSchema });
|
|
7503
|
-
strictObject({
|
|
7504
|
-
expectedOrganizationId: trimmedNonEmptyStringSchema$5,
|
|
7505
|
-
includeAuthorizationExpiry: literal("true").optional()
|
|
7506
|
-
});
|
|
7507
|
-
strictObject({ userId: trimmedNonEmptyStringSchema$5 });
|
|
7508
|
-
strictObject({ connection: connectorConnectionSchema });
|
|
7509
|
-
strictObject({
|
|
7510
|
-
availableConnectionNames: array(connectorConnectionNameSchema).max(500),
|
|
7511
|
-
service: connectorServiceSchema
|
|
7512
|
-
});
|
|
7513
|
-
strictObject({
|
|
7514
|
-
connection: connectorConnectionSchema.nullable(),
|
|
7515
|
-
selection: enumFactory(["requester", "shared"]).nullable()
|
|
7516
|
-
});
|
|
7517
7694
|
//#endregion
|
|
7518
7695
|
//#region ../../packages/schemas/dist/schemas/http/owner-computer-diagnostics.js
|
|
7519
7696
|
const boundedDiagnosticCodeSchema = z$1.string().trim().min(1).max(256);
|
|
@@ -8172,6 +8349,8 @@ const getSpaceStatusResponseSchema = z$1.object({
|
|
|
8172
8349
|
spacePurpose: optionalTrimmedStringSchema$1,
|
|
8173
8350
|
directMessageConvertedAt: isoDateTimeSchema$2.optional(),
|
|
8174
8351
|
organizationVisibility: spaceOrganizationVisibilitySchema.optional(),
|
|
8352
|
+
ownerUserIds: z$1.array(z$1.string().min(1)).optional(),
|
|
8353
|
+
allowGuests: z$1.boolean().optional(),
|
|
8175
8354
|
accessMode: spaceAccessModeSchema,
|
|
8176
8355
|
passwordProtected: z$1.boolean(),
|
|
8177
8356
|
dispatchPolicy: spaceDispatchPolicySchema,
|
|
@@ -8196,6 +8375,7 @@ const optionalThreadSignalLimitSchema = z$1.preprocess((value) => {
|
|
|
8196
8375
|
return decimalIntegerPattern.test(normalized) ? Number.parseInt(normalized, 10) : NaN;
|
|
8197
8376
|
}, z$1.number().int().min(1).max(100).optional());
|
|
8198
8377
|
const listSpaceThreadSignalsQuerySchema = z$1.strictObject({
|
|
8378
|
+
includeWakeContinuation: z$1.preprocess((value) => value === "true" ? true : value, z$1.union([z$1.literal(true), z$1.literal("conversation")]).optional()),
|
|
8199
8379
|
afterSignalId: optionalThreadSignalAnchorSchema,
|
|
8200
8380
|
limit: optionalThreadSignalLimitSchema
|
|
8201
8381
|
}).superRefine((value, ctx) => {
|
|
@@ -8230,10 +8410,15 @@ const listSpaceThreadsResponseSchema = z$1.strictObject({
|
|
|
8230
8410
|
previews: z$1.array(spaceThreadPreviewSchema).default([])
|
|
8231
8411
|
});
|
|
8232
8412
|
const listSpaceThreadSignalsResponseSchema = z$1.strictObject({
|
|
8413
|
+
wakeContinuation: z$1.strictObject({
|
|
8414
|
+
targetProfileId: z$1.string().min(1).nullable(),
|
|
8415
|
+
automaticTargetProfileId: z$1.string().min(1).nullable().optional()
|
|
8416
|
+
}).optional(),
|
|
8233
8417
|
signals: z$1.array(signalEnvelopeSchema),
|
|
8234
8418
|
placements: z$1.array(spaceThreadSignalPlacementSchema)
|
|
8235
8419
|
});
|
|
8236
8420
|
const postSpaceThreadSignalBodySchema = z$1.strictObject({
|
|
8421
|
+
threadWakeContinuation: z$1.literal(true).optional(),
|
|
8237
8422
|
text: signalTextSchema.shape.data.shape.text,
|
|
8238
8423
|
deviceWait: signalTextSchema.shape.data.shape.deviceWait.optional(),
|
|
8239
8424
|
files: signalTextSchema.shape.data.shape.files.optional(),
|
|
@@ -8364,10 +8549,10 @@ const createSpaceBodySchema = z$1.strictObject({
|
|
|
8364
8549
|
});
|
|
8365
8550
|
//#endregion
|
|
8366
8551
|
//#region ../../packages/schemas/dist/schemas/runtime/remote-agent-worker.js
|
|
8367
|
-
const nonEmptyStringSchema = string().trim().min(1);
|
|
8368
|
-
const optionalNonEmptyStringSchema = nonEmptyStringSchema.optional();
|
|
8369
|
-
const nullableNonEmptyStringSchema = nonEmptyStringSchema.nullable();
|
|
8370
|
-
const optionalDispatchErrorSummarySchema = nonEmptyStringSchema.max(512).optional();
|
|
8552
|
+
const nonEmptyStringSchema$1 = string().trim().min(1);
|
|
8553
|
+
const optionalNonEmptyStringSchema = nonEmptyStringSchema$1.optional();
|
|
8554
|
+
const nullableNonEmptyStringSchema = nonEmptyStringSchema$1.nullable();
|
|
8555
|
+
const optionalDispatchErrorSummarySchema = nonEmptyStringSchema$1.max(512).optional();
|
|
8371
8556
|
const REMOTE_AGENT_CONVERSATION_CONTINUITY_ENTRY_TEXT_MAX_CHARS = 4e3;
|
|
8372
8557
|
const REMOTE_AGENT_LOGICAL_CONVERSATION_ID_MAX_CHARS = 1024;
|
|
8373
8558
|
const REMOTE_AGENT_RUNTIME_CONVERSATION_ID_MAX_CHARS = 2048;
|
|
@@ -8379,14 +8564,14 @@ function buildPersonalRemoteAgentConversationId(input) {
|
|
|
8379
8564
|
input.organizationId,
|
|
8380
8565
|
input.agentProfileId,
|
|
8381
8566
|
input.spaceId
|
|
8382
|
-
].map((value) => nonEmptyStringSchema.max(256).parse(value)).map((value) => `${value.length}:${value}`)].join("|");
|
|
8567
|
+
].map((value) => nonEmptyStringSchema$1.max(256).parse(value)).map((value) => `${value.length}:${value}`)].join("|");
|
|
8383
8568
|
}
|
|
8384
8569
|
function buildRemoteAgentRuntimeConversationId(input) {
|
|
8385
|
-
const organizationId = nonEmptyStringSchema.max(256).parse(input.organizationId);
|
|
8386
|
-
const logicalConversationId = nonEmptyStringSchema.max(REMOTE_AGENT_LOGICAL_CONVERSATION_ID_MAX_CHARS).parse(input.logicalConversationId);
|
|
8570
|
+
const organizationId = nonEmptyStringSchema$1.max(256).parse(input.organizationId);
|
|
8571
|
+
const logicalConversationId = nonEmptyStringSchema$1.max(REMOTE_AGENT_LOGICAL_CONVERSATION_ID_MAX_CHARS).parse(input.logicalConversationId);
|
|
8387
8572
|
const generation = number().int().nonnegative().parse(input.generation);
|
|
8388
8573
|
if (generation === 0) return logicalConversationId;
|
|
8389
|
-
return nonEmptyStringSchema.max(REMOTE_AGENT_RUNTIME_CONVERSATION_ID_MAX_CHARS).parse([
|
|
8574
|
+
return nonEmptyStringSchema$1.max(REMOTE_AGENT_RUNTIME_CONVERSATION_ID_MAX_CHARS).parse([
|
|
8390
8575
|
"remote-agent-runtime-generation.v1",
|
|
8391
8576
|
`${organizationId.length}:${organizationId}`,
|
|
8392
8577
|
`${logicalConversationId.length}:${logicalConversationId}`,
|
|
@@ -8395,13 +8580,13 @@ function buildRemoteAgentRuntimeConversationId(input) {
|
|
|
8395
8580
|
}
|
|
8396
8581
|
const remoteAgentConversationContinuityEntrySourceSchema = discriminatedUnion("kind", [strictObject({
|
|
8397
8582
|
kind: literal("space_signal"),
|
|
8398
|
-
signalId: nonEmptyStringSchema.max(256),
|
|
8399
|
-
spaceId: nonEmptyStringSchema.max(256),
|
|
8583
|
+
signalId: nonEmptyStringSchema$1.max(256),
|
|
8584
|
+
spaceId: nonEmptyStringSchema$1.max(256),
|
|
8400
8585
|
version: contentHashSchema
|
|
8401
8586
|
}), strictObject({
|
|
8402
|
-
conversationId: nonEmptyStringSchema.max(512),
|
|
8587
|
+
conversationId: nonEmptyStringSchema$1.max(512),
|
|
8403
8588
|
kind: literal("message_channel_message"),
|
|
8404
|
-
messageId: nonEmptyStringSchema.max(256),
|
|
8589
|
+
messageId: nonEmptyStringSchema$1.max(256),
|
|
8405
8590
|
provider: enumFactory([
|
|
8406
8591
|
"feishu",
|
|
8407
8592
|
"lark",
|
|
@@ -8411,8 +8596,8 @@ const remoteAgentConversationContinuityEntrySourceSchema = discriminatedUnion("k
|
|
|
8411
8596
|
const remoteAgentConversationContinuityContextSchema = strictObject({
|
|
8412
8597
|
entries: array(strictObject({
|
|
8413
8598
|
author: strictObject({
|
|
8414
|
-
displayName: nonEmptyStringSchema.max(256).optional(),
|
|
8415
|
-
id: nonEmptyStringSchema.max(256).optional(),
|
|
8599
|
+
displayName: nonEmptyStringSchema$1.max(256).optional(),
|
|
8600
|
+
id: nonEmptyStringSchema$1.max(256).optional(),
|
|
8416
8601
|
kind: enumFactory([
|
|
8417
8602
|
"agent",
|
|
8418
8603
|
"bot",
|
|
@@ -8444,7 +8629,7 @@ const remoteAgentConversationContinuityContextSchema = strictObject({
|
|
|
8444
8629
|
});
|
|
8445
8630
|
})).min(1).max(20),
|
|
8446
8631
|
fromGeneration: number().int().nonnegative(),
|
|
8447
|
-
logicalConversationId: nonEmptyStringSchema.max(REMOTE_AGENT_LOGICAL_CONVERSATION_ID_MAX_CHARS),
|
|
8632
|
+
logicalConversationId: nonEmptyStringSchema$1.max(REMOTE_AGENT_LOGICAL_CONVERSATION_ID_MAX_CHARS),
|
|
8448
8633
|
toGeneration: number().int().positive(),
|
|
8449
8634
|
truncated: boolean(),
|
|
8450
8635
|
v: literal(1)
|
|
@@ -8462,7 +8647,7 @@ const remoteAgentConversationContinuityContextSchema = strictObject({
|
|
|
8462
8647
|
});
|
|
8463
8648
|
const remoteAgentRuntimeConversationSchema = strictObject({
|
|
8464
8649
|
generation: number().int().nonnegative(),
|
|
8465
|
-
id: nonEmptyStringSchema.max(REMOTE_AGENT_RUNTIME_CONVERSATION_ID_MAX_CHARS)
|
|
8650
|
+
id: nonEmptyStringSchema$1.max(REMOTE_AGENT_RUNTIME_CONVERSATION_ID_MAX_CHARS)
|
|
8466
8651
|
});
|
|
8467
8652
|
const REMOTE_AGENT_STREAM_DELTA_MAX_CHARS = 1024;
|
|
8468
8653
|
enumFactory(Object.values({
|
|
@@ -8510,7 +8695,7 @@ const remoteAgentRuntimeEvidenceReasonCodeSchema = enumFactory(Object.values({
|
|
|
8510
8695
|
TURN_TIMEOUT: "remote_agent.turn.timeout"
|
|
8511
8696
|
}));
|
|
8512
8697
|
const remoteAgentWorkerSubmitMessagesResultSchema = strictObject({
|
|
8513
|
-
submissionId: nonEmptyStringSchema,
|
|
8698
|
+
submissionId: nonEmptyStringSchema$1,
|
|
8514
8699
|
idempotencyKey: optionalNonEmptyStringSchema,
|
|
8515
8700
|
requestId: optionalNonEmptyStringSchema,
|
|
8516
8701
|
status: enumFactory([
|
|
@@ -8536,8 +8721,8 @@ const remoteAgentWorkerAdmissionRejectionCodeSchema = enumFactory([
|
|
|
8536
8721
|
]);
|
|
8537
8722
|
union([remoteAgentRuntimeEvidenceReasonCodeSchema, remoteAgentWorkerAdmissionRejectionCodeSchema]);
|
|
8538
8723
|
union([remoteAgentWorkerSubmitMessagesResultSchema, strictObject({
|
|
8539
|
-
idempotencyKey: nonEmptyStringSchema,
|
|
8540
|
-
message: nonEmptyStringSchema,
|
|
8724
|
+
idempotencyKey: nonEmptyStringSchema$1,
|
|
8725
|
+
message: nonEmptyStringSchema$1,
|
|
8541
8726
|
outcome: literal("rejected"),
|
|
8542
8727
|
reasonCode: remoteAgentWorkerAdmissionRejectionCodeSchema,
|
|
8543
8728
|
v: literal(1)
|
|
@@ -8549,7 +8734,7 @@ const remoteAgentWorkerInputAttachmentsSchema = array(union([spaceMessageAttachm
|
|
|
8549
8734
|
/**
|
|
8550
8735
|
* Core-resolved immutable object key for a canonical Space File revision.
|
|
8551
8736
|
*/
|
|
8552
|
-
objectKey: nonEmptyStringSchema.max(4096),
|
|
8737
|
+
objectKey: nonEmptyStringSchema$1.max(4096),
|
|
8553
8738
|
removeAfterAdmission: neverFactory().optional(),
|
|
8554
8739
|
sizeBytes: number().int().finite().min(1).max(SPACE_FILE_MAX_SIZE_BYTES)
|
|
8555
8740
|
})])).max(10).superRefine((attachments, context) => {
|
|
@@ -8561,7 +8746,7 @@ const remoteAgentWorkerInputAttachmentsSchema = array(union([spaceMessageAttachm
|
|
|
8561
8746
|
});
|
|
8562
8747
|
const remoteAgentWorkerTurnMessageSchema = strictObject({
|
|
8563
8748
|
role: enumFactory(["user"]),
|
|
8564
|
-
content: nonEmptyStringSchema,
|
|
8749
|
+
content: nonEmptyStringSchema$1,
|
|
8565
8750
|
attachments: remoteAgentWorkerInputAttachmentsSchema.optional()
|
|
8566
8751
|
});
|
|
8567
8752
|
const remoteAgentWorkerAuthorContextSchema = strictObject({
|
|
@@ -8574,16 +8759,16 @@ const remoteAgentWorkerAuthorContextSchema = strictObject({
|
|
|
8574
8759
|
displayName: nullableNonEmptyStringSchema
|
|
8575
8760
|
});
|
|
8576
8761
|
const remoteAgentWorkerSubmitTurnRequestShape = {
|
|
8577
|
-
organizationId: nonEmptyStringSchema,
|
|
8578
|
-
spaceId: nonEmptyStringSchema,
|
|
8762
|
+
organizationId: nonEmptyStringSchema$1,
|
|
8763
|
+
spaceId: nonEmptyStringSchema$1,
|
|
8579
8764
|
conversationId: optionalNonEmptyStringSchema,
|
|
8580
8765
|
agentProfileId: agentProfileIdSchema,
|
|
8581
|
-
agentProfileOwnerUserId: nonEmptyStringSchema.nullable(),
|
|
8582
|
-
bindingId: nonEmptyStringSchema,
|
|
8583
|
-
triggerMessageId: nonEmptyStringSchema,
|
|
8584
|
-
dispatchId: nonEmptyStringSchema,
|
|
8766
|
+
agentProfileOwnerUserId: nonEmptyStringSchema$1.nullable(),
|
|
8767
|
+
bindingId: nonEmptyStringSchema$1,
|
|
8768
|
+
triggerMessageId: nonEmptyStringSchema$1,
|
|
8769
|
+
dispatchId: nonEmptyStringSchema$1,
|
|
8585
8770
|
sourceClientMessageId: nullableNonEmptyStringSchema.optional(),
|
|
8586
|
-
idempotencyKey: nonEmptyStringSchema,
|
|
8771
|
+
idempotencyKey: nonEmptyStringSchema$1,
|
|
8587
8772
|
toolExecutionDeadlineAtMs: number().int().positive().max(Number.MAX_SAFE_INTEGER).optional(),
|
|
8588
8773
|
messages: array(remoteAgentWorkerTurnMessageSchema).min(1),
|
|
8589
8774
|
author: remoteAgentWorkerAuthorContextSchema,
|
|
@@ -8602,7 +8787,7 @@ const remoteAgentWorkerSubmitTurnRequestV2Schema = strictObject({
|
|
|
8602
8787
|
});
|
|
8603
8788
|
const remoteAgentWorkerConversationIdentitySchema = strictObject({
|
|
8604
8789
|
kind: literal("personal_agent"),
|
|
8605
|
-
agentProfileId: nonEmptyStringSchema
|
|
8790
|
+
agentProfileId: nonEmptyStringSchema$1
|
|
8606
8791
|
});
|
|
8607
8792
|
discriminatedUnion("v", [
|
|
8608
8793
|
remoteAgentWorkerSubmitTurnRequestV1Schema,
|
|
@@ -8611,16 +8796,16 @@ discriminatedUnion("v", [
|
|
|
8611
8796
|
v: literal(4),
|
|
8612
8797
|
...remoteAgentWorkerSubmitTurnRequestShape,
|
|
8613
8798
|
conversationIdentity: remoteAgentWorkerConversationIdentitySchema.optional(),
|
|
8614
|
-
conversationId: nonEmptyStringSchema.max(REMOTE_AGENT_LOGICAL_CONVERSATION_ID_MAX_CHARS),
|
|
8799
|
+
conversationId: nonEmptyStringSchema$1.max(REMOTE_AGENT_LOGICAL_CONVERSATION_ID_MAX_CHARS),
|
|
8615
8800
|
continuityContext: remoteAgentConversationContinuityContextSchema.optional(),
|
|
8616
8801
|
sourceMessageEnvelope: messageEnvelopeSchema.optional(),
|
|
8617
8802
|
modelRoute: centerAgentModelRouteSchema,
|
|
8618
8803
|
runtimeConversation: remoteAgentRuntimeConversationSchema,
|
|
8619
8804
|
spaceDispatchContext: strictObject({
|
|
8620
|
-
dispatchChainId: nonEmptyStringSchema,
|
|
8805
|
+
dispatchChainId: nonEmptyStringSchema$1,
|
|
8621
8806
|
autoRelayDepth: number().int().nonnegative(),
|
|
8622
|
-
visitedProfileIds: array(nonEmptyStringSchema).max(256),
|
|
8623
|
-
visitedProfileIdsHash: nonEmptyStringSchema
|
|
8807
|
+
visitedProfileIds: array(nonEmptyStringSchema$1).max(256),
|
|
8808
|
+
visitedProfileIdsHash: nonEmptyStringSchema$1
|
|
8624
8809
|
}).optional()
|
|
8625
8810
|
}).superRefine((request, context) => {
|
|
8626
8811
|
if (request.conversationIdentity?.kind === "personal_agent") {
|
|
@@ -8659,10 +8844,10 @@ discriminatedUnion("v", [
|
|
|
8659
8844
|
]);
|
|
8660
8845
|
const remoteAgentWorkerExecutionIdentitySchema = {
|
|
8661
8846
|
v: literal(1),
|
|
8662
|
-
organizationId: nonEmptyStringSchema,
|
|
8663
|
-
spaceId: nonEmptyStringSchema,
|
|
8664
|
-
submissionId: nonEmptyStringSchema,
|
|
8665
|
-
idempotencyKey: nonEmptyStringSchema
|
|
8847
|
+
organizationId: nonEmptyStringSchema$1,
|
|
8848
|
+
spaceId: nonEmptyStringSchema$1,
|
|
8849
|
+
submissionId: nonEmptyStringSchema$1,
|
|
8850
|
+
idempotencyKey: nonEmptyStringSchema$1
|
|
8666
8851
|
};
|
|
8667
8852
|
const remoteAgentWorkerExecutionStatusSchema = enumFactory([
|
|
8668
8853
|
"pending",
|
|
@@ -8696,7 +8881,7 @@ const remoteAgentWorkerExecutionStateSchema = strictObject({
|
|
|
8696
8881
|
lastProgressAtMs: number().int().nonnegative(),
|
|
8697
8882
|
lastProgressKind: remoteAgentWorkerExecutionProgressKindSchema,
|
|
8698
8883
|
completedAtMs: number().int().nonnegative().nullable(),
|
|
8699
|
-
cancellationReason: nonEmptyStringSchema.max(512).nullable()
|
|
8884
|
+
cancellationReason: nonEmptyStringSchema$1.max(512).nullable()
|
|
8700
8885
|
});
|
|
8701
8886
|
union([
|
|
8702
8887
|
strictObject({
|
|
@@ -8712,7 +8897,7 @@ union([
|
|
|
8712
8897
|
strictObject({
|
|
8713
8898
|
...remoteAgentWorkerExecutionIdentitySchema,
|
|
8714
8899
|
conversationId: optionalNonEmptyStringSchema,
|
|
8715
|
-
reason: nonEmptyStringSchema.max(512).optional()
|
|
8900
|
+
reason: nonEmptyStringSchema$1.max(512).optional()
|
|
8716
8901
|
});
|
|
8717
8902
|
union([
|
|
8718
8903
|
strictObject({
|
|
@@ -8735,12 +8920,12 @@ union([
|
|
|
8735
8920
|
]);
|
|
8736
8921
|
strictObject({
|
|
8737
8922
|
organizationId: optionalNonEmptyStringSchema,
|
|
8738
|
-
runtimeConversationId: nonEmptyStringSchema.max(REMOTE_AGENT_RUNTIME_CONVERSATION_ID_MAX_CHARS),
|
|
8739
|
-
spaceId: nonEmptyStringSchema
|
|
8923
|
+
runtimeConversationId: nonEmptyStringSchema$1.max(REMOTE_AGENT_RUNTIME_CONVERSATION_ID_MAX_CHARS),
|
|
8924
|
+
spaceId: nonEmptyStringSchema$1
|
|
8740
8925
|
});
|
|
8741
8926
|
strictObject({
|
|
8742
|
-
runtimeConversationId: nonEmptyStringSchema.max(REMOTE_AGENT_RUNTIME_CONVERSATION_ID_MAX_CHARS),
|
|
8743
|
-
spaceId: nonEmptyStringSchema
|
|
8927
|
+
runtimeConversationId: nonEmptyStringSchema$1.max(REMOTE_AGENT_RUNTIME_CONVERSATION_ID_MAX_CHARS),
|
|
8928
|
+
spaceId: nonEmptyStringSchema$1
|
|
8744
8929
|
});
|
|
8745
8930
|
const nullableNonNegativeIntegerSchema = number().int().nonnegative().nullable();
|
|
8746
8931
|
const remoteAgentRuntimeSubmissionDiagnosticSchema = strictObject({
|
|
@@ -8764,37 +8949,37 @@ const remoteAgentRuntimeSubmissionDiagnosticSchema = strictObject({
|
|
|
8764
8949
|
"terminalizing",
|
|
8765
8950
|
"settled"
|
|
8766
8951
|
]),
|
|
8767
|
-
submissionId: nonEmptyStringSchema,
|
|
8952
|
+
submissionId: nonEmptyStringSchema$1,
|
|
8768
8953
|
timeoutAtMs: number().int().nonnegative()
|
|
8769
8954
|
});
|
|
8770
8955
|
const remoteAgentRuntimeAttemptMarkerDiagnosticSchema = strictObject({
|
|
8771
|
-
attemptId: nonEmptyStringSchema,
|
|
8956
|
+
attemptId: nonEmptyStringSchema$1,
|
|
8772
8957
|
createdAtMs: number().int().nonnegative(),
|
|
8773
|
-
submissionId: nonEmptyStringSchema
|
|
8958
|
+
submissionId: nonEmptyStringSchema$1
|
|
8774
8959
|
});
|
|
8775
8960
|
const remoteAgentRuntimeActiveRunDiagnosticSchema = strictObject({
|
|
8776
8961
|
createdAtMs: number().int().nonnegative(),
|
|
8777
|
-
id: nonEmptyStringSchema,
|
|
8778
|
-
name: nonEmptyStringSchema
|
|
8962
|
+
id: nonEmptyStringSchema$1,
|
|
8963
|
+
name: nonEmptyStringSchema$1
|
|
8779
8964
|
});
|
|
8780
8965
|
const remoteAgentRuntimeFiberDiagnosticSchema = strictObject({
|
|
8781
8966
|
completedAtMs: nullableNonNegativeIntegerSchema,
|
|
8782
8967
|
createdAtMs: number().int().nonnegative(),
|
|
8783
|
-
fiberId: nonEmptyStringSchema,
|
|
8968
|
+
fiberId: nonEmptyStringSchema$1,
|
|
8784
8969
|
idempotencyKey: nullableNonEmptyStringSchema,
|
|
8785
|
-
name: nonEmptyStringSchema,
|
|
8970
|
+
name: nonEmptyStringSchema$1,
|
|
8786
8971
|
startedAtMs: nullableNonNegativeIntegerSchema,
|
|
8787
|
-
status: nonEmptyStringSchema
|
|
8972
|
+
status: nonEmptyStringSchema$1
|
|
8788
8973
|
});
|
|
8789
8974
|
const remoteAgentRuntimeScheduleDiagnosticSchema = strictObject({
|
|
8790
8975
|
callback: nullableNonEmptyStringSchema,
|
|
8791
8976
|
createdAtSeconds: number().int().nonnegative(),
|
|
8792
8977
|
delayInSeconds: nullableNonNegativeIntegerSchema,
|
|
8793
8978
|
executionStartedAtMs: nullableNonNegativeIntegerSchema,
|
|
8794
|
-
id: nonEmptyStringSchema,
|
|
8979
|
+
id: nonEmptyStringSchema$1,
|
|
8795
8980
|
running: boolean(),
|
|
8796
8981
|
timeMs: nullableNonNegativeIntegerSchema,
|
|
8797
|
-
type: nonEmptyStringSchema
|
|
8982
|
+
type: nonEmptyStringSchema$1
|
|
8798
8983
|
});
|
|
8799
8984
|
const remoteAgentRuntimeCallbackContextDiagnosticSchema = strictObject({
|
|
8800
8985
|
callbackAttempts: number().int().nonnegative(),
|
|
@@ -8808,7 +8993,7 @@ const remoteAgentRuntimeCallbackContextDiagnosticSchema = strictObject({
|
|
|
8808
8993
|
"rejected",
|
|
8809
8994
|
"retryable"
|
|
8810
8995
|
]),
|
|
8811
|
-
dispatchId: nonEmptyStringSchema,
|
|
8996
|
+
dispatchId: nonEmptyStringSchema$1,
|
|
8812
8997
|
hasCompletedText: boolean(),
|
|
8813
8998
|
lastCoreResponseReasonCode: nullableNonEmptyStringSchema,
|
|
8814
8999
|
lastCoreResponseStatus: enumFactory([
|
|
@@ -8818,16 +9003,16 @@ const remoteAgentRuntimeCallbackContextDiagnosticSchema = strictObject({
|
|
|
8818
9003
|
"retryable"
|
|
8819
9004
|
]).nullable(),
|
|
8820
9005
|
lastFailureCode: nullableNonEmptyStringSchema,
|
|
8821
|
-
submissionId: nonEmptyStringSchema,
|
|
9006
|
+
submissionId: nonEmptyStringSchema$1,
|
|
8822
9007
|
updatedAtMs: number().int().nonnegative()
|
|
8823
9008
|
});
|
|
8824
9009
|
const remoteAgentRecentToolCallDiagnosticSchema = strictObject({
|
|
8825
9010
|
calledAtMs: number().int().nonnegative(),
|
|
8826
9011
|
source: enumFactory(["code_mode", "direct"]),
|
|
8827
|
-
toolName: nonEmptyStringSchema.max(160)
|
|
9012
|
+
toolName: nonEmptyStringSchema$1.max(160)
|
|
8828
9013
|
});
|
|
8829
9014
|
const remoteAgentCapabilityDiscoveryDiagnosticSchema = strictObject({
|
|
8830
|
-
capabilityNames: array(nonEmptyStringSchema.max(160)).max(12),
|
|
9015
|
+
capabilityNames: array(nonEmptyStringSchema$1.max(160)).max(12),
|
|
8831
9016
|
observedAtMs: number().int().nonnegative(),
|
|
8832
9017
|
operation: enumFactory(["describe", "search"]),
|
|
8833
9018
|
resultCount: number().int().nonnegative()
|
|
@@ -8860,7 +9045,7 @@ const remoteAgentTurnRuntimeEvidenceSchema = strictObject({
|
|
|
8860
9045
|
recentCapabilityDiscovery: array(remoteAgentCapabilityDiscoveryDiagnosticSchema).max(16),
|
|
8861
9046
|
recentProviderRequests: array(remoteAgentProviderRequestDiagnosticSchema).max(16),
|
|
8862
9047
|
recentToolCalls: array(remoteAgentRecentToolCallDiagnosticSchema).max(32),
|
|
8863
|
-
submissionId: nonEmptyStringSchema,
|
|
9048
|
+
submissionId: nonEmptyStringSchema$1,
|
|
8864
9049
|
toolCallCount: number().int().nonnegative(),
|
|
8865
9050
|
toolCallLimit: number().int().positive(),
|
|
8866
9051
|
updatedAtMs: number().int().nonnegative()
|
|
@@ -8873,7 +9058,7 @@ const remoteAgentWorkerRuntimeDiagnosticsResponseV1Schema = strictObject({
|
|
|
8873
9058
|
durableObjectAlarmAtMs: nullableNonNegativeIntegerSchema,
|
|
8874
9059
|
fibers: array(remoteAgentRuntimeFiberDiagnosticSchema).max(50),
|
|
8875
9060
|
schedules: array(remoteAgentRuntimeScheduleDiagnosticSchema).max(50),
|
|
8876
|
-
spaceId: nonEmptyStringSchema,
|
|
9061
|
+
spaceId: nonEmptyStringSchema$1,
|
|
8877
9062
|
submissions: array(remoteAgentRuntimeSubmissionDiagnosticSchema).max(50),
|
|
8878
9063
|
turnObservability: array(remoteAgentTurnRuntimeEvidenceSchema).max(50).optional(),
|
|
8879
9064
|
v: literal(1)
|
|
@@ -8901,29 +9086,29 @@ const remoteAgentWorkerRuntimeDiagnosticsResponseSchema = discriminatedUnion("v"
|
|
|
8901
9086
|
v: literal(2)
|
|
8902
9087
|
})]);
|
|
8903
9088
|
const remoteAgentCoreCallbackIdentitySchema = {
|
|
8904
|
-
submissionId: nonEmptyStringSchema,
|
|
8905
|
-
idempotencyKey: nonEmptyStringSchema,
|
|
8906
|
-
organizationId: nonEmptyStringSchema,
|
|
8907
|
-
spaceId: nonEmptyStringSchema,
|
|
9089
|
+
submissionId: nonEmptyStringSchema$1,
|
|
9090
|
+
idempotencyKey: nonEmptyStringSchema$1,
|
|
9091
|
+
organizationId: nonEmptyStringSchema$1,
|
|
9092
|
+
spaceId: nonEmptyStringSchema$1,
|
|
8908
9093
|
agentProfileId: agentProfileIdSchema,
|
|
8909
|
-
bindingId: nonEmptyStringSchema,
|
|
8910
|
-
triggerMessageId: nonEmptyStringSchema,
|
|
8911
|
-
dispatchId: nonEmptyStringSchema,
|
|
9094
|
+
bindingId: nonEmptyStringSchema$1,
|
|
9095
|
+
triggerMessageId: nonEmptyStringSchema$1,
|
|
9096
|
+
dispatchId: nonEmptyStringSchema$1,
|
|
8912
9097
|
callbackAttempt: number().int().positive().optional()
|
|
8913
9098
|
};
|
|
8914
9099
|
const remoteAgentStreamDeltaCallbackIdentitySchema = {
|
|
8915
|
-
submissionId: nonEmptyStringSchema,
|
|
8916
|
-
idempotencyKey: nonEmptyStringSchema,
|
|
8917
|
-
organizationId: nonEmptyStringSchema,
|
|
8918
|
-
spaceId: nonEmptyStringSchema,
|
|
9100
|
+
submissionId: nonEmptyStringSchema$1,
|
|
9101
|
+
idempotencyKey: nonEmptyStringSchema$1,
|
|
9102
|
+
organizationId: nonEmptyStringSchema$1,
|
|
9103
|
+
spaceId: nonEmptyStringSchema$1,
|
|
8919
9104
|
agentProfileId: agentProfileIdSchema,
|
|
8920
|
-
bindingId: nonEmptyStringSchema,
|
|
8921
|
-
triggerMessageId: nonEmptyStringSchema,
|
|
8922
|
-
dispatchId: nonEmptyStringSchema
|
|
9105
|
+
bindingId: nonEmptyStringSchema$1,
|
|
9106
|
+
triggerMessageId: nonEmptyStringSchema$1,
|
|
9107
|
+
dispatchId: nonEmptyStringSchema$1
|
|
8923
9108
|
};
|
|
8924
9109
|
const legacyRemoteAgentStreamDeltaCallbackBodySchema = strictObject({
|
|
8925
9110
|
v: literal(1),
|
|
8926
|
-
streamId: nonEmptyStringSchema,
|
|
9111
|
+
streamId: nonEmptyStringSchema$1,
|
|
8927
9112
|
sequence: number().int().positive(),
|
|
8928
9113
|
...remoteAgentStreamDeltaCallbackIdentitySchema,
|
|
8929
9114
|
source: enumFactory(["flue.text_delta", "simulated.final_text"]),
|
|
@@ -8933,7 +9118,7 @@ const legacyRemoteAgentStreamDeltaCallbackBodySchema = strictObject({
|
|
|
8933
9118
|
});
|
|
8934
9119
|
const typedRemoteAgentStreamDeltaCallbackIdentitySchema = {
|
|
8935
9120
|
v: literal(2),
|
|
8936
|
-
streamId: nonEmptyStringSchema,
|
|
9121
|
+
streamId: nonEmptyStringSchema$1,
|
|
8937
9122
|
sequence: number().int().positive(),
|
|
8938
9123
|
...remoteAgentStreamDeltaCallbackIdentitySchema,
|
|
8939
9124
|
delta: string().min(1).max(REMOTE_AGENT_STREAM_DELTA_MAX_CHARS),
|
|
@@ -8955,7 +9140,7 @@ union([
|
|
|
8955
9140
|
]);
|
|
8956
9141
|
strictObject({
|
|
8957
9142
|
v: literal(1),
|
|
8958
|
-
streamId: nonEmptyStringSchema,
|
|
9143
|
+
streamId: nonEmptyStringSchema$1,
|
|
8959
9144
|
sequence: number().int().positive(),
|
|
8960
9145
|
...remoteAgentStreamDeltaCallbackIdentitySchema,
|
|
8961
9146
|
source: literal("flue.tool"),
|
|
@@ -8977,12 +9162,12 @@ union([
|
|
|
8977
9162
|
strictObject({
|
|
8978
9163
|
status: literal("rejected"),
|
|
8979
9164
|
lastSequence: remoteAgentStreamLastSequenceSchema,
|
|
8980
|
-
reasonCode: nonEmptyStringSchema
|
|
9165
|
+
reasonCode: nonEmptyStringSchema$1
|
|
8981
9166
|
}),
|
|
8982
9167
|
strictObject({
|
|
8983
9168
|
status: literal("retryable"),
|
|
8984
9169
|
lastSequence: remoteAgentStreamLastSequenceSchema,
|
|
8985
|
-
reasonCode: nonEmptyStringSchema,
|
|
9170
|
+
reasonCode: nonEmptyStringSchema$1,
|
|
8986
9171
|
retryAfterMs: remoteAgentRetryAfterMsSchema.optional()
|
|
8987
9172
|
})
|
|
8988
9173
|
]);
|
|
@@ -8991,15 +9176,15 @@ const remoteAgentCoreCallbackBodySchema = union([strictObject({
|
|
|
8991
9176
|
conversationCompaction: conversationCompactionMarkerSchema.optional(),
|
|
8992
9177
|
navigationTarget: openMeldNavigationTargetSchema.optional(),
|
|
8993
9178
|
status: literal("completed").optional(),
|
|
8994
|
-
text: nonEmptyStringSchema.max(MAX_TEXT_LENGTH$1),
|
|
9179
|
+
text: nonEmptyStringSchema$1.max(MAX_TEXT_LENGTH$1),
|
|
8995
9180
|
attachments: spaceMessageAttachmentsSchema.optional(),
|
|
8996
9181
|
files: spaceMessageFileReferencesSchema.optional()
|
|
8997
9182
|
}), strictObject({
|
|
8998
9183
|
...remoteAgentCoreCallbackIdentitySchema,
|
|
8999
9184
|
status: literal("failed"),
|
|
9000
|
-
failureCode: nonEmptyStringSchema,
|
|
9185
|
+
failureCode: nonEmptyStringSchema$1,
|
|
9001
9186
|
failureDetail: optionalDispatchErrorSummarySchema,
|
|
9002
|
-
failureMessage: nonEmptyStringSchema
|
|
9187
|
+
failureMessage: nonEmptyStringSchema$1
|
|
9003
9188
|
})]);
|
|
9004
9189
|
union([remoteAgentCoreCallbackBodySchema, strictObject({
|
|
9005
9190
|
...remoteAgentCoreCallbackIdentitySchema,
|
|
@@ -9010,7 +9195,7 @@ discriminatedUnion("kind", [strictObject({
|
|
|
9010
9195
|
callback: remoteAgentCoreCallbackBodySchema,
|
|
9011
9196
|
kind: literal("callback")
|
|
9012
9197
|
}), strictObject({
|
|
9013
|
-
failureCode: nonEmptyStringSchema,
|
|
9198
|
+
failureCode: nonEmptyStringSchema$1,
|
|
9014
9199
|
kind: literal("terminal_failure")
|
|
9015
9200
|
})]);
|
|
9016
9201
|
strictObject({
|
|
@@ -9018,16 +9203,16 @@ strictObject({
|
|
|
9018
9203
|
conversationCompaction: conversationCompactionMarkerSchema.optional(),
|
|
9019
9204
|
navigationTarget: openMeldNavigationTargetSchema.optional(),
|
|
9020
9205
|
status: literal("completed"),
|
|
9021
|
-
text: nonEmptyStringSchema.max(MAX_TEXT_LENGTH$1),
|
|
9206
|
+
text: nonEmptyStringSchema$1.max(MAX_TEXT_LENGTH$1),
|
|
9022
9207
|
attachments: spaceMessageAttachmentsSchema.optional(),
|
|
9023
9208
|
files: spaceMessageFileReferencesSchema.optional()
|
|
9024
9209
|
});
|
|
9025
9210
|
strictObject({
|
|
9026
9211
|
...remoteAgentCoreCallbackIdentitySchema,
|
|
9027
9212
|
status: literal("failed"),
|
|
9028
|
-
failureCode: nonEmptyStringSchema,
|
|
9213
|
+
failureCode: nonEmptyStringSchema$1,
|
|
9029
9214
|
failureDetail: optionalDispatchErrorSummarySchema,
|
|
9030
|
-
failureMessage: nonEmptyStringSchema
|
|
9215
|
+
failureMessage: nonEmptyStringSchema$1
|
|
9031
9216
|
});
|
|
9032
9217
|
strictObject({
|
|
9033
9218
|
status: enumFactory([
|
|
@@ -9036,8 +9221,8 @@ strictObject({
|
|
|
9036
9221
|
"rejected",
|
|
9037
9222
|
"retryable"
|
|
9038
9223
|
]),
|
|
9039
|
-
reasonCode: nonEmptyStringSchema.optional(),
|
|
9040
|
-
publishedSignalId: nonEmptyStringSchema.nullable().optional(),
|
|
9224
|
+
reasonCode: nonEmptyStringSchema$1.optional(),
|
|
9225
|
+
publishedSignalId: nonEmptyStringSchema$1.nullable().optional(),
|
|
9041
9226
|
retryAfterMs: remoteAgentRetryAfterMsSchema.optional()
|
|
9042
9227
|
});
|
|
9043
9228
|
//#endregion
|
|
@@ -10766,6 +10951,7 @@ const centerAgentConnectorActionAuditOutcomeSchema = enumFactory([
|
|
|
10766
10951
|
"outcome_unknown"
|
|
10767
10952
|
]);
|
|
10768
10953
|
strictObject({
|
|
10954
|
+
connectionName: connectorConnectionNameSchema.optional(),
|
|
10769
10955
|
actionId: trimmedNonEmptyStringSchema$1.max(160),
|
|
10770
10956
|
operationId: trimmedNonEmptyStringSchema$1.max(256),
|
|
10771
10957
|
outcome: centerAgentConnectorActionAuditOutcomeSchema,
|
|
@@ -10824,6 +11010,12 @@ strictObject({ operation: strictObject({
|
|
|
10824
11010
|
}).nullable() });
|
|
10825
11011
|
strictObject({
|
|
10826
11012
|
actionId: trimmedNonEmptyStringSchema$1.max(160),
|
|
11013
|
+
effect: enumFactory([
|
|
11014
|
+
"read",
|
|
11015
|
+
"write",
|
|
11016
|
+
"destructive",
|
|
11017
|
+
"unspecified"
|
|
11018
|
+
]).optional(),
|
|
10827
11019
|
connectionName: connectorConnectionNameSchema,
|
|
10828
11020
|
operationId: trimmedNonEmptyStringSchema$1.max(256),
|
|
10829
11021
|
outcome: centerAgentConnectorActionAuditOutcomeSchema,
|
|
@@ -11960,6 +12152,7 @@ const inboxViewSchema = enumFactory([
|
|
|
11960
12152
|
"all",
|
|
11961
12153
|
"unread",
|
|
11962
12154
|
"needs_action",
|
|
12155
|
+
"needs_review",
|
|
11963
12156
|
"updates",
|
|
11964
12157
|
"urgent_updates",
|
|
11965
12158
|
"recent_updates"
|
|
@@ -12532,6 +12725,141 @@ const organizationUsageOverviewResponseSchema = z$1.strictObject({
|
|
|
12532
12725
|
});
|
|
12533
12726
|
z$1.strictObject({ context: openMeldRequestContextSchema });
|
|
12534
12727
|
//#endregion
|
|
12728
|
+
//#region ../../packages/schemas/dist/schemas/runtime/openconnector-runtime.js
|
|
12729
|
+
const nonEmptyStringSchema = z$1.string().trim().min(1);
|
|
12730
|
+
const jsonSchemaObjectSchema = z$1.record(z$1.string(), z$1.unknown());
|
|
12731
|
+
const openConnectorRuntimeActionEffectSchema = z$1.enum([
|
|
12732
|
+
"destructive",
|
|
12733
|
+
"read",
|
|
12734
|
+
"write"
|
|
12735
|
+
]);
|
|
12736
|
+
const openConnectorRuntimeActionExecutionSchema = z$1.strictObject({
|
|
12737
|
+
catalogOnly: z$1.boolean(),
|
|
12738
|
+
locallyExecutable: z$1.boolean(),
|
|
12739
|
+
needsCredential: z$1.boolean(),
|
|
12740
|
+
noAuthRunnable: z$1.boolean(),
|
|
12741
|
+
requiredAuthTypes: z$1.array(z$1.enum([
|
|
12742
|
+
"no_auth",
|
|
12743
|
+
"api_key",
|
|
12744
|
+
"custom_credential",
|
|
12745
|
+
"oauth2"
|
|
12746
|
+
]))
|
|
12747
|
+
}).superRefine((execution, context) => {
|
|
12748
|
+
if (execution.catalogOnly === execution.locallyExecutable) context.addIssue({
|
|
12749
|
+
code: "custom",
|
|
12750
|
+
message: "OpenConnector action execution must be either locally executable or catalog-only.",
|
|
12751
|
+
path: ["locallyExecutable"]
|
|
12752
|
+
});
|
|
12753
|
+
if (execution.needsCredential === execution.noAuthRunnable) context.addIssue({
|
|
12754
|
+
code: "custom",
|
|
12755
|
+
message: "OpenConnector action credential requirements are inconsistent.",
|
|
12756
|
+
path: ["needsCredential"]
|
|
12757
|
+
});
|
|
12758
|
+
});
|
|
12759
|
+
const openConnectorRuntimeActionSchema = z$1.strictObject({
|
|
12760
|
+
asyncLifecycle: z$1.strictObject({
|
|
12761
|
+
cancelActionId: nonEmptyStringSchema.optional(),
|
|
12762
|
+
startActionId: nonEmptyStringSchema,
|
|
12763
|
+
statusActionId: nonEmptyStringSchema
|
|
12764
|
+
}).nullable(),
|
|
12765
|
+
description: nonEmptyStringSchema,
|
|
12766
|
+
effect: openConnectorRuntimeActionEffectSchema.optional(),
|
|
12767
|
+
execution: openConnectorRuntimeActionExecutionSchema,
|
|
12768
|
+
followUpActions: z$1.array(z$1.strictObject({ actionId: nonEmptyStringSchema })),
|
|
12769
|
+
id: nonEmptyStringSchema,
|
|
12770
|
+
inputSchema: jsonSchemaObjectSchema,
|
|
12771
|
+
name: nonEmptyStringSchema,
|
|
12772
|
+
outputSchema: jsonSchemaObjectSchema,
|
|
12773
|
+
providerPermissions: z$1.array(nonEmptyStringSchema),
|
|
12774
|
+
requiredScopes: z$1.array(nonEmptyStringSchema),
|
|
12775
|
+
service: nonEmptyStringSchema
|
|
12776
|
+
});
|
|
12777
|
+
const openConnectorRuntimeActionListSchema = z$1.array(openConnectorRuntimeActionSchema);
|
|
12778
|
+
const openConnectorRuntimeActionSearchResultSchema = z$1.strictObject({
|
|
12779
|
+
authenticated: z$1.boolean(),
|
|
12780
|
+
description: nonEmptyStringSchema,
|
|
12781
|
+
effect: openConnectorRuntimeActionEffectSchema.optional(),
|
|
12782
|
+
id: nonEmptyStringSchema,
|
|
12783
|
+
inputSchema: jsonSchemaObjectSchema,
|
|
12784
|
+
name: nonEmptyStringSchema,
|
|
12785
|
+
outputSchema: jsonSchemaObjectSchema,
|
|
12786
|
+
service: nonEmptyStringSchema
|
|
12787
|
+
});
|
|
12788
|
+
z$1.array(openConnectorRuntimeActionSearchResultSchema);
|
|
12789
|
+
const openConnectorRuntimeActionOperationMetaSchema = z$1.strictObject({
|
|
12790
|
+
actionId: nonEmptyStringSchema,
|
|
12791
|
+
auditPersisted: z$1.boolean(),
|
|
12792
|
+
executionId: nonEmptyStringSchema
|
|
12793
|
+
});
|
|
12794
|
+
z$1.strictObject({
|
|
12795
|
+
data: z$1.unknown(),
|
|
12796
|
+
message: z$1.literal("OK"),
|
|
12797
|
+
meta: openConnectorRuntimeActionOperationMetaSchema,
|
|
12798
|
+
outputSchema: jsonSchemaObjectSchema,
|
|
12799
|
+
success: z$1.literal(true)
|
|
12800
|
+
});
|
|
12801
|
+
//#endregion
|
|
12802
|
+
//#region ../../packages/schemas/dist/schemas/http/plugin-actions.js
|
|
12803
|
+
const selectedAccountSchema = centerAgentConnectorActionExecutionConnectionSchema.extend({ permission: enumFactory(["read", "write"]) });
|
|
12804
|
+
const selection = {
|
|
12805
|
+
service: connectorServiceSchema,
|
|
12806
|
+
account: enumFactory(["personal", "shared"])
|
|
12807
|
+
};
|
|
12808
|
+
const pluginActionRequestSchema = strictObject({
|
|
12809
|
+
dispatchId: string().trim().min(1).max(256).optional(),
|
|
12810
|
+
action: discriminatedUnion("operation", [
|
|
12811
|
+
strictObject({ operation: literal("list") }),
|
|
12812
|
+
strictObject({
|
|
12813
|
+
operation: literal("actions"),
|
|
12814
|
+
...selection
|
|
12815
|
+
}),
|
|
12816
|
+
strictObject({
|
|
12817
|
+
operation: literal("execute"),
|
|
12818
|
+
...selection,
|
|
12819
|
+
actionId: string().trim().min(1).max(160),
|
|
12820
|
+
input: record(string(), unknown()),
|
|
12821
|
+
operationId: string().trim().min(1).max(256),
|
|
12822
|
+
confirmationToken: string().uuid().optional()
|
|
12823
|
+
})
|
|
12824
|
+
])
|
|
12825
|
+
});
|
|
12826
|
+
strictObject({
|
|
12827
|
+
context: openMeldRequestContextSchema,
|
|
12828
|
+
expectedOrganizationId: string().trim().min(1),
|
|
12829
|
+
request: pluginActionRequestSchema
|
|
12830
|
+
});
|
|
12831
|
+
const pluginActionResponseSchema = discriminatedUnion("kind", [
|
|
12832
|
+
strictObject({
|
|
12833
|
+
kind: literal("connections"),
|
|
12834
|
+
connections: array(selectedAccountSchema)
|
|
12835
|
+
}),
|
|
12836
|
+
strictObject({
|
|
12837
|
+
kind: literal("actions"),
|
|
12838
|
+
connection: selectedAccountSchema,
|
|
12839
|
+
actions: openConnectorRuntimeActionListSchema
|
|
12840
|
+
}),
|
|
12841
|
+
strictObject({
|
|
12842
|
+
kind: literal("confirmation_required"),
|
|
12843
|
+
connection: selectedAccountSchema,
|
|
12844
|
+
actionId: string(),
|
|
12845
|
+
operationId: string(),
|
|
12846
|
+
confirmationToken: string().uuid(),
|
|
12847
|
+
expiresAtMs: number(),
|
|
12848
|
+
message: string()
|
|
12849
|
+
}),
|
|
12850
|
+
strictObject({
|
|
12851
|
+
kind: literal("execution"),
|
|
12852
|
+
connection: centerAgentConnectorActionExecutionConnectionSchema,
|
|
12853
|
+
actionId: string(),
|
|
12854
|
+
operationId: string(),
|
|
12855
|
+
status: centerAgentConnectorActionOperationStatusSchema,
|
|
12856
|
+
replayed: boolean(),
|
|
12857
|
+
data: unknown().optional(),
|
|
12858
|
+
error: string().optional(),
|
|
12859
|
+
providerExecutionId: string().nullable()
|
|
12860
|
+
})
|
|
12861
|
+
]);
|
|
12862
|
+
//#endregion
|
|
12535
12863
|
//#region ../../packages/schemas/dist/schemas/http/space-agent-interaction.js
|
|
12536
12864
|
const respondToSpaceAgentInteractionBodySchema = z$1.strictObject({
|
|
12537
12865
|
runtimeCoordinatorExecutionId: runtimeCoordinatorExecutionRecordSchema.shape.runtimeCoordinatorExecutionId,
|
|
@@ -12701,7 +13029,11 @@ const spaceEntryTargetSchema = z$1.strictObject({
|
|
|
12701
13029
|
});
|
|
12702
13030
|
const spaceEntryAllowedViewSchema = z$1.strictObject({
|
|
12703
13031
|
state: z$1.literal("allowed"),
|
|
12704
|
-
experience: z$1.enum([
|
|
13032
|
+
experience: z$1.enum([
|
|
13033
|
+
"member",
|
|
13034
|
+
"public",
|
|
13035
|
+
"guest"
|
|
13036
|
+
])
|
|
12705
13037
|
});
|
|
12706
13038
|
const spaceEntryBlockedViewSchema = z$1.discriminatedUnion("state", [
|
|
12707
13039
|
z$1.strictObject({ state: z$1.literal("sign_in_required") }),
|
|
@@ -12740,6 +13072,19 @@ const getSpaceEntryResolutionResponseSchema = z$1.strictObject({
|
|
|
12740
13072
|
recovery: spaceEntryRecoverySchema.nullable()
|
|
12741
13073
|
});
|
|
12742
13074
|
//#endregion
|
|
13075
|
+
//#region ../../packages/schemas/dist/schemas/http/space-file-update-settings.js
|
|
13076
|
+
const spaceFileUpdateSettingsSchema = z$1.strictObject({
|
|
13077
|
+
fileId: spaceFileEntryIdSchema,
|
|
13078
|
+
version: z$1.number().int().nonnegative(),
|
|
13079
|
+
recipientProfileIds: z$1.array(z$1.string().trim().min(1)).max(50),
|
|
13080
|
+
configuredBy: spaceFileActorSchema.nullable()
|
|
13081
|
+
});
|
|
13082
|
+
z$1.discriminatedUnion("action", [z$1.strictObject({ action: z$1.literal("read") }), z$1.strictObject({
|
|
13083
|
+
action: z$1.literal("configure"),
|
|
13084
|
+
baseVersion: z$1.number().int().nonnegative(),
|
|
13085
|
+
recipientProfileIds: z$1.array(z$1.string().trim().min(1)).max(50)
|
|
13086
|
+
})]);
|
|
13087
|
+
//#endregion
|
|
12743
13088
|
//#region ../../packages/schemas/dist/schemas/http/space-wake-trace-waterfall.js
|
|
12744
13089
|
const optionalSelectorSchema$1 = z$1.preprocess((value) => {
|
|
12745
13090
|
const normalized = String(value ?? "").trim();
|
|
@@ -13424,6 +13769,9 @@ const getActiveSpaceWakeProgressResponseSchema = z$1.strictObject({
|
|
|
13424
13769
|
items: z$1.array(wakeProgressItemSchema)
|
|
13425
13770
|
});
|
|
13426
13771
|
//#endregion
|
|
13772
|
+
//#region ../../packages/schemas/dist/space-access-version.js
|
|
13773
|
+
const SPACE_ACCESS_VERSION_HEADER = "x-openmeld-space-access-version";
|
|
13774
|
+
//#endregion
|
|
13427
13775
|
//#region ../../packages/gateway-contract/dist/index.js
|
|
13428
13776
|
const OPENMELD_HEADER_REQUEST_ID = "x-openmeld-request-id";
|
|
13429
13777
|
const OPENMELD_HEADER_CALLER_PRINCIPAL_ID = "x-openmeld-caller-principal-id";
|
|
@@ -13884,7 +14232,8 @@ const createAgentProfileBindingApi = (client) => {
|
|
|
13884
14232
|
});
|
|
13885
14233
|
},
|
|
13886
14234
|
getExecutionReadinessBatch: async (input) => {
|
|
13887
|
-
const
|
|
14235
|
+
const { signal, ...body } = input;
|
|
14236
|
+
const request = requireValidExecutionReadinessBatchInput(body);
|
|
13888
14237
|
return await client.requestJson({
|
|
13889
14238
|
body: JSON.stringify({
|
|
13890
14239
|
agentProfileIds: request.agentProfileIds,
|
|
@@ -13894,6 +14243,7 @@ const createAgentProfileBindingApi = (client) => {
|
|
|
13894
14243
|
invalidMessage: "Invalid Agent Execution Readiness batch response.",
|
|
13895
14244
|
method: "POST",
|
|
13896
14245
|
operation: "agent_execution_readiness.batch_read",
|
|
14246
|
+
signal,
|
|
13897
14247
|
requestContext: request.requestContext,
|
|
13898
14248
|
schema: getAgentExecutionReadinessBatchResponseSchema,
|
|
13899
14249
|
url: buildAgentExecutionReadinessBatchRoute()
|
|
@@ -16601,6 +16951,22 @@ function requestOptions$2(input) {
|
|
|
16601
16951
|
...input.timeoutMs === void 0 ? {} : { timeoutMs: input.timeoutMs }
|
|
16602
16952
|
};
|
|
16603
16953
|
}
|
|
16954
|
+
function createPluginsApi(client) {
|
|
16955
|
+
return { action: async (input) => {
|
|
16956
|
+
const request = pluginActionRequestSchema.parse(input.request);
|
|
16957
|
+
return await client.requestJson({
|
|
16958
|
+
method: "POST",
|
|
16959
|
+
operation: "plugins.action",
|
|
16960
|
+
timeoutMs: input.request.action.operation === "execute" ? 12e4 : 3e4,
|
|
16961
|
+
requestContext: input.requestContext,
|
|
16962
|
+
url: `/v1/organizations/current/plugins/actions?expectedOrganizationId=${encodeURIComponent(input.organizationId)}`,
|
|
16963
|
+
body: JSON.stringify(request),
|
|
16964
|
+
headers: { "content-type": "application/json" },
|
|
16965
|
+
schema: pluginActionResponseSchema,
|
|
16966
|
+
invalidMessage: "Invalid plugin action response."
|
|
16967
|
+
});
|
|
16968
|
+
} };
|
|
16969
|
+
}
|
|
16604
16970
|
function buildPrepareReadinessRoute(deviceId) {
|
|
16605
16971
|
return `/v1/devices/${encodeURIComponent(deviceId)}/prepare-readiness`;
|
|
16606
16972
|
}
|
|
@@ -17309,10 +17675,13 @@ function buildSpaceThreadEventsPath(spaceId, threadId) {
|
|
|
17309
17675
|
function buildSpaceThreadSignalsPath(spaceId, threadId, query) {
|
|
17310
17676
|
const path = `${buildSpaceThreadPath(spaceId, threadId)}/signals`;
|
|
17311
17677
|
if (!query) return path;
|
|
17312
|
-
|
|
17313
|
-
|
|
17314
|
-
|
|
17315
|
-
|
|
17678
|
+
const searchParams = new URLSearchParams();
|
|
17679
|
+
if (query.afterSignalId && query.limit !== void 0) {
|
|
17680
|
+
searchParams.set("afterSignalId", query.afterSignalId);
|
|
17681
|
+
searchParams.set("limit", String(query.limit));
|
|
17682
|
+
}
|
|
17683
|
+
if (query.includeWakeContinuation) searchParams.set("includeWakeContinuation", String(query.includeWakeContinuation));
|
|
17684
|
+
return `${path}?${searchParams.toString()}`;
|
|
17316
17685
|
}
|
|
17317
17686
|
function buildSpaceRoutePath(spaceId, segment) {
|
|
17318
17687
|
return `/v1/spaces/${encodeURIComponent(spaceId)}/${segment}`;
|
|
@@ -17418,6 +17787,9 @@ function toRequestBody$1(bytes) {
|
|
|
17418
17787
|
function readRequestBodySize(body) {
|
|
17419
17788
|
return body instanceof Blob ? body.size : body.byteLength;
|
|
17420
17789
|
}
|
|
17790
|
+
function currentSpaceAccessHeaders() {
|
|
17791
|
+
return { [SPACE_ACCESS_VERSION_HEADER]: "1" };
|
|
17792
|
+
}
|
|
17421
17793
|
function currentSpaceAddressingHeaders(contentType) {
|
|
17422
17794
|
return {
|
|
17423
17795
|
...contentType ? { "content-type": contentType } : {},
|
|
@@ -17534,7 +17906,10 @@ async function getSpaceBootstrap(client, input) {
|
|
|
17534
17906
|
return await client.requestJson({
|
|
17535
17907
|
url: buildSpaceBootstrapReadPath(input.spaceId, input.historyQuery, input.includeAgentStreamPresence),
|
|
17536
17908
|
operation: "space.bootstrap.read",
|
|
17537
|
-
headers:
|
|
17909
|
+
headers: {
|
|
17910
|
+
...currentSpaceAddressingHeaders(),
|
|
17911
|
+
...currentSpaceAccessHeaders()
|
|
17912
|
+
},
|
|
17538
17913
|
requestContext: input.requestContext,
|
|
17539
17914
|
signal: input.signal,
|
|
17540
17915
|
timeoutMs: input.timeoutMs,
|
|
@@ -17557,7 +17932,10 @@ async function createSpace(client, input) {
|
|
|
17557
17932
|
url: buildCreateSpacePath(),
|
|
17558
17933
|
operation: "space.create",
|
|
17559
17934
|
method: "POST",
|
|
17560
|
-
headers: {
|
|
17935
|
+
headers: {
|
|
17936
|
+
...currentSpaceAccessHeaders(),
|
|
17937
|
+
"content-type": "application/json"
|
|
17938
|
+
},
|
|
17561
17939
|
body: JSON.stringify(parsedBody.data),
|
|
17562
17940
|
requestContext: input.requestContext,
|
|
17563
17941
|
schema: createSpaceResponseSchema,
|
|
@@ -17649,6 +18027,83 @@ async function executeSpaceExecutionRecovery(client, input) {
|
|
|
17649
18027
|
url: buildSpaceExecutionRecoveryPath(input.spaceId, input.dispatchId)
|
|
17650
18028
|
});
|
|
17651
18029
|
}
|
|
18030
|
+
async function spaceFileUpdateSettings(client, input) {
|
|
18031
|
+
const read = input.command.action === "read";
|
|
18032
|
+
return await client.requestJson({
|
|
18033
|
+
url: `/v1/spaces/${encodeURIComponent(input.spaceId)}/files/${encodeURIComponent(input.fileId)}/update-settings`,
|
|
18034
|
+
method: read ? "GET" : "PATCH",
|
|
18035
|
+
operation: "space.files.update-settings",
|
|
18036
|
+
headers: { "content-type": "application/json" },
|
|
18037
|
+
...read ? {} : { body: JSON.stringify(input.command) },
|
|
18038
|
+
requestContext: input.requestContext,
|
|
18039
|
+
signal: input.signal,
|
|
18040
|
+
timeoutMs: input.timeoutMs,
|
|
18041
|
+
...input.spacePassword === void 0 ? {} : { spacePassword: input.spacePassword },
|
|
18042
|
+
schema: spaceFileUpdateSettingsSchema,
|
|
18043
|
+
invalidMessage: "Invalid file update settings response"
|
|
18044
|
+
});
|
|
18045
|
+
}
|
|
18046
|
+
function bodySize(body) {
|
|
18047
|
+
return body instanceof Blob ? body.size : body.byteLength;
|
|
18048
|
+
}
|
|
18049
|
+
async function mutationUploadId(mutation) {
|
|
18050
|
+
const hash = await crypto.subtle.digest("SHA-256", new TextEncoder().encode(mutation));
|
|
18051
|
+
const hex = Array.from(new Uint8Array(hash), (b) => b.toString(16).padStart(2, "0")).join("");
|
|
18052
|
+
return `${hex.slice(0, 8)}-${hex.slice(8, 12)}-4${hex.slice(13, 16)}-a${hex.slice(17, 20)}-${hex.slice(20, 32)}`;
|
|
18053
|
+
}
|
|
18054
|
+
async function uploadMultipart(client, input, target, uploadId) {
|
|
18055
|
+
const body = toRequestBody(input.bytes);
|
|
18056
|
+
const blob = body instanceof Blob ? body : new Blob([body]);
|
|
18057
|
+
const url = `/v1/spaces/${encodeURIComponent(input.spaceId)}/file-uploads/${uploadId}`;
|
|
18058
|
+
const request = async (command, part) => {
|
|
18059
|
+
return await retryUploadRequest(input.signal, () => client.requestJson({
|
|
18060
|
+
...requestFields$1(input),
|
|
18061
|
+
url: command.action === "part" ? `${url}?part=${command.partNumber}` : url,
|
|
18062
|
+
method: "POST",
|
|
18063
|
+
operation: "space.files.upload",
|
|
18064
|
+
headers: { "content-type": part ? "application/octet-stream" : "application/json" },
|
|
18065
|
+
body: part ?? JSON.stringify(command),
|
|
18066
|
+
schema: spaceFileUploadResponseSchema,
|
|
18067
|
+
invalidMessage: "Invalid file upload response."
|
|
18068
|
+
}));
|
|
18069
|
+
};
|
|
18070
|
+
const partDigests = [];
|
|
18071
|
+
for (let offset = 0; offset < blob.size; offset += SPACE_FILE_UPLOAD_PART_BYTES) {
|
|
18072
|
+
input.signal?.throwIfAborted();
|
|
18073
|
+
const hash = await crypto.subtle.digest("SHA-256", await blob.slice(offset, offset + SPACE_FILE_UPLOAD_PART_BYTES).arrayBuffer());
|
|
18074
|
+
partDigests.push(Array.from(new Uint8Array(hash), (b) => b.toString(16).padStart(2, "0")).join(""));
|
|
18075
|
+
}
|
|
18076
|
+
let session = await request({
|
|
18077
|
+
action: "start",
|
|
18078
|
+
metadata: {
|
|
18079
|
+
target,
|
|
18080
|
+
mimeType: input.mimeType,
|
|
18081
|
+
sizeBytes: blob.size,
|
|
18082
|
+
partDigests
|
|
18083
|
+
}
|
|
18084
|
+
});
|
|
18085
|
+
if (session.file || session.upload) return session;
|
|
18086
|
+
input.onProgress?.(session.parts.reduce((n, p) => n + p.sizeBytes, 0), blob.size);
|
|
18087
|
+
for (let start = 0, number = 1; start < blob.size; start += session.partSizeBytes, number++) {
|
|
18088
|
+
if (session.parts.some((p) => p.partNumber === number)) continue;
|
|
18089
|
+
session = await request({
|
|
18090
|
+
action: "part",
|
|
18091
|
+
partNumber: number
|
|
18092
|
+
}, blob.slice(start, start + session.partSizeBytes));
|
|
18093
|
+
input.onProgress?.(session.parts.reduce((n, p) => n + p.sizeBytes, 0), blob.size);
|
|
18094
|
+
}
|
|
18095
|
+
return await request({ action: "complete" });
|
|
18096
|
+
}
|
|
18097
|
+
async function retryUploadRequest(signal, request) {
|
|
18098
|
+
for (let attempt = 0;; attempt++) try {
|
|
18099
|
+
signal?.throwIfAborted();
|
|
18100
|
+
return await request();
|
|
18101
|
+
} catch (error) {
|
|
18102
|
+
const status = error && typeof error === "object" && "status" in error ? error.status : void 0;
|
|
18103
|
+
if (signal?.aborted || attempt >= 2 || typeof status === "number" && status < 500 && status !== 429) throw error;
|
|
18104
|
+
await new Promise((resolve) => setTimeout(resolve, 250 * 2 ** attempt));
|
|
18105
|
+
}
|
|
18106
|
+
}
|
|
17652
18107
|
async function listSpaceFiles(client, input) {
|
|
17653
18108
|
const response = await client.requestJson({
|
|
17654
18109
|
...requestFields$1(input),
|
|
@@ -17755,6 +18210,16 @@ async function uploadSpaceFile(client, input) {
|
|
|
17755
18210
|
const body = toRequestBody(input.bytes);
|
|
17756
18211
|
validateSize(body);
|
|
17757
18212
|
const mimeType = parseMimeType(input.mimeType);
|
|
18213
|
+
if (bodySize(body) > 10485760) {
|
|
18214
|
+
const response = await uploadMultipart(client, input, {
|
|
18215
|
+
kind: "file",
|
|
18216
|
+
clientMutationId: input.clientMutationId,
|
|
18217
|
+
name: input.name,
|
|
18218
|
+
parentId: input.parentId ?? null
|
|
18219
|
+
}, await mutationUploadId(input.clientMutationId));
|
|
18220
|
+
if (!response.file) throw new Error("The upload did not return a file.");
|
|
18221
|
+
return response.file;
|
|
18222
|
+
}
|
|
17758
18223
|
return (await client.requestJson({
|
|
17759
18224
|
...requestFields$1(input),
|
|
17760
18225
|
url: buildSpaceFileUploadPath(input),
|
|
@@ -17770,6 +18235,14 @@ async function stageSpaceComposerUpload(client, input) {
|
|
|
17770
18235
|
const body = toRequestBody(input.bytes);
|
|
17771
18236
|
validateSize(body);
|
|
17772
18237
|
const mimeType = parseMimeType(input.mimeType);
|
|
18238
|
+
if (bodySize(body) > 10485760) {
|
|
18239
|
+
const response = await uploadMultipart(client, input, {
|
|
18240
|
+
kind: "composer",
|
|
18241
|
+
name: input.name
|
|
18242
|
+
}, input.uploadId);
|
|
18243
|
+
if (!response.upload) throw new Error("The upload did not return a staged file.");
|
|
18244
|
+
return response.upload;
|
|
18245
|
+
}
|
|
17773
18246
|
return (await client.requestJson({
|
|
17774
18247
|
...requestFields$1(input),
|
|
17775
18248
|
body,
|
|
@@ -17807,6 +18280,16 @@ async function updateSpaceFileContent(client, input) {
|
|
|
17807
18280
|
const body = toRequestBody(input.bytes);
|
|
17808
18281
|
validateSize(body);
|
|
17809
18282
|
const mimeType = parseMimeType(input.mimeType);
|
|
18283
|
+
if (bodySize(body) > 10485760) {
|
|
18284
|
+
const response = await uploadMultipart(client, input, {
|
|
18285
|
+
kind: "revision",
|
|
18286
|
+
clientMutationId: input.clientMutationId,
|
|
18287
|
+
fileId: input.fileId,
|
|
18288
|
+
baseRevision: input.baseRevision
|
|
18289
|
+
}, await mutationUploadId(input.clientMutationId));
|
|
18290
|
+
if (!response.file) throw new Error("The upload did not return a file.");
|
|
18291
|
+
return response.file;
|
|
18292
|
+
}
|
|
17810
18293
|
return (await client.requestJson({
|
|
17811
18294
|
...requestFields$1(input),
|
|
17812
18295
|
url: buildSpaceFileContentPath(input.spaceId, input.fileId, {
|
|
@@ -17822,6 +18305,13 @@ async function updateSpaceFileContent(client, input) {
|
|
|
17822
18305
|
})).file;
|
|
17823
18306
|
}
|
|
17824
18307
|
async function downloadSpaceFileContent(client, input) {
|
|
18308
|
+
const content = await streamSpaceFileContent(client, input);
|
|
18309
|
+
return {
|
|
18310
|
+
...content,
|
|
18311
|
+
bytes: await new Response(content.bytes).arrayBuffer()
|
|
18312
|
+
};
|
|
18313
|
+
}
|
|
18314
|
+
async function streamSpaceFileContent(client, input) {
|
|
17825
18315
|
const response = await client.requestResponse({
|
|
17826
18316
|
...requestFields$1(input),
|
|
17827
18317
|
url: buildSpaceFileContentPath(input.spaceId, input.fileId, { revision: input.revision }),
|
|
@@ -17834,8 +18324,9 @@ async function downloadSpaceFileContent(client, input) {
|
|
|
17834
18324
|
const mimeType = parseMimeType(response.headers.get("content-type") ?? "application/octet-stream");
|
|
17835
18325
|
const revision = Number(response.headers.get("x-openmeld-file-revision"));
|
|
17836
18326
|
if (!(Number.isInteger(revision) && revision > 0)) throw new Error("invalid Space file revision response header");
|
|
18327
|
+
if (!response.body) throw new Error("Space file download has no body.");
|
|
17837
18328
|
return {
|
|
17838
|
-
bytes:
|
|
18329
|
+
bytes: response.body,
|
|
17839
18330
|
mimeType,
|
|
17840
18331
|
revision
|
|
17841
18332
|
};
|
|
@@ -17860,7 +18351,7 @@ function toRequestBody(bytes) {
|
|
|
17860
18351
|
return copy.buffer;
|
|
17861
18352
|
}
|
|
17862
18353
|
function validateSize(body) {
|
|
17863
|
-
if ((body instanceof Blob ? body.size : body.byteLength) >
|
|
18354
|
+
if ((body instanceof Blob ? body.size : body.byteLength) > 262144e3) throw new Error("Space files must be 250 MiB or smaller");
|
|
17864
18355
|
}
|
|
17865
18356
|
function getSpaceHistoryNavigation(client, input) {
|
|
17866
18357
|
const query = new URLSearchParams();
|
|
@@ -17890,6 +18381,20 @@ async function leaveSpace(client, input) {
|
|
|
17890
18381
|
invalidMessage: "invalid leave space response"
|
|
17891
18382
|
});
|
|
17892
18383
|
}
|
|
18384
|
+
function getSpaceLinkPreviews(client, input) {
|
|
18385
|
+
const query = new URLSearchParams({ signalId: input.signalId });
|
|
18386
|
+
return client.requestJson({
|
|
18387
|
+
url: `/v1/spaces/${encodeURIComponent(input.spaceId)}/link-previews?${query}`,
|
|
18388
|
+
operation: "space.link_previews",
|
|
18389
|
+
method: "GET",
|
|
18390
|
+
requestContext: input.requestContext,
|
|
18391
|
+
signal: input.signal,
|
|
18392
|
+
timeoutMs: input.timeoutMs ?? 3e4,
|
|
18393
|
+
...input.spacePassword === void 0 ? {} : { spacePassword: input.spacePassword },
|
|
18394
|
+
schema: getSpaceLinkPreviewsResponseSchema,
|
|
18395
|
+
invalidMessage: "Invalid link preview response."
|
|
18396
|
+
});
|
|
18397
|
+
}
|
|
17893
18398
|
async function getSpaceMembersSnapshot(client, input) {
|
|
17894
18399
|
return await client.requestJson({
|
|
17895
18400
|
url: buildSpaceMembersPath(input.spaceId),
|
|
@@ -18045,6 +18550,8 @@ function requestFields(input) {
|
|
|
18045
18550
|
}
|
|
18046
18551
|
async function updateSpaceMeta(client, input) {
|
|
18047
18552
|
const parsedBody = patchSpaceMetaBodySchema.safeParse({
|
|
18553
|
+
...input.ownership === void 0 ? {} : { ownership: input.ownership },
|
|
18554
|
+
...input.allowGuests === void 0 ? {} : { allowGuests: input.allowGuests },
|
|
18048
18555
|
...input.visibility === void 0 ? {} : { visibility: input.visibility },
|
|
18049
18556
|
...input.name === void 0 ? {} : { name: input.name },
|
|
18050
18557
|
...input.purpose === void 0 ? {} : { purpose: input.purpose },
|
|
@@ -18055,7 +18562,10 @@ async function updateSpaceMeta(client, input) {
|
|
|
18055
18562
|
url: buildSpaceMetaPath(input.spaceId),
|
|
18056
18563
|
operation: "space.meta.update",
|
|
18057
18564
|
method: "PATCH",
|
|
18058
|
-
headers: {
|
|
18565
|
+
headers: {
|
|
18566
|
+
...currentSpaceAccessHeaders(),
|
|
18567
|
+
"content-type": "application/json"
|
|
18568
|
+
},
|
|
18059
18569
|
body: JSON.stringify(parsedBody.data),
|
|
18060
18570
|
requestContext: input.requestContext,
|
|
18061
18571
|
signal: input.signal,
|
|
@@ -18133,6 +18643,7 @@ async function getSpaceStatus(client, input) {
|
|
|
18133
18643
|
return await client.requestJson({
|
|
18134
18644
|
url: buildSpaceStatusPath(input.spaceId),
|
|
18135
18645
|
operation: "space.status.read",
|
|
18646
|
+
headers: currentSpaceAccessHeaders(),
|
|
18136
18647
|
requestContext: input.requestContext,
|
|
18137
18648
|
signal: input.signal,
|
|
18138
18649
|
timeoutMs: input.timeoutMs,
|
|
@@ -18206,16 +18717,13 @@ async function listSpaceThreadEvents(client, input) {
|
|
|
18206
18717
|
}
|
|
18207
18718
|
async function listSpaceThreadSignals(client, input) {
|
|
18208
18719
|
const parsedQuery = listSpaceThreadSignalsQuerySchema.safeParse({
|
|
18720
|
+
includeWakeContinuation: input.includeWakeContinuation,
|
|
18209
18721
|
afterSignalId: input.afterSignalId,
|
|
18210
18722
|
limit: input.limit
|
|
18211
18723
|
});
|
|
18212
18724
|
if (!parsedQuery.success) throw new Error(parsedQuery.error.issues[0]?.message ?? "Invalid bounded thread signals query");
|
|
18213
|
-
const hasBoundedQuery = parsedQuery.data.afterSignalId !== void 0;
|
|
18214
18725
|
return await client.requestJson({
|
|
18215
|
-
url: buildSpaceThreadSignalsPath(input.spaceId, input.threadId,
|
|
18216
|
-
afterSignalId: parsedQuery.data.afterSignalId,
|
|
18217
|
-
limit: parsedQuery.data.limit
|
|
18218
|
-
} : void 0),
|
|
18726
|
+
url: buildSpaceThreadSignalsPath(input.spaceId, input.threadId, parsedQuery.data.afterSignalId || parsedQuery.data.includeWakeContinuation ? parsedQuery.data : void 0),
|
|
18219
18727
|
operation: "space.thread.signals",
|
|
18220
18728
|
method: "GET",
|
|
18221
18729
|
headers: currentSpaceAddressingHeaders(),
|
|
@@ -18387,6 +18895,7 @@ const createSpaceApi = (client) => {
|
|
|
18387
18895
|
uploadAttachment: async (input) => await uploadSpaceAttachment(client, input),
|
|
18388
18896
|
listFiles: async (input) => await listSpaceFiles(client, input),
|
|
18389
18897
|
getFile: async (input) => await getSpaceFile(client, input),
|
|
18898
|
+
fileUpdateSettings: async (input) => await spaceFileUpdateSettings(client, input),
|
|
18390
18899
|
listFileRevisions: async (input) => await listSpaceFileRevisions(client, input),
|
|
18391
18900
|
createFolder: async (input) => await createSpaceFolder(client, input),
|
|
18392
18901
|
updateFileEntry: async (input) => await updateSpaceFileEntry(client, input),
|
|
@@ -18399,6 +18908,7 @@ const createSpaceApi = (client) => {
|
|
|
18399
18908
|
discardComposerUpload: async (input) => await discardSpaceComposerUpload(client, input),
|
|
18400
18909
|
updateFileContent: async (input) => await updateSpaceFileContent(client, input),
|
|
18401
18910
|
downloadFileContent: async (input) => await downloadSpaceFileContent(client, input),
|
|
18911
|
+
streamFileContent: async (input) => await streamSpaceFileContent(client, input),
|
|
18402
18912
|
removeMembers: async (input) => await removeSpaceMembers(client, input),
|
|
18403
18913
|
setAccessMode: async (input) => await setSpaceAccessMode(client, input),
|
|
18404
18914
|
updateMeta: async (input) => await updateSpaceMeta(client, input),
|
|
@@ -18424,6 +18934,7 @@ const createSpaceApi = (client) => {
|
|
|
18424
18934
|
getMessageReactions: (input) => getSpaceMessageReactions(client, input),
|
|
18425
18935
|
setMessageReaction: (input) => setSpaceMessageReaction(client, input),
|
|
18426
18936
|
getMessageDetails: async (input) => await getSpaceMessageDetails(client, input),
|
|
18937
|
+
getLinkPreviews: (input) => getSpaceLinkPreviews(client, input),
|
|
18427
18938
|
createDiagnosticReport: async (input) => await createSpaceDiagnosticReport(client, input),
|
|
18428
18939
|
mutateMessage: (input) => mutateSpaceMessage(client, input),
|
|
18429
18940
|
postNormalMessage: async (input) => await postSpaceNormalMessage(client, input),
|
|
@@ -18474,11 +18985,12 @@ function createFetchTransport(input) {
|
|
|
18474
18985
|
return async function fetchTransport(request) {
|
|
18475
18986
|
const timeoutMs = normalizeOptionalTimeoutMs(request.timeoutMs) ?? defaultTimeoutMs;
|
|
18476
18987
|
const timeoutSignal = timeoutMs === void 0 ? null : AbortSignal.timeout(timeoutMs);
|
|
18477
|
-
const
|
|
18988
|
+
const signals = [request.init?.signal, timeoutSignal].filter((signal) => signal != null);
|
|
18989
|
+
const signal = signals.length > 1 ? AbortSignal.any(signals) : signals[0];
|
|
18478
18990
|
try {
|
|
18479
18991
|
return await input.fetch(request.url, {
|
|
18480
18992
|
...request.init,
|
|
18481
|
-
signal
|
|
18993
|
+
signal
|
|
18482
18994
|
});
|
|
18483
18995
|
} catch (error) {
|
|
18484
18996
|
if (timeoutSignal?.aborted && timeoutMs !== void 0) throw createTimeoutError({
|
|
@@ -18492,8 +19004,6 @@ function createFetchTransport(input) {
|
|
|
18492
19004
|
cause: error
|
|
18493
19005
|
});
|
|
18494
19006
|
throw error;
|
|
18495
|
-
} finally {
|
|
18496
|
-
composed.cleanup();
|
|
18497
19007
|
}
|
|
18498
19008
|
};
|
|
18499
19009
|
}
|
|
@@ -18532,42 +19042,7 @@ function shouldWrapNetworkRequestError(error) {
|
|
|
18532
19042
|
const message = toErrorMessage(error).toLowerCase();
|
|
18533
19043
|
return message.includes("fetch failed") || message.includes("failed to fetch") || message.includes("network request failed");
|
|
18534
19044
|
}
|
|
18535
|
-
function composeAbortSignals(parent, timeout) {
|
|
18536
|
-
if (!(parent || timeout)) return {
|
|
18537
|
-
signal: void 0,
|
|
18538
|
-
cleanup: () => void 0
|
|
18539
|
-
};
|
|
18540
|
-
if (!parent) return {
|
|
18541
|
-
signal: timeout ?? void 0,
|
|
18542
|
-
cleanup: () => void 0
|
|
18543
|
-
};
|
|
18544
|
-
if (!timeout) return {
|
|
18545
|
-
signal: parent,
|
|
18546
|
-
cleanup: () => void 0
|
|
18547
|
-
};
|
|
18548
|
-
if (parent.aborted || timeout.aborted) {
|
|
18549
|
-
const controller = new AbortController();
|
|
18550
|
-
controller.abort();
|
|
18551
|
-
return {
|
|
18552
|
-
signal: controller.signal,
|
|
18553
|
-
cleanup: () => void 0
|
|
18554
|
-
};
|
|
18555
|
-
}
|
|
18556
|
-
const controller = new AbortController();
|
|
18557
|
-
const abort = () => {
|
|
18558
|
-
controller.abort();
|
|
18559
|
-
};
|
|
18560
|
-
parent.addEventListener("abort", abort, { once: true });
|
|
18561
|
-
timeout.addEventListener("abort", abort, { once: true });
|
|
18562
|
-
return {
|
|
18563
|
-
signal: controller.signal,
|
|
18564
|
-
cleanup: () => {
|
|
18565
|
-
parent.removeEventListener("abort", abort);
|
|
18566
|
-
timeout.removeEventListener("abort", abort);
|
|
18567
|
-
}
|
|
18568
|
-
};
|
|
18569
|
-
}
|
|
18570
19045
|
//#endregion
|
|
18571
|
-
export { buildLocalFolderPickerPath as $,
|
|
19046
|
+
export { buildLocalFolderPickerPath as $, DEFAULT_AGENT_PROFILE_CREATION_CONFIGURATION as $n, spaceMemberDirectorySchema as $r, createProfilesApi as $t, buildCurrentOrganizationDirectoryPath as A, resolveCustomMentionAliasOverride as An, deleteCenterAgentRoutineResponseSchema as Ar, createAccountSpaceIndexApi as At, buildCurrentOrganizationMessageChannelsPath as B, SPACE_DISPATCH_TRACE_PROMPT_PREVIEW_MAX_CHARS as Bn, agentActivitySessionStatusSchema as Br, createFetchTransport as Bt, buildCenterAgentSessionPath as C, uploadSpaceFile as Cn, authProfileManagedRoleSchema as Cr, buildRoutineTargetSpacesPath as Ct, buildCurrentAgentProfileSessionRoute as D, parseEnvelope as Dn, submitFeedbackIssueRequestSchema as Dr, buildSpaceInboxReadThroughPath as Dt, buildComputerFileAccessUpdatePath as E, MAX_TEXT_LENGTH as En, organizationComputersResponseSchema as Er, buildSpaceBootstrapReadPath as Et, buildCurrentOrganizationMessageChannelPath as F, buildOpenMeldRequestContextHeaders as Fn, updateCenterAgentRoutineResponseSchema as Fr, createComputerFileAccessApi as Ft, buildFeedbackIssueSubmissionPath as G, spaceDispatchTraceDispatchStatusSchema as Gn, localProjectControlDiscoverProjectsResponseSchema as Gr, createOpenMeldApiClient as Gt, buildCurrentOrganizationSpacesWithMemberCountsPath as H, projectSpaceDispatchTraceFinalVisibleOutcome as Hn, agentActivitySnapshotResponseSchema as Hr, createLocalFolderPickerApi as Ht, buildCurrentOrganizationMessageChannelRegistrationPath as I, toErrorMessage$2 as In, AGENT_ACTIVITY_EVENT_MAX_BYTES as Ir, createConfigApi as It, buildInboxItemReadPath as J, projectObservabilityWakeCorrelation as Jn, removeSpaceMembersResponseSchema as Jr, createOrganizationSkillsApi as Jt, buildInboxItemDismissPath as K, spaceDispatchTraceResponseSchema as Kn, leaveSpaceResponseSchema as Kr, createOrganizationApi as Kt, buildCurrentOrganizationMessageChannelRegistrationPollPath as L, getSpaceUpdatesResponseSchema as Ln, AGENT_ACTIVITY_PRESENCE_TTL_MAX_MS as Lr, createCurrentDeviceApi as Lt, buildCurrentOrganizationInformationProtectionPath as M, OPENMELD_HEADER_REQUESTED_ORGANIZATION_ID as Mn, listCenterAgentRoutinesResponseSchema as Mr, createAgentProfileBindingApi as Mt, buildCurrentOrganizationLogoPath as N, OPENMELD_HEADER_REQUEST_ID as Nn, pauseCenterAgentRoutineResponseSchema as Nr, createAgentProfileWorkRecoveryApi as Nt, buildCurrentOrganizationCenterAgentMemoryWipeSelfPath as O, parseIncoming as On, submitFeedbackIssueResponseSchema as Or, buildSpaceInboxSummaryPath as Ot, buildCurrentOrganizationMemberOpenMeldServiceStatusesPath as P, OPENMELD_HEADER_SPACE_ADDRESSING_VERSION as Pn, resumeCenterAgentRoutineResponseSchema as Pr, createCenterAgentApi as Pt, buildInboxSummaryPath as Q, summarizeComputerFileAccessPolicy as Qn, spaceMemberDirectoryEntrySchema as Qr, createProfileSpaceHistoryApi as Qt, buildCurrentOrganizationMessageChannelRegistrationsPath as R, spaceEntryTargetSchema as Rn, agentActivityEventSchema as Rr, createDirectMessageApi as Rt, buildCenterAgentProfilePath as S, toCompatibleSpaceAddressingRequestWireValue as Si, uploadSpaceAttachment as Sn, authProfileKindSchema as Sr, buildRoutineRunsPath as St, buildComputerFileAccessReadPath as T, DAEMON_STREAM_KEEPALIVE_PONG as Tn, profileErrorResponseSchema as Tr, buildSpaceAttachmentDownloadPath as Tt, buildDirectMessageConversionPath as U, resolveSpaceDispatchTraceRootCause as Un, localProjectControlConnectionSchema as Ur, createLocalProjectControlApi as Ut, buildCurrentOrganizationSpacesPath as V, SPACE_DISPATCH_TRACE_RESPONSE_CONTRACT_VERSION_HEADER as Vn, agentActivitySnapshotQuerySchema as Vr, createInboxApi as Vt, buildDirectMessageSpacePath as W, spaceDispatchTraceAttemptStatusSchema as Wn, localProjectControlDaemonFrameSchema as Wr, createLocalRuntimeExpectedRoutesApi as Wt, buildInboxPath as X, ownerComputerDiagnosticsSchema as Xn, spaceMemberAgentWakeAvailabilitySchema as Xr, createPluginsApi as Xt, buildInboxMarkAllReadPath as Y, submitAgentControllerTaskLifecycleEventItemSchema as Yn, resolvedSpaceMemberProfileSchema as Yr, createOrganizationUsageApi as Yt, buildInboxPreferencesPath as Z, projectOwnerComputerLocalRuntimes as Zn, spaceMemberDirectoryAllowedRelationsSchema as Zr, createPrepareReadinessApi as Zt, buildCenterAgentDirectMessageSpacePath as _, START_TRIMMED_NON_EMPTY_STRING_SCHEMA as _i, toStructuredApiClientFailure as _n, organizationSkillSummarySchema as _r, buildProjectPath as _t, buildAgentActivitySessionsPath as a, localAgentSessionProviderSchema as ai, downloadSpaceFileContent as an, computerFileAccessDaemonFrameSchema as ar, buildOrganizationDocumentsPath as at, buildCenterAgentMemberResearchPath as b, agentControllerPermissionModeSchema as bi, updateSpaceFileEntry as bn, ADDITIONAL_HUMAN_PROFILE_CREATION_DISABLED_CODE as br, buildRoutinePausePath as bt, buildAgentProfileCreationApprovalPreferencePath as c, createProjectResponseSchema as ci, listSpaceFileRevisions as cn, modelCatalogSchema as cr, buildOrganizationSkillGitHubPreviewPath as ct, buildAgentProfileCreationRequestDecisionPath as d, updateProjectResponseSchema as di, publicSpaceUrls as dn, spaceCreatorSchema as dr, buildOrganizationSkillsPath as dt, spaceMemberKindSchema as ei, createProjectsApi as en, agentProfileCreationConfigurationSchema as er, buildLocalProjectControlPath as et, buildAgentProfileCreationRequestRetryPath as f, centerAgentToolSpeakerSchema as fi, readOrUpdateSpaceFilePins as fn, spaceMetaSchema as fr, buildOrganizationUsageOverviewPath as ft, buildCenterAgentDesignationPath as g, START_ISO_DATE_TIME_SCHEMA as gi, setSpaceAccessMode as gn, organizationSkillReleaseSummarySchema as gr, buildProfileSpaceHistoryUpsertPath as gt, buildCenterAgentAuditJournalPath as h, START_BOUNDED_VERSION_SCHEMA as hi, resolveProfileSpaceHistoryGatewayHost as hn, organizationSkillBundleSchema as hr, buildProfileSpaceHistoryStatusPath as ht, buildAccountSpaceIndexPath as i, agentActivitySessionInventoryResponseSchema as ii, createSpaceFolder as in, OPENMELD_RUNTIME_CAPABILITIES_HEADER as ir, buildOrganizationDocumentPath as it, buildCurrentOrganizationFeedbackReportingPolicyPath as j, OPENMELD_HEADER_PROFILE_ID as jn, listCenterAgentRoutineRunsResponseSchema as jr, createAgentActivityApi as jt, buildCurrentOrganizationComputersPath as k, parseServerErrorFrame as kn, createCenterAgentRoutineResponseSchema as kr, buildSpaceInboxUnreadTargetsPath as kt, buildAgentProfileCreationDefaultsPath as l, listProjectsResponseSchema as li, listSpaceFiles as ln, organizationSpaceDirectoryWithMemberCountsResponseSchema as lr, buildOrganizationSkillMaintainersPath as lt, buildAgentProfileWorkRecoveryRoute as m, START_BOUNDED_ID_SCHEMA as mi, resolveAccountSpaceIndexGatewayHost as mn, listOrganizationSkillsResponseSchema as mr, buildProfileSpaceHistoryListPath as mt, OpenMeldApiClientInvalidResponseError as n, agentActivityInventorySessionStatusSchema as ni, createRuntimeReportingApi as nn, gatewayErrorEnvelopeSchema as nr, buildOrganizationDocumentApproveDraftPath as nt, buildAgentActivitySnapshotPath as o, observedLocalAgentSessionSchema as oi, getModelCatalog as on, computerFileAccessPolicyInputSchema as or, buildOrganizationSkillEnabledPath as ot, buildAgentProfileCreationRequestsPath as p, openCodePermissionConfigSchema as pi, readOrUpdateSpaceMessagePins as pn, getOrganizationSkillResponseSchema as pr, buildProfileRoute as pt, buildInboxItemPath as q, observabilityWakeTraceSelectorSchema as qn, postSpaceMembersResponseSchema as qr, createOrganizationDocumentsApi as qt, buildAccountSpaceActiveWakeSummaryPath as r, agentActivitySessionInventoryQuerySchema as ri, createSpaceApi as rn, COMPUTER_FILE_ACCESS_RUNTIME_CAPABILITY as rr, buildOrganizationDocumentDiscardDraftPath as rt, buildAgentActivityStatsPath as s, archiveProjectResponseSchema as si, getSpaceFile as sn, computerFileAccessPolicySchema as sr, buildOrganizationSkillGitHubImportPath as st, OpenMeldApiClientHttpError as t, agentActivityInventorySessionOriginSchema as ti, createRoutinesApi as tn, createAgentProfileCreationRequestBodySchema as tr, buildModelCatalogPath as tt, buildAgentProfileCreationRequestCancelPath as u, projectSchema as ui, normalizeApiBaseUrl as un, resolveInitialSpaceAccessMode as ur, buildOrganizationSkillPath as ut, buildCenterAgentInboxReadThroughPath as v, startReplyReadinessSummarySchema as vi, trashSpaceFileEntry as vn, stringifyOrganizationSkillBundleCanonicalJson as vr, buildProjectsPath as vt, buildCenterAgentSessionsPath as w, DAEMON_STREAM_KEEPALIVE_PING as wn, profileCapabilitiesResponseSchema as wr, buildRoutinesPath as wt, buildCenterAgentOperatingStatePath as x, agentControllerCollaborationModeSchema as xi, updateSpaceMeta as xn, ADDITIONAL_HUMAN_PROFILE_CREATION_DISABLED_MESSAGE as xr, buildRoutineResumePath as xt, buildCenterAgentInboxSummaryPath as y, localAgentCatalogSchema as yi, updateSpaceFileContent as yn, organizationDirectoryResponseSchema as yr, buildRoutinePath as yt, buildCurrentOrganizationMessageChannelSetupRequestsPath as z, pluginActionRequestSchema as zn, agentActivityProviderSchema as zr, createFeedbackApi as zt };
|
|
18572
19047
|
|
|
18573
|
-
//# sourceMappingURL=dist-
|
|
19048
|
+
//# sourceMappingURL=dist-DMOtlPEO.js.map
|