@axiom-lattice/pg-stores 4.0.4 → 4.1.0
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/.turbo/turbo-build.log +10 -10
- package/CHANGELOG.md +22 -0
- package/dist/index.d.mts +41 -3
- package/dist/index.d.ts +41 -3
- package/dist/index.js +167 -37
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +163 -37
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
- package/src/__tests__/PostgresSharedResourceStore.kind.test.ts +210 -0
- package/src/createPgStoreConfig.ts +2 -0
- package/src/index.ts +1 -0
- package/src/migrations/add_share_kind.ts +45 -0
- package/src/stores/PostgresSharedResourceStore.ts +125 -17
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @axiom-lattice/pg-stores@4.0
|
|
2
|
+
> @axiom-lattice/pg-stores@4.1.0 build /home/runner/work/agentic/agentic/packages/pg-stores
|
|
3
3
|
> tsup src/index.ts --format cjs,esm --dts --sourcemap
|
|
4
4
|
|
|
5
5
|
[34mCLI[39m Building entry: src/index.ts
|
|
@@ -8,13 +8,13 @@
|
|
|
8
8
|
[34mCLI[39m Target: es2020
|
|
9
9
|
[34mCJS[39m Build start
|
|
10
10
|
[34mESM[39m Build start
|
|
11
|
-
[
|
|
12
|
-
[
|
|
13
|
-
[
|
|
14
|
-
[
|
|
15
|
-
[
|
|
16
|
-
[
|
|
11
|
+
[32mESM[39m [1mdist/index.mjs [22m[32m524.13 KB[39m
|
|
12
|
+
[32mESM[39m [1mdist/index.mjs.map [22m[32m970.30 KB[39m
|
|
13
|
+
[32mESM[39m ⚡️ Build success in 1104ms
|
|
14
|
+
[32mCJS[39m [1mdist/index.js [22m[32m533.87 KB[39m
|
|
15
|
+
[32mCJS[39m [1mdist/index.js.map [22m[32m970.61 KB[39m
|
|
16
|
+
[32mCJS[39m ⚡️ Build success in 1106ms
|
|
17
17
|
[34mDTS[39m Build start
|
|
18
|
-
[32mDTS[39m ⚡️ Build success in
|
|
19
|
-
[32mDTS[39m [1mdist/index.d.ts [22m[
|
|
20
|
-
[32mDTS[39m [1mdist/index.d.mts [22m[
|
|
18
|
+
[32mDTS[39m ⚡️ Build success in 15397ms
|
|
19
|
+
[32mDTS[39m [1mdist/index.d.ts [22m[32m112.00 KB[39m
|
|
20
|
+
[32mDTS[39m [1mdist/index.d.mts [22m[32m112.00 KB[39m
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,27 @@
|
|
|
1
1
|
# @axiom-lattice/pg-stores
|
|
2
2
|
|
|
3
|
+
## 4.1.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- a7af52d: Add MCP App share links (public/password), a hosted share page that re-runs the saved tool on every open, the share card MCP App UI, the `share_app` agent tool, and a built-in `app-share-publishing` skill for Plugin Builder and other share-enabled agents. Add a reusable Gateway fixed-window rate-limit service and wire it to share RPC/unlock/bootstrap, `auth.login`, Open API/Agent, and A2A JSON-RPC.
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [a7af52d]
|
|
12
|
+
- Updated dependencies [ecc4ace]
|
|
13
|
+
- Updated dependencies [449de9c]
|
|
14
|
+
- Updated dependencies [5e84195]
|
|
15
|
+
- @axiom-lattice/protocols@6.3.0
|
|
16
|
+
- @axiom-lattice/core@10.1.0
|
|
17
|
+
|
|
18
|
+
## 4.0.5
|
|
19
|
+
|
|
20
|
+
### Patch Changes
|
|
21
|
+
|
|
22
|
+
- Updated dependencies [acf07ce]
|
|
23
|
+
- @axiom-lattice/core@10.0.5
|
|
24
|
+
|
|
3
25
|
## 4.0.4
|
|
4
26
|
|
|
5
27
|
### Patch Changes
|
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Pool, PoolConfig, PoolClient } from 'pg';
|
|
2
2
|
export { Pool, PoolConfig } from 'pg';
|
|
3
|
-
import { ThreadStore, Thread, CreateThreadRequest, AssistantStore, Assistant, CreateAssistantRequest, DatabaseConfigStore, DatabaseConfigEntry, CreateDatabaseConfigRequest, UpdateDatabaseConfigRequest, ConnectionStore, ConnectionEntry, MetricsServerConfigStore, MetricsServerConfigEntry, CreateMetricsServerConfigRequest, UpdateMetricsServerConfigRequest, McpServerConfigStore, McpServerConfigEntry, CreateMcpServerConfigRequest, UpdateMcpServerConfigRequest, WorkspaceStore, Workspace, CreateWorkspaceRequest, UpdateWorkspaceRequest, ProjectStore, ProjectFilter, Project, CreateProjectRequest, UpdateProjectRequest, UpdateProjectCapabilityBundlesResult, UserStore, User, CreateUserRequest, UpdateUserRequest, TenantStore, Tenant, CreateTenantRequest, UpdateTenantRequest, UserTenantLinkStore, UserTenantLink, CreateUserTenantLinkRequest, UpdateUserTenantLinkRequest, WorkflowTrackingStore, CreateWorkflowRunRequest, WorkflowRun, UpdateWorkflowRunRequest, QueryWorkflowRunsOptions, QueryWorkflowRunsResult, CreateRunStepRequest, RunStep, UpdateRunStepRequest, StepType, EvalStore, EvalProject, CreateEvalProjectRequest, EvalSuite, CreateEvalSuiteRequest, EvalCase, CreateEvalCaseRequest, EvalRun, CreateEvalRunRequest, EvalRunResult, EvalProjectReport, BindingRegistry, Binding, CreateBindingInput, BindingMutablePatch, BindingListParams, ChannelInstallationStore, ChannelInstallation, ChannelInstallationType, CreateChannelInstallationInput, UpdateChannelInstallationRequest, A2AApiKeyStore, A2AApiKeyRecord, CreateA2AApiKeyInput, UpdateA2AApiKeyInput, A2AApiKeyEntry, OpenAuditStore, OpenAuditQuery, OpenAuditRecord, OpenAuditAppendInput, AgentWebAppStore, AgentWebApp, CreateAgentWebAppInput, AgentWebAppStorePatch, AgentWebAppUpdateOptions, ScheduleStorage, ScheduledTaskDefinition, ScheduledTaskStatus, ScheduleExecutionType, TaskStore, CreateTaskRequest, TaskItem, TaskListFilter, TaskDependentListQuery, UpdateTaskRequest, TaskMutationSnapshot, TaskWorkItemStore, CreateWorkItemRequest, TaskWorkItem, CreateWorkItemIfAbsentRequest, TaskWorkItemListFilter, ProjectLifecycleEventQuery, MenuRegistry, MenuItem, CreateMenuItemInput, UpdateMenuItemInput, SharedResourceStore, ShareRecord, CollectionStore, Collection, CreateCollectionRequest, UpdateCollectionRequest, VectorStoreProvider, VectorStoreCreateParams, CapabilityBundleStore, CapabilityBundle, InternalCreateCapabilityBundleInput, InternalUpdateCapabilityBundleInput, CapabilityBundleDeleteResult, ProjectRoomStore, ProjectRoom, ProjectMembershipStore, ProjectMembership, ProjectHumanRole, ProjectMembershipMutationResult, ProjectBotMembershipStore, ProjectBotMembership, ProjectRoomMessageStore, ProjectRoomMessage, ProjectRoomReadStateStore, ProjectRoomReadState, UserPushSubscriptionStore, UserPushSubscription, ModelProviderStore, ModelProviderEntry, CreateModelProviderRequest, UpdateModelProviderRequest, ModelProviderStatus, ModelProviderModelEntry, ProviderModelInput, LeaseStore, LeaseRecord, OutboxStore, OutboxEvent, PluginDeploymentStore, PluginDeployment, ChannelReplyJobStore, CreateChannelReplyJobInput, ChannelReplyJob, CheckpointStorage, CheckpointMaintenance, ThreadCheckpointStorage, StoreProtocol, StorePutInput, StoreItem, StoreSearchInput, SkillStore, Skill, CreateSkillRequest } from '@axiom-lattice/protocols';
|
|
3
|
+
import { ThreadStore, Thread, CreateThreadRequest, AssistantStore, Assistant, CreateAssistantRequest, DatabaseConfigStore, DatabaseConfigEntry, CreateDatabaseConfigRequest, UpdateDatabaseConfigRequest, ConnectionStore, ConnectionEntry, MetricsServerConfigStore, MetricsServerConfigEntry, CreateMetricsServerConfigRequest, UpdateMetricsServerConfigRequest, McpServerConfigStore, McpServerConfigEntry, CreateMcpServerConfigRequest, UpdateMcpServerConfigRequest, WorkspaceStore, Workspace, CreateWorkspaceRequest, UpdateWorkspaceRequest, ProjectStore, ProjectFilter, Project, CreateProjectRequest, UpdateProjectRequest, UpdateProjectCapabilityBundlesResult, UserStore, User, CreateUserRequest, UpdateUserRequest, TenantStore, Tenant, CreateTenantRequest, UpdateTenantRequest, UserTenantLinkStore, UserTenantLink, CreateUserTenantLinkRequest, UpdateUserTenantLinkRequest, WorkflowTrackingStore, CreateWorkflowRunRequest, WorkflowRun, UpdateWorkflowRunRequest, QueryWorkflowRunsOptions, QueryWorkflowRunsResult, CreateRunStepRequest, RunStep, UpdateRunStepRequest, StepType, EvalStore, EvalProject, CreateEvalProjectRequest, EvalSuite, CreateEvalSuiteRequest, EvalCase, CreateEvalCaseRequest, EvalRun, CreateEvalRunRequest, EvalRunResult, EvalProjectReport, BindingRegistry, Binding, CreateBindingInput, BindingMutablePatch, BindingListParams, ChannelInstallationStore, ChannelInstallation, ChannelInstallationType, CreateChannelInstallationInput, UpdateChannelInstallationRequest, A2AApiKeyStore, A2AApiKeyRecord, CreateA2AApiKeyInput, UpdateA2AApiKeyInput, A2AApiKeyEntry, OpenAuditStore, OpenAuditQuery, OpenAuditRecord, OpenAuditAppendInput, AgentWebAppStore, AgentWebApp, CreateAgentWebAppInput, AgentWebAppStorePatch, AgentWebAppUpdateOptions, ScheduleStorage, ScheduledTaskDefinition, ScheduledTaskStatus, ScheduleExecutionType, TaskStore, CreateTaskRequest, TaskItem, TaskListFilter, TaskDependentListQuery, UpdateTaskRequest, TaskMutationSnapshot, TaskWorkItemStore, CreateWorkItemRequest, TaskWorkItem, CreateWorkItemIfAbsentRequest, TaskWorkItemListFilter, ProjectLifecycleEventQuery, MenuRegistry, MenuItem, CreateMenuItemInput, UpdateMenuItemInput, SharedResourceStore, ShareRecord, CreateShareRecord, CollectionStore, Collection, CreateCollectionRequest, UpdateCollectionRequest, VectorStoreProvider, VectorStoreCreateParams, CapabilityBundleStore, CapabilityBundle, InternalCreateCapabilityBundleInput, InternalUpdateCapabilityBundleInput, CapabilityBundleDeleteResult, ProjectRoomStore, ProjectRoom, ProjectMembershipStore, ProjectMembership, ProjectHumanRole, ProjectMembershipMutationResult, ProjectBotMembershipStore, ProjectBotMembership, ProjectRoomMessageStore, ProjectRoomMessage, ProjectRoomReadStateStore, ProjectRoomReadState, UserPushSubscriptionStore, UserPushSubscription, ModelProviderStore, ModelProviderEntry, CreateModelProviderRequest, UpdateModelProviderRequest, ModelProviderStatus, ModelProviderModelEntry, ProviderModelInput, LeaseStore, LeaseRecord, OutboxStore, OutboxEvent, PluginDeploymentStore, PluginDeployment, ChannelReplyJobStore, CreateChannelReplyJobInput, ChannelReplyJob, CheckpointStorage, CheckpointMaintenance, ThreadCheckpointStorage, StoreProtocol, StorePutInput, StoreItem, StoreSearchInput, SkillStore, Skill, CreateSkillRequest } from '@axiom-lattice/protocols';
|
|
4
4
|
export { AgentWebApp, AgentWebAppAppearance, AgentWebAppFeatures, AgentWebAppScope, AgentWebAppStatus, AgentWebAppStore, Assistant, AssistantStore, Binding, BindingRegistry, CapabilityBundle, CapabilityBundleStore, ChannelInstallation, ChannelInstallationStore, ConnectionEntry, ConnectionStore, CreateAgentWebAppInput, CreateAssistantRequest, CreateBindingInput, CreateCapabilityBundleInput, CreateChannelInstallationInput, CreateChannelInstallationRequest, CreateDatabaseConfigRequest, CreateEvalCaseRequest, CreateEvalProjectRequest, CreateEvalRunRequest, CreateEvalSuiteRequest, CreateMcpServerConfigRequest, CreateMenuItemInput, CreateMetricsServerConfigRequest, CreateProjectRequest, CreateRunStepRequest, CreateShareRequest, CreateSkillRequest, CreateTenantRequest, CreateThreadRequest, CreateUserRequest, CreateUserTenantLinkRequest, CreateWorkflowRunRequest, CreateWorkspaceRequest, DatabaseConfig, DatabaseConfigEntry, DatabaseConfigStore, DatabaseType, EvalCase, EvalProject, EvalProjectReport, EvalRun, EvalRunResult, EvalStore, EvalSuite, LarkChannelInstallationConfig, McpServerConfigEntry, McpServerConfigStore, MenuItem, MenuRegistry, MetricsServerConfig, MetricsServerConfigEntry, MetricsServerConfigStore, Project, ProjectStore, ResourceAddress, RunStep, ScheduleExecutionType, ScheduleStorage, ScheduledTaskDefinition, ScheduledTaskStatus, ShareRecord, ShareResult, ShareVisibility, SharedResourceStore, Skill, SkillStore, StorageType, Tenant, TenantStatus, TenantStore, Thread, ThreadStore, UpdateAgentWebAppInput, UpdateCapabilityBundleInput, UpdateChannelInstallationRequest, UpdateDatabaseConfigRequest, UpdateMcpServerConfigRequest, UpdateMetricsServerConfigRequest, UpdateProjectRequest, UpdateRunStepRequest, UpdateTenantRequest, UpdateUserRequest, UpdateUserTenantLinkRequest, UpdateWorkflowRunRequest, UpdateWorkspaceRequest, User, UserStore, UserTenantLink, UserTenantLinkStore, UserTenantRole, WorkflowRun, WorkflowTrackingStore, Workspace, WorkspaceStore } from '@axiom-lattice/protocols';
|
|
5
5
|
import { IMessageQueueStore, AddMessageParams, PendingMessage, QueueScope, ClaimMessagesOptions, ThreadInfo, IAgentRunLedger, BeginAgentRunInput, AgentRunRecord, CreatePendingAgentRunInput, ListPendingRunsOptions, ClaimAgentRunInput, DeleteAgentRunExpected, AgentRunStatus, RollbackFailureResult, AgentRunRollbackResult, AgentRunExpiredOutcome, SettleExpiredRunOptions, AgentRunCounts, AgentRunSource, ReapedAgentRun } from '@axiom-lattice/core';
|
|
6
6
|
export { AddMessageParams, PendingMessage, ThreadInfo } from '@axiom-lattice/core';
|
|
@@ -1384,6 +1384,42 @@ interface PostgresSharedResourceStoreOptions {
|
|
|
1384
1384
|
poolConfig?: string | PoolConfig;
|
|
1385
1385
|
autoMigrate?: boolean;
|
|
1386
1386
|
}
|
|
1387
|
+
/**
|
|
1388
|
+
* Raised when a persisted MCP App share row does not carry a valid app target.
|
|
1389
|
+
*/
|
|
1390
|
+
declare class InvalidMcpAppShareAddressError extends Error {
|
|
1391
|
+
/** Machine-readable failure code. */
|
|
1392
|
+
readonly code: "INVALID_MCP_APP_SHARE_ADDRESS";
|
|
1393
|
+
/**
|
|
1394
|
+
* @param token - Share token owning the invalid address.
|
|
1395
|
+
*/
|
|
1396
|
+
constructor(token: string);
|
|
1397
|
+
}
|
|
1398
|
+
/**
|
|
1399
|
+
* Raised when a persisted MCP App share row uses an unsupported visibility.
|
|
1400
|
+
*/
|
|
1401
|
+
declare class InvalidMcpAppShareVisibilityError extends Error {
|
|
1402
|
+
/** Machine-readable failure code. */
|
|
1403
|
+
readonly code: "INVALID_MCP_APP_SHARE_VISIBILITY";
|
|
1404
|
+
/** Visibility value found in the row. */
|
|
1405
|
+
readonly visibility: string;
|
|
1406
|
+
/**
|
|
1407
|
+
* @param token - Share token owning the invalid visibility.
|
|
1408
|
+
* @param visibility - Visibility value found in the row.
|
|
1409
|
+
*/
|
|
1410
|
+
constructor(token: string, visibility: string);
|
|
1411
|
+
}
|
|
1412
|
+
/**
|
|
1413
|
+
* Raised when a persisted file share row does not carry a valid resource address.
|
|
1414
|
+
*/
|
|
1415
|
+
declare class InvalidFileShareAddressError extends Error {
|
|
1416
|
+
/** Machine-readable failure code. */
|
|
1417
|
+
readonly code: "INVALID_FILE_SHARE_ADDRESS";
|
|
1418
|
+
/**
|
|
1419
|
+
* @param token - Share token owning the invalid address.
|
|
1420
|
+
*/
|
|
1421
|
+
constructor(token: string);
|
|
1422
|
+
}
|
|
1387
1423
|
declare class PostgresSharedResourceStore implements SharedResourceStore {
|
|
1388
1424
|
private pool;
|
|
1389
1425
|
private migrationManager;
|
|
@@ -1394,7 +1430,7 @@ declare class PostgresSharedResourceStore implements SharedResourceStore {
|
|
|
1394
1430
|
initialize(): Promise<void>;
|
|
1395
1431
|
dispose(): Promise<void>;
|
|
1396
1432
|
findByToken(token: string): Promise<ShareRecord | null>;
|
|
1397
|
-
create(record:
|
|
1433
|
+
create(record: CreateShareRecord): Promise<ShareRecord>;
|
|
1398
1434
|
update(token: string, patch: Record<string, unknown>): Promise<void>;
|
|
1399
1435
|
listByUser(tenantId: string, userId: string): Promise<ShareRecord[]>;
|
|
1400
1436
|
incrementAccess(token: string): Promise<void>;
|
|
@@ -2650,6 +2686,8 @@ declare const createChannelBindingsTable: Migration;
|
|
|
2650
2686
|
|
|
2651
2687
|
declare const createSharedResourcesTable: Migration;
|
|
2652
2688
|
|
|
2689
|
+
declare const addShareKind: Migration;
|
|
2690
|
+
|
|
2653
2691
|
declare const createA2AApiKeysTable: Migration;
|
|
2654
2692
|
|
|
2655
2693
|
declare const createAgentWebAppsTable: Migration;
|
|
@@ -2835,4 +2873,4 @@ declare const createChannelReplyJobsTable: Migration;
|
|
|
2835
2873
|
*/
|
|
2836
2874
|
declare const createStoreItemsTable: Migration;
|
|
2837
2875
|
|
|
2838
|
-
export { ChannelBindingStore, type ChannelBindingStoreOptions, type ChannelIdentityMapping, ChannelIdentityMappingStore, type ChannelIdentityMappingStoreOptions, CheckpointBaseNotFoundError, CheckpointTargetNotEmptyError, type CreateChannelIdentityMappingInput, DuplicateProjectMembershipError, DuplicateProjectRoomMessageIdempotencyKeyError, MenuStore, type MenuStoreOptions, type Migration, MigrationManager, PGVectorStoreProvider, PostgreSQLA2AApiKeyStore, type PostgreSQLA2AApiKeyStoreOptions, PostgreSQLAgentRunLedger, type PostgreSQLAgentRunLedgerOptions, PostgreSQLAgentWebAppStore, type PostgreSQLAgentWebAppStoreOptions, PostgreSQLAssistantStore, type PostgreSQLAssistantStoreOptions, PostgreSQLCapabilityBundleStore, type PostgreSQLCapabilityBundleStoreOptions, PostgreSQLChannelInstallationStore, type PostgreSQLChannelInstallationStoreOptions, PostgreSQLChannelReplyJobStore, type PostgreSQLChannelReplyJobStoreOptions, PostgreSQLCheckpointStorage, PostgreSQLCollectionStore, type PostgreSQLCollectionStoreOptions, PostgreSQLConnectionStore, PostgreSQLDatabaseConfigStore, type PostgreSQLDatabaseConfigStoreOptions, PostgreSQLEvalStore, type PostgreSQLEvalStoreOptions, PostgreSQLMcpServerConfigStore, type PostgreSQLMcpServerConfigStoreOptions, PostgreSQLMetricsServerConfigStore, type PostgreSQLMetricsServerConfigStoreOptions, PostgreSQLModelProviderStore, type PostgreSQLModelProviderStoreOptions, PostgreSQLOpenAuditStore, type PostgreSQLOpenAuditStoreOptions, PostgreSQLPluginDeploymentStore, PostgreSQLProjectBotMembershipStore, PostgreSQLProjectMembershipStore, PostgreSQLProjectRoomMessageStore, PostgreSQLProjectRoomReadStateStore, PostgreSQLProjectRoomStore, PostgreSQLProjectStore, type PostgreSQLProjectStoreOptions, PostgreSQLScheduleStorage, type PostgreSQLScheduleStorageOptions, PostgreSQLSkillStore, type PostgreSQLSkillStoreOptions, PostgreSQLStore, PostgreSQLTaskWorkItemStore, type PostgreSQLTaskWorkItemStoreOptions, PostgreSQLTenantStore, type PostgreSQLTenantStoreOptions, type PostgreSQLThreadMessageQueueStoreOptions, PostgreSQLThreadStore, type PostgreSQLThreadStoreOptions, PostgreSQLUserStore, type PostgreSQLUserStoreOptions, PostgreSQLUserTenantLinkStore, type PostgreSQLUserTenantLinkStoreOptions, PostgreSQLWorkflowTrackingStore, type PostgreSQLWorkflowTrackingStoreOptions, PostgreSQLWorkspaceStore, type PostgreSQLWorkspaceStoreOptions, PostgresSharedResourceStore, type PostgresSharedResourceStoreOptions, ProjectBotMembershipIdConflictError, ProjectMembershipIdConflictError, ProjectRoomMessageIdConflictError, ThreadMessageQueueStore, addAssistantTenantId, addCancelRequestedToEvalRuns, addEnvToEvalRuns, addFileContentType, addHoldoutToEvalRuns, addInterruptColumnsToEval, addInterruptPolicyToEvalCases, addMcpAppContentType, addProjectConfigColumn, addScheduleTenantId, addSkillTenantId, addStepThreadId, addTaskIdToEvalRuns, addThreadExpiresAt, addThreadTenantId, addWorkflowRunsTenantStatusUpdatedIndex, alterChannelInstallationsTable, changeAssistantPrimaryKey, changeSkillPrimaryKey, changeThreadPrimaryKey, createA2AApiKeysTable, createAgentRunLedgerTable, createAgentWebAppsTable, createAssistantsTable, createCapabilityBundlesTable, createChannelBindingsTable, createChannelIdentityMappingTables, createChannelInstallationsTable, createChannelReplyJobsTable, createCollectionsTable, createDatabaseConfigsTable, createEvalCasesTable, createEvalProjectsTable, createEvalRunResultsTable, createEvalRunsTable, createEvalSuitesTable, createMcpServerConfigsTable, createMenuItemsTable, createMetricsConfigsTable, createPGVectorStoreProvider, createPgStoreConfig, createPluginDeployments, createProjectRoomReadStates, createProjectRoomTables, createProjectsTable, createScheduledTasksTable, createSharedResourcesTable, createSkillsTable, createStoreItemsTable, createTenantsTable, createThreadMessageQueueTable, createThreadsTable, createUsersTable, createWorkflowTrackingTables, createWorkspacesTable, dropPluginDeploymentAuthToken, enforceUniqueEvalProjectName, evalMigrations, mapRowToRunStep, mapRowToWorkflowRun, safeParse };
|
|
2876
|
+
export { ChannelBindingStore, type ChannelBindingStoreOptions, type ChannelIdentityMapping, ChannelIdentityMappingStore, type ChannelIdentityMappingStoreOptions, CheckpointBaseNotFoundError, CheckpointTargetNotEmptyError, type CreateChannelIdentityMappingInput, DuplicateProjectMembershipError, DuplicateProjectRoomMessageIdempotencyKeyError, InvalidFileShareAddressError, InvalidMcpAppShareAddressError, InvalidMcpAppShareVisibilityError, MenuStore, type MenuStoreOptions, type Migration, MigrationManager, PGVectorStoreProvider, PostgreSQLA2AApiKeyStore, type PostgreSQLA2AApiKeyStoreOptions, PostgreSQLAgentRunLedger, type PostgreSQLAgentRunLedgerOptions, PostgreSQLAgentWebAppStore, type PostgreSQLAgentWebAppStoreOptions, PostgreSQLAssistantStore, type PostgreSQLAssistantStoreOptions, PostgreSQLCapabilityBundleStore, type PostgreSQLCapabilityBundleStoreOptions, PostgreSQLChannelInstallationStore, type PostgreSQLChannelInstallationStoreOptions, PostgreSQLChannelReplyJobStore, type PostgreSQLChannelReplyJobStoreOptions, PostgreSQLCheckpointStorage, PostgreSQLCollectionStore, type PostgreSQLCollectionStoreOptions, PostgreSQLConnectionStore, PostgreSQLDatabaseConfigStore, type PostgreSQLDatabaseConfigStoreOptions, PostgreSQLEvalStore, type PostgreSQLEvalStoreOptions, PostgreSQLMcpServerConfigStore, type PostgreSQLMcpServerConfigStoreOptions, PostgreSQLMetricsServerConfigStore, type PostgreSQLMetricsServerConfigStoreOptions, PostgreSQLModelProviderStore, type PostgreSQLModelProviderStoreOptions, PostgreSQLOpenAuditStore, type PostgreSQLOpenAuditStoreOptions, PostgreSQLPluginDeploymentStore, PostgreSQLProjectBotMembershipStore, PostgreSQLProjectMembershipStore, PostgreSQLProjectRoomMessageStore, PostgreSQLProjectRoomReadStateStore, PostgreSQLProjectRoomStore, PostgreSQLProjectStore, type PostgreSQLProjectStoreOptions, PostgreSQLScheduleStorage, type PostgreSQLScheduleStorageOptions, PostgreSQLSkillStore, type PostgreSQLSkillStoreOptions, PostgreSQLStore, PostgreSQLTaskWorkItemStore, type PostgreSQLTaskWorkItemStoreOptions, PostgreSQLTenantStore, type PostgreSQLTenantStoreOptions, type PostgreSQLThreadMessageQueueStoreOptions, PostgreSQLThreadStore, type PostgreSQLThreadStoreOptions, PostgreSQLUserStore, type PostgreSQLUserStoreOptions, PostgreSQLUserTenantLinkStore, type PostgreSQLUserTenantLinkStoreOptions, PostgreSQLWorkflowTrackingStore, type PostgreSQLWorkflowTrackingStoreOptions, PostgreSQLWorkspaceStore, type PostgreSQLWorkspaceStoreOptions, PostgresSharedResourceStore, type PostgresSharedResourceStoreOptions, ProjectBotMembershipIdConflictError, ProjectMembershipIdConflictError, ProjectRoomMessageIdConflictError, ThreadMessageQueueStore, addAssistantTenantId, addCancelRequestedToEvalRuns, addEnvToEvalRuns, addFileContentType, addHoldoutToEvalRuns, addInterruptColumnsToEval, addInterruptPolicyToEvalCases, addMcpAppContentType, addProjectConfigColumn, addScheduleTenantId, addShareKind, addSkillTenantId, addStepThreadId, addTaskIdToEvalRuns, addThreadExpiresAt, addThreadTenantId, addWorkflowRunsTenantStatusUpdatedIndex, alterChannelInstallationsTable, changeAssistantPrimaryKey, changeSkillPrimaryKey, changeThreadPrimaryKey, createA2AApiKeysTable, createAgentRunLedgerTable, createAgentWebAppsTable, createAssistantsTable, createCapabilityBundlesTable, createChannelBindingsTable, createChannelIdentityMappingTables, createChannelInstallationsTable, createChannelReplyJobsTable, createCollectionsTable, createDatabaseConfigsTable, createEvalCasesTable, createEvalProjectsTable, createEvalRunResultsTable, createEvalRunsTable, createEvalSuitesTable, createMcpServerConfigsTable, createMenuItemsTable, createMetricsConfigsTable, createPGVectorStoreProvider, createPgStoreConfig, createPluginDeployments, createProjectRoomReadStates, createProjectRoomTables, createProjectsTable, createScheduledTasksTable, createSharedResourcesTable, createSkillsTable, createStoreItemsTable, createTenantsTable, createThreadMessageQueueTable, createThreadsTable, createUsersTable, createWorkflowTrackingTables, createWorkspacesTable, dropPluginDeploymentAuthToken, enforceUniqueEvalProjectName, evalMigrations, mapRowToRunStep, mapRowToWorkflowRun, safeParse };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Pool, PoolConfig, PoolClient } from 'pg';
|
|
2
2
|
export { Pool, PoolConfig } from 'pg';
|
|
3
|
-
import { ThreadStore, Thread, CreateThreadRequest, AssistantStore, Assistant, CreateAssistantRequest, DatabaseConfigStore, DatabaseConfigEntry, CreateDatabaseConfigRequest, UpdateDatabaseConfigRequest, ConnectionStore, ConnectionEntry, MetricsServerConfigStore, MetricsServerConfigEntry, CreateMetricsServerConfigRequest, UpdateMetricsServerConfigRequest, McpServerConfigStore, McpServerConfigEntry, CreateMcpServerConfigRequest, UpdateMcpServerConfigRequest, WorkspaceStore, Workspace, CreateWorkspaceRequest, UpdateWorkspaceRequest, ProjectStore, ProjectFilter, Project, CreateProjectRequest, UpdateProjectRequest, UpdateProjectCapabilityBundlesResult, UserStore, User, CreateUserRequest, UpdateUserRequest, TenantStore, Tenant, CreateTenantRequest, UpdateTenantRequest, UserTenantLinkStore, UserTenantLink, CreateUserTenantLinkRequest, UpdateUserTenantLinkRequest, WorkflowTrackingStore, CreateWorkflowRunRequest, WorkflowRun, UpdateWorkflowRunRequest, QueryWorkflowRunsOptions, QueryWorkflowRunsResult, CreateRunStepRequest, RunStep, UpdateRunStepRequest, StepType, EvalStore, EvalProject, CreateEvalProjectRequest, EvalSuite, CreateEvalSuiteRequest, EvalCase, CreateEvalCaseRequest, EvalRun, CreateEvalRunRequest, EvalRunResult, EvalProjectReport, BindingRegistry, Binding, CreateBindingInput, BindingMutablePatch, BindingListParams, ChannelInstallationStore, ChannelInstallation, ChannelInstallationType, CreateChannelInstallationInput, UpdateChannelInstallationRequest, A2AApiKeyStore, A2AApiKeyRecord, CreateA2AApiKeyInput, UpdateA2AApiKeyInput, A2AApiKeyEntry, OpenAuditStore, OpenAuditQuery, OpenAuditRecord, OpenAuditAppendInput, AgentWebAppStore, AgentWebApp, CreateAgentWebAppInput, AgentWebAppStorePatch, AgentWebAppUpdateOptions, ScheduleStorage, ScheduledTaskDefinition, ScheduledTaskStatus, ScheduleExecutionType, TaskStore, CreateTaskRequest, TaskItem, TaskListFilter, TaskDependentListQuery, UpdateTaskRequest, TaskMutationSnapshot, TaskWorkItemStore, CreateWorkItemRequest, TaskWorkItem, CreateWorkItemIfAbsentRequest, TaskWorkItemListFilter, ProjectLifecycleEventQuery, MenuRegistry, MenuItem, CreateMenuItemInput, UpdateMenuItemInput, SharedResourceStore, ShareRecord, CollectionStore, Collection, CreateCollectionRequest, UpdateCollectionRequest, VectorStoreProvider, VectorStoreCreateParams, CapabilityBundleStore, CapabilityBundle, InternalCreateCapabilityBundleInput, InternalUpdateCapabilityBundleInput, CapabilityBundleDeleteResult, ProjectRoomStore, ProjectRoom, ProjectMembershipStore, ProjectMembership, ProjectHumanRole, ProjectMembershipMutationResult, ProjectBotMembershipStore, ProjectBotMembership, ProjectRoomMessageStore, ProjectRoomMessage, ProjectRoomReadStateStore, ProjectRoomReadState, UserPushSubscriptionStore, UserPushSubscription, ModelProviderStore, ModelProviderEntry, CreateModelProviderRequest, UpdateModelProviderRequest, ModelProviderStatus, ModelProviderModelEntry, ProviderModelInput, LeaseStore, LeaseRecord, OutboxStore, OutboxEvent, PluginDeploymentStore, PluginDeployment, ChannelReplyJobStore, CreateChannelReplyJobInput, ChannelReplyJob, CheckpointStorage, CheckpointMaintenance, ThreadCheckpointStorage, StoreProtocol, StorePutInput, StoreItem, StoreSearchInput, SkillStore, Skill, CreateSkillRequest } from '@axiom-lattice/protocols';
|
|
3
|
+
import { ThreadStore, Thread, CreateThreadRequest, AssistantStore, Assistant, CreateAssistantRequest, DatabaseConfigStore, DatabaseConfigEntry, CreateDatabaseConfigRequest, UpdateDatabaseConfigRequest, ConnectionStore, ConnectionEntry, MetricsServerConfigStore, MetricsServerConfigEntry, CreateMetricsServerConfigRequest, UpdateMetricsServerConfigRequest, McpServerConfigStore, McpServerConfigEntry, CreateMcpServerConfigRequest, UpdateMcpServerConfigRequest, WorkspaceStore, Workspace, CreateWorkspaceRequest, UpdateWorkspaceRequest, ProjectStore, ProjectFilter, Project, CreateProjectRequest, UpdateProjectRequest, UpdateProjectCapabilityBundlesResult, UserStore, User, CreateUserRequest, UpdateUserRequest, TenantStore, Tenant, CreateTenantRequest, UpdateTenantRequest, UserTenantLinkStore, UserTenantLink, CreateUserTenantLinkRequest, UpdateUserTenantLinkRequest, WorkflowTrackingStore, CreateWorkflowRunRequest, WorkflowRun, UpdateWorkflowRunRequest, QueryWorkflowRunsOptions, QueryWorkflowRunsResult, CreateRunStepRequest, RunStep, UpdateRunStepRequest, StepType, EvalStore, EvalProject, CreateEvalProjectRequest, EvalSuite, CreateEvalSuiteRequest, EvalCase, CreateEvalCaseRequest, EvalRun, CreateEvalRunRequest, EvalRunResult, EvalProjectReport, BindingRegistry, Binding, CreateBindingInput, BindingMutablePatch, BindingListParams, ChannelInstallationStore, ChannelInstallation, ChannelInstallationType, CreateChannelInstallationInput, UpdateChannelInstallationRequest, A2AApiKeyStore, A2AApiKeyRecord, CreateA2AApiKeyInput, UpdateA2AApiKeyInput, A2AApiKeyEntry, OpenAuditStore, OpenAuditQuery, OpenAuditRecord, OpenAuditAppendInput, AgentWebAppStore, AgentWebApp, CreateAgentWebAppInput, AgentWebAppStorePatch, AgentWebAppUpdateOptions, ScheduleStorage, ScheduledTaskDefinition, ScheduledTaskStatus, ScheduleExecutionType, TaskStore, CreateTaskRequest, TaskItem, TaskListFilter, TaskDependentListQuery, UpdateTaskRequest, TaskMutationSnapshot, TaskWorkItemStore, CreateWorkItemRequest, TaskWorkItem, CreateWorkItemIfAbsentRequest, TaskWorkItemListFilter, ProjectLifecycleEventQuery, MenuRegistry, MenuItem, CreateMenuItemInput, UpdateMenuItemInput, SharedResourceStore, ShareRecord, CreateShareRecord, CollectionStore, Collection, CreateCollectionRequest, UpdateCollectionRequest, VectorStoreProvider, VectorStoreCreateParams, CapabilityBundleStore, CapabilityBundle, InternalCreateCapabilityBundleInput, InternalUpdateCapabilityBundleInput, CapabilityBundleDeleteResult, ProjectRoomStore, ProjectRoom, ProjectMembershipStore, ProjectMembership, ProjectHumanRole, ProjectMembershipMutationResult, ProjectBotMembershipStore, ProjectBotMembership, ProjectRoomMessageStore, ProjectRoomMessage, ProjectRoomReadStateStore, ProjectRoomReadState, UserPushSubscriptionStore, UserPushSubscription, ModelProviderStore, ModelProviderEntry, CreateModelProviderRequest, UpdateModelProviderRequest, ModelProviderStatus, ModelProviderModelEntry, ProviderModelInput, LeaseStore, LeaseRecord, OutboxStore, OutboxEvent, PluginDeploymentStore, PluginDeployment, ChannelReplyJobStore, CreateChannelReplyJobInput, ChannelReplyJob, CheckpointStorage, CheckpointMaintenance, ThreadCheckpointStorage, StoreProtocol, StorePutInput, StoreItem, StoreSearchInput, SkillStore, Skill, CreateSkillRequest } from '@axiom-lattice/protocols';
|
|
4
4
|
export { AgentWebApp, AgentWebAppAppearance, AgentWebAppFeatures, AgentWebAppScope, AgentWebAppStatus, AgentWebAppStore, Assistant, AssistantStore, Binding, BindingRegistry, CapabilityBundle, CapabilityBundleStore, ChannelInstallation, ChannelInstallationStore, ConnectionEntry, ConnectionStore, CreateAgentWebAppInput, CreateAssistantRequest, CreateBindingInput, CreateCapabilityBundleInput, CreateChannelInstallationInput, CreateChannelInstallationRequest, CreateDatabaseConfigRequest, CreateEvalCaseRequest, CreateEvalProjectRequest, CreateEvalRunRequest, CreateEvalSuiteRequest, CreateMcpServerConfigRequest, CreateMenuItemInput, CreateMetricsServerConfigRequest, CreateProjectRequest, CreateRunStepRequest, CreateShareRequest, CreateSkillRequest, CreateTenantRequest, CreateThreadRequest, CreateUserRequest, CreateUserTenantLinkRequest, CreateWorkflowRunRequest, CreateWorkspaceRequest, DatabaseConfig, DatabaseConfigEntry, DatabaseConfigStore, DatabaseType, EvalCase, EvalProject, EvalProjectReport, EvalRun, EvalRunResult, EvalStore, EvalSuite, LarkChannelInstallationConfig, McpServerConfigEntry, McpServerConfigStore, MenuItem, MenuRegistry, MetricsServerConfig, MetricsServerConfigEntry, MetricsServerConfigStore, Project, ProjectStore, ResourceAddress, RunStep, ScheduleExecutionType, ScheduleStorage, ScheduledTaskDefinition, ScheduledTaskStatus, ShareRecord, ShareResult, ShareVisibility, SharedResourceStore, Skill, SkillStore, StorageType, Tenant, TenantStatus, TenantStore, Thread, ThreadStore, UpdateAgentWebAppInput, UpdateCapabilityBundleInput, UpdateChannelInstallationRequest, UpdateDatabaseConfigRequest, UpdateMcpServerConfigRequest, UpdateMetricsServerConfigRequest, UpdateProjectRequest, UpdateRunStepRequest, UpdateTenantRequest, UpdateUserRequest, UpdateUserTenantLinkRequest, UpdateWorkflowRunRequest, UpdateWorkspaceRequest, User, UserStore, UserTenantLink, UserTenantLinkStore, UserTenantRole, WorkflowRun, WorkflowTrackingStore, Workspace, WorkspaceStore } from '@axiom-lattice/protocols';
|
|
5
5
|
import { IMessageQueueStore, AddMessageParams, PendingMessage, QueueScope, ClaimMessagesOptions, ThreadInfo, IAgentRunLedger, BeginAgentRunInput, AgentRunRecord, CreatePendingAgentRunInput, ListPendingRunsOptions, ClaimAgentRunInput, DeleteAgentRunExpected, AgentRunStatus, RollbackFailureResult, AgentRunRollbackResult, AgentRunExpiredOutcome, SettleExpiredRunOptions, AgentRunCounts, AgentRunSource, ReapedAgentRun } from '@axiom-lattice/core';
|
|
6
6
|
export { AddMessageParams, PendingMessage, ThreadInfo } from '@axiom-lattice/core';
|
|
@@ -1384,6 +1384,42 @@ interface PostgresSharedResourceStoreOptions {
|
|
|
1384
1384
|
poolConfig?: string | PoolConfig;
|
|
1385
1385
|
autoMigrate?: boolean;
|
|
1386
1386
|
}
|
|
1387
|
+
/**
|
|
1388
|
+
* Raised when a persisted MCP App share row does not carry a valid app target.
|
|
1389
|
+
*/
|
|
1390
|
+
declare class InvalidMcpAppShareAddressError extends Error {
|
|
1391
|
+
/** Machine-readable failure code. */
|
|
1392
|
+
readonly code: "INVALID_MCP_APP_SHARE_ADDRESS";
|
|
1393
|
+
/**
|
|
1394
|
+
* @param token - Share token owning the invalid address.
|
|
1395
|
+
*/
|
|
1396
|
+
constructor(token: string);
|
|
1397
|
+
}
|
|
1398
|
+
/**
|
|
1399
|
+
* Raised when a persisted MCP App share row uses an unsupported visibility.
|
|
1400
|
+
*/
|
|
1401
|
+
declare class InvalidMcpAppShareVisibilityError extends Error {
|
|
1402
|
+
/** Machine-readable failure code. */
|
|
1403
|
+
readonly code: "INVALID_MCP_APP_SHARE_VISIBILITY";
|
|
1404
|
+
/** Visibility value found in the row. */
|
|
1405
|
+
readonly visibility: string;
|
|
1406
|
+
/**
|
|
1407
|
+
* @param token - Share token owning the invalid visibility.
|
|
1408
|
+
* @param visibility - Visibility value found in the row.
|
|
1409
|
+
*/
|
|
1410
|
+
constructor(token: string, visibility: string);
|
|
1411
|
+
}
|
|
1412
|
+
/**
|
|
1413
|
+
* Raised when a persisted file share row does not carry a valid resource address.
|
|
1414
|
+
*/
|
|
1415
|
+
declare class InvalidFileShareAddressError extends Error {
|
|
1416
|
+
/** Machine-readable failure code. */
|
|
1417
|
+
readonly code: "INVALID_FILE_SHARE_ADDRESS";
|
|
1418
|
+
/**
|
|
1419
|
+
* @param token - Share token owning the invalid address.
|
|
1420
|
+
*/
|
|
1421
|
+
constructor(token: string);
|
|
1422
|
+
}
|
|
1387
1423
|
declare class PostgresSharedResourceStore implements SharedResourceStore {
|
|
1388
1424
|
private pool;
|
|
1389
1425
|
private migrationManager;
|
|
@@ -1394,7 +1430,7 @@ declare class PostgresSharedResourceStore implements SharedResourceStore {
|
|
|
1394
1430
|
initialize(): Promise<void>;
|
|
1395
1431
|
dispose(): Promise<void>;
|
|
1396
1432
|
findByToken(token: string): Promise<ShareRecord | null>;
|
|
1397
|
-
create(record:
|
|
1433
|
+
create(record: CreateShareRecord): Promise<ShareRecord>;
|
|
1398
1434
|
update(token: string, patch: Record<string, unknown>): Promise<void>;
|
|
1399
1435
|
listByUser(tenantId: string, userId: string): Promise<ShareRecord[]>;
|
|
1400
1436
|
incrementAccess(token: string): Promise<void>;
|
|
@@ -2650,6 +2686,8 @@ declare const createChannelBindingsTable: Migration;
|
|
|
2650
2686
|
|
|
2651
2687
|
declare const createSharedResourcesTable: Migration;
|
|
2652
2688
|
|
|
2689
|
+
declare const addShareKind: Migration;
|
|
2690
|
+
|
|
2653
2691
|
declare const createA2AApiKeysTable: Migration;
|
|
2654
2692
|
|
|
2655
2693
|
declare const createAgentWebAppsTable: Migration;
|
|
@@ -2835,4 +2873,4 @@ declare const createChannelReplyJobsTable: Migration;
|
|
|
2835
2873
|
*/
|
|
2836
2874
|
declare const createStoreItemsTable: Migration;
|
|
2837
2875
|
|
|
2838
|
-
export { ChannelBindingStore, type ChannelBindingStoreOptions, type ChannelIdentityMapping, ChannelIdentityMappingStore, type ChannelIdentityMappingStoreOptions, CheckpointBaseNotFoundError, CheckpointTargetNotEmptyError, type CreateChannelIdentityMappingInput, DuplicateProjectMembershipError, DuplicateProjectRoomMessageIdempotencyKeyError, MenuStore, type MenuStoreOptions, type Migration, MigrationManager, PGVectorStoreProvider, PostgreSQLA2AApiKeyStore, type PostgreSQLA2AApiKeyStoreOptions, PostgreSQLAgentRunLedger, type PostgreSQLAgentRunLedgerOptions, PostgreSQLAgentWebAppStore, type PostgreSQLAgentWebAppStoreOptions, PostgreSQLAssistantStore, type PostgreSQLAssistantStoreOptions, PostgreSQLCapabilityBundleStore, type PostgreSQLCapabilityBundleStoreOptions, PostgreSQLChannelInstallationStore, type PostgreSQLChannelInstallationStoreOptions, PostgreSQLChannelReplyJobStore, type PostgreSQLChannelReplyJobStoreOptions, PostgreSQLCheckpointStorage, PostgreSQLCollectionStore, type PostgreSQLCollectionStoreOptions, PostgreSQLConnectionStore, PostgreSQLDatabaseConfigStore, type PostgreSQLDatabaseConfigStoreOptions, PostgreSQLEvalStore, type PostgreSQLEvalStoreOptions, PostgreSQLMcpServerConfigStore, type PostgreSQLMcpServerConfigStoreOptions, PostgreSQLMetricsServerConfigStore, type PostgreSQLMetricsServerConfigStoreOptions, PostgreSQLModelProviderStore, type PostgreSQLModelProviderStoreOptions, PostgreSQLOpenAuditStore, type PostgreSQLOpenAuditStoreOptions, PostgreSQLPluginDeploymentStore, PostgreSQLProjectBotMembershipStore, PostgreSQLProjectMembershipStore, PostgreSQLProjectRoomMessageStore, PostgreSQLProjectRoomReadStateStore, PostgreSQLProjectRoomStore, PostgreSQLProjectStore, type PostgreSQLProjectStoreOptions, PostgreSQLScheduleStorage, type PostgreSQLScheduleStorageOptions, PostgreSQLSkillStore, type PostgreSQLSkillStoreOptions, PostgreSQLStore, PostgreSQLTaskWorkItemStore, type PostgreSQLTaskWorkItemStoreOptions, PostgreSQLTenantStore, type PostgreSQLTenantStoreOptions, type PostgreSQLThreadMessageQueueStoreOptions, PostgreSQLThreadStore, type PostgreSQLThreadStoreOptions, PostgreSQLUserStore, type PostgreSQLUserStoreOptions, PostgreSQLUserTenantLinkStore, type PostgreSQLUserTenantLinkStoreOptions, PostgreSQLWorkflowTrackingStore, type PostgreSQLWorkflowTrackingStoreOptions, PostgreSQLWorkspaceStore, type PostgreSQLWorkspaceStoreOptions, PostgresSharedResourceStore, type PostgresSharedResourceStoreOptions, ProjectBotMembershipIdConflictError, ProjectMembershipIdConflictError, ProjectRoomMessageIdConflictError, ThreadMessageQueueStore, addAssistantTenantId, addCancelRequestedToEvalRuns, addEnvToEvalRuns, addFileContentType, addHoldoutToEvalRuns, addInterruptColumnsToEval, addInterruptPolicyToEvalCases, addMcpAppContentType, addProjectConfigColumn, addScheduleTenantId, addSkillTenantId, addStepThreadId, addTaskIdToEvalRuns, addThreadExpiresAt, addThreadTenantId, addWorkflowRunsTenantStatusUpdatedIndex, alterChannelInstallationsTable, changeAssistantPrimaryKey, changeSkillPrimaryKey, changeThreadPrimaryKey, createA2AApiKeysTable, createAgentRunLedgerTable, createAgentWebAppsTable, createAssistantsTable, createCapabilityBundlesTable, createChannelBindingsTable, createChannelIdentityMappingTables, createChannelInstallationsTable, createChannelReplyJobsTable, createCollectionsTable, createDatabaseConfigsTable, createEvalCasesTable, createEvalProjectsTable, createEvalRunResultsTable, createEvalRunsTable, createEvalSuitesTable, createMcpServerConfigsTable, createMenuItemsTable, createMetricsConfigsTable, createPGVectorStoreProvider, createPgStoreConfig, createPluginDeployments, createProjectRoomReadStates, createProjectRoomTables, createProjectsTable, createScheduledTasksTable, createSharedResourcesTable, createSkillsTable, createStoreItemsTable, createTenantsTable, createThreadMessageQueueTable, createThreadsTable, createUsersTable, createWorkflowTrackingTables, createWorkspacesTable, dropPluginDeploymentAuthToken, enforceUniqueEvalProjectName, evalMigrations, mapRowToRunStep, mapRowToWorkflowRun, safeParse };
|
|
2876
|
+
export { ChannelBindingStore, type ChannelBindingStoreOptions, type ChannelIdentityMapping, ChannelIdentityMappingStore, type ChannelIdentityMappingStoreOptions, CheckpointBaseNotFoundError, CheckpointTargetNotEmptyError, type CreateChannelIdentityMappingInput, DuplicateProjectMembershipError, DuplicateProjectRoomMessageIdempotencyKeyError, InvalidFileShareAddressError, InvalidMcpAppShareAddressError, InvalidMcpAppShareVisibilityError, MenuStore, type MenuStoreOptions, type Migration, MigrationManager, PGVectorStoreProvider, PostgreSQLA2AApiKeyStore, type PostgreSQLA2AApiKeyStoreOptions, PostgreSQLAgentRunLedger, type PostgreSQLAgentRunLedgerOptions, PostgreSQLAgentWebAppStore, type PostgreSQLAgentWebAppStoreOptions, PostgreSQLAssistantStore, type PostgreSQLAssistantStoreOptions, PostgreSQLCapabilityBundleStore, type PostgreSQLCapabilityBundleStoreOptions, PostgreSQLChannelInstallationStore, type PostgreSQLChannelInstallationStoreOptions, PostgreSQLChannelReplyJobStore, type PostgreSQLChannelReplyJobStoreOptions, PostgreSQLCheckpointStorage, PostgreSQLCollectionStore, type PostgreSQLCollectionStoreOptions, PostgreSQLConnectionStore, PostgreSQLDatabaseConfigStore, type PostgreSQLDatabaseConfigStoreOptions, PostgreSQLEvalStore, type PostgreSQLEvalStoreOptions, PostgreSQLMcpServerConfigStore, type PostgreSQLMcpServerConfigStoreOptions, PostgreSQLMetricsServerConfigStore, type PostgreSQLMetricsServerConfigStoreOptions, PostgreSQLModelProviderStore, type PostgreSQLModelProviderStoreOptions, PostgreSQLOpenAuditStore, type PostgreSQLOpenAuditStoreOptions, PostgreSQLPluginDeploymentStore, PostgreSQLProjectBotMembershipStore, PostgreSQLProjectMembershipStore, PostgreSQLProjectRoomMessageStore, PostgreSQLProjectRoomReadStateStore, PostgreSQLProjectRoomStore, PostgreSQLProjectStore, type PostgreSQLProjectStoreOptions, PostgreSQLScheduleStorage, type PostgreSQLScheduleStorageOptions, PostgreSQLSkillStore, type PostgreSQLSkillStoreOptions, PostgreSQLStore, PostgreSQLTaskWorkItemStore, type PostgreSQLTaskWorkItemStoreOptions, PostgreSQLTenantStore, type PostgreSQLTenantStoreOptions, type PostgreSQLThreadMessageQueueStoreOptions, PostgreSQLThreadStore, type PostgreSQLThreadStoreOptions, PostgreSQLUserStore, type PostgreSQLUserStoreOptions, PostgreSQLUserTenantLinkStore, type PostgreSQLUserTenantLinkStoreOptions, PostgreSQLWorkflowTrackingStore, type PostgreSQLWorkflowTrackingStoreOptions, PostgreSQLWorkspaceStore, type PostgreSQLWorkspaceStoreOptions, PostgresSharedResourceStore, type PostgresSharedResourceStoreOptions, ProjectBotMembershipIdConflictError, ProjectMembershipIdConflictError, ProjectRoomMessageIdConflictError, ThreadMessageQueueStore, addAssistantTenantId, addCancelRequestedToEvalRuns, addEnvToEvalRuns, addFileContentType, addHoldoutToEvalRuns, addInterruptColumnsToEval, addInterruptPolicyToEvalCases, addMcpAppContentType, addProjectConfigColumn, addScheduleTenantId, addShareKind, addSkillTenantId, addStepThreadId, addTaskIdToEvalRuns, addThreadExpiresAt, addThreadTenantId, addWorkflowRunsTenantStatusUpdatedIndex, alterChannelInstallationsTable, changeAssistantPrimaryKey, changeSkillPrimaryKey, changeThreadPrimaryKey, createA2AApiKeysTable, createAgentRunLedgerTable, createAgentWebAppsTable, createAssistantsTable, createCapabilityBundlesTable, createChannelBindingsTable, createChannelIdentityMappingTables, createChannelInstallationsTable, createChannelReplyJobsTable, createCollectionsTable, createDatabaseConfigsTable, createEvalCasesTable, createEvalProjectsTable, createEvalRunResultsTable, createEvalRunsTable, createEvalSuitesTable, createMcpServerConfigsTable, createMenuItemsTable, createMetricsConfigsTable, createPGVectorStoreProvider, createPgStoreConfig, createPluginDeployments, createProjectRoomReadStates, createProjectRoomTables, createProjectsTable, createScheduledTasksTable, createSharedResourcesTable, createSkillsTable, createStoreItemsTable, createTenantsTable, createThreadMessageQueueTable, createThreadsTable, createUsersTable, createWorkflowTrackingTables, createWorkspacesTable, dropPluginDeploymentAuthToken, enforceUniqueEvalProjectName, evalMigrations, mapRowToRunStep, mapRowToWorkflowRun, safeParse };
|
package/dist/index.js
CHANGED
|
@@ -36,6 +36,9 @@ __export(index_exports, {
|
|
|
36
36
|
CheckpointTargetNotEmptyError: () => CheckpointTargetNotEmptyError,
|
|
37
37
|
DuplicateProjectMembershipError: () => DuplicateProjectMembershipError,
|
|
38
38
|
DuplicateProjectRoomMessageIdempotencyKeyError: () => DuplicateProjectRoomMessageIdempotencyKeyError,
|
|
39
|
+
InvalidFileShareAddressError: () => InvalidFileShareAddressError,
|
|
40
|
+
InvalidMcpAppShareAddressError: () => InvalidMcpAppShareAddressError,
|
|
41
|
+
InvalidMcpAppShareVisibilityError: () => InvalidMcpAppShareVisibilityError,
|
|
39
42
|
MenuStore: () => MenuStore,
|
|
40
43
|
MigrationManager: () => MigrationManager,
|
|
41
44
|
PGVectorStoreProvider: () => PGVectorStoreProvider,
|
|
@@ -88,6 +91,7 @@ __export(index_exports, {
|
|
|
88
91
|
addMcpAppContentType: () => addMcpAppContentType,
|
|
89
92
|
addProjectConfigColumn: () => addProjectConfigColumn,
|
|
90
93
|
addScheduleTenantId: () => addScheduleTenantId,
|
|
94
|
+
addShareKind: () => addShareKind,
|
|
91
95
|
addSkillTenantId: () => addSkillTenantId,
|
|
92
96
|
addStepThreadId: () => addStepThreadId,
|
|
93
97
|
addTaskIdToEvalRuns: () => addTaskIdToEvalRuns,
|
|
@@ -9375,7 +9379,106 @@ var createSharedResourcesTable = {
|
|
|
9375
9379
|
}
|
|
9376
9380
|
};
|
|
9377
9381
|
|
|
9382
|
+
// src/migrations/add_share_open_grants.ts
|
|
9383
|
+
var addShareOpenGrants = {
|
|
9384
|
+
version: 180,
|
|
9385
|
+
name: "add_share_open_grants",
|
|
9386
|
+
up: async (client) => {
|
|
9387
|
+
await client.query(`
|
|
9388
|
+
ALTER TABLE lattice_shared_resources
|
|
9389
|
+
ADD COLUMN IF NOT EXISTS open_grants JSONB
|
|
9390
|
+
`);
|
|
9391
|
+
},
|
|
9392
|
+
down: async (client) => {
|
|
9393
|
+
await client.query(`
|
|
9394
|
+
ALTER TABLE lattice_shared_resources
|
|
9395
|
+
DROP COLUMN IF EXISTS open_grants
|
|
9396
|
+
`);
|
|
9397
|
+
}
|
|
9398
|
+
};
|
|
9399
|
+
|
|
9400
|
+
// src/migrations/add_share_kind.ts
|
|
9401
|
+
var addShareKind = {
|
|
9402
|
+
version: 208,
|
|
9403
|
+
name: "add_share_kind",
|
|
9404
|
+
up: async (client) => {
|
|
9405
|
+
await client.query(`
|
|
9406
|
+
ALTER TABLE lattice_shared_resources
|
|
9407
|
+
ADD COLUMN IF NOT EXISTS kind VARCHAR(16) NOT NULL DEFAULT 'file'
|
|
9408
|
+
`);
|
|
9409
|
+
await client.query(`
|
|
9410
|
+
ALTER TABLE lattice_shared_resources
|
|
9411
|
+
DROP CONSTRAINT IF EXISTS lattice_shared_resources_kind_check
|
|
9412
|
+
`);
|
|
9413
|
+
await client.query(`
|
|
9414
|
+
ALTER TABLE lattice_shared_resources
|
|
9415
|
+
ADD CONSTRAINT lattice_shared_resources_kind_check
|
|
9416
|
+
CHECK (kind IN ('file', 'mcpApp'))
|
|
9417
|
+
`);
|
|
9418
|
+
await client.query(`
|
|
9419
|
+
ALTER TABLE lattice_shared_resources
|
|
9420
|
+
DROP CONSTRAINT IF EXISTS lattice_shared_resources_mcp_app_visibility_check
|
|
9421
|
+
`);
|
|
9422
|
+
await client.query(`
|
|
9423
|
+
ALTER TABLE lattice_shared_resources
|
|
9424
|
+
ADD CONSTRAINT lattice_shared_resources_mcp_app_visibility_check
|
|
9425
|
+
CHECK (kind <> 'mcpApp' OR visibility IN ('public', 'password'))
|
|
9426
|
+
`);
|
|
9427
|
+
},
|
|
9428
|
+
down: async (client) => {
|
|
9429
|
+
await client.query(`
|
|
9430
|
+
ALTER TABLE lattice_shared_resources
|
|
9431
|
+
DROP CONSTRAINT IF EXISTS lattice_shared_resources_mcp_app_visibility_check
|
|
9432
|
+
`);
|
|
9433
|
+
await client.query(`
|
|
9434
|
+
ALTER TABLE lattice_shared_resources
|
|
9435
|
+
DROP CONSTRAINT IF EXISTS lattice_shared_resources_kind_check
|
|
9436
|
+
`);
|
|
9437
|
+
await client.query(`
|
|
9438
|
+
ALTER TABLE lattice_shared_resources
|
|
9439
|
+
DROP COLUMN IF EXISTS kind
|
|
9440
|
+
`);
|
|
9441
|
+
}
|
|
9442
|
+
};
|
|
9443
|
+
|
|
9378
9444
|
// src/stores/PostgresSharedResourceStore.ts
|
|
9445
|
+
var InvalidMcpAppShareAddressError = class extends Error {
|
|
9446
|
+
/**
|
|
9447
|
+
* @param token - Share token owning the invalid address.
|
|
9448
|
+
*/
|
|
9449
|
+
constructor(token) {
|
|
9450
|
+
super(`Share ${token} has an invalid MCP App address`);
|
|
9451
|
+
/** Machine-readable failure code. */
|
|
9452
|
+
this.code = "INVALID_MCP_APP_SHARE_ADDRESS";
|
|
9453
|
+
this.name = "InvalidMcpAppShareAddressError";
|
|
9454
|
+
}
|
|
9455
|
+
};
|
|
9456
|
+
var InvalidMcpAppShareVisibilityError = class extends Error {
|
|
9457
|
+
/**
|
|
9458
|
+
* @param token - Share token owning the invalid visibility.
|
|
9459
|
+
* @param visibility - Visibility value found in the row.
|
|
9460
|
+
*/
|
|
9461
|
+
constructor(token, visibility) {
|
|
9462
|
+
super(
|
|
9463
|
+
`Share ${token} has unsupported MCP App visibility: ${visibility}`
|
|
9464
|
+
);
|
|
9465
|
+
/** Machine-readable failure code. */
|
|
9466
|
+
this.code = "INVALID_MCP_APP_SHARE_VISIBILITY";
|
|
9467
|
+
this.name = "InvalidMcpAppShareVisibilityError";
|
|
9468
|
+
this.visibility = visibility;
|
|
9469
|
+
}
|
|
9470
|
+
};
|
|
9471
|
+
var InvalidFileShareAddressError = class extends Error {
|
|
9472
|
+
/**
|
|
9473
|
+
* @param token - Share token owning the invalid address.
|
|
9474
|
+
*/
|
|
9475
|
+
constructor(token) {
|
|
9476
|
+
super(`Share ${token} has an invalid file address`);
|
|
9477
|
+
/** Machine-readable failure code. */
|
|
9478
|
+
this.code = "INVALID_FILE_SHARE_ADDRESS";
|
|
9479
|
+
this.name = "InvalidFileShareAddressError";
|
|
9480
|
+
}
|
|
9481
|
+
};
|
|
9379
9482
|
var PostgresSharedResourceStore = class {
|
|
9380
9483
|
constructor(options) {
|
|
9381
9484
|
this.initialized = false;
|
|
@@ -9392,6 +9495,8 @@ var PostgresSharedResourceStore = class {
|
|
|
9392
9495
|
})();
|
|
9393
9496
|
this.migrationManager = new MigrationManager(this.pool);
|
|
9394
9497
|
this.migrationManager.register(createSharedResourcesTable);
|
|
9498
|
+
this.migrationManager.register(addShareOpenGrants);
|
|
9499
|
+
this.migrationManager.register(addShareKind);
|
|
9395
9500
|
if (options.autoMigrate !== false) {
|
|
9396
9501
|
this.initialize().catch((error) => {
|
|
9397
9502
|
console.error(
|
|
@@ -9433,13 +9538,14 @@ var PostgresSharedResourceStore = class {
|
|
|
9433
9538
|
await this.ensureInitialized();
|
|
9434
9539
|
const { rows } = await this.pool.query(
|
|
9435
9540
|
`INSERT INTO lattice_shared_resources
|
|
9436
|
-
(token, address, title, created_by, tenant_id, workspace_id, project_id,
|
|
9541
|
+
(token, kind, address, title, created_by, tenant_id, workspace_id, project_id,
|
|
9437
9542
|
assistant_id, vm_isolation, visibility, password_hash,
|
|
9438
9543
|
expires_at, max_access, open_grants, revoked)
|
|
9439
|
-
VALUES ($1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15)
|
|
9544
|
+
VALUES ($1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16)
|
|
9440
9545
|
RETURNING *`,
|
|
9441
9546
|
[
|
|
9442
9547
|
record.token,
|
|
9548
|
+
record.kind ?? "file",
|
|
9443
9549
|
JSON.stringify(record.address),
|
|
9444
9550
|
record.title,
|
|
9445
9551
|
record.createdBy,
|
|
@@ -9528,15 +9634,9 @@ var PostgresSharedResourceStore = class {
|
|
|
9528
9634
|
}
|
|
9529
9635
|
}
|
|
9530
9636
|
_mapRow(row) {
|
|
9531
|
-
|
|
9532
|
-
|
|
9533
|
-
address = JSON.parse(row.address);
|
|
9534
|
-
} else {
|
|
9535
|
-
address = row.address;
|
|
9536
|
-
}
|
|
9537
|
-
return {
|
|
9637
|
+
const address = parseShareAddress(row.address);
|
|
9638
|
+
const base = {
|
|
9538
9639
|
token: row.token,
|
|
9539
|
-
address,
|
|
9540
9640
|
title: row.title,
|
|
9541
9641
|
createdBy: row.created_by,
|
|
9542
9642
|
tenantId: row.tenant_id,
|
|
@@ -9544,7 +9644,6 @@ var PostgresSharedResourceStore = class {
|
|
|
9544
9644
|
projectId: row.project_id,
|
|
9545
9645
|
assistantId: row.assistant_id,
|
|
9546
9646
|
vmIsolation: row.vm_isolation,
|
|
9547
|
-
visibility: row.visibility,
|
|
9548
9647
|
passwordHash: row.password_hash,
|
|
9549
9648
|
expiresAt: row.expires_at ? new Date(row.expires_at) : null,
|
|
9550
9649
|
maxAccess: row.max_access,
|
|
@@ -9554,8 +9653,52 @@ var PostgresSharedResourceStore = class {
|
|
|
9554
9653
|
createdAt: new Date(row.created_at),
|
|
9555
9654
|
version: row.version ?? 1
|
|
9556
9655
|
};
|
|
9656
|
+
if (row.kind === "mcpApp") {
|
|
9657
|
+
if (!isRecord3(address) || address.kind !== "mcpApp") {
|
|
9658
|
+
throw new InvalidMcpAppShareAddressError(row.token);
|
|
9659
|
+
}
|
|
9660
|
+
const app = address.app;
|
|
9661
|
+
if (!isMcpAppShareApp(app)) {
|
|
9662
|
+
throw new InvalidMcpAppShareAddressError(row.token);
|
|
9663
|
+
}
|
|
9664
|
+
if (row.visibility !== "public" && row.visibility !== "password") {
|
|
9665
|
+
throw new InvalidMcpAppShareVisibilityError(row.token, row.visibility);
|
|
9666
|
+
}
|
|
9667
|
+
return {
|
|
9668
|
+
...base,
|
|
9669
|
+
kind: "mcpApp",
|
|
9670
|
+
address: { kind: "mcpApp", app },
|
|
9671
|
+
visibility: row.visibility
|
|
9672
|
+
};
|
|
9673
|
+
}
|
|
9674
|
+
if (!isRecord3(address) || typeof address.volume !== "string" || typeof address.resourcePath !== "string") {
|
|
9675
|
+
throw new InvalidFileShareAddressError(row.token);
|
|
9676
|
+
}
|
|
9677
|
+
return {
|
|
9678
|
+
...base,
|
|
9679
|
+
kind: "file",
|
|
9680
|
+
address: {
|
|
9681
|
+
volume: address.volume,
|
|
9682
|
+
resourcePath: address.resourcePath
|
|
9683
|
+
},
|
|
9684
|
+
visibility: row.visibility
|
|
9685
|
+
};
|
|
9557
9686
|
}
|
|
9558
9687
|
};
|
|
9688
|
+
function isRecord3(value) {
|
|
9689
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
9690
|
+
}
|
|
9691
|
+
function isMcpAppShareApp(value) {
|
|
9692
|
+
return isRecord3(value) && (value.kind === "plugin" || value.kind === "mcp");
|
|
9693
|
+
}
|
|
9694
|
+
function parseShareAddress(raw) {
|
|
9695
|
+
if (typeof raw !== "string") return raw;
|
|
9696
|
+
try {
|
|
9697
|
+
return JSON.parse(raw);
|
|
9698
|
+
} catch {
|
|
9699
|
+
return null;
|
|
9700
|
+
}
|
|
9701
|
+
}
|
|
9559
9702
|
|
|
9560
9703
|
// src/stores/PostgreSQLCollectionStore.ts
|
|
9561
9704
|
var import_pg24 = require("pg");
|
|
@@ -10070,24 +10213,6 @@ var reencryptLegacyConnectionSecrets = {
|
|
|
10070
10213
|
}
|
|
10071
10214
|
};
|
|
10072
10215
|
|
|
10073
|
-
// src/migrations/add_share_open_grants.ts
|
|
10074
|
-
var addShareOpenGrants = {
|
|
10075
|
-
version: 180,
|
|
10076
|
-
name: "add_share_open_grants",
|
|
10077
|
-
up: async (client) => {
|
|
10078
|
-
await client.query(`
|
|
10079
|
-
ALTER TABLE lattice_shared_resources
|
|
10080
|
-
ADD COLUMN IF NOT EXISTS open_grants JSONB
|
|
10081
|
-
`);
|
|
10082
|
-
},
|
|
10083
|
-
down: async (client) => {
|
|
10084
|
-
await client.query(`
|
|
10085
|
-
ALTER TABLE lattice_shared_resources
|
|
10086
|
-
DROP COLUMN IF EXISTS open_grants
|
|
10087
|
-
`);
|
|
10088
|
-
}
|
|
10089
|
-
};
|
|
10090
|
-
|
|
10091
10216
|
// src/migrations/collection_migrations.ts
|
|
10092
10217
|
var createCollectionsTable = {
|
|
10093
10218
|
version: 137,
|
|
@@ -11587,14 +11712,14 @@ var DuplicateProjectRoomMessageIdempotencyKeyError = class extends Error {
|
|
|
11587
11712
|
this.name = "DuplicateProjectRoomMessageIdempotencyKeyError";
|
|
11588
11713
|
}
|
|
11589
11714
|
};
|
|
11590
|
-
function
|
|
11715
|
+
function isRecord4(value) {
|
|
11591
11716
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
11592
11717
|
}
|
|
11593
11718
|
function hasOnlyKeys(value, keys) {
|
|
11594
11719
|
return Object.keys(value).every((key) => keys.includes(key));
|
|
11595
11720
|
}
|
|
11596
11721
|
function mapAuthor(value) {
|
|
11597
|
-
if (!
|
|
11722
|
+
if (!isRecord4(value) || typeof value.type !== "string") return void 0;
|
|
11598
11723
|
if (value.type === "human" && hasOnlyKeys(value, ["type", "userId"]) && typeof value.userId === "string") return { type: "human", userId: value.userId };
|
|
11599
11724
|
if (value.type === "bot" && hasOnlyKeys(value, ["type", "membershipId", "assistantId"]) && typeof value.membershipId === "string" && typeof value.assistantId === "string") {
|
|
11600
11725
|
return { type: "bot", membershipId: value.membershipId, assistantId: value.assistantId };
|
|
@@ -11603,7 +11728,7 @@ function mapAuthor(value) {
|
|
|
11603
11728
|
return void 0;
|
|
11604
11729
|
}
|
|
11605
11730
|
function mapMention(value) {
|
|
11606
|
-
if (!
|
|
11731
|
+
if (!isRecord4(value) || typeof value.type !== "string") return void 0;
|
|
11607
11732
|
if (value.type === "bot" && hasOnlyKeys(value, ["type", "membershipId"]) && typeof value.membershipId === "string") {
|
|
11608
11733
|
return { type: "bot", membershipId: value.membershipId };
|
|
11609
11734
|
}
|
|
@@ -11615,7 +11740,7 @@ function isSource(value) {
|
|
|
11615
11740
|
}
|
|
11616
11741
|
function mapRow5(row) {
|
|
11617
11742
|
const author = mapAuthor(row.author);
|
|
11618
|
-
const content =
|
|
11743
|
+
const content = isRecord4(row.content) && row.content.type === "text" && typeof row.content.text === "string" && hasOnlyKeys(row.content, ["type", "text"]) ? { type: "text", text: row.content.text } : void 0;
|
|
11619
11744
|
const mentions = Array.isArray(row.mentions) ? row.mentions.map(mapMention) : void 0;
|
|
11620
11745
|
if (typeof row.id !== "string" || typeof row.tenant_id !== "string" || typeof row.workspace_id !== "string" || typeof row.project_id !== "string" || typeof row.room_id !== "string" || !author || !content || !mentions || mentions.some((mention) => mention === void 0) || row.reply_to_message_id !== null && typeof row.reply_to_message_id !== "string" || !isSource(row.source) || row.source_id !== null && typeof row.source_id !== "string" || row.idempotency_key !== null && typeof row.idempotency_key !== "string" || !(row.created_at instanceof Date) || Number.isNaN(row.created_at.getTime())) {
|
|
11621
11746
|
throw new Error("Invalid project room message row");
|
|
@@ -14041,7 +14166,7 @@ async function rollbackQuietly(client) {
|
|
|
14041
14166
|
function isUniqueViolation3(error) {
|
|
14042
14167
|
return typeof error === "object" && error !== null && "code" in error && error.code === "23505";
|
|
14043
14168
|
}
|
|
14044
|
-
function
|
|
14169
|
+
function isRecord5(value) {
|
|
14045
14170
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
14046
14171
|
}
|
|
14047
14172
|
function checkpointKey(checkpointNs, checkpointId) {
|
|
@@ -14054,17 +14179,17 @@ function checkpointRecord(value) {
|
|
|
14054
14179
|
if (typeof value === "string") {
|
|
14055
14180
|
try {
|
|
14056
14181
|
const parsed = JSON.parse(value);
|
|
14057
|
-
return
|
|
14182
|
+
return isRecord5(parsed) ? parsed : void 0;
|
|
14058
14183
|
} catch {
|
|
14059
14184
|
return void 0;
|
|
14060
14185
|
}
|
|
14061
14186
|
}
|
|
14062
|
-
return
|
|
14187
|
+
return isRecord5(value) ? value : void 0;
|
|
14063
14188
|
}
|
|
14064
14189
|
function channelVersions(value) {
|
|
14065
14190
|
const checkpoint = checkpointRecord(value);
|
|
14066
14191
|
const versions = checkpoint?.channel_versions;
|
|
14067
|
-
return
|
|
14192
|
+
return isRecord5(versions) ? versions : void 0;
|
|
14068
14193
|
}
|
|
14069
14194
|
var DELETE_CHUNK_SIZE = 100;
|
|
14070
14195
|
function chunk(items, size) {
|
|
@@ -14712,6 +14837,7 @@ async function createPgStoreConfig(connectionString) {
|
|
|
14712
14837
|
mm.register(createAgentRunProjectTaskMigration);
|
|
14713
14838
|
mm.register(agentRunProjectTaskRunningIndexMigration);
|
|
14714
14839
|
mm.register(addModelProviderKindDefault);
|
|
14840
|
+
mm.register(addShareKind);
|
|
14715
14841
|
await mm.migrate();
|
|
14716
14842
|
const checkpoint = import_langgraph_checkpoint_postgres.PostgresSaver.fromConnString(connectionString);
|
|
14717
14843
|
checkpoint.setup().catch((err) => {
|
|
@@ -15320,6 +15446,9 @@ function mapRowToChannelIdentityMapping(row) {
|
|
|
15320
15446
|
CheckpointTargetNotEmptyError,
|
|
15321
15447
|
DuplicateProjectMembershipError,
|
|
15322
15448
|
DuplicateProjectRoomMessageIdempotencyKeyError,
|
|
15449
|
+
InvalidFileShareAddressError,
|
|
15450
|
+
InvalidMcpAppShareAddressError,
|
|
15451
|
+
InvalidMcpAppShareVisibilityError,
|
|
15323
15452
|
MenuStore,
|
|
15324
15453
|
MigrationManager,
|
|
15325
15454
|
PGVectorStoreProvider,
|
|
@@ -15372,6 +15501,7 @@ function mapRowToChannelIdentityMapping(row) {
|
|
|
15372
15501
|
addMcpAppContentType,
|
|
15373
15502
|
addProjectConfigColumn,
|
|
15374
15503
|
addScheduleTenantId,
|
|
15504
|
+
addShareKind,
|
|
15375
15505
|
addSkillTenantId,
|
|
15376
15506
|
addStepThreadId,
|
|
15377
15507
|
addTaskIdToEvalRuns,
|