@clipform/mcp-server 5.18.0 → 5.20.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/dist/api-client.js +1 -1
- package/dist/{chunk-NRYDSMLT.js → chunk-4U235K5L.js} +2 -2
- package/dist/{chunk-DOXSGWYD.js → chunk-E2ORDV2Y.js} +3 -3
- package/dist/{chunk-HIEBNDBW.js → chunk-H2XLORU7.js} +3 -3
- package/dist/{chunk-THJUTILR.js → chunk-MRMTV4FY.js} +66 -23
- package/dist/{chunk-THJUTILR.js.map → chunk-MRMTV4FY.js.map} +1 -1
- package/dist/{chunk-K4NSJZAP.js → chunk-MVZJFCTX.js} +16 -2
- package/dist/{chunk-K4NSJZAP.js.map → chunk-MVZJFCTX.js.map} +1 -1
- package/dist/index.js +5 -5
- package/dist/prompts.js +3 -3
- package/dist/resources.js +3 -3
- package/dist/server.js +5 -5
- package/package.json +1 -1
- package/server.json +2 -2
- /package/dist/{chunk-NRYDSMLT.js.map → chunk-4U235K5L.js.map} +0 -0
- /package/dist/{chunk-DOXSGWYD.js.map → chunk-E2ORDV2Y.js.map} +0 -0
- /package/dist/{chunk-HIEBNDBW.js.map → chunk-H2XLORU7.js.map} +0 -0
package/dist/api-client.js
CHANGED
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
CURRENT_PLAN_VERSIONS,
|
|
3
3
|
PLAN_LIMITS,
|
|
4
4
|
callApi
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-MVZJFCTX.js";
|
|
6
6
|
import {
|
|
7
7
|
getMcpAuth
|
|
8
8
|
} from "./chunk-ENVV65JX.js";
|
|
@@ -145,4 +145,4 @@ export {
|
|
|
145
145
|
getSessionContextWithAuth,
|
|
146
146
|
getSessionContext
|
|
147
147
|
};
|
|
148
|
-
//# sourceMappingURL=chunk-
|
|
148
|
+
//# sourceMappingURL=chunk-4U235K5L.js.map
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
FULL_CAPS,
|
|
3
3
|
getSessionContext
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-4U235K5L.js";
|
|
5
5
|
import {
|
|
6
6
|
ALL_VARIANTS,
|
|
7
7
|
FORM_TYPES,
|
|
8
8
|
FORM_TYPE_KEYS,
|
|
9
9
|
callApi
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-MVZJFCTX.js";
|
|
11
11
|
import {
|
|
12
12
|
getMcpAuth
|
|
13
13
|
} from "./chunk-ENVV65JX.js";
|
|
@@ -146,4 +146,4 @@ export {
|
|
|
146
146
|
getGuideUri,
|
|
147
147
|
registerResources
|
|
148
148
|
};
|
|
149
|
-
//# sourceMappingURL=chunk-
|
|
149
|
+
//# sourceMappingURL=chunk-E2ORDV2Y.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
FULL_CAPS,
|
|
3
3
|
getSessionContextWithAuth
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-4U235K5L.js";
|
|
5
5
|
import {
|
|
6
6
|
FORM_TYPES,
|
|
7
7
|
MAX_CLIP_SECONDS,
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
WORKFLOW_TYPES,
|
|
11
11
|
exposedCompositionIds,
|
|
12
12
|
getDiscoveryParams
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-MVZJFCTX.js";
|
|
14
14
|
import {
|
|
15
15
|
__export
|
|
16
16
|
} from "./chunk-PZ5AY32C.js";
|
|
@@ -20462,4 +20462,4 @@ export {
|
|
|
20462
20462
|
getWorkflowText,
|
|
20463
20463
|
registerPrompts
|
|
20464
20464
|
};
|
|
20465
|
-
//# sourceMappingURL=chunk-
|
|
20465
|
+
//# sourceMappingURL=chunk-H2XLORU7.js.map
|
|
@@ -31,7 +31,7 @@ import {
|
|
|
31
31
|
union,
|
|
32
32
|
unknown,
|
|
33
33
|
url
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-H2XLORU7.js";
|
|
35
35
|
import {
|
|
36
36
|
GUIDE_TYPES,
|
|
37
37
|
QUIZ_VARIANTS,
|
|
@@ -40,7 +40,7 @@ import {
|
|
|
40
40
|
getGuideUri,
|
|
41
41
|
guideFallbackText,
|
|
42
42
|
registerResources
|
|
43
|
-
} from "./chunk-
|
|
43
|
+
} from "./chunk-E2ORDV2Y.js";
|
|
44
44
|
import {
|
|
45
45
|
ANON_PREVIEW_LINK_LABEL,
|
|
46
46
|
ANON_PREVIEW_NOTICE,
|
|
@@ -54,13 +54,14 @@ import {
|
|
|
54
54
|
isPreviewViewerUrl,
|
|
55
55
|
previewOnlyNotice,
|
|
56
56
|
withAdoptedNotice
|
|
57
|
-
} from "./chunk-
|
|
57
|
+
} from "./chunk-4U235K5L.js";
|
|
58
58
|
import {
|
|
59
59
|
ACTIVE_NODE_TYPES,
|
|
60
60
|
ANON_MCP_BLOCKED_NODE_TYPES,
|
|
61
61
|
ANON_MCP_LIVE_TTL_DAYS,
|
|
62
62
|
ANON_MCP_RESPONSE_CAP,
|
|
63
63
|
CHOICE_MAX_OPTIONS,
|
|
64
|
+
COMPANY_CHECKLIST_KINDS,
|
|
64
65
|
CONSENT_TYPES,
|
|
65
66
|
CONTACT_FIELDS,
|
|
66
67
|
FEATURE_FLAGS,
|
|
@@ -68,6 +69,8 @@ import {
|
|
|
68
69
|
FORM_TYPE_ALIASES,
|
|
69
70
|
GUIDE_CONFIG_KEY,
|
|
70
71
|
GUIDE_LIMITS,
|
|
72
|
+
GUIDE_NODE_SECTIONS,
|
|
73
|
+
GUIDE_SECTIONS,
|
|
71
74
|
GUIDE_TOUR_ANCHORS,
|
|
72
75
|
LINK_VARIABLE_PRESETS,
|
|
73
76
|
LOGIC_TARGET_TYPES,
|
|
@@ -117,7 +120,7 @@ import {
|
|
|
117
120
|
textResult,
|
|
118
121
|
validateVariableKey,
|
|
119
122
|
viewerUrl
|
|
120
|
-
} from "./chunk-
|
|
123
|
+
} from "./chunk-MVZJFCTX.js";
|
|
121
124
|
import {
|
|
122
125
|
getMcpAuth,
|
|
123
126
|
runWithMcpAuth,
|
|
@@ -19203,60 +19206,100 @@ function registerSetLinkVariablesTool(server) {
|
|
|
19203
19206
|
|
|
19204
19207
|
// src/tools/set-node-guide.ts
|
|
19205
19208
|
var NOT_AVAILABLE2 = "Walkthrough notes are not available on this workspace.";
|
|
19209
|
+
var SECTION_LABELS = {
|
|
19210
|
+
media: "the video or image area",
|
|
19211
|
+
prompt: "the question text",
|
|
19212
|
+
body: "the answer area",
|
|
19213
|
+
formats: "the answer-type tiles",
|
|
19214
|
+
options: "the option list"
|
|
19215
|
+
};
|
|
19216
|
+
var TOUR_ANCHORS = [...GUIDE_TOUR_ANCHORS, ...GUIDE_SECTIONS];
|
|
19217
|
+
var SECTION_DOC = GUIDE_SECTIONS.map((name) => {
|
|
19218
|
+
const types = Object.entries(GUIDE_NODE_SECTIONS).filter(([, extra]) => extra.includes(name)).map(([type]) => type);
|
|
19219
|
+
return `"${name}" (${SECTION_LABELS[name]}${types.length ? `, ${types.join("/")} steps only` : ""})`;
|
|
19220
|
+
}).join(", ");
|
|
19221
|
+
function anchorText(anchor) {
|
|
19222
|
+
if (anchor === "share") return "points at Share";
|
|
19223
|
+
const label = SECTION_LABELS[anchor];
|
|
19224
|
+
return label ? `points at ${label}` : "points at the node";
|
|
19225
|
+
}
|
|
19206
19226
|
var TourSchema = external_exports.object({
|
|
19207
19227
|
title: external_exports.string().min(1).max(GUIDE_LIMITS.titleMax).describe(`Short heading, up to ${GUIDE_LIMITS.titleMax} characters`),
|
|
19208
19228
|
body: external_exports.string().min(1).max(GUIDE_LIMITS.bodyMax).describe(`The note, up to ${GUIDE_LIMITS.bodyMax} characters of plain text`),
|
|
19209
|
-
anchor: external_exports.enum(
|
|
19229
|
+
anchor: external_exports.enum(TOUR_ANCHORS).optional().describe(
|
|
19230
|
+
`Where the note points: "node" (default, the whole step), "share" for the closing note on the Share button, or one part of the step: ${SECTION_DOC}. A part the step's type does not have is refused with the valid ones. Example: anchor "media" on "This is where you add your video".`
|
|
19231
|
+
)
|
|
19232
|
+
});
|
|
19233
|
+
var ChecklistItemSchema = external_exports.object({
|
|
19234
|
+
kind: external_exports.enum(COMPANY_CHECKLIST_KINDS).describe(
|
|
19235
|
+
"What ticks the item: record_video (the owner records or uploads their own video on THIS step, so put it on a step that carries a video), preview (they answer a step in the preview), connect (they connect `integration`), go_live (they publish), claim_account (an anonymous visitor creates an account; hidden once signed in)"
|
|
19236
|
+
),
|
|
19237
|
+
label: external_exports.string().min(1).max(GUIDE_LIMITS.checklistLabelMax).describe(`The item, up to ${GUIDE_LIMITS.checklistLabelMax} characters, e.g. "Record your intro"`),
|
|
19238
|
+
description: external_exports.string().max(GUIDE_LIMITS.checklistDescriptionMax).optional().describe(`A short sentence under it, up to ${GUIDE_LIMITS.checklistDescriptionMax} characters (the card is narrow: keep it to about two lines)`),
|
|
19239
|
+
integration: external_exports.string().optional().describe('connect only: the integration slug, e.g. "stripe" or "calendly" (live integrations only)')
|
|
19210
19240
|
});
|
|
19211
19241
|
var IntroSchema = external_exports.object({
|
|
19212
19242
|
title: external_exports.string().min(1).max(GUIDE_LIMITS.titleMax).describe(`Who it was built for, up to ${GUIDE_LIMITS.titleMax} characters`),
|
|
19213
|
-
body: external_exports.string().min(1).max(GUIDE_LIMITS.bodyMax).describe(
|
|
19243
|
+
body: external_exports.string().min(1).max(GUIDE_LIMITS.bodyMax).describe(`What the form does for them: one or two plain sentences, four short lines at most (up to ${GUIDE_LIMITS.bodyMax} characters)`)
|
|
19214
19244
|
});
|
|
19215
19245
|
function registerSetNodeGuideTool(server) {
|
|
19216
19246
|
server.registerTool(
|
|
19217
19247
|
"clipform_set_node_guide",
|
|
19218
19248
|
{
|
|
19219
|
-
title: "Set a walkthrough note",
|
|
19220
|
-
description: `Set or remove the builder walkthrough
|
|
19249
|
+
title: "Set a walkthrough intro, note or checklist",
|
|
19250
|
+
description: `Set or remove the builder walkthrough intro, note and getting-started checklist on one node of an outbound template. When someone copies the template and opens it in the builder, an intro card says what was built for them (title: who it is for, body: what the form does, four short lines at most), then the walkthrough pans to each noted node in form order and shows its note, then the checklist opens with the items of every node (form order, then list order), replacing the generic list on that copy; each item ticks itself from what the owner really does. Write public facts about the company only, never a person's name. Put the intro on the first noted node; each note covers only its own node, and the closing note goes on the last step with anchor "share". Put a record_video item on the step whose video the owner should replace, and the workspace-wide items (connect, go_live, claim_account) on the End screen. At most ${GUIDE_LIMITS.maxTourSteps} notes and ${GUIDE_LIMITS.maxChecklistItems} checklist items show per form. Send any of tour, intro and checklist; null removes that one and leaves the others.`,
|
|
19221
19251
|
inputSchema: external_exports.object({
|
|
19222
19252
|
form_id: external_exports.string().uuid().describe("The form UUID (returned by clipform_create_form, not the short share_id from the URL)"),
|
|
19223
|
-
node_id: external_exports.string().uuid().describe("The node to put the note on (ids from clipform_get_form). Not the Start node."),
|
|
19224
|
-
tour: TourSchema.nullable().optional().describe("The note, or null to remove it. Omit to leave it as is."),
|
|
19225
|
-
intro: IntroSchema.nullable().optional().describe("The intro card shown before the first note, or null to remove it. Omit to leave it as is.")
|
|
19253
|
+
node_id: external_exports.string().uuid().describe("The node to put the note or items on (ids from clipform_get_form). Not the Start node."),
|
|
19254
|
+
tour: TourSchema.nullable().optional().describe("The note, or null to remove it. Omit to leave it as it is."),
|
|
19255
|
+
intro: IntroSchema.nullable().optional().describe("The intro card shown before the first note, or null to remove it. Omit to leave it as it is."),
|
|
19256
|
+
checklist: external_exports.array(ChecklistItemSchema).max(GUIDE_LIMITS.maxChecklistItems).nullable().optional().describe("This node's checklist items (replaces its list), or null to remove them. Omit to leave them as they are.")
|
|
19226
19257
|
}),
|
|
19227
19258
|
outputSchema: external_exports.object({
|
|
19228
19259
|
form_id: external_exports.string(),
|
|
19229
19260
|
node_id: external_exports.string(),
|
|
19230
19261
|
tour: TourSchema.nullable().describe("The note now stored on the node (trimmed), or null when it has none"),
|
|
19231
|
-
intro: IntroSchema.nullable().describe("The intro now stored on the node (trimmed), or null when it has none")
|
|
19262
|
+
intro: IntroSchema.nullable().describe("The intro now stored on the node (trimmed), or null when it has none"),
|
|
19263
|
+
checklist: external_exports.array(ChecklistItemSchema).nullable().describe("The checklist items now stored on the node (trimmed), or null when it has none")
|
|
19232
19264
|
}),
|
|
19233
19265
|
annotations: {
|
|
19234
19266
|
readOnlyHint: false,
|
|
19235
|
-
// Replaces the node's note, and
|
|
19267
|
+
// Replaces the node's note or items, and null removes them.
|
|
19236
19268
|
destructiveHint: true,
|
|
19237
19269
|
idempotentHint: true,
|
|
19238
19270
|
openWorldHint: false
|
|
19239
19271
|
}
|
|
19240
19272
|
},
|
|
19241
|
-
async ({ form_id, node_id, tour, intro }) => {
|
|
19242
|
-
if (tour === void 0 && intro === void 0
|
|
19243
|
-
|
|
19273
|
+
async ({ form_id, node_id, tour, intro, checklist }) => {
|
|
19274
|
+
if (tour === void 0 && intro === void 0 && checklist === void 0) {
|
|
19275
|
+
return refusedResult("Send tour, intro or checklist (null removes one).");
|
|
19276
|
+
}
|
|
19277
|
+
const guide = {};
|
|
19278
|
+
if (tour !== void 0) guide.tour = tour;
|
|
19279
|
+
if (intro !== void 0) guide.intro = intro;
|
|
19280
|
+
if (checklist !== void 0) guide.checklist = checklist;
|
|
19244
19281
|
const res = await callApi(`/forms/${form_id}/nodes/${node_id}`, { method: "PATCH", body: { config: { guide } } });
|
|
19245
19282
|
if (!res.ok) return apiErrorResult(res);
|
|
19246
19283
|
const data = res.data;
|
|
19247
19284
|
const storedTour = data?.config?.guide?.tour ?? null;
|
|
19248
19285
|
const storedIntro = data?.config?.guide?.intro ?? null;
|
|
19249
|
-
|
|
19250
|
-
|
|
19286
|
+
const storedChecklist = data?.config?.guide?.checklist ?? null;
|
|
19287
|
+
if (tour && !storedTour || intro && !storedIntro || checklist?.length && !storedChecklist) return refusedResult(NOT_AVAILABLE2);
|
|
19288
|
+
const parts = [];
|
|
19251
19289
|
if (tour !== void 0) {
|
|
19252
|
-
|
|
19253
|
-
storedTour ? `Walkthrough note set on node ${node_id}: "${storedTour.title}" (${storedTour.anchor
|
|
19290
|
+
parts.push(
|
|
19291
|
+
storedTour ? `Walkthrough note set on node ${node_id}: "${storedTour.title}" (${anchorText(storedTour.anchor)}).` : `Walkthrough note removed from node ${node_id}.`
|
|
19254
19292
|
);
|
|
19255
19293
|
}
|
|
19256
19294
|
if (intro !== void 0) {
|
|
19257
|
-
|
|
19295
|
+
parts.push(storedIntro ? `Intro card set on node ${node_id}: "${storedIntro.title}".` : `Intro card removed from node ${node_id}.`);
|
|
19296
|
+
}
|
|
19297
|
+
if (checklist !== void 0) {
|
|
19298
|
+
parts.push(
|
|
19299
|
+
storedChecklist ? `Checklist on node ${node_id}: ${storedChecklist.map((i) => `"${i.label}" (${i.kind})`).join(", ")}.` : `Checklist removed from node ${node_id}.`
|
|
19300
|
+
);
|
|
19258
19301
|
}
|
|
19259
|
-
return structuredResult(
|
|
19302
|
+
return structuredResult(parts.join(" "), { form_id, node_id, tour: storedTour, intro: storedIntro, checklist: storedChecklist });
|
|
19260
19303
|
}
|
|
19261
19304
|
);
|
|
19262
19305
|
}
|
|
@@ -21063,4 +21106,4 @@ export {
|
|
|
21063
21106
|
* MIT Licensed
|
|
21064
21107
|
*)
|
|
21065
21108
|
*/
|
|
21066
|
-
//# sourceMappingURL=chunk-
|
|
21109
|
+
//# sourceMappingURL=chunk-MRMTV4FY.js.map
|