callman-mcp 0.4.0 → 0.6.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/CHANGELOG.md +70 -0
- package/README.md +43 -11
- package/dist/client/api.d.ts +104 -1
- package/dist/client/api.d.ts.map +1 -1
- package/dist/client/api.js +137 -0
- package/dist/client/api.js.map +1 -1
- package/dist/client/errors.d.ts.map +1 -1
- package/dist/client/errors.js +46 -11
- package/dist/client/errors.js.map +1 -1
- package/dist/client/types.d.ts +257 -0
- package/dist/client/types.d.ts.map +1 -1
- package/dist/domain/diagram/patch.d.ts +32 -32
- package/dist/domain/scenario/build.d.ts.map +1 -1
- package/dist/domain/scenario/build.js +68 -17
- package/dist/domain/scenario/build.js.map +1 -1
- package/dist/domain/scenario/summarize.d.ts +1 -0
- package/dist/domain/scenario/summarize.d.ts.map +1 -1
- package/dist/domain/scenario/summarize.js +1 -0
- package/dist/domain/scenario/summarize.js.map +1 -1
- package/dist/domain/uiTest/compose.d.ts +55 -0
- package/dist/domain/uiTest/compose.d.ts.map +1 -0
- package/dist/domain/uiTest/compose.js +228 -0
- package/dist/domain/uiTest/compose.js.map +1 -0
- package/dist/domain/uiTest/summarize.d.ts +273 -0
- package/dist/domain/uiTest/summarize.d.ts.map +1 -0
- package/dist/domain/uiTest/summarize.js +145 -0
- package/dist/domain/uiTest/summarize.js.map +1 -0
- package/dist/lib/truncate.d.ts +1 -1
- package/dist/lib/truncate.d.ts.map +1 -1
- package/dist/lib/truncate.js.map +1 -1
- package/dist/resources/docs/diagramSchema.d.ts +2 -1
- package/dist/resources/docs/diagramSchema.d.ts.map +1 -1
- package/dist/resources/docs/diagramSchema.js +30 -3
- package/dist/resources/docs/diagramSchema.js.map +1 -1
- package/dist/resources/docs/overview.d.ts +1 -1
- package/dist/resources/docs/overview.d.ts.map +1 -1
- package/dist/resources/docs/overview.js +40 -7
- package/dist/resources/docs/overview.js.map +1 -1
- package/dist/resources/docs/uiTests.d.ts +2 -0
- package/dist/resources/docs/uiTests.d.ts.map +1 -0
- package/dist/resources/docs/uiTests.js +101 -0
- package/dist/resources/docs/uiTests.js.map +1 -0
- package/dist/resources/generated/aiPacks.d.ts +1 -1
- package/dist/resources/generated/aiPacks.js +4 -4
- package/dist/resources/generated/aiPacks.js.map +1 -1
- package/dist/resources/index.d.ts.map +1 -1
- package/dist/resources/index.js +15 -4
- package/dist/resources/index.js.map +1 -1
- package/dist/server.d.ts +1 -1
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +2 -2
- package/dist/server.js.map +1 -1
- package/dist/tools/catalog.d.ts +1 -1
- package/dist/tools/catalog.d.ts.map +1 -1
- package/dist/tools/catalog.js +37 -0
- package/dist/tools/catalog.js.map +1 -1
- package/dist/tools/diagrams.d.ts.map +1 -1
- package/dist/tools/diagrams.js +4 -1
- package/dist/tools/diagrams.js.map +1 -1
- package/dist/tools/index.d.ts.map +1 -1
- package/dist/tools/index.js +8 -0
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/lookups.d.ts +19 -1
- package/dist/tools/lookups.d.ts.map +1 -1
- package/dist/tools/lookups.js +77 -0
- package/dist/tools/lookups.js.map +1 -1
- package/dist/tools/scenarioAdmin.d.ts +4 -0
- package/dist/tools/scenarioAdmin.d.ts.map +1 -0
- package/dist/tools/scenarioAdmin.js +142 -0
- package/dist/tools/scenarioAdmin.js.map +1 -0
- package/dist/tools/scenarios.d.ts +4 -0
- package/dist/tools/scenarios.d.ts.map +1 -1
- package/dist/tools/scenarios.js +111 -16
- package/dist/tools/scenarios.js.map +1 -1
- package/dist/tools/shared.d.ts +5 -0
- package/dist/tools/shared.d.ts.map +1 -1
- package/dist/tools/shared.js +10 -0
- package/dist/tools/shared.js.map +1 -1
- package/dist/tools/uiTestAdmin.d.ts +4 -0
- package/dist/tools/uiTestAdmin.d.ts.map +1 -0
- package/dist/tools/uiTestAdmin.js +509 -0
- package/dist/tools/uiTestAdmin.js.map +1 -0
- package/dist/tools/uiTestRuns.d.ts +24 -0
- package/dist/tools/uiTestRuns.d.ts.map +1 -0
- package/dist/tools/uiTestRuns.js +367 -0
- package/dist/tools/uiTestRuns.js.map +1 -0
- package/dist/tools/uiTestShared.d.ts +236 -0
- package/dist/tools/uiTestShared.d.ts.map +1 -0
- package/dist/tools/uiTestShared.js +187 -0
- package/dist/tools/uiTestShared.js.map +1 -0
- package/dist/tools/uiTests.d.ts +4 -0
- package/dist/tools/uiTests.d.ts.map +1 -0
- package/dist/tools/uiTests.js +572 -0
- package/dist/tools/uiTests.js.map +1 -0
- package/dist-cjs/client/api.js +137 -0
- package/dist-cjs/client/errors.js +46 -11
- package/dist-cjs/domain/scenario/build.js +68 -17
- package/dist-cjs/domain/scenario/summarize.js +1 -0
- package/dist-cjs/domain/uiTest/compose.js +242 -0
- package/dist-cjs/domain/uiTest/summarize.js +155 -0
- package/dist-cjs/resources/docs/diagramSchema.js +32 -4
- package/dist-cjs/resources/docs/overview.js +40 -7
- package/dist-cjs/resources/docs/uiTests.js +103 -0
- package/dist-cjs/resources/generated/aiPacks.js +4 -4
- package/dist-cjs/resources/index.js +12 -1
- package/dist-cjs/server.js +2 -2
- package/dist-cjs/tools/catalog.js +37 -0
- package/dist-cjs/tools/diagrams.js +4 -1
- package/dist-cjs/tools/index.js +8 -0
- package/dist-cjs/tools/lookups.js +83 -1
- package/dist-cjs/tools/scenarioAdmin.js +145 -0
- package/dist-cjs/tools/scenarios.js +113 -17
- package/dist-cjs/tools/shared.js +12 -1
- package/dist-cjs/tools/uiTestAdmin.js +512 -0
- package/dist-cjs/tools/uiTestRuns.js +372 -0
- package/dist-cjs/tools/uiTestShared.js +202 -0
- package/dist-cjs/tools/uiTests.js +575 -0
- package/package.json +3 -3
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
import { resolveRunSettings } from "callman-core";
|
|
2
|
+
import { isMasked } from "../../lib/mask.js";
|
|
3
|
+
import { clip, jsonPreview } from "../../lib/truncate.js";
|
|
4
|
+
// Compact UI-test views: a flow row, a run timeline with the failing steps
|
|
5
|
+
// expanded, schedule rows. Screenshots never go into structuredContent —
|
|
6
|
+
// they travel as MCP image blocks (tools/uiTestRuns) or as `has…` flags.
|
|
7
|
+
const time = (value) => {
|
|
8
|
+
if (value === null || value === undefined || value === "")
|
|
9
|
+
return null;
|
|
10
|
+
const date = typeof value === "number" ? new Date(value) : new Date(String(value));
|
|
11
|
+
return Number.isNaN(date.getTime()) ? String(value) : date.toISOString();
|
|
12
|
+
};
|
|
13
|
+
export const flowSummaryView = (flow, folderPath) => ({
|
|
14
|
+
id: flow.clientId,
|
|
15
|
+
name: flow.name,
|
|
16
|
+
platform: flow.platform,
|
|
17
|
+
...(flow.description ? { description: clip(flow.description, 300) } : {}),
|
|
18
|
+
folder: folderPath ?? null,
|
|
19
|
+
tags: flow.tags ?? [],
|
|
20
|
+
testType: flow.testType ?? null,
|
|
21
|
+
severity: flow.severity ?? null,
|
|
22
|
+
version: flow.version ?? null,
|
|
23
|
+
...(flow.reviewStatus ? { reviewStatus: flow.reviewStatus } : {}),
|
|
24
|
+
...(flow.activeVersionNumber ? { activeVersionNumber: flow.activeVersionNumber } : {}),
|
|
25
|
+
...(flow.groupName ? { group: flow.groupName } : {}),
|
|
26
|
+
updatedAt: time(flow.updatedAt),
|
|
27
|
+
});
|
|
28
|
+
export const maskedDatasetKeys = (dataset) => Object.entries(dataset ?? {}).filter(([, value]) => isMasked(value)).map(([key]) => key);
|
|
29
|
+
export const settingsView = (flow) => ({
|
|
30
|
+
...(flow.platform === "web" ? { browserKind: flow.browserKind ?? null, headless: flow.headless ?? null } : { dismissPopups: flow.dismissPopups ?? [] }),
|
|
31
|
+
runSettings: resolveRunSettings(flow.runSettings ?? null),
|
|
32
|
+
});
|
|
33
|
+
const MAX_STEP_ROWS = 300;
|
|
34
|
+
const stepRow = (step, index) => ({
|
|
35
|
+
index: index + 1,
|
|
36
|
+
command: clip(step.command ?? "", 160),
|
|
37
|
+
status: step.status,
|
|
38
|
+
durationMs: step.durationMs ?? null,
|
|
39
|
+
...(step.error ? { error: clip(step.error, 500) } : {}),
|
|
40
|
+
...(step.source ? { source: step.source } : {}),
|
|
41
|
+
...(step.healed ? { healed: clip(step.healed, 200) } : {}),
|
|
42
|
+
...(step.retries ? { retries: step.retries } : {}),
|
|
43
|
+
});
|
|
44
|
+
const failedStepDetail = (step, index) => ({
|
|
45
|
+
index: index + 1,
|
|
46
|
+
command: clip(step.command ?? "", 400),
|
|
47
|
+
status: step.status,
|
|
48
|
+
error: step.error ? clip(step.error, 4000) : null,
|
|
49
|
+
...(step.source ? { source: step.source } : {}),
|
|
50
|
+
...(step.note ? { note: clip(step.note, 500) } : {}),
|
|
51
|
+
...(step.data !== undefined && step.data !== null ? { data: jsonPreview(step.data, 3000) } : {}),
|
|
52
|
+
...(step.extracted ? { extracted: jsonPreview(step.extracted, 1500) } : {}),
|
|
53
|
+
...(step.dataTruncated ? { dataTruncated: true } : {}),
|
|
54
|
+
});
|
|
55
|
+
const isFailed = (status) => status === "failed" || status === "error";
|
|
56
|
+
export const runReportView = (report, options = {}) => {
|
|
57
|
+
const steps = report.steps ?? [];
|
|
58
|
+
const counts = steps.reduce((acc, step) => ((acc[step.status] = (acc[step.status] ?? 0) + 1), acc), {});
|
|
59
|
+
const failed = steps.map((step, index) => ({ step, index })).filter(({ step }) => isFailed(step.status));
|
|
60
|
+
const withData = options.allStepData ? steps.map((step, index) => ({ step, index })).filter(({ step }) => !isFailed(step.status) && (step.data != null || step.extracted)) : [];
|
|
61
|
+
return {
|
|
62
|
+
reportId: report.id,
|
|
63
|
+
flow: { id: report.flowClientId, name: report.flowName },
|
|
64
|
+
status: report.status,
|
|
65
|
+
...(report.executor ? { executor: report.executor } : {}),
|
|
66
|
+
...(report.platform ? { platform: report.platform } : {}),
|
|
67
|
+
...(report.relay?.deviceName || report.relay?.deviceId ? { device: report.relay.deviceName ?? report.relay.deviceId } : {}),
|
|
68
|
+
triggerType: report.triggerType ?? null,
|
|
69
|
+
...(report.scheduleName ? { schedule: report.scheduleName } : {}),
|
|
70
|
+
startedAt: time(report.startedAt),
|
|
71
|
+
finishedAt: time(report.finishedAt),
|
|
72
|
+
durationMs: report.durationMs ?? null,
|
|
73
|
+
...(report.error ? { error: clip(report.error, 4000) } : {}),
|
|
74
|
+
stepCounts: counts,
|
|
75
|
+
steps: steps.slice(0, MAX_STEP_ROWS).map(stepRow),
|
|
76
|
+
...(steps.length > MAX_STEP_ROWS ? { stepsTruncated: steps.length } : {}),
|
|
77
|
+
...(failed.length > 0 ? { failedSteps: failed.slice(0, 10).map(({ step, index }) => failedStepDetail(step, index)) } : {}),
|
|
78
|
+
...(withData.length > 0 ? { stepData: withData.slice(0, 30).map(({ step, index }) => failedStepDetail(step, index)) } : {}),
|
|
79
|
+
...(report.datasetIssues?.length ? { datasetIssues: report.datasetIssues } : {}),
|
|
80
|
+
...(report.warnings?.length ? { warnings: report.warnings } : {}),
|
|
81
|
+
screenshots: {
|
|
82
|
+
failure: Boolean(report.failureScreenshot ?? report.hasFailureScreenshot),
|
|
83
|
+
final: Boolean(report.finalScreenshot ?? report.hasFinalScreenshot),
|
|
84
|
+
},
|
|
85
|
+
...(options.includeNetwork
|
|
86
|
+
? { network: jsonPreview(report.network ?? [], 12_000), ...(report.networkTruncated ? { networkTruncated: true } : {}) }
|
|
87
|
+
: (report.network?.length ?? report.networkCount)
|
|
88
|
+
? { networkEvents: report.network?.length ?? report.networkCount }
|
|
89
|
+
: {}),
|
|
90
|
+
...(report.fromApprovedSnapshot ? { fromApprovedSnapshot: true, flowVersionNumber: report.flowVersionNumber ?? null } : {}),
|
|
91
|
+
};
|
|
92
|
+
};
|
|
93
|
+
export const runListRow = (report) => ({
|
|
94
|
+
reportId: report.id,
|
|
95
|
+
flow: { id: report.flowClientId, name: report.flowName },
|
|
96
|
+
status: report.status,
|
|
97
|
+
...(report.executor ? { executor: report.executor } : {}),
|
|
98
|
+
triggerType: report.triggerType ?? null,
|
|
99
|
+
startedAt: time(report.startedAt),
|
|
100
|
+
durationMs: report.durationMs ?? null,
|
|
101
|
+
...(report.error ? { error: clip(report.error, 300) } : {}),
|
|
102
|
+
...(report.steps ? { failedStep: (() => {
|
|
103
|
+
const index = report.steps.findIndex((step) => isFailed(step.status));
|
|
104
|
+
return index >= 0 ? { index: index + 1, command: clip(report.steps[index].command, 160) } : null;
|
|
105
|
+
})() } : {}),
|
|
106
|
+
});
|
|
107
|
+
export const historyRow = (row) => ({
|
|
108
|
+
flow: { id: row.flowClientId, name: row.flowName },
|
|
109
|
+
status: row.status,
|
|
110
|
+
source: row.triggeredBy === "schedule" ? "schedule" : row.triggeredBy ? row.triggeredBy : "desktop",
|
|
111
|
+
platform: row.platform,
|
|
112
|
+
...(row.deviceId ? { device: row.deviceId } : {}),
|
|
113
|
+
startedAt: time(row.startedAt),
|
|
114
|
+
durationMs: row.durationMs,
|
|
115
|
+
...(row.error ? { error: clip(row.error, 300) } : {}),
|
|
116
|
+
...(row.reportId ? { reportId: row.reportId } : {}),
|
|
117
|
+
});
|
|
118
|
+
export const scheduleView = (schedule) => ({
|
|
119
|
+
id: schedule.id,
|
|
120
|
+
name: schedule.name,
|
|
121
|
+
flow: { id: schedule.flowClientId, name: schedule.flowName },
|
|
122
|
+
enabled: schedule.enabled,
|
|
123
|
+
triggerType: schedule.triggerType,
|
|
124
|
+
timezone: schedule.timezone,
|
|
125
|
+
...(schedule.dailyConfig ? { dailyConfig: schedule.dailyConfig } : {}),
|
|
126
|
+
...(schedule.weeklyConfig ? { weeklyConfig: schedule.weeklyConfig } : {}),
|
|
127
|
+
...(schedule.monthlyConfig ? { monthlyConfig: schedule.monthlyConfig } : {}),
|
|
128
|
+
...(schedule.customCronExpression ? { customCronExpression: schedule.customCronExpression } : {}),
|
|
129
|
+
...(schedule.description ? { description: schedule.description } : {}),
|
|
130
|
+
...(schedule.executionPolicy ? { executionPolicy: schedule.executionPolicy } : {}),
|
|
131
|
+
...(schedule.failurePolicy ? { failurePolicy: schedule.failurePolicy } : {}),
|
|
132
|
+
...(schedule.notificationConfig ? { notificationConfig: schedule.notificationConfig } : {}),
|
|
133
|
+
lastRunAt: time(schedule.lastRunAt),
|
|
134
|
+
lastRunStatus: schedule.lastRunStatus ?? null,
|
|
135
|
+
nextRunAt: time(schedule.nextRunAt),
|
|
136
|
+
...(schedule.isRunning ? { isRunning: true } : {}),
|
|
137
|
+
});
|
|
138
|
+
// `data:image/jpeg;base64,…` → an MCP image block.
|
|
139
|
+
export const imageFromDataUrl = (dataUrl) => {
|
|
140
|
+
if (!dataUrl)
|
|
141
|
+
return null;
|
|
142
|
+
const match = /^data:(image\/[a-z0-9.+-]+);base64,(.+)$/i.exec(dataUrl.trim());
|
|
143
|
+
return match ? { mimeType: match[1].toLowerCase(), data: match[2] } : null;
|
|
144
|
+
};
|
|
145
|
+
//# sourceMappingURL=summarize.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"summarize.js","sourceRoot":"","sources":["../../../src/domain/uiTest/summarize.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAGlD,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAE1D,2EAA2E;AAC3E,yEAAyE;AACzE,yEAAyE;AAEzE,MAAM,IAAI,GAAG,CAAC,KAAc,EAAiB,EAAE;IAC7C,IAAI,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,EAAE;QAAE,OAAO,IAAI,CAAC;IACvE,MAAM,IAAI,GAAG,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;IACnF,OAAO,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC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,CAAC,WAAW,EAAE,EAAE,IAAI,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC;AAC7E,CAAC,CAAC"}
|
package/dist/lib/truncate.d.ts
CHANGED
|
@@ -19,7 +19,7 @@ export interface Clipped {
|
|
|
19
19
|
totalBytes: number;
|
|
20
20
|
}
|
|
21
21
|
export declare const clipBytes: (value: string, maxBytes: number) => Clipped;
|
|
22
|
-
export declare const jsonPreview: (value: unknown, max?:
|
|
22
|
+
export declare const jsonPreview: (value: unknown, max?: number) => string | null;
|
|
23
23
|
export declare const safeStringify: (value: unknown, space?: number) => string;
|
|
24
24
|
export declare const byteLength: (value: unknown) => number;
|
|
25
25
|
//# sourceMappingURL=truncate.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"truncate.d.ts","sourceRoot":"","sources":["../../src/lib/truncate.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,MAAM;;;;;;;;;;;;;EAajB,CAAC;AAEH,eAAO,MAAM,IAAI,GAAI,OAAO,MAAM,EAAE,KAAK,MAAM,KAAG,MACM,CAAC;AAEzD,MAAM,WAAW,OAAO;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,OAAO,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;CACpB;AAGD,eAAO,MAAM,SAAS,GAAI,OAAO,MAAM,EAAE,UAAU,MAAM,KAAG,OAM3D,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,OAAO,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"truncate.d.ts","sourceRoot":"","sources":["../../src/lib/truncate.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,MAAM;;;;;;;;;;;;;EAajB,CAAC;AAEH,eAAO,MAAM,IAAI,GAAI,OAAO,MAAM,EAAE,KAAK,MAAM,KAAG,MACM,CAAC;AAEzD,MAAM,WAAW,OAAO;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAA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AAI,IAAI,KAAK,KAAK,SAAS;QAAE,OAAO,IAAI,CAAC;IACvD,MAAM,IAAI,GAAG,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IACtE,OAAO,IAAI,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC;AACzB,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,KAAc,EAAE,KAAc,EAAU,EAAE;IACtE,IAAI,CAAC;QACH,OAAO,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC;IACtD,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,MAAM,CAAC,KAAK,CAAC,CAAC;IACvB,CAAC;AACH,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,KAAc,EAAU,EAAE,CACnD,MAAM,CAAC,UAAU,CAAC,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,aAAa,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC,CAAC"}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
export declare const DIAGRAM_SCHEMA_DOC = "# Diagrams (create_diagram, update_diagram, patch_diagram)\n\nA diagram is a **DiagramDocument** (schemaVersion 1): typed nodes with positions and sizes,\nedges between nodes, a title. You write the compact form below; the server assigns ids,\nsizes from the component catalog, edge styles from the semantic, and lays the nodes out.\nEvery object is strict: a misspelled or unknown key is an error that names the valid keys,\nnever silently dropped.\n\n## Compact input\n```jsonc\n{\n \"name\": \"Order platform\", // library entry name\n \"title\": \"Order platform \u2014 runtime view\",\n \"nodes\": [\n { \"id\": \"k8s\", \"type\": \"frame\", \"label\": \"Kubernetes\", // a container\n \"style\": { \"stroke\": \"#8B5CF6\", \"fill\": \"rgba(139,92,246,0.07)\", \"textColor\": \"#8B5CF6\", \"strokeWidth\": 2, \"bold\": true } },\n { \"id\": \"gw\", \"type\": \"net.api-gateway\", \"label\": \"API Gateway\" },\n { \"id\": \"orders\",\"type\": \"net.service\", \"label\": \"Orders service\", \"parent\": \"k8s\" },\n { \"id\": \"db\", \"type\": \"db.postgres\", \"label\": \"orders db\" },\n { \"id\": \"bus\", \"type\": \"mq.kafka\", \"label\": \"events\" }\n ],\n \"edges\": [\n { \"source\": \"gw\", \"target\": \"orders\", \"label\": \"REST\", \"semantic\": \"sync\" },\n { \"source\": \"orders\", \"target\": \"db\", \"semantic\": \"sync\", \"color\": \"#10B981\" },\n { \"source\": \"orders\", \"target\": \"bus\", \"label\": \"OrderCreated\" } // \u2192 bus automatically\n ]\n}\n```\n\n## Nodes\n| Field | Type | Notes |\n| --- | --- | --- |\n| `id` | string | Stable id you reference from `parent` and edges; generated (n1, n2\u2026) when omitted |\n| `type` | string | MUST be a catalog type \u2014 `callman://diagram/components` (or one category: `callman://diagram/components/aws`). Unknown types are rejected with suggestions; `strictTypes: false` draws them as rectangles |\n| `label` | string | 1\u20133 words reads best |\n| `parent` | node id | Puts the node inside a container: `frame`, `pool.horizontal` or `pool.vertical` |\n| `position` | {x, y} | Top-left, relative to the parent container. Omit to auto-layout |\n| `size` | {width, height} | Defaults to the catalog size |\n| `style` | object | See **Styling** |\n| `rotation` | number | Degrees, clockwise |\n| `locked` / `hidden` | boolean | Locked nodes cannot be moved in the studio |\n| `data` | object | Free-form metadata kept with the node; not rendered |\n\n`line`, `arrow` and `line.dashed` are connectors in the studio's palette, not nodes \u2014 draw\nconnections as edges.\n\n## Edges\n| Field | Type | Notes |\n| --- | --- | --- |\n| `source`, `target` | node id | A container id is allowed |\n| `label` | string | |\n| `semantic` | sync \u00B7 async \u00B7 fallback \u00B7 bus | `sync` solid (request/response, default), `async` dashed (event, callback), `fallback` dotted (retry / optional path), `bus` heavy (message bus / stream \u2014 automatic when an end is a messaging component) |\n| `color` | CSS color | Line color, independent of the semantic |\n| `routing` | orthogonal \u00B7 straight \u00B7 curved | Default orthogonal (auto-routed right angles) |\n| `markerEnd` / `markerStart` | none \u00B7 classic \u00B7 classicThin \u00B7 open \u00B7 block \u00B7 diamond \u00B7 oval | Default: classicThin at the target, none at the source. Set `markerStart` for a two-way line |\n\nThe semantic owns the line pattern and width; there is no separate dash or width field on edges.\n\n## Styling (node `style`)\n| Key | Type | Notes |\n| --- | --- | --- |\n| `fill` | CSS color | Background. A translucent `rgba(r,g,b,0.07)` tints a container without hiding its children |\n| `stroke` | CSS color | Border |\n| `textColor` | CSS color | Label |\n| `strokeWidth` | number (px) | Border width |\n| `dashed` | boolean | Containers (frame) are dashed by default |\n| `dashPattern` | string | SVG dash array when dashed: `\"6 4\"` dashed, `\"1 3\"` dotted |\n| `radius` | number (px) | Corner radius (`rounded: true` for the default radius) |\n| `fontSize` | number (px) | |\n| `fontFamily` | string | |\n| `bold`, `italic`, `underline` | boolean | |\n| `align` | left \u00B7 center \u00B7 right | |\n| `verticalAlign` | top \u00B7 middle \u00B7 bottom | |\n| `shadow` | boolean | |\n| `opacity` | 0\u2013100 | |\n\nColors are CSS strings \u2014 `\"#3B82F6\"`, `\"rgb(59,130,246)\"`, `\"rgba(59,130,246,0.08)\"`, `\"tomato\"`.\nPick mid-tone colors: the studio has light and dark themes.\n\nColor-coding containers is the quickest way to make zones read at a glance:\n```jsonc\n{ \"op\": \"updateNode\", \"id\": \"k8s\", \"changes\": { \"style\": { \"stroke\": \"#8B5CF6\", \"fill\": \"rgba(139,92,246,0.07)\", \"textColor\": \"#8B5CF6\", \"strokeWidth\": 2, \"bold\": true } } }\n```\n\n## Layout\nPositions are optional; when any node lacks one the whole diagram is laid out\n(`direction`: DOWN, RIGHT, UP, LEFT). Give explicit `position: {x,y}` only when the user\nasks for a specific arrangement. Keep diagrams readable: 8\u201325 nodes, short labels, one edge\nper relationship.\n\n## Editing: patch_diagram ops\nOps describe CHANGES; the rest of the diagram stays exactly as it is. The op list below is the\nsame vocabulary the desktop's AI assistant uses \u2014 one implementation (callman-core) applies both.\n```jsonc\n{ \"op\": \"addNode\", \"node\": { \"type\": \"db.redis\", \"label\": \"cache\", \"parent\": \"k8s\" } }\n{ \"op\": \"updateNode\", \"id\": \"orders\", \"changes\": { \"label\": \"Orders API\", \"style\": { \"fill\": \"#EFF6FF\" } } }\n{ \"op\": \"updateNode\", \"id\": \"orders\", \"changes\": { \"style\": { \"fill\": null } } } // remove one style key\n{ \"op\": \"updateNode\", \"id\": \"orders\", \"changes\": { \"style\": null } } // clear the style\n{ \"op\": \"removeNode\", \"id\": \"bus\" } // its edges are removed, its children move to the top level\n{ \"op\": \"addEdge\", \"edge\": { \"source\": \"orders\", \"target\": \"cache\", \"semantic\": \"async\", \"color\": \"#F59E0B\" } }\n{ \"op\": \"updateEdge\", \"id\": \"e2\", \"changes\": { \"label\": \"gRPC\", \"semantic\": \"fallback\" } } // color is kept\n{ \"op\": \"updateEdge\", \"id\": \"e2\", \"changes\": { \"color\": null } } // back to the default color\n{ \"op\": \"removeEdge\", \"id\": \"e3\" }\n{ \"op\": \"setTitle\", \"title\": \"New title\" }\n{ \"op\": \"moveNode\", \"id\": \"orders\", \"position\": { \"x\": 320, \"y\": 80 } }\n{ \"op\": \"reparent\", \"id\": \"orders\", \"parent\": \"k8s\" } // null = top level\n{ \"op\": \"setEdgeRoute\", \"id\": \"e2\", \"routing\": \"smart\", \"sourceSide\": \"right\", \"targetSide\": \"left\" }\n{ \"op\": \"reorder\", \"id\": \"k8s\", \"index\": \"back\" }\n{ \"op\": \"setCanvas\", \"canvas\": { \"background\": \"grid\", \"defaultRouting\": \"orthogonal\" } }\n{ \"op\": \"group\", \"ids\": [\"orders\", \"db\"], \"label\": \"Order domain\" } // a new frame around them\n{ \"op\": \"ungroup\", \"id\": \"k8s\" } // members stay where they are\n{ \"op\": \"relayout\", \"scope\": \"new\" } // hint: place only the new nodes (or \"all\")\n```\n- updateNode `changes` accepts: type, label, parent (null/\"\" = top level), position, size,\n style, rotation, locked, hidden, collapsed, data. `style` and `data` MERGE into what the\n node has; a key set to null is removed.\n- updateEdge `changes` accepts: source, target, label (\"\" removes it), semantic, color,\n routing, markerEnd, markerStart, sourceSide, targetSide (null = floating).\n- Ids: a node written without an id gets a slug of its label (`orders-service`, `-2` on a\n clash); the result's `idMap` reports any id that had to change.\n- Moving a node (position, size or parent) or re-pointing an edge drops the saved route of\n the edges involved; the studio re-routes them (`reroutedEdges` in the result).\n- `relayout`: `new` (default \u2014 only new nodes get a place), `all` (re-run layout), `none`.\n- `get_diagram` (view `graph`) returns nodes and edges in this same shape \u2014 ids, parents,\n styles, colors, routing, sides \u2014 so read it before a patch.\n- If someone saved the diagram between your read and your patch, the ops are re-applied on\n the newer version automatically (they describe intent, not a whole document).\n\n## Mermaid\n- `get_diagram` view `mermaid` renders any diagram as a Mermaid flowchart (`id@{ shape, label }`\n nodes, `subgraph` containers, `e1@-->` edge ids, `-->`/`-.->`/`==>` for sync/async/bus).\n- `create_diagram` / `update_diagram` accept `source: { format: \"mermaid\", text }` instead of\n nodes: a flowchart/graph becomes nodes and edges (laid out automatically) and the text stays\n attached as the diagram's source \u2014 later ops keep it in sync (the desktop shows both).\n Bracket shapes map to component types (`[( )]` \u2192 database, `{ }` \u2192 decision, `([ ])` \u2192\n terminator \u2026); `click`, `%%` comments and unknown statements are kept untouched.\n- Any other Mermaid type (sequenceDiagram, classDiagram, erDiagram \u2026) is stored as source only:\n `get_diagram` view `source` returns it, the desktop previews it, and structural ops are\n refused with `DIAGRAM_SOURCE_UNSUPPORTED_TYPE`.\n\n## BPMN\n- A BPMN diagram keeps its truth in BPMN 2.0 XML: `create_diagram` with `kind: \"bpmn\"` (or nodes\n typed bpmn.*) writes the XML from your nodes and edges; `source: { format: \"bpmn\", text }` stores a\n file you already have (from Camunda Modeler, for example). The desktop opens it in its BPMN editor.\n- Node `type` is one of the bpmn.* types listed under DIAGRAM OPS above (bpmn.start-event,\n bpmn.user-task, bpmn.service-task, bpmn.exclusive-gateway, bpmn.parallel-gateway, bpmn.subprocess,\n bpmn.pool, bpmn.lane, bpmn.boundary-event \u2026). `data.bpmn` carries the BPMN facts:\n `eventDefinition` (message | timer | error | signal | \u2026), `attachedTo` (boundary events),\n `cancelActivity`, `isExpanded`. Edges are sequence flows; `data.bpmn` may set\n `flow: \"message\"` (between pools), `conditionExpression` and `isDefault`.\n- Pools and lanes are containers (`parent`); a boundary event's parent is its host's parent.\n New nodes need no position: they are placed after their predecessor.\n- `patch_diagram` works as on any diagram: every op lands on the XML as a minimal edit \u2014 extension\n elements, annotations and the modeler's formatting stay untouched. `get_diagram` view `source`\n returns the XML; view `graph` shows the derived nodes/edges with their `bpmn` facts.\n\n## Database diagrams (ERD)\n- A database diagram keeps its truth in a JSON database model (`source.format: \"database\"`):\n tables (`entities`) with columns, keys, indexes and comments, and relationships between them;\n the nodes on the canvas hold only positions and visibility. The desktop opens it on an ERD\n canvas; `get_diagram` view `schema` shows tables with their columns and the relationships as\n `table.column` pairs \u2014 read it before editing.\n- Create one with `create_diagram`: `tables` + `relationships` (`{ name, schema?, columns:\n [{ name, dataType, primaryKey?, nullable?, unique?, defaultValue?, comment? }] }` and\n `{ source: \"orders.user_id\", target: \"users.id\", cardinality: \"N:1\" }` \u2014 source is the child /\n foreign-key side), or nodes typed db.table / db.view / db.collection with the columns in\n `data.db.columns`, or `fromConnection` to read a real database through one of the\n workspace's connections (`introspect_database` reads the same schema without drawing it).\n- Edit with the schema ops of `patch_diagram`:\n```jsonc\n{ \"op\": \"addTable\", \"table\": { \"name\": \"payments\", \"columns\": [{ \"name\": \"id\", \"dataType\": \"uuid\", \"primaryKey\": true }, { \"name\": \"order_id\", \"dataType\": \"bigint\" }, { \"name\": \"amount\", \"dataType\": \"numeric(12,2)\" }] } }\n{ \"op\": \"addColumn\", \"table\": \"users\", \"column\": { \"name\": \"profile_id\", \"dataType\": \"uuid\", \"nullable\": true }, \"after\": \"id\" }\n{ \"op\": \"alterColumn\", \"table\": \"users\", \"column\": \"email\", \"changes\": { \"unique\": true, \"nullable\": false } }\n{ \"op\": \"removeColumn\", \"table\": \"users\", \"column\": \"nickname\" }\n{ \"op\": \"setPrimaryKey\", \"table\": \"order_items\", \"columns\": [\"order_id\", \"line\"] }\n{ \"op\": \"renameTable\", \"table\": \"users\", \"name\": \"accounts\", \"schema\": \"auth\" }\n{ \"op\": \"setTableComment\", \"table\": \"users\", \"comment\": \"People who can sign in\" }\n{ \"op\": \"addRelationship\", \"source\": \"payments.order_id\", \"target\": \"orders.id\", \"cardinality\": \"N:1\" }\n{ \"op\": \"updateRelationship\", \"relationship\": \"fk-payments-orders\", \"changes\": { \"cardinality\": \"1:1\", \"label\": \"settles\" } }\n{ \"op\": \"removeRelationship\", \"relationship\": \"fk-payments-orders\" }\n{ \"op\": \"removeTable\", \"table\": \"audit_log\" } // its relationships go with it\n{ \"op\": \"hideTable\", \"table\": \"migrations\" } // canvas only; showTable brings it back\n```\n Tables are named (`users`, `public.users`), columns as `table.column`; ids stay stable\n across renames. New tables are placed to the right of the existing ones (or laid out with\n `relayout: \"all\"`). moveNode, hideTable/showTable and setCanvas change the canvas only;\n group / ungroup / reparent do not apply.\n\n## Stored document (get_diagram view: \"full\")\n```ts\ninterface DiagramDocument {\n schemaVersion: 1; id: string;\n meta: { title: string; createdAt: string; updatedAt: string; revision?: number };\n canvas?: { background?: \"grid\" | \"dots\" | \"blank\"; gridSize?: number;\n defaultRouting?: \"orthogonal\" | \"straight\" | \"curved\" | \"smart\";\n layout?: { algorithm; direction }; viewport?: { x; y; zoom } };\n nodes: { id; type; position: {x,y}; size: {width,height}; label?; parentId?; rotation?;\n locked?; hidden?; collapsed?; collapsedSize?; style?: DiagramStyle; data? }[];\n edges: { id; source?; target?; label?; labelPosition?; routing?; sourceHandle?; targetHandle?;\n style?: DiagramStyle; markerStart?; markerEnd?; waypoints? }[];\n source?: { format: \"mermaid\" | \"bpmn\" | \"database\"; text; diagramType; grammar?; valid? };\n}\n// Stored colors are { raw: \"#3B82F6\" } (or a theme { token }); bold/italic/underline are\n// the bitmask fontStyle (1 | 2 | 4). The tools convert both ways \u2014 write plain colors.\n```\nEdge meaning is derived from `style` (dashed + dashPattern + strokeWidth) \u2014 set it with\n`semantic`, never directly.\n";
|
|
1
|
+
export declare const DIAGRAM_SCHEMA_DOC = "# Diagrams (create_diagram, update_diagram, patch_diagram)\n\nThe desktop has four kinds of diagram, and every tool here works on all of them:\n| Kind | Create with | Node types | Section |\n|---|---|---|---|\n| System design (canvas) | `nodes` + `edges` (default) | callman://diagram/components | Compact input |\n| BPMN process | `kind: \"bpmn\"`, bpmn.* nodes, or `source: { format: \"bpmn\" }` | bpmn.* (end of this doc) | BPMN |\n| Mermaid | `source: { format: \"mermaid\", text }` | \u2014 (a flowchart becomes nodes) | Mermaid |\n| Database / ERD | `kind: \"database\"` + `tables` / `relationships`, or `fromConnection` | db.table / db.view / db.collection | Database diagrams |\n\nA diagram is a **DiagramDocument** (schemaVersion 1): typed nodes with positions and sizes,\nedges between nodes, a title. You write the compact form below; the server assigns ids,\nsizes from the component catalog, edge styles from the semantic, and lays the nodes out.\nEvery object is strict: a misspelled or unknown key is an error that names the valid keys,\nnever silently dropped.\n\n## Compact input\n```jsonc\n{\n \"name\": \"Order platform\", // library entry name\n \"title\": \"Order platform \u2014 runtime view\",\n \"nodes\": [\n { \"id\": \"k8s\", \"type\": \"frame\", \"label\": \"Kubernetes\", // a container\n \"style\": { \"stroke\": \"#8B5CF6\", \"fill\": \"rgba(139,92,246,0.07)\", \"textColor\": \"#8B5CF6\", \"strokeWidth\": 2, \"bold\": true } },\n { \"id\": \"gw\", \"type\": \"net.api-gateway\", \"label\": \"API Gateway\" },\n { \"id\": \"orders\",\"type\": \"net.service\", \"label\": \"Orders service\", \"parent\": \"k8s\" },\n { \"id\": \"db\", \"type\": \"db.postgres\", \"label\": \"orders db\" },\n { \"id\": \"bus\", \"type\": \"mq.kafka\", \"label\": \"events\" }\n ],\n \"edges\": [\n { \"source\": \"gw\", \"target\": \"orders\", \"label\": \"REST\", \"semantic\": \"sync\" },\n { \"source\": \"orders\", \"target\": \"db\", \"semantic\": \"sync\", \"color\": \"#10B981\" },\n { \"source\": \"orders\", \"target\": \"bus\", \"label\": \"OrderCreated\" } // \u2192 bus automatically\n ]\n}\n```\n\n## Nodes\n| Field | Type | Notes |\n| --- | --- | --- |\n| `id` | string | Stable id you reference from `parent` and edges; generated (n1, n2\u2026) when omitted |\n| `type` | string | MUST be a catalog type \u2014 `callman://diagram/components` (or one category: `callman://diagram/components/aws`). Unknown types are rejected with suggestions; `strictTypes: false` draws them as rectangles |\n| `label` | string | 1\u20133 words reads best |\n| `parent` | node id | Puts the node inside a container: `frame`, `pool.horizontal` or `pool.vertical` |\n| `position` | {x, y} | Top-left, relative to the parent container. Omit to auto-layout |\n| `size` | {width, height} | Defaults to the catalog size |\n| `style` | object | See **Styling** |\n| `rotation` | number | Degrees, clockwise |\n| `locked` / `hidden` | boolean | Locked nodes cannot be moved in the studio |\n| `data` | object | Free-form metadata kept with the node; not rendered |\n\n`line`, `arrow` and `line.dashed` are connectors in the studio's palette, not nodes \u2014 draw\nconnections as edges.\n\n## Edges\n| Field | Type | Notes |\n| --- | --- | --- |\n| `source`, `target` | node id | A container id is allowed |\n| `label` | string | |\n| `semantic` | sync \u00B7 async \u00B7 fallback \u00B7 bus | `sync` solid (request/response, default), `async` dashed (event, callback), `fallback` dotted (retry / optional path), `bus` heavy (message bus / stream \u2014 automatic when an end is a messaging component) |\n| `color` | CSS color | Line color, independent of the semantic |\n| `routing` | orthogonal \u00B7 straight \u00B7 curved | Default orthogonal (auto-routed right angles) |\n| `markerEnd` / `markerStart` | none \u00B7 classic \u00B7 classicThin \u00B7 open \u00B7 block \u00B7 diamond \u00B7 oval | Default: classicThin at the target, none at the source. Set `markerStart` for a two-way line |\n\nThe semantic owns the line pattern and width; there is no separate dash or width field on edges.\n\n## Styling (node `style`)\n| Key | Type | Notes |\n| --- | --- | --- |\n| `fill` | CSS color | Background. A translucent `rgba(r,g,b,0.07)` tints a container without hiding its children |\n| `stroke` | CSS color | Border |\n| `textColor` | CSS color | Label |\n| `strokeWidth` | number (px) | Border width |\n| `dashed` | boolean | Containers (frame) are dashed by default |\n| `dashPattern` | string | SVG dash array when dashed: `\"6 4\"` dashed, `\"1 3\"` dotted |\n| `radius` | number (px) | Corner radius (`rounded: true` for the default radius) |\n| `fontSize` | number (px) | |\n| `fontFamily` | string | |\n| `bold`, `italic`, `underline` | boolean | |\n| `align` | left \u00B7 center \u00B7 right | |\n| `verticalAlign` | top \u00B7 middle \u00B7 bottom | |\n| `shadow` | boolean | |\n| `opacity` | 0\u2013100 | |\n\nColors are CSS strings \u2014 `\"#3B82F6\"`, `\"rgb(59,130,246)\"`, `\"rgba(59,130,246,0.08)\"`, `\"tomato\"`.\nPick mid-tone colors: the studio has light and dark themes.\n\nColor-coding containers is the quickest way to make zones read at a glance:\n```jsonc\n{ \"op\": \"updateNode\", \"id\": \"k8s\", \"changes\": { \"style\": { \"stroke\": \"#8B5CF6\", \"fill\": \"rgba(139,92,246,0.07)\", \"textColor\": \"#8B5CF6\", \"strokeWidth\": 2, \"bold\": true } } }\n```\n\n## Layout\nPositions are optional; when any node lacks one the whole diagram is laid out\n(`direction`: DOWN, RIGHT, UP, LEFT). Give explicit `position: {x,y}` only when the user\nasks for a specific arrangement. Keep diagrams readable: 8\u201325 nodes, short labels, one edge\nper relationship.\n\n## Editing: patch_diagram ops\nOps describe CHANGES; the rest of the diagram stays exactly as it is. The op list below is the\nsame vocabulary the desktop's AI assistant uses \u2014 one implementation (callman-core) applies both.\n```jsonc\n{ \"op\": \"addNode\", \"node\": { \"type\": \"db.redis\", \"label\": \"cache\", \"parent\": \"k8s\" } }\n{ \"op\": \"updateNode\", \"id\": \"orders\", \"changes\": { \"label\": \"Orders API\", \"style\": { \"fill\": \"#EFF6FF\" } } }\n{ \"op\": \"updateNode\", \"id\": \"orders\", \"changes\": { \"style\": { \"fill\": null } } } // remove one style key\n{ \"op\": \"updateNode\", \"id\": \"orders\", \"changes\": { \"style\": null } } // clear the style\n{ \"op\": \"removeNode\", \"id\": \"bus\" } // its edges are removed, its children move to the top level\n{ \"op\": \"addEdge\", \"edge\": { \"source\": \"orders\", \"target\": \"cache\", \"semantic\": \"async\", \"color\": \"#F59E0B\" } }\n{ \"op\": \"updateEdge\", \"id\": \"e2\", \"changes\": { \"label\": \"gRPC\", \"semantic\": \"fallback\" } } // color is kept\n{ \"op\": \"updateEdge\", \"id\": \"e2\", \"changes\": { \"color\": null } } // back to the default color\n{ \"op\": \"removeEdge\", \"id\": \"e3\" }\n{ \"op\": \"setTitle\", \"title\": \"New title\" }\n{ \"op\": \"moveNode\", \"id\": \"orders\", \"position\": { \"x\": 320, \"y\": 80 } }\n{ \"op\": \"reparent\", \"id\": \"orders\", \"parent\": \"k8s\" } // null = top level\n{ \"op\": \"setEdgeRoute\", \"id\": \"e2\", \"routing\": \"smart\", \"sourceSide\": \"right\", \"targetSide\": \"left\" }\n{ \"op\": \"reorder\", \"id\": \"k8s\", \"index\": \"back\" }\n{ \"op\": \"setCanvas\", \"canvas\": { \"background\": \"grid\", \"defaultRouting\": \"orthogonal\" } }\n{ \"op\": \"group\", \"ids\": [\"orders\", \"db\"], \"label\": \"Order domain\" } // a new frame around them\n{ \"op\": \"ungroup\", \"id\": \"k8s\" } // members stay where they are\n{ \"op\": \"relayout\", \"scope\": \"new\" } // hint: place only the new nodes (or \"all\")\n```\n- updateNode `changes` accepts: type, label, parent (null/\"\" = top level), position, size,\n style, rotation, locked, hidden, collapsed, data. `style` and `data` MERGE into what the\n node has; a key set to null is removed.\n- updateEdge `changes` accepts: source, target, label (\"\" removes it), semantic, color,\n routing, markerEnd, markerStart, sourceSide, targetSide (null = floating).\n- Ids: a node written without an id gets a slug of its label (`orders-service`, `-2` on a\n clash); the result's `idMap` reports any id that had to change.\n- Moving a node (position, size or parent) or re-pointing an edge drops the saved route of\n the edges involved; the studio re-routes them (`reroutedEdges` in the result).\n- `relayout`: `new` (default \u2014 only new nodes get a place), `all` (re-run layout), `none`.\n- `get_diagram` (view `graph`) returns nodes and edges in this same shape \u2014 ids, parents,\n styles, colors, routing, sides \u2014 so read it before a patch.\n- If someone saved the diagram between your read and your patch, the ops are re-applied on\n the newer version automatically (they describe intent, not a whole document).\n\n## Mermaid\n- `get_diagram` view `mermaid` renders any diagram as a Mermaid flowchart (`id@{ shape, label }`\n nodes, `subgraph` containers, `e1@-->` edge ids, `-->`/`-.->`/`==>` for sync/async/bus).\n- `create_diagram` / `update_diagram` accept `source: { format: \"mermaid\", text }` instead of\n nodes: a flowchart/graph becomes nodes and edges (laid out automatically) and the text stays\n attached as the diagram's source \u2014 later ops keep it in sync (the desktop shows both).\n Bracket shapes map to component types (`[( )]` \u2192 database, `{ }` \u2192 decision, `([ ])` \u2192\n terminator \u2026); `click`, `%%` comments and unknown statements are kept untouched.\n- Any other Mermaid type (sequenceDiagram, classDiagram, erDiagram \u2026) is stored as source only:\n `get_diagram` view `source` returns it, the desktop previews it, and structural ops are\n refused with `DIAGRAM_SOURCE_UNSUPPORTED_TYPE`.\n\n## BPMN\n- A BPMN diagram keeps its truth in BPMN 2.0 XML: `create_diagram` with `kind: \"bpmn\"` (or nodes\n typed bpmn.*) writes the XML from your nodes and edges; `source: { format: \"bpmn\", text }` stores a\n file you already have (from Camunda Modeler, for example). The desktop opens it in its BPMN editor.\n- Node `type` is one of the bpmn.* types \u2014 the full list is under \"Reference: BPMN vocabulary\" at\n the end of this document (bpmn.start-event, bpmn.user-task, bpmn.service-task,\n bpmn.exclusive-gateway, bpmn.parallel-gateway, bpmn.subprocess, bpmn.pool, bpmn.lane,\n bpmn.boundary-event \u2026). They are not in callman://diagram/components. `data.bpmn` carries the BPMN facts:\n `eventDefinition` (message | timer | error | signal | \u2026), `attachedTo` (boundary events),\n `cancelActivity`, `isExpanded`. Edges are sequence flows; `data.bpmn` may set\n `flow: \"message\"` (between pools), `conditionExpression` and `isDefault`.\n- Pools and lanes are containers (`parent`); a boundary event's parent is its host's parent.\n New nodes need no position: they are placed after their predecessor.\n- `patch_diagram` works as on any diagram: every op lands on the XML as a minimal edit \u2014 extension\n elements, annotations and the modeler's formatting stay untouched. `get_diagram` view `source`\n returns the XML; view `graph` shows the derived nodes/edges with their `bpmn` facts.\n\n## Database diagrams (ERD)\n- A database diagram keeps its truth in a JSON database model (`source.format: \"database\"`):\n tables (`entities`) with columns, keys, indexes and comments, and relationships between them;\n the nodes on the canvas hold only positions and visibility. The desktop opens it on an ERD\n canvas; `get_diagram` view `schema` shows tables with their columns and the relationships as\n `table.column` pairs \u2014 read it before editing.\n- Create one with `create_diagram`: `tables` + `relationships` (`{ name, schema?, columns:\n [{ name, dataType, primaryKey?, nullable?, unique?, defaultValue?, comment? }] }` and\n `{ source: \"orders.user_id\", target: \"users.id\", cardinality: \"N:1\" }` \u2014 source is the child /\n foreign-key side), or nodes typed db.table / db.view / db.collection with the columns in\n `data.db.columns`, or `fromConnection` to read a real database through one of the\n workspace's connections (`introspect_database` reads the same schema without drawing it).\n- Edit with the schema ops of `patch_diagram`:\n```jsonc\n{ \"op\": \"addTable\", \"table\": { \"name\": \"payments\", \"columns\": [{ \"name\": \"id\", \"dataType\": \"uuid\", \"primaryKey\": true }, { \"name\": \"order_id\", \"dataType\": \"bigint\" }, { \"name\": \"amount\", \"dataType\": \"numeric(12,2)\" }] } }\n{ \"op\": \"addColumn\", \"table\": \"users\", \"column\": { \"name\": \"profile_id\", \"dataType\": \"uuid\", \"nullable\": true }, \"after\": \"id\" }\n{ \"op\": \"alterColumn\", \"table\": \"users\", \"column\": \"email\", \"changes\": { \"unique\": true, \"nullable\": false } }\n{ \"op\": \"removeColumn\", \"table\": \"users\", \"column\": \"nickname\" }\n{ \"op\": \"setPrimaryKey\", \"table\": \"order_items\", \"columns\": [\"order_id\", \"line\"] }\n{ \"op\": \"renameTable\", \"table\": \"users\", \"name\": \"accounts\", \"schema\": \"auth\" }\n{ \"op\": \"setTableComment\", \"table\": \"users\", \"comment\": \"People who can sign in\" }\n{ \"op\": \"addRelationship\", \"source\": \"payments.order_id\", \"target\": \"orders.id\", \"cardinality\": \"N:1\" }\n{ \"op\": \"updateRelationship\", \"relationship\": \"fk-payments-orders\", \"changes\": { \"cardinality\": \"1:1\", \"label\": \"settles\" } }\n{ \"op\": \"removeRelationship\", \"relationship\": \"fk-payments-orders\" }\n{ \"op\": \"removeTable\", \"table\": \"audit_log\" } // its relationships go with it\n{ \"op\": \"hideTable\", \"table\": \"migrations\" } // canvas only; showTable brings it back\n```\n Tables are named (`users`, `public.users`), columns as `table.column`; ids stay stable\n across renames. New tables are placed to the right of the existing ones (or laid out with\n `relayout: \"all\"`). moveNode, hideTable/showTable and setCanvas change the canvas only;\n group / ungroup / reparent do not apply.\n\n## Stored document (get_diagram view: \"full\")\n```ts\ninterface DiagramDocument {\n schemaVersion: 1; id: string;\n meta: { title: string; createdAt: string; updatedAt: string; revision?: number };\n canvas?: { background?: \"grid\" | \"dots\" | \"blank\"; gridSize?: number;\n defaultRouting?: \"orthogonal\" | \"straight\" | \"curved\" | \"smart\";\n layout?: { algorithm; direction }; viewport?: { x; y; zoom } };\n nodes: { id; type; position: {x,y}; size: {width,height}; label?; parentId?; rotation?;\n locked?; hidden?; collapsed?; collapsedSize?; style?: DiagramStyle; data? }[];\n edges: { id; source?; target?; label?; labelPosition?; routing?; sourceHandle?; targetHandle?;\n style?: DiagramStyle; markerStart?; markerEnd?; waypoints? }[];\n source?: { format: \"mermaid\" | \"bpmn\" | \"database\"; text; diagramType; grammar?; valid? };\n}\n// Stored colors are { raw: \"#3B82F6\" } (or a theme { token }); bold/italic/underline are\n// the bitmask fontStyle (1 | 2 | 4). The tools convert both ways \u2014 write plain colors.\n```\nEdge meaning is derived from `style` (dashed + dashPattern + strokeWidth) \u2014 set it with\n`semantic`, never directly.\n";
|
|
2
|
+
export declare const diagramSchemaDoc: () => string;
|
|
2
3
|
//# sourceMappingURL=diagramSchema.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"diagramSchema.d.ts","sourceRoot":"","sources":["../../../src/resources/docs/diagramSchema.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"diagramSchema.d.ts","sourceRoot":"","sources":["../../../src/resources/docs/diagramSchema.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,kBAAkB,i0eAwN9B,CAAC;AAIF,eAAO,MAAM,gBAAgB,QAAO,MAetB,CAAC"}
|
|
@@ -1,5 +1,14 @@
|
|
|
1
|
+
import { renderBpmnVocabulary, renderDatabaseOps, renderDatabaseVocabulary } from "callman-core";
|
|
1
2
|
export const DIAGRAM_SCHEMA_DOC = `# Diagrams (create_diagram, update_diagram, patch_diagram)
|
|
2
3
|
|
|
4
|
+
The desktop has four kinds of diagram, and every tool here works on all of them:
|
|
5
|
+
| Kind | Create with | Node types | Section |
|
|
6
|
+
|---|---|---|---|
|
|
7
|
+
| System design (canvas) | \`nodes\` + \`edges\` (default) | callman://diagram/components | Compact input |
|
|
8
|
+
| BPMN process | \`kind: "bpmn"\`, bpmn.* nodes, or \`source: { format: "bpmn" }\` | bpmn.* (end of this doc) | BPMN |
|
|
9
|
+
| Mermaid | \`source: { format: "mermaid", text }\` | — (a flowchart becomes nodes) | Mermaid |
|
|
10
|
+
| Database / ERD | \`kind: "database"\` + \`tables\` / \`relationships\`, or \`fromConnection\` | db.table / db.view / db.collection | Database diagrams |
|
|
11
|
+
|
|
3
12
|
A diagram is a **DiagramDocument** (schemaVersion 1): typed nodes with positions and sizes,
|
|
4
13
|
edges between nodes, a title. You write the compact form below; the server assigns ids,
|
|
5
14
|
sizes from the component catalog, edge styles from the semantic, and lays the nodes out.
|
|
@@ -142,9 +151,10 @@ same vocabulary the desktop's AI assistant uses — one implementation (callman-
|
|
|
142
151
|
- A BPMN diagram keeps its truth in BPMN 2.0 XML: \`create_diagram\` with \`kind: "bpmn"\` (or nodes
|
|
143
152
|
typed bpmn.*) writes the XML from your nodes and edges; \`source: { format: "bpmn", text }\` stores a
|
|
144
153
|
file you already have (from Camunda Modeler, for example). The desktop opens it in its BPMN editor.
|
|
145
|
-
- Node \`type\` is one of the bpmn.* types
|
|
146
|
-
bpmn.
|
|
147
|
-
bpmn.
|
|
154
|
+
- Node \`type\` is one of the bpmn.* types — the full list is under "Reference: BPMN vocabulary" at
|
|
155
|
+
the end of this document (bpmn.start-event, bpmn.user-task, bpmn.service-task,
|
|
156
|
+
bpmn.exclusive-gateway, bpmn.parallel-gateway, bpmn.subprocess, bpmn.pool, bpmn.lane,
|
|
157
|
+
bpmn.boundary-event …). They are not in callman://diagram/components. \`data.bpmn\` carries the BPMN facts:
|
|
148
158
|
\`eventDefinition\` (message | timer | error | signal | …), \`attachedTo\` (boundary events),
|
|
149
159
|
\`cancelActivity\`, \`isExpanded\`. Edges are sequence flows; \`data.bpmn\` may set
|
|
150
160
|
\`flow: "message"\` (between pools), \`conditionExpression\` and \`isDefault\`.
|
|
@@ -206,4 +216,21 @@ interface DiagramDocument {
|
|
|
206
216
|
Edge meaning is derived from \`style\` (dashed + dashPattern + strokeWidth) — set it with
|
|
207
217
|
\`semantic\`, never directly.
|
|
208
218
|
`;
|
|
219
|
+
// The BPMN and database vocabularies come from callman-core — the same text the
|
|
220
|
+
// desktop's AI reads — so the type lists and op shapes can never drift.
|
|
221
|
+
export const diagramSchemaDoc = () => [
|
|
222
|
+
DIAGRAM_SCHEMA_DOC,
|
|
223
|
+
"## Reference: BPMN vocabulary",
|
|
224
|
+
"```text",
|
|
225
|
+
renderBpmnVocabulary(),
|
|
226
|
+
"```",
|
|
227
|
+
"",
|
|
228
|
+
"## Reference: database model and schema ops",
|
|
229
|
+
"```text",
|
|
230
|
+
renderDatabaseVocabulary(),
|
|
231
|
+
"",
|
|
232
|
+
renderDatabaseOps(),
|
|
233
|
+
"```",
|
|
234
|
+
"",
|
|
235
|
+
].join("\n");
|
|
209
236
|
//# sourceMappingURL=diagramSchema.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"diagramSchema.js","sourceRoot":"","sources":["../../../src/resources/docs/diagramSchema.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,kBAAkB,GAAG
|
|
1
|
+
{"version":3,"file":"diagramSchema.js","sourceRoot":"","sources":["../../../src/resources/docs/diagramSchema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,wBAAwB,EAAE,MAAM,cAAc,CAAC;AAEjG,MAAM,CAAC,MAAM,kBAAkB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAwNjC,CAAC;AAEF,gFAAgF;AAChF,wEAAwE;AACxE,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAW,EAAE,CAC3C;IACE,kBAAkB;IAClB,+BAA+B;IAC/B,SAAS;IACT,oBAAoB,EAAE;IACtB,KAAK;IACL,EAAE;IACF,6CAA6C;IAC7C,SAAS;IACT,wBAAwB,EAAE;IAC1B,EAAE;IACF,iBAAiB,EAAE;IACnB,KAAK;IACL,EAAE;CACH,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const OVERVIEW_DOC = "# Working with Callman through MCP\n\nCallman is an API client and test platform (collections of HTTP requests, environments,\nmulti-step test scenarios,
|
|
1
|
+
export declare const OVERVIEW_DOC = "# Working with Callman through MCP\n\nCallman is an API client and test platform (collections of HTTP requests, environments,\nmulti-step API test scenarios, UI tests for web / Android / iOS, and diagrams). This\nserver exposes it to you through tools; everything you do goes to the same server the Callman desktop app uses, as the user\nwhose token is configured, limited to that token's permissions and the user's workspace role.\n\n## Start here\n1. `whoami` \u2014 proves the connection and tells you the workspaces, features and which tools\n this token can use.\n2. Look before you create: `list_collections` / `get_collection_tree` / `search_requests`.\n Creating a collection whose name exists is refused on purpose.\n3. Arguments are strict: a misspelled or unknown argument is an error that lists the valid\n ones \u2014 read it and retry; nothing is silently ignored.\n4. Names work as references everywhere an id does (collection, folder, request, environment,\n scenario, UI test, diagram, workspace). Ambiguous names come back as a candidate list \u2014 pick one.\n5. Preview big writes with `dryRun: true` (bulk create, imports, scenarios, diagrams).\n6. Deletions need `confirm: true` and an exact name or id. Ask the user unless they explicitly\n requested the deletion.\n\n## Workspaces\nThe token works in EVERY workspace the user belongs to (with their role in each):\n- Lists and searches (`list_collections`, `search_requests`, `list_environments`,\n `list_connections`, `list_scenarios`) cover all workspaces unless you pass `workspace`;\n every row says which workspace it is in.\n- A name (collection, request, environment) is looked up in the default workspace first, then\n in all others; a unique match anywhere is used and the result says where it was found. The\n same name in several workspaces comes back as candidates tagged with their workspace \u2014 pass\n `workspace` or the id.\n- Creating needs one target: `workspace`, or the collection it goes into, or the session\n default. `use_workspace` changes the default for the session (it never hides the others).\n- Environments, connections and global variables belong to one workspace: a request uses the\n ones of its own workspace.\n\n## Requests\n- Use `{{variable}}` for hosts and secrets (`{{baseUrl}}/users`) and put the values in an\n environment (`create_environment` / `set_environment_variables`). Use `:id` for path\n variables. See `callman://docs/request-schema`.\n- get_request returns a request in the same shape create/update take \u2014 read, change, send back.\n- Bodies: a JSON value, a raw string, or `{ mode: raw|formdata|urlencoded|json }`.\n- Database / Kafka / Redis steps and DB assertions are request fields; connections are\n referenced by id or name (`list_connections`).\n- Contract checks (field rules, data-driven rows) \u2014 `callman://docs/contracts`.\n- Scripts run in a sandbox with the `pm.*` API \u2014 `callman://docs/scripting/pm-api`.\n- `run_request` / `run_collection` execute on the user's machine with real variable values;\n you only get results and the names of variables scripts changed.\n\n## Secrets\nEnvironment values come back masked (`\u2022\u2022\u2022\u2022ab`) unless the token holds `environments:reveal`\nand you ask for `reveal: true`. Never write a masked environment value back \u2014 it is refused.\nRequest auth secrets and sensitive headers are masked the same way; sending a masked request\nsecret back UNCHANGED keeps the stored one, anything else masked is refused.\n\n## Scenarios\nMulti-step flows as a graph of typed nodes (request, condition, assertion, set-vars, poll,\ndb, kafka, script, wait, end \u2026). Read `callman://docs/scenario-nodes` before building one;\npartial node configs are merged over defaults. Link a shared setup / teardown with a\nscenario-ref node: `config: { scenario: \"<name or id>\" }` \u2014 the server copies it in. Nodes\nwithout a position are placed next to the node they follow, clear of the others.\n- **Where runs happen.** `run_scenario` runs on the Callman server by default, which only\n reaches what the server's network reaches. For the user's localhost, port-forwards, VPN-only\n hosts or internal databases use `target: \"desktop\"`: the user's own Callman desktop app runs\n it (open, signed in, Settings \u2192 AI tools \u2192 \"Let AI tools run scenarios on this computer\").\n- **Reports.** `get_scenario_report` shows server, scheduled, CLI and desktop runs\n (`triggerType` / `executor`).\n- **Negative checks** (\"this event must NOT be published\", \"this call must be refused\"): give the\n node `executionPolicy.expectFailure` \u2014 an error edge always ends the run\n completed_with_failures.\n- **Editing.** `update_scenario` (whole graph) is checked against the version you last read; if\n the user saved in the desktop meanwhile you get a conflict \u2014 re-read, then retry. Folders:\n `create_scenario_folder` / `update_scenario_folder` / `delete_scenario_folder`. On-prem\n review: `submit_scenario`, `review_scenario`, `list_scenario_versions`,\n `restore_scenario_version`.\n\n## UI tests\nBrowser and mobile-app flows (YAML: header, `---`, steps) \u2014 the desktop app's UI Testing area.\nRead `callman://docs/ui-tests` first and `callman://docs/ui-test-steps` for every step. Flows are\nlinted before they are saved (`validate_ui_test`); edit steps by number with\n`patch_ui_test_steps`. Web flows run on the server runner when there is one; Android, iOS (and\nweb without a runner) run on the user's own Callman desktop app, which must be open with\n\"Let AI tools run UI tests on this computer\" on \u2014 `list_ui_test_devices` shows what is\navailable. Runs return per-step results; screenshots come back as images on request.\n\n## Diagrams\nFour kinds, all built with `create_diagram` (auto layout), edited with `patch_diagram` and\nshared with `share_diagram` \u2014 read `callman://docs/diagram-schema` first:\n- **System design**: nodes from the fixed component catalog `callman://diagram/components`.\n- **BPMN process**: `kind: \"bpmn\"` with bpmn.* nodes, stored as BPMN 2.0 XML.\n- **Mermaid**: `source: { format: \"mermaid\", text }` \u2014 a flowchart becomes nodes, other\n Mermaid types are kept as source.\n- **Database / ERD**: `kind: \"database\"` with `tables` + `relationships`, or `fromConnection`\n to read a real database's schema (`introspect_database` reads it without drawing). Edit it\n with the schema ops (addTable, addColumn, addRelationship \u2026) and read it with view `schema`.\n\nThe user's library has private\nfolders: `list_diagrams` shows the tree as paths (\"Architecture/Payments\"); file a\ndiagram with `folder` on `create_diagram` / `update_diagram`; manage folders with\n`create_diagram_folder`, `update_diagram_folder`, `delete_diagram_folder`.\n\n## After writing\nThe desktop app refreshes when the user switches back to it. Tell the user what you created\nand where (collection / folder names).\n";
|
|
2
2
|
//# sourceMappingURL=overview.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"overview.d.ts","sourceRoot":"","sources":["../../../src/resources/docs/overview.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,YAAY,
|
|
1
|
+
{"version":3,"file":"overview.d.ts","sourceRoot":"","sources":["../../../src/resources/docs/overview.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,YAAY,m2NAsGxB,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
export const OVERVIEW_DOC = `# Working with Callman through MCP
|
|
2
2
|
|
|
3
3
|
Callman is an API client and test platform (collections of HTTP requests, environments,
|
|
4
|
-
multi-step test scenarios,
|
|
5
|
-
tools; everything you do goes to the same server the Callman desktop app uses, as the user
|
|
4
|
+
multi-step API test scenarios, UI tests for web / Android / iOS, and diagrams). This
|
|
5
|
+
server exposes it to you through tools; everything you do goes to the same server the Callman desktop app uses, as the user
|
|
6
6
|
whose token is configured, limited to that token's permissions and the user's workspace role.
|
|
7
7
|
|
|
8
8
|
## Start here
|
|
@@ -13,7 +13,7 @@ whose token is configured, limited to that token's permissions and the user's wo
|
|
|
13
13
|
3. Arguments are strict: a misspelled or unknown argument is an error that lists the valid
|
|
14
14
|
ones — read it and retry; nothing is silently ignored.
|
|
15
15
|
4. Names work as references everywhere an id does (collection, folder, request, environment,
|
|
16
|
-
scenario, diagram, workspace). Ambiguous names come back as a candidate list — pick one.
|
|
16
|
+
scenario, UI test, diagram, workspace). Ambiguous names come back as a candidate list — pick one.
|
|
17
17
|
5. Preview big writes with \`dryRun: true\` (bulk create, imports, scenarios, diagrams).
|
|
18
18
|
6. Deletions need \`confirm: true\` and an exact name or id. Ask the user unless they explicitly
|
|
19
19
|
requested the deletion.
|
|
@@ -54,12 +54,45 @@ secret back UNCHANGED keeps the stored one, anything else masked is refused.
|
|
|
54
54
|
## Scenarios
|
|
55
55
|
Multi-step flows as a graph of typed nodes (request, condition, assertion, set-vars, poll,
|
|
56
56
|
db, kafka, script, wait, end …). Read \`callman://docs/scenario-nodes\` before building one;
|
|
57
|
-
partial node configs are merged over defaults.
|
|
57
|
+
partial node configs are merged over defaults. Link a shared setup / teardown with a
|
|
58
|
+
scenario-ref node: \`config: { scenario: "<name or id>" }\` — the server copies it in. Nodes
|
|
59
|
+
without a position are placed next to the node they follow, clear of the others.
|
|
60
|
+
- **Where runs happen.** \`run_scenario\` runs on the Callman server by default, which only
|
|
61
|
+
reaches what the server's network reaches. For the user's localhost, port-forwards, VPN-only
|
|
62
|
+
hosts or internal databases use \`target: "desktop"\`: the user's own Callman desktop app runs
|
|
63
|
+
it (open, signed in, Settings → AI tools → "Let AI tools run scenarios on this computer").
|
|
64
|
+
- **Reports.** \`get_scenario_report\` shows server, scheduled, CLI and desktop runs
|
|
65
|
+
(\`triggerType\` / \`executor\`).
|
|
66
|
+
- **Negative checks** ("this event must NOT be published", "this call must be refused"): give the
|
|
67
|
+
node \`executionPolicy.expectFailure\` — an error edge always ends the run
|
|
68
|
+
completed_with_failures.
|
|
69
|
+
- **Editing.** \`update_scenario\` (whole graph) is checked against the version you last read; if
|
|
70
|
+
the user saved in the desktop meanwhile you get a conflict — re-read, then retry. Folders:
|
|
71
|
+
\`create_scenario_folder\` / \`update_scenario_folder\` / \`delete_scenario_folder\`. On-prem
|
|
72
|
+
review: \`submit_scenario\`, \`review_scenario\`, \`list_scenario_versions\`,
|
|
73
|
+
\`restore_scenario_version\`.
|
|
74
|
+
|
|
75
|
+
## UI tests
|
|
76
|
+
Browser and mobile-app flows (YAML: header, \`---\`, steps) — the desktop app's UI Testing area.
|
|
77
|
+
Read \`callman://docs/ui-tests\` first and \`callman://docs/ui-test-steps\` for every step. Flows are
|
|
78
|
+
linted before they are saved (\`validate_ui_test\`); edit steps by number with
|
|
79
|
+
\`patch_ui_test_steps\`. Web flows run on the server runner when there is one; Android, iOS (and
|
|
80
|
+
web without a runner) run on the user's own Callman desktop app, which must be open with
|
|
81
|
+
"Let AI tools run UI tests on this computer" on — \`list_ui_test_devices\` shows what is
|
|
82
|
+
available. Runs return per-step results; screenshots come back as images on request.
|
|
58
83
|
|
|
59
84
|
## Diagrams
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
85
|
+
Four kinds, all built with \`create_diagram\` (auto layout), edited with \`patch_diagram\` and
|
|
86
|
+
shared with \`share_diagram\` — read \`callman://docs/diagram-schema\` first:
|
|
87
|
+
- **System design**: nodes from the fixed component catalog \`callman://diagram/components\`.
|
|
88
|
+
- **BPMN process**: \`kind: "bpmn"\` with bpmn.* nodes, stored as BPMN 2.0 XML.
|
|
89
|
+
- **Mermaid**: \`source: { format: "mermaid", text }\` — a flowchart becomes nodes, other
|
|
90
|
+
Mermaid types are kept as source.
|
|
91
|
+
- **Database / ERD**: \`kind: "database"\` with \`tables\` + \`relationships\`, or \`fromConnection\`
|
|
92
|
+
to read a real database's schema (\`introspect_database\` reads it without drawing). Edit it
|
|
93
|
+
with the schema ops (addTable, addColumn, addRelationship …) and read it with view \`schema\`.
|
|
94
|
+
|
|
95
|
+
The user's library has private
|
|
63
96
|
folders: \`list_diagrams\` shows the tree as paths ("Architecture/Payments"); file a
|
|
64
97
|
diagram with \`folder\` on \`create_diagram\` / \`update_diagram\`; manage folders with
|
|
65
98
|
\`create_diagram_folder\`, \`update_diagram_folder\`, \`delete_diagram_folder\`.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"overview.js","sourceRoot":"","sources":["../../../src/resources/docs/overview.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,YAAY,GAAG
|
|
1
|
+
{"version":3,"file":"overview.js","sourceRoot":"","sources":["../../../src/resources/docs/overview.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsG3B,CAAC"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export declare const UI_TESTS_DOC = "# UI tests in Callman\n\nUI tests drive a real web browser or a mobile app step by step \u2014 the same flows QA builds in\nthe desktop app's UI Testing area. Every step (`tapOn`, `inputText`, `assertVisible`,\n`dbQuery` \u2026) with its arguments is in `callman://docs/ui-test-steps`.\n\n## A flow\nA flow is YAML text: an optional **header**, a `---` line, then a **list of steps**.\n\n```yaml\nurl: https://shop.example.com # web: where the browser starts (mobile: appId: com.shop.app)\n---\n- runFlow: \"Login\" # precondition: another flow, by EXACT name\n- tapOn: \"Catalog\"\n- inputText:\n id: \"search\"\n text: \"{{product}}\" # dataset placeholder\n- assertVisible:\n text: \"{{product}}\"\n label: \"Search shows the product\"\n- dbQuery: # hybrid data step (runs between UI steps)\n connection: orders-db # a workspace connection, by name or id\n query: \"select status from orders where id = '{{orderId}}'\"\n expect:\n - field: \"rows[0].status\"\n op: equals\n value: \"PAID\"\n```\n\n- **Platforms**: `web` (Playwright), `android` and `ios` (the mobile engine in the desktop app).\n A flow has one platform; steps the platform cannot run are lint warnings.\n- **Header**: `url` (web) or `appId` (android/ios) is what matters; `env`, `tags`, `appActivity`,\n `deviceName`, `onFlowStart`/`onFlowComplete` are optional.\n- **Preconditions / sub-flows**: `- runFlow: \"Name\"` inlines another flow of the library by its\n exact name (recursively). The leading runFlow lines are the flow's *preconditions*\n (create_ui_test / update_ui_test `preconditions: [\"Login\"]`). Renaming a flow breaks callers \u2014\n update_ui_test lists them. Names are unique per workspace.\n- **Labels**: any mapping step may carry `label:` \u2014 its name in reports (patch op `setLabel`).\n\n## Data\n- **dataset**: key \u2192 value, used as `{{key}}` anywhere (header included). Values whose key looks\n secret (password, token, apiKey, pin, otp \u2026) come back masked (`\u2022\u2022\u2022\u2022ab`) unless the token holds\n `environments:reveal` and you pass `reveal: true`. Editing a flow without reveal is fine:\n stored secrets are kept as they are. Never type a masked value yourself \u2014 pass the real value\n to change a secret, or leave the key out.\n- **datasetSources**: `{ key: { connection, query, column? } }` \u2014 the value comes from a database\n query at run time (a database connection of the workspace).\n- **Extracted values**: `extract` / `copyTextFrom` / data steps save `{{vars}}` for later steps.\n- **Hybrid steps**: `dbQuery`, `apiCall`, `kafkaPublish`, `kafkaCheck`, `redisCheck`, `runScript`\n run outside the UI engine, in order. Connections are the workspace's (`list_connections`),\n referenced by name or id.\n\n## Settings\nPer flow: `browserKind` (chrome / firefox / webkit) and `headless` for web desktop runs;\n`dismissPopups` (texts auto-dismissed) for mobile; `runSettings` { screenshotOnSuccess,\nscreenshotOnFailure, autoRetryTransient, captureNetwork } \u2014 null = the shared default.\n\n## Where runs happen\n- **Server runner** (`target: \"server\"`): web flows only, when the installation runs one.\n Schedules always use it.\n- **Your desktop app** (`target: \"desktop\"`): the Callman desktop app on the user's computer runs\n the job \u2014 Android devices/emulators, iOS simulators/devices, local browsers. It must be open,\n signed in, with **Settings \u2192 AI tools \u2192 \"Let AI tools run UI tests on this computer\"** on.\n Desktop runs queue one at a time. `device`, `browserKind`, `headless` and a one-off\n `dataset` override apply here.\n- `target: \"auto\"` (default): web \u2192 server runner when available, otherwise the desktop.\n- `list_ui_test_devices` shows the server runner, the online desktop apps and their devices.\n `UI_TEST_DESKTOP_OFFLINE` means no desktop app of the user is online.\n\n## Reports\n`run_ui_test` / `get_ui_test_run` return per-step rows (command, status, duration, error, the\nsub-flow it came from), failing steps expanded with the data they returned (DB rows, API\nresponses, extracted vars), dataset issues and warnings. `includeScreenshots: true` adds the\nfailure / final screenshots as images; `includeNetwork: true` the captured API calls.\n`list_ui_test_runs` merges server reports with the history the desktop app recorded itself.\n\n## Schedules\nWeb flows only, on the server runner: daily / weekly / monthly at times (HH:mm) or a cron\nexpression, with retries and notifications. One call can schedule many flows. On-prem,\nschedules run the flow's APPROVED version.\n\n## Review (on-prem)\nEditing a flow makes it a draft. `submit_ui_test` sends it for review; an approver\n`review_ui_test` (approve / reject with a note). Each approval is a version\n(`list_ui_test_versions`, with a diff against the current content); `restore_ui_test_version`\nre-activates an older one. Cloud has no review workflow \u2014 flows run as saved.\n\n## Recommended workflow\n1. `list_ui_test_devices` \u2014 where can it run (server runner? desktop app + devices?).\n2. `list_ui_tests` \u2014 reuse existing flows (Login \u2026) as preconditions instead of copying steps.\n3. Read `callman://docs/ui-test-steps`, draft the steps, then `validate_ui_test` (content +\n platform) \u2014 or `create_ui_test` with `dryRun: true`.\n4. `create_ui_test` (lint errors refuse the save; warnings are reported).\n5. `run_ui_test` \u2192 read the failing steps; `get_ui_test_run includeScreenshots: true` when a\n picture helps.\n6. Fix with `patch_ui_test_steps` (insert / replace / remove / move / setLabel by step number\n from `get_ui_test`) and run again.\n7. Organise with folders (`create_ui_test_folder`, `move_ui_tests`), schedule web flows\n (`create_ui_test_schedule`), submit for approval on-prem.\n";
|
|
2
|
+
//# sourceMappingURL=uiTests.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"uiTests.d.ts","sourceRoot":"","sources":["../../../src/resources/docs/uiTests.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,YAAY,gzLAmGxB,CAAC"}
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
export const UI_TESTS_DOC = `# UI tests in Callman
|
|
2
|
+
|
|
3
|
+
UI tests drive a real web browser or a mobile app step by step — the same flows QA builds in
|
|
4
|
+
the desktop app's UI Testing area. Every step (\`tapOn\`, \`inputText\`, \`assertVisible\`,
|
|
5
|
+
\`dbQuery\` …) with its arguments is in \`callman://docs/ui-test-steps\`.
|
|
6
|
+
|
|
7
|
+
## A flow
|
|
8
|
+
A flow is YAML text: an optional **header**, a \`---\` line, then a **list of steps**.
|
|
9
|
+
|
|
10
|
+
\`\`\`yaml
|
|
11
|
+
url: https://shop.example.com # web: where the browser starts (mobile: appId: com.shop.app)
|
|
12
|
+
---
|
|
13
|
+
- runFlow: "Login" # precondition: another flow, by EXACT name
|
|
14
|
+
- tapOn: "Catalog"
|
|
15
|
+
- inputText:
|
|
16
|
+
id: "search"
|
|
17
|
+
text: "{{product}}" # dataset placeholder
|
|
18
|
+
- assertVisible:
|
|
19
|
+
text: "{{product}}"
|
|
20
|
+
label: "Search shows the product"
|
|
21
|
+
- dbQuery: # hybrid data step (runs between UI steps)
|
|
22
|
+
connection: orders-db # a workspace connection, by name or id
|
|
23
|
+
query: "select status from orders where id = '{{orderId}}'"
|
|
24
|
+
expect:
|
|
25
|
+
- field: "rows[0].status"
|
|
26
|
+
op: equals
|
|
27
|
+
value: "PAID"
|
|
28
|
+
\`\`\`
|
|
29
|
+
|
|
30
|
+
- **Platforms**: \`web\` (Playwright), \`android\` and \`ios\` (the mobile engine in the desktop app).
|
|
31
|
+
A flow has one platform; steps the platform cannot run are lint warnings.
|
|
32
|
+
- **Header**: \`url\` (web) or \`appId\` (android/ios) is what matters; \`env\`, \`tags\`, \`appActivity\`,
|
|
33
|
+
\`deviceName\`, \`onFlowStart\`/\`onFlowComplete\` are optional.
|
|
34
|
+
- **Preconditions / sub-flows**: \`- runFlow: "Name"\` inlines another flow of the library by its
|
|
35
|
+
exact name (recursively). The leading runFlow lines are the flow's *preconditions*
|
|
36
|
+
(create_ui_test / update_ui_test \`preconditions: ["Login"]\`). Renaming a flow breaks callers —
|
|
37
|
+
update_ui_test lists them. Names are unique per workspace.
|
|
38
|
+
- **Labels**: any mapping step may carry \`label:\` — its name in reports (patch op \`setLabel\`).
|
|
39
|
+
|
|
40
|
+
## Data
|
|
41
|
+
- **dataset**: key → value, used as \`{{key}}\` anywhere (header included). Values whose key looks
|
|
42
|
+
secret (password, token, apiKey, pin, otp …) come back masked (\`••••ab\`) unless the token holds
|
|
43
|
+
\`environments:reveal\` and you pass \`reveal: true\`. Editing a flow without reveal is fine:
|
|
44
|
+
stored secrets are kept as they are. Never type a masked value yourself — pass the real value
|
|
45
|
+
to change a secret, or leave the key out.
|
|
46
|
+
- **datasetSources**: \`{ key: { connection, query, column? } }\` — the value comes from a database
|
|
47
|
+
query at run time (a database connection of the workspace).
|
|
48
|
+
- **Extracted values**: \`extract\` / \`copyTextFrom\` / data steps save \`{{vars}}\` for later steps.
|
|
49
|
+
- **Hybrid steps**: \`dbQuery\`, \`apiCall\`, \`kafkaPublish\`, \`kafkaCheck\`, \`redisCheck\`, \`runScript\`
|
|
50
|
+
run outside the UI engine, in order. Connections are the workspace's (\`list_connections\`),
|
|
51
|
+
referenced by name or id.
|
|
52
|
+
|
|
53
|
+
## Settings
|
|
54
|
+
Per flow: \`browserKind\` (chrome / firefox / webkit) and \`headless\` for web desktop runs;
|
|
55
|
+
\`dismissPopups\` (texts auto-dismissed) for mobile; \`runSettings\` { screenshotOnSuccess,
|
|
56
|
+
screenshotOnFailure, autoRetryTransient, captureNetwork } — null = the shared default.
|
|
57
|
+
|
|
58
|
+
## Where runs happen
|
|
59
|
+
- **Server runner** (\`target: "server"\`): web flows only, when the installation runs one.
|
|
60
|
+
Schedules always use it.
|
|
61
|
+
- **Your desktop app** (\`target: "desktop"\`): the Callman desktop app on the user's computer runs
|
|
62
|
+
the job — Android devices/emulators, iOS simulators/devices, local browsers. It must be open,
|
|
63
|
+
signed in, with **Settings → AI tools → "Let AI tools run UI tests on this computer"** on.
|
|
64
|
+
Desktop runs queue one at a time. \`device\`, \`browserKind\`, \`headless\` and a one-off
|
|
65
|
+
\`dataset\` override apply here.
|
|
66
|
+
- \`target: "auto"\` (default): web → server runner when available, otherwise the desktop.
|
|
67
|
+
- \`list_ui_test_devices\` shows the server runner, the online desktop apps and their devices.
|
|
68
|
+
\`UI_TEST_DESKTOP_OFFLINE\` means no desktop app of the user is online.
|
|
69
|
+
|
|
70
|
+
## Reports
|
|
71
|
+
\`run_ui_test\` / \`get_ui_test_run\` return per-step rows (command, status, duration, error, the
|
|
72
|
+
sub-flow it came from), failing steps expanded with the data they returned (DB rows, API
|
|
73
|
+
responses, extracted vars), dataset issues and warnings. \`includeScreenshots: true\` adds the
|
|
74
|
+
failure / final screenshots as images; \`includeNetwork: true\` the captured API calls.
|
|
75
|
+
\`list_ui_test_runs\` merges server reports with the history the desktop app recorded itself.
|
|
76
|
+
|
|
77
|
+
## Schedules
|
|
78
|
+
Web flows only, on the server runner: daily / weekly / monthly at times (HH:mm) or a cron
|
|
79
|
+
expression, with retries and notifications. One call can schedule many flows. On-prem,
|
|
80
|
+
schedules run the flow's APPROVED version.
|
|
81
|
+
|
|
82
|
+
## Review (on-prem)
|
|
83
|
+
Editing a flow makes it a draft. \`submit_ui_test\` sends it for review; an approver
|
|
84
|
+
\`review_ui_test\` (approve / reject with a note). Each approval is a version
|
|
85
|
+
(\`list_ui_test_versions\`, with a diff against the current content); \`restore_ui_test_version\`
|
|
86
|
+
re-activates an older one. Cloud has no review workflow — flows run as saved.
|
|
87
|
+
|
|
88
|
+
## Recommended workflow
|
|
89
|
+
1. \`list_ui_test_devices\` — where can it run (server runner? desktop app + devices?).
|
|
90
|
+
2. \`list_ui_tests\` — reuse existing flows (Login …) as preconditions instead of copying steps.
|
|
91
|
+
3. Read \`callman://docs/ui-test-steps\`, draft the steps, then \`validate_ui_test\` (content +
|
|
92
|
+
platform) — or \`create_ui_test\` with \`dryRun: true\`.
|
|
93
|
+
4. \`create_ui_test\` (lint errors refuse the save; warnings are reported).
|
|
94
|
+
5. \`run_ui_test\` → read the failing steps; \`get_ui_test_run includeScreenshots: true\` when a
|
|
95
|
+
picture helps.
|
|
96
|
+
6. Fix with \`patch_ui_test_steps\` (insert / replace / remove / move / setLabel by step number
|
|
97
|
+
from \`get_ui_test\`) and run again.
|
|
98
|
+
7. Organise with folders (\`create_ui_test_folder\`, \`move_ui_tests\`), schedule web flows
|
|
99
|
+
(\`create_ui_test_schedule\`), submit for approval on-prem.
|
|
100
|
+
`;
|
|
101
|
+
//# sourceMappingURL=uiTests.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"uiTests.js","sourceRoot":"","sources":["../../../src/resources/docs/uiTests.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmG3B,CAAC"}
|