@imbue-ai/detent 1.15.1 → 1.15.2
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/README.md +12 -0
- package/dist/src/schemas/generatedBuiltinSchemas.d.ts.map +1 -1
- package/dist/src/schemas/generatedBuiltinSchemas.js +551 -7
- package/dist/src/schemas/generatedBuiltinSchemas.js.map +1 -1
- package/dist/tests/builtinSchemas.test.js +91 -0
- package/dist/tests/builtinSchemas.test.js.map +1 -1
- package/package.json +1 -1
|
@@ -992,18 +992,42 @@ describe('builtin schemas: notion-mcp', () => {
|
|
|
992
992
|
const readAll = builtinRegistry.get('notion-mcp-read-all');
|
|
993
993
|
for (const tool of [
|
|
994
994
|
'notion-search',
|
|
995
|
+
'notion-ai-search',
|
|
995
996
|
'notion-fetch',
|
|
996
997
|
'notion-query-data-sources',
|
|
998
|
+
'notion-query-multiple-data-sources',
|
|
997
999
|
'notion-query-database-view',
|
|
1000
|
+
'notion-query-meeting-notes',
|
|
1001
|
+
'notion-list-recent-pages',
|
|
1002
|
+
'notion-list-private-pages',
|
|
1003
|
+
'notion-list-favorite-pages',
|
|
1004
|
+
'notion-list-shared-pages',
|
|
998
1005
|
'notion-get-comments',
|
|
999
1006
|
'notion-get-teams',
|
|
1007
|
+
'notion-get-users',
|
|
1000
1008
|
'notion-get-self',
|
|
1009
|
+
'notion-get-async-task',
|
|
1010
|
+
'notion-search-skills',
|
|
1011
|
+
'notion-download-skill',
|
|
1012
|
+
'notion-download-attachment',
|
|
1013
|
+
'notion-list-agents',
|
|
1014
|
+
'notion-search-agents',
|
|
1015
|
+
'notion-query-sessions',
|
|
1016
|
+
'notion-search-sessions',
|
|
1017
|
+
'notion-get-session-status',
|
|
1018
|
+
'notion-wait-session',
|
|
1019
|
+
'notion-list-session-events',
|
|
1020
|
+
'notion-read-session-event',
|
|
1021
|
+
'notion-check-mcp-next-steps',
|
|
1022
|
+
'notion-show-advanced-analysis-next-steps',
|
|
1001
1023
|
]) {
|
|
1002
1024
|
expect(readAll.match(mcpRequest(toolCall(tool))), `read-all should allow ${tool}`).toBe(true);
|
|
1003
1025
|
}
|
|
1004
1026
|
expect(readAll.match(mcpRequest(rpc('initialize')))).toBe(true);
|
|
1005
1027
|
expect(readAll.match(mcpRequest(toolCall('notion-create-pages')))).toBe(false);
|
|
1006
1028
|
expect(readAll.match(mcpRequest(toolCall('notion-update-page')))).toBe(false);
|
|
1029
|
+
expect(readAll.match(mcpRequest(toolCall('notion-spawn-session')))).toBe(false);
|
|
1030
|
+
expect(readAll.match(mcpRequest(toolCall('notion-create-attachment')))).toBe(false);
|
|
1007
1031
|
});
|
|
1008
1032
|
it('notion-mcp-write-all matches write tools and the handshake but not reads', () => {
|
|
1009
1033
|
expectSchemaExists('notion-mcp-write-all');
|
|
@@ -1013,17 +1037,84 @@ describe('builtin schemas: notion-mcp', () => {
|
|
|
1013
1037
|
'notion-update-page',
|
|
1014
1038
|
'notion-move-pages',
|
|
1015
1039
|
'notion-duplicate-page',
|
|
1040
|
+
'notion-convert-page-to-skill',
|
|
1041
|
+
'notion-create-file-upload',
|
|
1042
|
+
'notion-create-attachment',
|
|
1016
1043
|
'notion-create-database',
|
|
1044
|
+
'notion-create-folder',
|
|
1045
|
+
'notion-update-folder',
|
|
1017
1046
|
'notion-update-data-source',
|
|
1018
1047
|
'notion-create-view',
|
|
1019
1048
|
'notion-update-view',
|
|
1020
1049
|
'notion-create-comment',
|
|
1050
|
+
'notion-spawn-session',
|
|
1051
|
+
'notion-stop-session',
|
|
1052
|
+
'notion-send-message-to-session',
|
|
1021
1053
|
]) {
|
|
1022
1054
|
expect(writeAll.match(mcpRequest(toolCall(tool))), `write-all should allow ${tool}`).toBe(true);
|
|
1023
1055
|
}
|
|
1024
1056
|
expect(writeAll.match(mcpRequest(rpc('initialize')))).toBe(true);
|
|
1025
1057
|
expect(writeAll.match(mcpRequest(toolCall('notion-search')))).toBe(false);
|
|
1026
1058
|
expect(writeAll.match(mcpRequest(toolCall('notion-fetch')))).toBe(false);
|
|
1059
|
+
expect(writeAll.match(mcpRequest(toolCall('notion-list-private-pages')))).toBe(false);
|
|
1060
|
+
});
|
|
1061
|
+
it('notion-mcp-list-pages matches the undocumented page-listing tools', () => {
|
|
1062
|
+
expectSchemaExists('notion-mcp-list-pages');
|
|
1063
|
+
const listPages = builtinRegistry.get('notion-mcp-list-pages');
|
|
1064
|
+
for (const tool of [
|
|
1065
|
+
'notion-list-recent-pages',
|
|
1066
|
+
'notion-list-private-pages',
|
|
1067
|
+
'notion-list-favorite-pages',
|
|
1068
|
+
'notion-list-shared-pages',
|
|
1069
|
+
]) {
|
|
1070
|
+
expect(listPages.match(mcpRequest(toolCall(tool))), `should allow ${tool}`).toBe(true);
|
|
1071
|
+
}
|
|
1072
|
+
expect(listPages.match(mcpRequest(toolCall('notion-search')))).toBe(false);
|
|
1073
|
+
});
|
|
1074
|
+
it('notion-mcp-query-data-sources covers the single and multi data source tools', () => {
|
|
1075
|
+
expectSchemaExists('notion-mcp-query-data-sources');
|
|
1076
|
+
const query = builtinRegistry.get('notion-mcp-query-data-sources');
|
|
1077
|
+
expect(query.match(mcpRequest(toolCall('notion-query-data-sources')))).toBe(true);
|
|
1078
|
+
expect(query.match(mcpRequest(toolCall('notion-query-multiple-data-sources')))).toBe(true);
|
|
1079
|
+
expect(query.match(mcpRequest(toolCall('notion-query-database-view')))).toBe(false);
|
|
1080
|
+
});
|
|
1081
|
+
it('notion-mcp agent schemas separate reading sessions from driving them', () => {
|
|
1082
|
+
expectSchemaExists('notion-mcp-read-agents');
|
|
1083
|
+
expectSchemaExists('notion-mcp-write-agents');
|
|
1084
|
+
const readAgents = builtinRegistry.get('notion-mcp-read-agents');
|
|
1085
|
+
const writeAgents = builtinRegistry.get('notion-mcp-write-agents');
|
|
1086
|
+
expect(readAgents.match(mcpRequest(toolCall('notion-list-agents')))).toBe(true);
|
|
1087
|
+
expect(readAgents.match(mcpRequest(toolCall('notion-read-session-event')))).toBe(true);
|
|
1088
|
+
expect(readAgents.match(mcpRequest(toolCall('notion-spawn-session')))).toBe(false);
|
|
1089
|
+
expect(writeAgents.match(mcpRequest(toolCall('notion-spawn-session')))).toBe(true);
|
|
1090
|
+
expect(writeAgents.match(mcpRequest(toolCall('notion-send-message-to-session')))).toBe(true);
|
|
1091
|
+
expect(writeAgents.match(mcpRequest(toolCall('notion-get-session-status')))).toBe(false);
|
|
1092
|
+
});
|
|
1093
|
+
it('notion-mcp attachment schemas separate downloads from uploads', () => {
|
|
1094
|
+
expectSchemaExists('notion-mcp-read-attachments');
|
|
1095
|
+
expectSchemaExists('notion-mcp-write-attachments');
|
|
1096
|
+
const readAttachments = builtinRegistry.get('notion-mcp-read-attachments');
|
|
1097
|
+
const writeAttachments = builtinRegistry.get('notion-mcp-write-attachments');
|
|
1098
|
+
expect(readAttachments.match(mcpRequest(toolCall('notion-download-attachment')))).toBe(true);
|
|
1099
|
+
expect(readAttachments.match(mcpRequest(toolCall('notion-create-attachment')))).toBe(false);
|
|
1100
|
+
expect(writeAttachments.match(mcpRequest(toolCall('notion-create-file-upload')))).toBe(true);
|
|
1101
|
+
expect(writeAttachments.match(mcpRequest(toolCall('notion-create-attachment')))).toBe(true);
|
|
1102
|
+
expect(writeAttachments.match(mcpRequest(toolCall('notion-download-attachment')))).toBe(false);
|
|
1103
|
+
});
|
|
1104
|
+
it('notion-mcp single-tool schemas do not match the session handshake', () => {
|
|
1105
|
+
for (const schemaName of [
|
|
1106
|
+
'notion-mcp-ai-search',
|
|
1107
|
+
'notion-mcp-list-pages',
|
|
1108
|
+
'notion-mcp-query-meeting-notes',
|
|
1109
|
+
'notion-mcp-get-async-task',
|
|
1110
|
+
'notion-mcp-read-skills',
|
|
1111
|
+
'notion-mcp-next-steps',
|
|
1112
|
+
'notion-mcp-convert-page-to-skill',
|
|
1113
|
+
'notion-mcp-write-folders',
|
|
1114
|
+
]) {
|
|
1115
|
+
expectSchemaExists(schemaName);
|
|
1116
|
+
expect(builtinRegistry.get(schemaName).match(mcpRequest(rpc('initialize'))), `${schemaName} should not match the handshake`).toBe(false);
|
|
1117
|
+
}
|
|
1027
1118
|
});
|
|
1028
1119
|
});
|
|
1029
1120
|
describe('builtin schemas: sentry', () => {
|