@crypto512/jicon-mcp 2.3.27 → 2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/TOOL_LIST.md +123 -92
- package/dist/config/types.d.ts +65 -214
- package/dist/config/types.d.ts.map +1 -1
- package/dist/config/types.js +3 -3
- package/dist/config/types.js.map +1 -1
- package/dist/confluence/tools.d.ts +52 -165
- package/dist/confluence/tools.d.ts.map +1 -1
- package/dist/confluence/tools.js +69 -57
- package/dist/confluence/tools.js.map +1 -1
- package/dist/index.js +16 -10
- package/dist/index.js.map +1 -1
- package/dist/jira/activity-tools.d.ts +19 -95
- package/dist/jira/activity-tools.d.ts.map +1 -1
- package/dist/jira/activity-tools.js +13 -13
- package/dist/jira/activity-tools.js.map +1 -1
- package/dist/jira/tools.d.ts +64 -216
- package/dist/jira/tools.d.ts.map +1 -1
- package/dist/jira/tools.js +65 -37
- package/dist/jira/tools.js.map +1 -1
- package/dist/permissions/filter.js +6 -6
- package/dist/permissions/filter.js.map +1 -1
- package/dist/permissions/tool-registry.d.ts +24 -24
- package/dist/permissions/tool-registry.d.ts.map +1 -1
- package/dist/permissions/tool-registry.js +26 -26
- package/dist/permissions/tool-registry.js.map +1 -1
- package/dist/permissions/write-home-validator.js +7 -7
- package/dist/tempo/tools.d.ts +24 -103
- package/dist/tempo/tools.d.ts.map +1 -1
- package/dist/tempo/tools.js +24 -21
- package/dist/tempo/tools.js.map +1 -1
- package/dist/transport/http.d.ts +4 -4
- package/dist/transport/http.d.ts.map +1 -1
- package/dist/transport/index.d.ts +2 -2
- package/dist/transport/index.js +2 -2
- package/dist/utils/buffer-tools.d.ts +24 -178
- package/dist/utils/buffer-tools.d.ts.map +1 -1
- package/dist/utils/buffer-tools.js +13 -13
- package/dist/utils/buffer-tools.js.map +1 -1
- package/dist/utils/date-tools.d.ts +8 -7
- package/dist/utils/date-tools.d.ts.map +1 -1
- package/dist/utils/date-tools.js +14 -0
- package/dist/utils/date-tools.js.map +1 -1
- package/dist/utils/http-client.js +1 -1
- package/dist/utils/http-client.js.map +1 -1
- package/dist/utils/jicon-help.d.ts +12 -9
- package/dist/utils/jicon-help.d.ts.map +1 -1
- package/dist/utils/jicon-help.js +53 -53
- package/dist/utils/jicon-help.js.map +1 -1
- package/dist/utils/mcp-schema.d.ts +19 -0
- package/dist/utils/mcp-schema.d.ts.map +1 -0
- package/dist/utils/mcp-schema.js +19 -0
- package/dist/utils/mcp-schema.js.map +1 -0
- package/dist/utils/plantuml/tools.d.ts +9 -20
- package/dist/utils/plantuml/tools.d.ts.map +1 -1
- package/dist/utils/plantuml/tools.js +4 -4
- package/dist/utils/plantuml/tools.js.map +1 -1
- package/dist/utils/plantuml/types.d.ts +21 -21
- package/dist/utils/plantuml/types.d.ts.map +1 -1
- package/dist/utils/response-formatter.js +1 -1
- package/dist/utils/response-formatter.js.map +1 -1
- package/dist/utils/sandbox/schema.d.ts +3 -29
- package/dist/utils/sandbox/schema.d.ts.map +1 -1
- package/dist/utils/sandbox/schema.js +1 -1
- package/dist/utils/sandbox/schema.js.map +1 -1
- package/dist/utils/schemas/jira.d.ts +2 -2
- package/dist/utils/schemas/jira.js +2 -2
- package/dist/utils/schemas/tempo.d.ts +4 -4
- package/dist/utils/schemas/tempo.js +4 -4
- package/dist/utils/url-tools.d.ts +5 -13
- package/dist/utils/url-tools.d.ts.map +1 -1
- package/dist/utils/url-tools.js +11 -11
- package/dist/utils/url-tools.js.map +1 -1
- package/dist/utils/whoami-tools.d.ts +8 -11
- package/dist/utils/whoami-tools.d.ts.map +1 -1
- package/dist/utils/whoami-tools.js +3 -3
- package/dist/utils/whoami-tools.js.map +1 -1
- package/dist/utils/workload-tools.d.ts +13 -31
- package/dist/utils/workload-tools.d.ts.map +1 -1
- package/dist/utils/xhtml/plantuml.js +2 -2
- package/dist/utils/xhtml/plantuml.js.map +1 -1
- package/dist/utils/xhtml/types.d.ts +45 -35
- package/dist/utils/xhtml/types.d.ts.map +1 -1
- package/dist/utils/xhtml/types.js +1 -1
- package/dist/utils/xhtml/types.js.map +1 -1
- package/package.json +9 -9
package/dist/confluence/tools.js
CHANGED
|
@@ -137,7 +137,7 @@ async function validateContentForWrite(content, bufferId) {
|
|
|
137
137
|
errorMessages.push(` Use buffer_grep(bufferId="${bufferId}", pattern="...") to find the error location.`);
|
|
138
138
|
}
|
|
139
139
|
}
|
|
140
|
-
errorMessages.push('TIP: Call
|
|
140
|
+
errorMessages.push('TIP: Call jicon_help(topic="storage") for XHTML syntax (HTML vs XHTML differences).');
|
|
141
141
|
errorMessages.push("");
|
|
142
142
|
errorMessages.push("ACTION REQUIRED: Fix content errors before calling this tool again.");
|
|
143
143
|
errorMessages.push("DO NOT claim success - the draft was NOT created.");
|
|
@@ -178,7 +178,7 @@ export function createConfluenceTools() {
|
|
|
178
178
|
|
|
179
179
|
Entry point for finding Confluence pages by content, title, or metadata.
|
|
180
180
|
|
|
181
|
-
REQUIRES: Valid CQL query (see
|
|
181
|
+
REQUIRES: Valid CQL query (see jicon_help(topic="cql") for syntax)
|
|
182
182
|
RETURNS: bufferId (JSON array), itemCount with page IDs and titles
|
|
183
183
|
NEXT: confluence_get_page (to load), buffer_transform (for reports), buffer_grep (to search results)
|
|
184
184
|
|
|
@@ -229,7 +229,7 @@ WARNING: Use text~ not content~. Use space KEY not name.`,
|
|
|
229
229
|
hint += " text~\"Mike Tasc\" - finds pages mentioning this person\n";
|
|
230
230
|
hint += " text~\"meeting\" AND space=MESH - finds meetings in MESH space\n";
|
|
231
231
|
hint += " title~\"sprint review\" - finds pages with sprint review in title\n";
|
|
232
|
-
hint += '\nTIP: Call
|
|
232
|
+
hint += '\nTIP: Call jicon_help(topic="cql") for full CQL syntax guide.';
|
|
233
233
|
return formatError({
|
|
234
234
|
...error,
|
|
235
235
|
message: error.message + hint
|
|
@@ -258,9 +258,9 @@ WARNING: Use text~ not content~. Use space KEY not name.`,
|
|
|
258
258
|
PREFERRED method when you have a page ID from search results. Faster and more reliable than get_page_by_title.
|
|
259
259
|
|
|
260
260
|
Returns pageId, version, bufferId, and structure (element IDs) for structured editing.
|
|
261
|
-
Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to add content, then
|
|
261
|
+
Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to add content, then confluence_create_draft(pageId=..., bufferId=...) for user review.`,
|
|
262
262
|
inputSchema: z.object({
|
|
263
|
-
pageId: z.coerce.string().describe(
|
|
263
|
+
pageId: z.coerce.string().describe('Page ID (number or string, e.g. "123456")'),
|
|
264
264
|
expand: stringOrArray.optional().describe("Additional data to expand (string or array)"),
|
|
265
265
|
}),
|
|
266
266
|
handler: async (args) => {
|
|
@@ -291,7 +291,7 @@ Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to add conten
|
|
|
291
291
|
...(navHint && { hint: navHint }),
|
|
292
292
|
message: navHint
|
|
293
293
|
? `Index page with child listing macro. ${navHint}`
|
|
294
|
-
: "Page loaded. Use buffer_edit to modify, then
|
|
294
|
+
: "Page loaded. Use buffer_edit to modify, then confluence_create_draft(pageId=..., bufferId=...) for user review.",
|
|
295
295
|
});
|
|
296
296
|
}
|
|
297
297
|
catch (error) {
|
|
@@ -305,7 +305,7 @@ Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to add conten
|
|
|
305
305
|
Use ONLY when you don't have a page ID. IMPORTANT: Use the space KEY (e.g. 'MESH', 'TC'), NOT the space name.
|
|
306
306
|
|
|
307
307
|
Returns pageId, version, bufferId, and structure (element IDs) for structured editing.
|
|
308
|
-
Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to add content, then
|
|
308
|
+
Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to add content, then confluence_create_draft(pageId=..., bufferId=...) for user review.`,
|
|
309
309
|
inputSchema: z.object({
|
|
310
310
|
spaceKey: z.string().describe("Space key (short code like 'MESH', 'TC'), NOT the full space name"),
|
|
311
311
|
title: z.string().describe("Page title"),
|
|
@@ -346,7 +346,7 @@ Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to add conten
|
|
|
346
346
|
...(navHint && { hint: navHint }),
|
|
347
347
|
message: navHint
|
|
348
348
|
? `Index page with child listing macro. ${navHint}`
|
|
349
|
-
: "Page loaded. Use buffer_edit to modify, then
|
|
349
|
+
: "Page loaded. Use buffer_edit to modify, then confluence_create_draft(pageId=..., bufferId=...) for user review.",
|
|
350
350
|
});
|
|
351
351
|
}
|
|
352
352
|
catch (error) {
|
|
@@ -357,11 +357,11 @@ Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to add conten
|
|
|
357
357
|
confluence_load: {
|
|
358
358
|
description: `Load an EXISTING page or draft into a buffer for editing.
|
|
359
359
|
|
|
360
|
-
For NEW pages: buffer_create(contentType="xhtml") →
|
|
360
|
+
For NEW pages: buffer_create(contentType="xhtml") → confluence_create_draft(spaceKey, title, bufferId)
|
|
361
361
|
|
|
362
362
|
ACCEPTS: URL | pageId | "draft:ID" | "SPACE/Title"
|
|
363
363
|
RETURNS: bufferId, structure, pageId, version
|
|
364
|
-
NEXT: buffer_edit →
|
|
364
|
+
NEXT: buffer_edit → confluence_create_draft → confluence_publish_review`,
|
|
365
365
|
inputSchema: z.object({
|
|
366
366
|
input: z.string().describe('URL, pageId, "draft:ID", or "SPACE/Title"'),
|
|
367
367
|
}),
|
|
@@ -396,7 +396,7 @@ NEXT: buffer_edit → confluence_draft_create → confluence_review_publish`,
|
|
|
396
396
|
bufferId,
|
|
397
397
|
structure,
|
|
398
398
|
contentSize: content.length,
|
|
399
|
-
message: "Content loaded. Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to add content, then
|
|
399
|
+
message: "Content loaded. Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to add content, then confluence_create_draft(pageId=..., bufferId=...) for user review.",
|
|
400
400
|
};
|
|
401
401
|
};
|
|
402
402
|
// Helper to load draft content
|
|
@@ -421,7 +421,7 @@ NEXT: buffer_edit → confluence_draft_create → confluence_review_publish`,
|
|
|
421
421
|
bufferId,
|
|
422
422
|
structure,
|
|
423
423
|
contentSize: content.length,
|
|
424
|
-
message: "Draft loaded. Use buffer_edit to modify, then
|
|
424
|
+
message: "Draft loaded. Use buffer_edit to modify, then confluence_save_draft to update.",
|
|
425
425
|
};
|
|
426
426
|
};
|
|
427
427
|
try {
|
|
@@ -458,7 +458,7 @@ NEXT: buffer_edit → confluence_draft_create → confluence_review_publish`,
|
|
|
458
458
|
message: `Page not found: "${parsed.title}" in space ${parsed.spaceKey}`,
|
|
459
459
|
statusCode: 404,
|
|
460
460
|
details: {
|
|
461
|
-
hint: `To CREATE a new page: buffer_create(content, contentType="xhtml") →
|
|
461
|
+
hint: `To CREATE a new page: buffer_create(content, contentType="xhtml") → confluence_create_draft(spaceKey="${parsed.spaceKey}", title="${parsed.title}", bufferId=...)`,
|
|
462
462
|
},
|
|
463
463
|
});
|
|
464
464
|
}
|
|
@@ -509,7 +509,7 @@ NEXT: buffer_edit → confluence_draft_create → confluence_review_publish`,
|
|
|
509
509
|
message: `Page not found: "${title}" in space ${spaceKey}`,
|
|
510
510
|
statusCode: 404,
|
|
511
511
|
details: {
|
|
512
|
-
hint: `To CREATE a new page: buffer_create(content, contentType="xhtml") →
|
|
512
|
+
hint: `To CREATE a new page: buffer_create(content, contentType="xhtml") → confluence_create_draft(spaceKey="${spaceKey}", title="${title}", bufferId=...)`,
|
|
513
513
|
},
|
|
514
514
|
});
|
|
515
515
|
}
|
|
@@ -540,8 +540,8 @@ NEXT: buffer_edit → confluence_draft_create → confluence_review_publish`,
|
|
|
540
540
|
},
|
|
541
541
|
},
|
|
542
542
|
// All page writes go through draft workflow: LLM creates/edits drafts, user publishes via Confluence UI
|
|
543
|
-
// - New pages:
|
|
544
|
-
// - Existing pages: confluence_get_page → buffer_edit →
|
|
543
|
+
// - New pages: confluence_create_draft → user publishes
|
|
544
|
+
// - Existing pages: confluence_get_page → buffer_edit → confluence_create_draft → user publishes
|
|
545
545
|
confluence_delete_page: {
|
|
546
546
|
description: `Delete a Confluence page permanently.
|
|
547
547
|
|
|
@@ -553,7 +553,7 @@ NEXT: None
|
|
|
553
553
|
|
|
554
554
|
Example: confluence_delete_page(pageId="123456")`,
|
|
555
555
|
inputSchema: z.object({
|
|
556
|
-
pageId: z.coerce.string().describe(
|
|
556
|
+
pageId: z.coerce.string().describe('Page ID (number or string, e.g. "123456")'),
|
|
557
557
|
}),
|
|
558
558
|
handler: async (args) => {
|
|
559
559
|
try {
|
|
@@ -578,7 +578,7 @@ Example: confluence_delete_page(pageId="123456")`,
|
|
|
578
578
|
|
|
579
579
|
Discover available spaces and their keys for use in CQL queries.
|
|
580
580
|
|
|
581
|
-
TIP: For YOUR personal space, use
|
|
581
|
+
TIP: For YOUR personal space, use user_whoami() instead — it returns your spaceKey directly.
|
|
582
582
|
|
|
583
583
|
REQUIRES: None (optional type filter)
|
|
584
584
|
RETURNS: bufferId with spaces array (key, name, type)
|
|
@@ -618,7 +618,7 @@ NEXT: confluence_search_content (to query space), confluence_get_page (homepage)
|
|
|
618
618
|
|
|
619
619
|
Example: confluence_get_space(spaceKey="DOCS")`,
|
|
620
620
|
inputSchema: z.object({
|
|
621
|
-
spaceKey: z.string().describe(
|
|
621
|
+
spaceKey: z.string().describe('Space key — the short code (e.g. "DOCS"), not the full space name'),
|
|
622
622
|
expand: stringOrArray.optional().describe("Additional data to expand (string or array)"),
|
|
623
623
|
}),
|
|
624
624
|
handler: async (args) => {
|
|
@@ -646,7 +646,7 @@ Example: confluence_get_space(spaceKey="DOCS")`,
|
|
|
646
646
|
Use when you need: "my space", user's space key for creating pages/drafts.
|
|
647
647
|
This is the DEFAULT space when the user does not specify a target space.
|
|
648
648
|
|
|
649
|
-
RETURNS: spaceKey, homePageId — use with
|
|
649
|
+
RETURNS: spaceKey, homePageId — use with confluence_create_draft(spaceKey=...).`,
|
|
650
650
|
inputSchema: z.object({}),
|
|
651
651
|
handler: async () => {
|
|
652
652
|
try {
|
|
@@ -752,10 +752,16 @@ NEXT: buffer_transform (RECOMMENDED for 10+ pages — aggregate server-side to a
|
|
|
752
752
|
},
|
|
753
753
|
},
|
|
754
754
|
confluence_add_comment: {
|
|
755
|
-
description:
|
|
755
|
+
description: `Add a comment to a Confluence page.
|
|
756
|
+
|
|
757
|
+
REQUIRES: pageId, comment (XHTML storage format)
|
|
758
|
+
RETURNS: Created comment (direct json)
|
|
759
|
+
NEXT: confluence_get_comments (to view all comments)
|
|
760
|
+
|
|
761
|
+
Example: confluence_add_comment(pageId="123456", comment="<p>Reviewed — looks good.</p>")`,
|
|
756
762
|
inputSchema: z.object({
|
|
757
|
-
pageId: z.coerce.string().describe(
|
|
758
|
-
comment: z.string().describe("Comment
|
|
763
|
+
pageId: z.coerce.string().describe('Page ID (number or string, e.g. "123456"). From a search/load result.'),
|
|
764
|
+
comment: z.string().describe("Comment body in Confluence XHTML storage format (e.g. <p>text</p>)"),
|
|
759
765
|
}),
|
|
760
766
|
handler: async (args) => {
|
|
761
767
|
try {
|
|
@@ -772,7 +778,7 @@ NEXT: buffer_transform (RECOMMENDED for 10+ pages — aggregate server-side to a
|
|
|
772
778
|
|
|
773
779
|
Returns bufferId. Use buffer_get_items to read, buffer_grep to search.`,
|
|
774
780
|
inputSchema: z.object({
|
|
775
|
-
pageId: z.coerce.string().describe(
|
|
781
|
+
pageId: z.coerce.string().describe('Page ID (number or string, e.g. "123456")'),
|
|
776
782
|
}),
|
|
777
783
|
handler: async (args) => {
|
|
778
784
|
try {
|
|
@@ -792,11 +798,17 @@ Returns bufferId. Use buffer_get_items to read, buffer_grep to search.`,
|
|
|
792
798
|
},
|
|
793
799
|
},
|
|
794
800
|
confluence_upload_attachment: {
|
|
795
|
-
description:
|
|
801
|
+
description: `Upload a local file as an attachment to a Confluence page.
|
|
802
|
+
|
|
803
|
+
REQUIRES: pageId, filePath (path readable by the server)
|
|
804
|
+
RETURNS: Uploaded attachment metadata (direct json)
|
|
805
|
+
NEXT: confluence_list_attachments (to verify)
|
|
806
|
+
|
|
807
|
+
Example: confluence_upload_attachment(pageId="123456", filePath="/tmp/report.pdf")`,
|
|
796
808
|
inputSchema: z.object({
|
|
797
|
-
pageId: z.coerce.string().describe(
|
|
798
|
-
filePath: z.string().describe("
|
|
799
|
-
comment: z.string().optional().describe("
|
|
809
|
+
pageId: z.coerce.string().describe('Page ID (number or string, e.g. "123456"). From a search/load result.'),
|
|
810
|
+
filePath: z.string().describe("Absolute local file path to upload (must be readable by the server)"),
|
|
811
|
+
comment: z.string().optional().describe("Optional version comment for the attachment"),
|
|
800
812
|
}),
|
|
801
813
|
handler: async (args) => {
|
|
802
814
|
try {
|
|
@@ -813,7 +825,7 @@ Returns bufferId. Use buffer_get_items to read, buffer_grep to search.`,
|
|
|
813
825
|
|
|
814
826
|
Returns bufferId. Use buffer_get_items to read, buffer_grep to search.`,
|
|
815
827
|
inputSchema: z.object({
|
|
816
|
-
pageId: z.coerce.string().describe(
|
|
828
|
+
pageId: z.coerce.string().describe('Page ID (number or string, e.g. "123456")'),
|
|
817
829
|
}),
|
|
818
830
|
handler: async (args) => {
|
|
819
831
|
try {
|
|
@@ -837,17 +849,17 @@ Returns bufferId. Use buffer_get_items to read, buffer_grep to search.`,
|
|
|
837
849
|
// ========================================
|
|
838
850
|
// Note: Confluence drafts cannot be updated via API, only created, read, or deleted.
|
|
839
851
|
// The workflow is: create draft → edit locally in buffer → save (delete+recreate) → publish
|
|
840
|
-
|
|
852
|
+
confluence_create_draft: {
|
|
841
853
|
description: `Create draft for user review. Requires bufferId with valid XHTML.
|
|
842
854
|
|
|
843
|
-
NEW page:
|
|
844
|
-
EDIT page: confluence_load → buffer_edit →
|
|
855
|
+
NEW page: confluence_create_draft(spaceKey, title, bufferId)
|
|
856
|
+
EDIT page: confluence_load → buffer_edit → confluence_create_draft(pageId, bufferId)
|
|
845
857
|
|
|
846
|
-
TIP: Need your personal spaceKey? Use
|
|
858
|
+
TIP: Need your personal spaceKey? Use user_whoami() first.
|
|
847
859
|
|
|
848
860
|
Draft title auto-prefixed with "[jicon-mcp REVIEW]" when editing existing pages.
|
|
849
861
|
RETURNS: draftId, bufferId, structure, url. On XHTML error: errorElementId for buffer_edit fix.
|
|
850
|
-
WARNING: pageId must be a PAGE ID, not a draft ID. Use
|
|
862
|
+
WARNING: pageId must be a PAGE ID, not a draft ID. Use confluence_open_draft for existing drafts.`,
|
|
851
863
|
inputSchema: z.object({
|
|
852
864
|
pageId: z.coerce.string().optional().describe("Existing PAGE ID to edit (NOT a draft ID). Get from confluence_get_page or confluence_load. When provided, bufferId must come from that page."),
|
|
853
865
|
spaceKey: z.string().optional().describe("Space key (required for new pages, auto-populated when pageId is provided)"),
|
|
@@ -936,11 +948,11 @@ WARNING: pageId must be a PAGE ID, not a draft ID. Use confluence_draft_open for
|
|
|
936
948
|
error instanceof Error ? error.message : String(error);
|
|
937
949
|
return formatError({
|
|
938
950
|
error: true,
|
|
939
|
-
message: `Page '${args.pageId}' not found. If this is a draft ID (from
|
|
951
|
+
message: `Page '${args.pageId}' not found. If this is a draft ID (from confluence_create_draft), use confluence_open_draft to continue editing instead.`,
|
|
940
952
|
statusCode: 404,
|
|
941
953
|
details: {
|
|
942
954
|
originalError: errorMessage,
|
|
943
|
-
hint: "For existing drafts:
|
|
955
|
+
hint: "For existing drafts: confluence_open_draft(draftId) → buffer_edit → confluence_save_draft. For new drafts from existing pages: confluence_load(pageId) → buffer_edit → confluence_create_draft(pageId, bufferId)",
|
|
944
956
|
pageIdProvided: args.pageId,
|
|
945
957
|
},
|
|
946
958
|
});
|
|
@@ -1100,12 +1112,12 @@ WARNING: pageId must be a PAGE ID, not a draft ID. Use confluence_draft_open for
|
|
|
1100
1112
|
note: "This is a REVIEW draft linked to the original page.",
|
|
1101
1113
|
};
|
|
1102
1114
|
response.message = existingReviewDraft
|
|
1103
|
-
? `Review draft updated for page ${originalPageId}. Use
|
|
1104
|
-
: `Review draft created for page ${originalPageId}. Use
|
|
1115
|
+
? `Review draft updated for page ${originalPageId}. Use confluence_publish_review(${result.id}) to apply changes.`
|
|
1116
|
+
: `Review draft created for page ${originalPageId}. Use confluence_publish_review(${result.id}) to apply changes.`;
|
|
1105
1117
|
response.nextSteps = {
|
|
1106
|
-
toPublish: `
|
|
1107
|
-
toDiscard: `
|
|
1108
|
-
toList: "
|
|
1118
|
+
toPublish: `confluence_publish_review(reviewDraftId="${result.id}")`,
|
|
1119
|
+
toDiscard: `confluence_discard_review(reviewDraftId="${result.id}")`,
|
|
1120
|
+
toList: "confluence_list_reviews()",
|
|
1109
1121
|
};
|
|
1110
1122
|
}
|
|
1111
1123
|
else {
|
|
@@ -1133,10 +1145,10 @@ WARNING: pageId must be a PAGE ID, not a draft ID. Use confluence_draft_open for
|
|
|
1133
1145
|
}
|
|
1134
1146
|
},
|
|
1135
1147
|
},
|
|
1136
|
-
|
|
1148
|
+
confluence_open_draft: {
|
|
1137
1149
|
description: `Open an existing draft page for editing. Loads content into buffer with structure (element IDs).
|
|
1138
1150
|
|
|
1139
|
-
Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to modify, then
|
|
1151
|
+
Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to modify, then confluence_save_draft. User publishes via Confluence UI.`,
|
|
1140
1152
|
inputSchema: z.object({
|
|
1141
1153
|
draftId: z.coerce.string().describe("Draft page ID"),
|
|
1142
1154
|
}),
|
|
@@ -1177,12 +1189,12 @@ Use buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) to modify, th
|
|
|
1177
1189
|
}
|
|
1178
1190
|
},
|
|
1179
1191
|
},
|
|
1180
|
-
|
|
1192
|
+
confluence_list_drafts: {
|
|
1181
1193
|
description: `List your UNPUBLISHED draft pages (work-in-progress, not yet published).
|
|
1182
1194
|
|
|
1183
1195
|
NOTE: To find PUBLISHED pages you edited, use:
|
|
1184
1196
|
confluence_search_content(cql="contributor=currentUser() ORDER BY lastmodified DESC")
|
|
1185
|
-
TIP: To find your personal space key, use
|
|
1197
|
+
TIP: To find your personal space key, use user_whoami().
|
|
1186
1198
|
|
|
1187
1199
|
Returns bufferId. Use buffer_get_items to read, buffer_grep to search.`,
|
|
1188
1200
|
inputSchema: z.object({
|
|
@@ -1209,7 +1221,7 @@ Returns bufferId. Use buffer_get_items to read, buffer_grep to search.`,
|
|
|
1209
1221
|
}
|
|
1210
1222
|
},
|
|
1211
1223
|
},
|
|
1212
|
-
|
|
1224
|
+
confluence_save_draft: {
|
|
1213
1225
|
description: `Save buffer content to server as a new draft for user review.
|
|
1214
1226
|
|
|
1215
1227
|
IMPORTANT: Raw @startuml outside macros is NOT supported. Use buffer_edit for auto-wrapping, or embed properly formatted ac:structured-macro elements.
|
|
@@ -1359,7 +1371,7 @@ Returns new draftId, bufferId, structure (element IDs), and URL. Always use the
|
|
|
1359
1371
|
}
|
|
1360
1372
|
},
|
|
1361
1373
|
},
|
|
1362
|
-
|
|
1374
|
+
confluence_delete_draft: {
|
|
1363
1375
|
description: `Delete a draft page permanently.
|
|
1364
1376
|
|
|
1365
1377
|
Drafts are NOT sent to trash - they are permanently deleted.`,
|
|
@@ -1391,12 +1403,12 @@ Drafts are NOT sent to trash - they are permanently deleted.`,
|
|
|
1391
1403
|
// These tools manage the "[jicon-mcp REVIEW]" workflow for editing existing pages.
|
|
1392
1404
|
// Review drafts are linked to original pages via labels and can be published
|
|
1393
1405
|
// to apply changes to the original page.
|
|
1394
|
-
|
|
1406
|
+
confluence_publish_review: {
|
|
1395
1407
|
description: `Publish a review draft to apply changes to the original page.
|
|
1396
1408
|
|
|
1397
1409
|
Apply changes from "[jicon-mcp REVIEW]" draft to the original page.
|
|
1398
1410
|
|
|
1399
|
-
REQUIRES: reviewDraftId (from
|
|
1411
|
+
REQUIRES: reviewDraftId (from confluence_create_draft with pageId)
|
|
1400
1412
|
RETURNS: Updated page info with new version number
|
|
1401
1413
|
NEXT: confluence_get_page (to verify), confluence_load (for more changes)
|
|
1402
1414
|
|
|
@@ -1405,7 +1417,7 @@ This tool:
|
|
|
1405
1417
|
2. Copies the draft content to the original page (creates new version)
|
|
1406
1418
|
3. Deletes the review draft
|
|
1407
1419
|
|
|
1408
|
-
Example:
|
|
1420
|
+
Example: confluence_publish_review(reviewDraftId="123456")`,
|
|
1409
1421
|
inputSchema: z.object({
|
|
1410
1422
|
reviewDraftId: z.coerce.string().describe("ID of the [jicon-mcp REVIEW] draft to publish"),
|
|
1411
1423
|
autoRetry: z
|
|
@@ -1430,7 +1442,7 @@ Example: confluence_review_publish(reviewDraftId="123456")`,
|
|
|
1430
1442
|
statusCode: 400,
|
|
1431
1443
|
details: {
|
|
1432
1444
|
actualTitle: reviewDraft.title,
|
|
1433
|
-
hint: "Use
|
|
1445
|
+
hint: "Use confluence_create_draft with pageId to create a review draft",
|
|
1434
1446
|
},
|
|
1435
1447
|
});
|
|
1436
1448
|
}
|
|
@@ -1444,7 +1456,7 @@ Example: confluence_review_publish(reviewDraftId="123456")`,
|
|
|
1444
1456
|
statusCode: 400,
|
|
1445
1457
|
details: {
|
|
1446
1458
|
labels: labels.map((l) => l.name),
|
|
1447
|
-
hint: "This draft may have been created manually. Use
|
|
1459
|
+
hint: "This draft may have been created manually. Use confluence_create_draft with pageId to create proper review drafts.",
|
|
1448
1460
|
},
|
|
1449
1461
|
});
|
|
1450
1462
|
}
|
|
@@ -1461,7 +1473,7 @@ Example: confluence_review_publish(reviewDraftId="123456")`,
|
|
|
1461
1473
|
statusCode: 404,
|
|
1462
1474
|
details: {
|
|
1463
1475
|
originalPageId,
|
|
1464
|
-
hint: "If the original page was deleted, use
|
|
1476
|
+
hint: "If the original page was deleted, use confluence_discard_review to remove this review draft.",
|
|
1465
1477
|
},
|
|
1466
1478
|
});
|
|
1467
1479
|
}
|
|
@@ -1508,7 +1520,7 @@ Example: confluence_review_publish(reviewDraftId="123456")`,
|
|
|
1508
1520
|
}
|
|
1509
1521
|
},
|
|
1510
1522
|
},
|
|
1511
|
-
|
|
1523
|
+
confluence_discard_review: {
|
|
1512
1524
|
description: `Discard a review draft without applying changes to the original page.
|
|
1513
1525
|
|
|
1514
1526
|
This tool:
|
|
@@ -1531,7 +1543,7 @@ This tool:
|
|
|
1531
1543
|
statusCode: 400,
|
|
1532
1544
|
details: {
|
|
1533
1545
|
actualTitle: reviewDraft.title,
|
|
1534
|
-
hint: "Use
|
|
1546
|
+
hint: "Use confluence_delete_draft for non-review drafts",
|
|
1535
1547
|
},
|
|
1536
1548
|
});
|
|
1537
1549
|
}
|
|
@@ -1552,7 +1564,7 @@ This tool:
|
|
|
1552
1564
|
}
|
|
1553
1565
|
},
|
|
1554
1566
|
},
|
|
1555
|
-
|
|
1567
|
+
confluence_list_reviews: {
|
|
1556
1568
|
description: `List all "[jicon-mcp REVIEW]" drafts for cleanup or management.
|
|
1557
1569
|
|
|
1558
1570
|
Returns review drafts with their linked original page IDs.
|
|
@@ -1589,7 +1601,7 @@ Use this to find abandoned review drafts or manage multiple review workflows.`,
|
|
|
1589
1601
|
reviewDrafts: reviews,
|
|
1590
1602
|
total: reviews.length,
|
|
1591
1603
|
message: reviews.length > 0
|
|
1592
|
-
? `Found ${reviews.length} review draft(s). Use
|
|
1604
|
+
? `Found ${reviews.length} review draft(s). Use confluence_publish_review or confluence_discard_review to manage.`
|
|
1593
1605
|
: "No review drafts found.",
|
|
1594
1606
|
});
|
|
1595
1607
|
}
|