@opengeni/contracts 0.40.0 → 0.44.1
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/atlassian.d.ts +278 -0
- package/dist/atlassian.js +55 -0
- package/dist/atlassian.js.map +1 -0
- package/dist/chunk-52SGB2QO.js +688 -0
- package/dist/chunk-52SGB2QO.js.map +1 -0
- package/dist/{chunk-7JZMI22I.js → chunk-5UDNP7AO.js} +34 -2
- package/dist/chunk-5UDNP7AO.js.map +1 -0
- package/dist/chunk-BVGIYW7D.js +11 -0
- package/dist/chunk-BVGIYW7D.js.map +1 -0
- package/dist/chunk-CADSX6UN.js +1145 -0
- package/dist/chunk-CADSX6UN.js.map +1 -0
- package/dist/chunk-D2HKF2EF.js +1460 -0
- package/dist/chunk-D2HKF2EF.js.map +1 -0
- package/dist/chunk-FJBG5E4O.js +194 -0
- package/dist/chunk-FJBG5E4O.js.map +1 -0
- package/dist/chunk-H5BVCZKF.js +382 -0
- package/dist/chunk-H5BVCZKF.js.map +1 -0
- package/dist/chunk-LSB7GRLG.js +779 -0
- package/dist/chunk-LSB7GRLG.js.map +1 -0
- package/dist/chunk-MYBZRDTY.js +340 -0
- package/dist/chunk-MYBZRDTY.js.map +1 -0
- package/dist/chunk-RIY7GYQS.js +1204 -0
- package/dist/chunk-RIY7GYQS.js.map +1 -0
- package/dist/chunk-TZ6YEYN4.js +386 -0
- package/dist/chunk-TZ6YEYN4.js.map +1 -0
- package/dist/chunk-VA22KRHS.js +15177 -0
- package/dist/chunk-VA22KRHS.js.map +1 -0
- package/dist/chunk-Y3MLSLB4.js +392 -0
- package/dist/chunk-Y3MLSLB4.js.map +1 -0
- package/dist/chunk-YRKRZ6OF.js +134 -0
- package/dist/chunk-YRKRZ6OF.js.map +1 -0
- package/dist/company-profile.d.ts +629 -0
- package/dist/document-artifact-commands.d.ts +282 -0
- package/dist/document-artifact-commands.js +54 -0
- package/dist/document-artifact-commands.js.map +1 -0
- package/dist/document-artifact-query.d.ts +2 -0
- package/dist/document-artifact-query.js +54 -0
- package/dist/document-artifact-query.js.map +1 -0
- package/dist/editable-artifact-binary.d.ts +56 -0
- package/dist/editable-artifact-causal-frontier.d.ts +12 -0
- package/dist/editable-artifact-causal-frontier.js +18 -0
- package/dist/editable-artifact-causal-frontier.js.map +1 -0
- package/dist/editable-artifact-codec-registry.d.ts +48 -0
- package/dist/editable-artifact-codec-registry.js +20 -0
- package/dist/editable-artifact-codec-registry.js.map +1 -0
- package/dist/editable-artifact-committed-transaction.d.ts +35 -0
- package/dist/editable-artifact-committed-transaction.js +19 -0
- package/dist/editable-artifact-committed-transaction.js.map +1 -0
- package/dist/editable-artifact-live.d.ts +276 -0
- package/dist/editable-artifact-live.js +907 -0
- package/dist/editable-artifact-live.js.map +1 -0
- package/dist/editable-artifact-serialized-commit.d.ts +53 -0
- package/dist/editable-artifact-serialized-commit.js +26 -0
- package/dist/editable-artifact-serialized-commit.js.map +1 -0
- package/dist/editable-artifact-versions.d.ts +6 -0
- package/dist/editable-artifact-versions.js +11 -0
- package/dist/editable-artifact-versions.js.map +1 -0
- package/dist/editable-artifacts.d.ts +46 -0
- package/dist/editable-artifacts.js +236 -0
- package/dist/editable-artifacts.js.map +1 -0
- package/dist/event-preview.d.ts +1 -1
- package/dist/google-drive.d.ts +114 -2
- package/dist/google-drive.js +70 -14
- package/dist/google-drive.js.map +1 -1
- package/dist/image-generation.d.ts +70 -0
- package/dist/index.d.ts +4460 -155
- package/dist/index.js +1127 -30
- package/dist/interaction.d.ts +6895 -0
- package/dist/memory-slack-delivery.d.ts +397 -0
- package/dist/presentation-artifact-commands.d.ts +349 -0
- package/dist/presentation-artifact-commands.js +66 -0
- package/dist/presentation-artifact-commands.js.map +1 -0
- package/dist/presentation-artifact-query.d.ts +2 -0
- package/dist/presentation-artifact-query.js +66 -0
- package/dist/presentation-artifact-query.js.map +1 -0
- package/dist/retained-output.d.ts +24 -0
- package/dist/sandbox-snapshots.d.ts +9 -0
- package/dist/scoped-knowledge.d.ts +14 -13
- package/dist/slack-bot-scopes.d.ts +4 -0
- package/dist/slack-bot-scopes.js +3 -1
- package/dist/spreadsheet-artifact-commands.d.ts +101 -0
- package/dist/spreadsheet-artifact-commands.js +27 -0
- package/dist/spreadsheet-artifact-commands.js.map +1 -0
- package/dist/spreadsheet-artifact-date.d.ts +4 -0
- package/dist/spreadsheet-artifact-query.d.ts +120 -0
- package/dist/spreadsheet-artifact-query.js +48 -0
- package/dist/spreadsheet-artifact-query.js.map +1 -0
- package/dist/tool-catalog.d.ts +576 -0
- package/dist/video-generation.d.ts +532 -0
- package/dist/video-generation.js +51 -0
- package/dist/video-generation.js.map +1 -0
- package/dist/workspace-learning-policy.d.ts +208 -0
- package/package.json +61 -1
- package/src/atlassian.ts +160 -0
- package/src/company-profile.ts +306 -0
- package/src/document-artifact-commands.ts +1709 -0
- package/src/document-artifact-query.ts +2 -0
- package/src/editable-artifact-binary.ts +396 -0
- package/src/editable-artifact-causal-frontier.ts +154 -0
- package/src/editable-artifact-codec-registry.ts +261 -0
- package/src/editable-artifact-committed-transaction.ts +478 -0
- package/src/editable-artifact-live.ts +1379 -0
- package/src/editable-artifact-serialized-commit.ts +494 -0
- package/src/editable-artifact-versions.ts +8 -0
- package/src/editable-artifacts.ts +473 -0
- package/src/google-drive.ts +68 -15
- package/src/image-generation.ts +106 -0
- package/src/index.ts +2326 -325
- package/src/interaction.ts +2292 -0
- package/src/memory-slack-delivery.ts +183 -0
- package/src/presentation-artifact-commands.ts +2035 -0
- package/src/presentation-artifact-query.ts +2 -0
- package/src/retained-output.ts +149 -2
- package/src/sandbox-snapshots.ts +28 -1
- package/src/scoped-knowledge.ts +18 -4
- package/src/slack-bot-scopes.ts +34 -1
- package/src/spreadsheet-artifact-commands.ts +999 -0
- package/src/spreadsheet-artifact-date.ts +21 -0
- package/src/spreadsheet-artifact-query.ts +1411 -0
- package/src/tool-catalog.ts +334 -0
- package/src/video-generation.ts +394 -0
- package/src/workspace-learning-policy.ts +233 -0
- package/dist/chunk-5HR2GPSC.js +0 -11031
- package/dist/chunk-5HR2GPSC.js.map +0 -1
- package/dist/chunk-7JZMI22I.js.map +0 -1
package/src/retained-output.ts
CHANGED
|
@@ -15,6 +15,10 @@ export const COMPUTER_SCREENSHOT_MAX_PIXELS = 67_108_864;
|
|
|
15
15
|
export const COMPUTER_SCREENSHOT_RETENTION_MS = 30 * 24 * 60 * 60 * 1_000;
|
|
16
16
|
/** Hard workspace reservation across pending + ready screenshot artifacts. */
|
|
17
17
|
export const COMPUTER_SCREENSHOT_WORKSPACE_QUOTA_BYTES = 5 * 1024 * 1024 * 1024;
|
|
18
|
+
/** Generated images are permanent workspace files, never inline history blobs. */
|
|
19
|
+
export const GENERATED_IMAGE_MAX_BYTES = 64 * 1024 * 1024;
|
|
20
|
+
/** Generated videos are permanent workspace files and are always streamed. */
|
|
21
|
+
export const GENERATED_VIDEO_MAX_BYTES = 512 * 1024 * 1024;
|
|
18
22
|
|
|
19
23
|
const encoder = new TextEncoder();
|
|
20
24
|
const LOWERCASE_UUID = /^[0-9a-f]{8}-[0-9a-f]{4}-[1-8][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/;
|
|
@@ -31,6 +35,8 @@ export const RetainedOutputKind = z.enum([
|
|
|
31
35
|
"internal_update",
|
|
32
36
|
"event_media",
|
|
33
37
|
"computer_screenshot",
|
|
38
|
+
"generated_image",
|
|
39
|
+
"generated_video",
|
|
34
40
|
"file",
|
|
35
41
|
]);
|
|
36
42
|
export type RetainedOutputKind = z.infer<typeof RetainedOutputKind>;
|
|
@@ -116,14 +122,72 @@ export const RetainedArtifactReferenceSchema = z
|
|
|
116
122
|
});
|
|
117
123
|
}
|
|
118
124
|
|
|
119
|
-
if (
|
|
125
|
+
if (
|
|
126
|
+
value.kind === "computer_screenshot" ||
|
|
127
|
+
value.kind === "generated_image" ||
|
|
128
|
+
value.kind === "generated_video"
|
|
129
|
+
) {
|
|
120
130
|
if (!value.dimensions) {
|
|
121
131
|
ctx.addIssue({
|
|
122
132
|
code: "custom",
|
|
123
133
|
path: ["dimensions"],
|
|
124
|
-
message:
|
|
134
|
+
message: `${value.kind} receipts require exact dimensions`,
|
|
135
|
+
});
|
|
136
|
+
} else if (
|
|
137
|
+
value.dimensions.width * value.dimensions.height >
|
|
138
|
+
COMPUTER_SCREENSHOT_MAX_PIXELS
|
|
139
|
+
) {
|
|
140
|
+
ctx.addIssue({
|
|
141
|
+
code: "custom",
|
|
142
|
+
path: ["dimensions"],
|
|
143
|
+
message: `${value.kind} dimensions exceed the pixel limit`,
|
|
144
|
+
});
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
if (value.kind === "generated_image") {
|
|
149
|
+
if (value.retention.policy !== "workspace_file" || !workspaceMatch || sessionMatch) {
|
|
150
|
+
ctx.addIssue({
|
|
151
|
+
code: "custom",
|
|
152
|
+
path: ["retention"],
|
|
153
|
+
message: "generated images require permanent workspace-file retrieval",
|
|
154
|
+
});
|
|
155
|
+
}
|
|
156
|
+
if (
|
|
157
|
+
!["image/png", "image/jpeg", "image/webp"].includes(value.contentType) ||
|
|
158
|
+
value.originalBytes <= 0 ||
|
|
159
|
+
value.originalBytes > GENERATED_IMAGE_MAX_BYTES
|
|
160
|
+
) {
|
|
161
|
+
ctx.addIssue({
|
|
162
|
+
code: "custom",
|
|
163
|
+
path: ["contentType"],
|
|
164
|
+
message: "generated image media metadata is invalid",
|
|
125
165
|
});
|
|
126
166
|
}
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
if (value.kind === "generated_video") {
|
|
170
|
+
if (value.retention.policy !== "workspace_file" || !workspaceMatch || sessionMatch) {
|
|
171
|
+
ctx.addIssue({
|
|
172
|
+
code: "custom",
|
|
173
|
+
path: ["retention"],
|
|
174
|
+
message: "generated videos require permanent workspace-file retrieval",
|
|
175
|
+
});
|
|
176
|
+
}
|
|
177
|
+
if (
|
|
178
|
+
value.contentType !== "video/mp4" ||
|
|
179
|
+
value.originalBytes <= 0 ||
|
|
180
|
+
value.originalBytes > GENERATED_VIDEO_MAX_BYTES
|
|
181
|
+
) {
|
|
182
|
+
ctx.addIssue({
|
|
183
|
+
code: "custom",
|
|
184
|
+
path: ["contentType"],
|
|
185
|
+
message: "generated video media metadata is invalid",
|
|
186
|
+
});
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
if (value.kind === "computer_screenshot") {
|
|
127
191
|
if (value.retention.policy !== "session_screenshot" || !sessionMatch) {
|
|
128
192
|
ctx.addIssue({
|
|
129
193
|
code: "custom",
|
|
@@ -190,6 +254,16 @@ export type RetainedScreenshotArtifactInput = RetainedArtifactFileInput & {
|
|
|
190
254
|
expiresAt: string;
|
|
191
255
|
};
|
|
192
256
|
|
|
257
|
+
export type RetainedGeneratedImageArtifactInput = RetainedArtifactFileInput & {
|
|
258
|
+
width: number;
|
|
259
|
+
height: number;
|
|
260
|
+
};
|
|
261
|
+
|
|
262
|
+
export type RetainedGeneratedVideoArtifactInput = RetainedArtifactFileInput & {
|
|
263
|
+
width: number;
|
|
264
|
+
height: number;
|
|
265
|
+
};
|
|
266
|
+
|
|
193
267
|
/**
|
|
194
268
|
* Convert a ready, integrity-addressed workspace file into the only available
|
|
195
269
|
* retained-output receipt shape. Invalid, pending, or checksum-less files fail
|
|
@@ -252,6 +326,79 @@ export function retainedScreenshotReferenceFromFile(
|
|
|
252
326
|
return parsed.success ? parsed.data : null;
|
|
253
327
|
}
|
|
254
328
|
|
|
329
|
+
/** Build the permanent workspace receipt for one validated generated image. */
|
|
330
|
+
export function retainedGeneratedImageReferenceFromFile(
|
|
331
|
+
file: RetainedGeneratedImageArtifactInput,
|
|
332
|
+
): RetainedArtifactReference | null {
|
|
333
|
+
if (
|
|
334
|
+
file.status !== "ready" ||
|
|
335
|
+
!file.sha256 ||
|
|
336
|
+
file.sizeBytes <= 0 ||
|
|
337
|
+
file.sizeBytes > GENERATED_IMAGE_MAX_BYTES
|
|
338
|
+
) {
|
|
339
|
+
return null;
|
|
340
|
+
}
|
|
341
|
+
const value = {
|
|
342
|
+
available: true as const,
|
|
343
|
+
artifactId: file.id,
|
|
344
|
+
kind: "generated_image" as const,
|
|
345
|
+
contentType: canonicalRetainedContentType(file.contentType),
|
|
346
|
+
originalBytes: file.sizeBytes,
|
|
347
|
+
sha256: file.sha256,
|
|
348
|
+
retainedAt: file.updatedAt,
|
|
349
|
+
dimensions: { width: file.width, height: file.height },
|
|
350
|
+
retention: {
|
|
351
|
+
policy: "workspace_file" as const,
|
|
352
|
+
expiresAt: null,
|
|
353
|
+
},
|
|
354
|
+
retrieval: {
|
|
355
|
+
method: "GET" as const,
|
|
356
|
+
path: `/v1/workspaces/${file.workspaceId}/artifacts/${file.id}/content`,
|
|
357
|
+
acceptRanges: "bytes" as const,
|
|
358
|
+
maxRangeBytes: RETAINED_OUTPUT_MAX_PAGE_BYTES,
|
|
359
|
+
},
|
|
360
|
+
};
|
|
361
|
+
const parsed = RetainedArtifactReferenceSchema.safeParse(value);
|
|
362
|
+
return parsed.success ? parsed.data : null;
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
/** Build the permanent workspace receipt for one validated generated video. */
|
|
366
|
+
export function retainedGeneratedVideoReferenceFromFile(
|
|
367
|
+
file: RetainedGeneratedVideoArtifactInput,
|
|
368
|
+
): RetainedArtifactReference | null {
|
|
369
|
+
if (
|
|
370
|
+
file.status !== "ready" ||
|
|
371
|
+
file.contentType !== "video/mp4" ||
|
|
372
|
+
!file.sha256 ||
|
|
373
|
+
file.sizeBytes <= 0 ||
|
|
374
|
+
file.sizeBytes > GENERATED_VIDEO_MAX_BYTES
|
|
375
|
+
) {
|
|
376
|
+
return null;
|
|
377
|
+
}
|
|
378
|
+
const value = {
|
|
379
|
+
available: true as const,
|
|
380
|
+
artifactId: file.id,
|
|
381
|
+
kind: "generated_video" as const,
|
|
382
|
+
contentType: "video/mp4" as const,
|
|
383
|
+
originalBytes: file.sizeBytes,
|
|
384
|
+
sha256: file.sha256,
|
|
385
|
+
retainedAt: file.updatedAt,
|
|
386
|
+
dimensions: { width: file.width, height: file.height },
|
|
387
|
+
retention: {
|
|
388
|
+
policy: "workspace_file" as const,
|
|
389
|
+
expiresAt: null,
|
|
390
|
+
},
|
|
391
|
+
retrieval: {
|
|
392
|
+
method: "GET" as const,
|
|
393
|
+
path: `/v1/workspaces/${file.workspaceId}/artifacts/${file.id}/content`,
|
|
394
|
+
acceptRanges: "bytes" as const,
|
|
395
|
+
maxRangeBytes: RETAINED_OUTPUT_MAX_PAGE_BYTES,
|
|
396
|
+
},
|
|
397
|
+
};
|
|
398
|
+
const parsed = RetainedArtifactReferenceSchema.safeParse(value);
|
|
399
|
+
return parsed.success ? parsed.data : null;
|
|
400
|
+
}
|
|
401
|
+
|
|
255
402
|
function canonicalRetainedContentType(value: string): string {
|
|
256
403
|
const mediaType = value.split(";", 1)[0]?.trim().toLowerCase() ?? "";
|
|
257
404
|
return CANONICAL_MEDIA_TYPE.test(mediaType) ? mediaType : "application/octet-stream";
|
package/src/sandbox-snapshots.ts
CHANGED
|
@@ -6,6 +6,14 @@ export type WorkspaceTreeFingerprint = {
|
|
|
6
6
|
entryCount: number;
|
|
7
7
|
fileCount: number;
|
|
8
8
|
totalFileBytes: number;
|
|
9
|
+
/**
|
|
10
|
+
* Absent means the original deterministic GNU-tar projection used by remote
|
|
11
|
+
* sandboxes. Host-backed Local/Docker sessions use the Agents SDK's portable
|
|
12
|
+
* archive projection, which intentionally contains directories and regular
|
|
13
|
+
* files only. Keeping the discriminator in the descriptor makes restores
|
|
14
|
+
* stable when a Docker image changes and preserves old descriptor behavior.
|
|
15
|
+
*/
|
|
16
|
+
projection?: "sdk_local_archive_v1";
|
|
9
17
|
};
|
|
10
18
|
|
|
11
19
|
export type TarWorkspaceArchiveDescriptor = {
|
|
@@ -114,7 +122,8 @@ export function parseWorkspaceArchiveDescriptor(value: unknown): WorkspaceArchiv
|
|
|
114
122
|
!SHA256.test(workspace.sha256) ||
|
|
115
123
|
!nonnegativeInteger(workspace.entryCount) ||
|
|
116
124
|
!nonnegativeInteger(workspace.fileCount) ||
|
|
117
|
-
!nonnegativeInteger(workspace.totalFileBytes)
|
|
125
|
+
!nonnegativeInteger(workspace.totalFileBytes) ||
|
|
126
|
+
(workspace.projection !== undefined && workspace.projection !== "sdk_local_archive_v1")
|
|
118
127
|
) {
|
|
119
128
|
return null;
|
|
120
129
|
}
|
|
@@ -181,6 +190,24 @@ export function decodeNativeSnapshotRef(bytes: Uint8Array): NativeSnapshotRef |
|
|
|
181
190
|
return null;
|
|
182
191
|
}
|
|
183
192
|
|
|
193
|
+
export function encodeNativeSnapshotRef(ref: NativeSnapshotRef): Uint8Array {
|
|
194
|
+
const prefix = NATIVE_SNAPSHOT_PREFIXES.find((entry) => entry.provider === ref.provider)?.prefix;
|
|
195
|
+
if (!prefix || typeof ref.snapshotId !== "string" || ref.snapshotId.length === 0) {
|
|
196
|
+
throw new TypeError("Native snapshot reference requires a supported provider and snapshot id");
|
|
197
|
+
}
|
|
198
|
+
if (ref.workspacePersistence !== undefined && typeof ref.workspacePersistence !== "string") {
|
|
199
|
+
throw new TypeError("Native snapshot workspace persistence must be a string");
|
|
200
|
+
}
|
|
201
|
+
return new TextEncoder().encode(
|
|
202
|
+
`${prefix}${JSON.stringify({
|
|
203
|
+
snapshot_id: ref.snapshotId,
|
|
204
|
+
...(ref.workspacePersistence === undefined
|
|
205
|
+
? {}
|
|
206
|
+
: { workspace_persistence: ref.workspacePersistence }),
|
|
207
|
+
})}`,
|
|
208
|
+
);
|
|
209
|
+
}
|
|
210
|
+
|
|
184
211
|
export function backendForNativeSnapshotProvider(provider: NativeSnapshotProvider): string {
|
|
185
212
|
return provider === "modal_snapshot_directory" || provider === "modal_snapshot_filesystem"
|
|
186
213
|
? "modal"
|
package/src/scoped-knowledge.ts
CHANGED
|
@@ -4,10 +4,24 @@ import { z } from "zod";
|
|
|
4
4
|
export const ScopedKnowledgeScopeKind = z.enum(["organization", "workspace", "personal"]);
|
|
5
5
|
export type ScopedKnowledgeScopeKind = z.infer<typeof ScopedKnowledgeScopeKind>;
|
|
6
6
|
|
|
7
|
-
export
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
export const ScopedKnowledgeScope = z.discriminatedUnion("kind", [
|
|
8
|
+
z.object({
|
|
9
|
+
kind: z.literal("organization"),
|
|
10
|
+
workspaceId: z.null(),
|
|
11
|
+
subjectId: z.null(),
|
|
12
|
+
}),
|
|
13
|
+
z.object({
|
|
14
|
+
kind: z.literal("workspace"),
|
|
15
|
+
workspaceId: z.string().uuid(),
|
|
16
|
+
subjectId: z.null(),
|
|
17
|
+
}),
|
|
18
|
+
z.object({
|
|
19
|
+
kind: z.literal("personal"),
|
|
20
|
+
workspaceId: z.string().uuid().nullable(),
|
|
21
|
+
subjectId: z.string().min(1).max(1024),
|
|
22
|
+
}),
|
|
23
|
+
]);
|
|
24
|
+
export type ScopedKnowledgeScope = z.infer<typeof ScopedKnowledgeScope>;
|
|
11
25
|
|
|
12
26
|
export const ScopedKnowledgeActorKind = z.enum(["human", "service"]);
|
|
13
27
|
export type ScopedKnowledgeActorKind = z.infer<typeof ScopedKnowledgeActorKind>;
|
package/src/slack-bot-scopes.ts
CHANGED
|
@@ -41,6 +41,35 @@ export const OPENGENI_SLACK_BOT_EVENTS = [
|
|
|
41
41
|
"reaction_added",
|
|
42
42
|
] as const;
|
|
43
43
|
|
|
44
|
+
/** Full user-token scope set for every tool currently exposed by Slack's hosted MCP server. */
|
|
45
|
+
export const OPENGENI_SLACK_MCP_USER_SCOPES = [
|
|
46
|
+
"search:read.public",
|
|
47
|
+
"search:read.private",
|
|
48
|
+
"search:read.mpim",
|
|
49
|
+
"search:read.im",
|
|
50
|
+
"search:read.files",
|
|
51
|
+
"files:read",
|
|
52
|
+
"emoji:read",
|
|
53
|
+
"search:read.users",
|
|
54
|
+
"chat:write",
|
|
55
|
+
"channels:history",
|
|
56
|
+
"groups:history",
|
|
57
|
+
"mpim:history",
|
|
58
|
+
"im:history",
|
|
59
|
+
"channels:write",
|
|
60
|
+
"groups:write",
|
|
61
|
+
"im:write",
|
|
62
|
+
"mpim:write",
|
|
63
|
+
"reactions:write",
|
|
64
|
+
"canvases:read",
|
|
65
|
+
"canvases:write",
|
|
66
|
+
"users:read",
|
|
67
|
+
"users:read.email",
|
|
68
|
+
"channels:read",
|
|
69
|
+
"groups:read",
|
|
70
|
+
"mpim:read",
|
|
71
|
+
] as const;
|
|
72
|
+
|
|
44
73
|
export const OPENGENI_MANAGED_PUBLIC_BASE_URL = "https://app.opengeni.ai" as const;
|
|
45
74
|
|
|
46
75
|
function normalizedSlackManifestBaseUrl(publicBaseUrl: string): string {
|
|
@@ -83,7 +112,10 @@ export function buildOpenGeniSlackBotManifest(publicBaseUrl: string) {
|
|
|
83
112
|
`${baseUrl}/v1/integrations/oauth/callback`,
|
|
84
113
|
`${baseUrl}/v1/integrations/slack/callback`,
|
|
85
114
|
],
|
|
86
|
-
scopes: {
|
|
115
|
+
scopes: {
|
|
116
|
+
bot: [...OPENGENI_SLACK_BOT_REQUESTED_SCOPES],
|
|
117
|
+
user: [...OPENGENI_SLACK_MCP_USER_SCOPES],
|
|
118
|
+
},
|
|
87
119
|
},
|
|
88
120
|
settings: {
|
|
89
121
|
event_subscriptions: {
|
|
@@ -94,6 +126,7 @@ export function buildOpenGeniSlackBotManifest(publicBaseUrl: string) {
|
|
|
94
126
|
is_enabled: true,
|
|
95
127
|
request_url: `${baseUrl}/v1/integrations/slack/interactions`,
|
|
96
128
|
},
|
|
129
|
+
is_mcp_enabled: true,
|
|
97
130
|
org_deploy_enabled: false,
|
|
98
131
|
socket_mode_enabled: false,
|
|
99
132
|
token_rotation_enabled: false,
|