@crypto512/jicon-mcp 1.1.1 → 1.3.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/PROMPT.md +214 -0
- package/README.md +77 -8
- package/TOOL_LIST.md +319 -101
- package/crypto512-jicon-mcp-1.3.0.tgz +0 -0
- package/dist/confluence/client.d.ts +7 -2
- package/dist/confluence/client.d.ts.map +1 -1
- package/dist/confluence/client.js +28 -10
- package/dist/confluence/client.js.map +1 -1
- package/dist/confluence/tools.d.ts +68 -20
- package/dist/confluence/tools.d.ts.map +1 -1
- package/dist/confluence/tools.js +682 -131
- package/dist/confluence/tools.js.map +1 -1
- package/dist/jira/tools.d.ts.map +1 -1
- package/dist/jira/tools.js +76 -25
- package/dist/jira/tools.js.map +1 -1
- package/dist/permissions/tool-registry.d.ts +9 -9
- package/dist/permissions/tool-registry.d.ts.map +1 -1
- package/dist/permissions/tool-registry.js +10 -3
- package/dist/permissions/tool-registry.js.map +1 -1
- package/dist/permissions/write-home-validator.d.ts.map +1 -1
- package/dist/permissions/write-home-validator.js +23 -3
- package/dist/permissions/write-home-validator.js.map +1 -1
- package/dist/tempo/client.js +1 -1
- package/dist/tempo/client.js.map +1 -1
- package/dist/tempo/tools.d.ts.map +1 -1
- package/dist/tempo/tools.js +75 -23
- package/dist/tempo/tools.js.map +1 -1
- package/dist/utils/buffer-tools.d.ts +10 -0
- package/dist/utils/buffer-tools.d.ts.map +1 -1
- package/dist/utils/buffer-tools.js +139 -28
- package/dist/utils/buffer-tools.js.map +1 -1
- package/dist/utils/content-buffer.d.ts +5 -1
- package/dist/utils/content-buffer.d.ts.map +1 -1
- package/dist/utils/content-buffer.js +6 -3
- package/dist/utils/content-buffer.js.map +1 -1
- package/dist/utils/jicon-help.d.ts +1 -1
- package/dist/utils/jicon-help.d.ts.map +1 -1
- package/dist/utils/jicon-help.js +158 -78
- package/dist/utils/jicon-help.js.map +1 -1
- package/dist/utils/plantuml/client.d.ts +15 -1
- package/dist/utils/plantuml/client.d.ts.map +1 -1
- package/dist/utils/plantuml/client.js +56 -3
- package/dist/utils/plantuml/client.js.map +1 -1
- package/dist/utils/plantuml/include-expander.d.ts +15 -0
- package/dist/utils/plantuml/include-expander.d.ts.map +1 -1
- package/dist/utils/plantuml/include-expander.js +47 -8
- package/dist/utils/plantuml/include-expander.js.map +1 -1
- package/dist/utils/plantuml/index.d.ts +1 -1
- package/dist/utils/plantuml/index.d.ts.map +1 -1
- package/dist/utils/plantuml/index.js +1 -1
- package/dist/utils/plantuml/index.js.map +1 -1
- package/dist/utils/plantuml/service.d.ts +1 -1
- package/dist/utils/plantuml/service.d.ts.map +1 -1
- package/dist/utils/plantuml/service.js +1 -1
- package/dist/utils/plantuml/service.js.map +1 -1
- package/dist/utils/plantuml/tools.d.ts.map +1 -1
- package/dist/utils/plantuml/tools.js +5 -2
- package/dist/utils/plantuml/tools.js.map +1 -1
- package/dist/utils/response-formatter.d.ts +13 -0
- package/dist/utils/response-formatter.d.ts.map +1 -1
- package/dist/utils/response-formatter.js +25 -0
- package/dist/utils/response-formatter.js.map +1 -1
- package/dist/utils/url-tools.d.ts +27 -1
- package/dist/utils/url-tools.d.ts.map +1 -1
- package/dist/utils/url-tools.js +142 -1
- package/dist/utils/url-tools.js.map +1 -1
- package/dist/utils/xhtml/index.d.ts +1 -1
- package/dist/utils/xhtml/index.d.ts.map +1 -1
- package/dist/utils/xhtml/index.js +1 -1
- package/dist/utils/xhtml/index.js.map +1 -1
- package/dist/utils/xhtml/plantuml.d.ts +24 -6
- package/dist/utils/xhtml/plantuml.d.ts.map +1 -1
- package/dist/utils/xhtml/plantuml.js +70 -12
- package/dist/utils/xhtml/plantuml.js.map +1 -1
- package/dist/utils/xhtml/types.d.ts +1 -0
- package/dist/utils/xhtml/types.d.ts.map +1 -1
- package/dist/utils/xhtml/validator.js +2 -2
- package/dist/utils/xhtml/validator.js.map +1 -1
- package/package.json +2 -2
package/dist/utils/jicon-help.js
CHANGED
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { z } from "zod";
|
|
8
8
|
import { formatSuccess, formatError } from "./response-formatter.js";
|
|
9
|
+
import { ALLOWED_INCLUDE_URLS } from "./plantuml/index.js";
|
|
9
10
|
// Available topics
|
|
10
11
|
const TOPICS = ["jql", "cql", "storage", "plantuml", "buffers"];
|
|
11
12
|
// Default workflow guide (shown when no topic specified)
|
|
@@ -15,9 +16,10 @@ const WORKFLOW_GUIDE = `# Jicon Quick Reference
|
|
|
15
16
|
|
|
16
17
|
| Task | First Step |
|
|
17
18
|
|------|------------|
|
|
18
|
-
| Edit Confluence page | \`
|
|
19
|
+
| Edit Confluence page | \`confluence_edit(input)\` ← accepts URL, pageId, or SPACE/Title |
|
|
20
|
+
| Create NEW page | \`buffer_create(content, contentType="xhtml")\` then \`confluence_draft_create\` |
|
|
19
21
|
| Create page with diagram | \`help(topic="plantuml")\` |
|
|
20
|
-
| XHTML syntax needed | \`help(topic="storage")\` |
|
|
22
|
+
| XHTML syntax needed | \`help(topic="storage")\` ← **READ THIS for HTML vs XHTML** |
|
|
21
23
|
| Search Confluence | \`help(topic="cql")\` |
|
|
22
24
|
| Search Jira | \`jira_get_issue_types()\` then \`help(topic="jql")\` |
|
|
23
25
|
| Log/get time | \`tempo_get_user_info()\` first |
|
|
@@ -26,17 +28,42 @@ const WORKFLOW_GUIDE = `# Jicon Quick Reference
|
|
|
26
28
|
|
|
27
29
|
## Core Workflows
|
|
28
30
|
|
|
29
|
-
###
|
|
31
|
+
### Edit Confluence Page (Review Workflow)
|
|
30
32
|
\`\`\`
|
|
31
|
-
1.
|
|
33
|
+
1. confluence_edit(input)
|
|
34
|
+
- Accepts: URL, pageId, "draft:ID", or "SPACE/Title"
|
|
35
|
+
→ Returns: bufferId, structure (element IDs), pageId
|
|
36
|
+
2. buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId)
|
|
37
|
+
→ Use content="<p>text</p>" for XHTML (use <br/> not <br>!)
|
|
38
|
+
→ Use plantuml="@startuml..." for diagrams
|
|
39
|
+
→ Use fromBufferId="buf_xxx" to merge another buffer
|
|
40
|
+
3. buffer_validate_xhtml(bufferId) → check for errors before saving
|
|
41
|
+
4. confluence_draft_create(pageId=..., bufferId=...)
|
|
42
|
+
→ Creates "[jicon-mcp REVIEW] Title" draft linked to original
|
|
43
|
+
→ Returns: reviewDraftId, draft URL for user review
|
|
44
|
+
5. User reviews in Confluence UI (can share draft with team)
|
|
45
|
+
6. confluence_review_publish(reviewDraftId) → applies changes to original
|
|
46
|
+
OR confluence_review_discard(reviewDraftId) → cancels without changes
|
|
47
|
+
\`\`\`
|
|
48
|
+
|
|
49
|
+
**Review Workflow Tools:**
|
|
50
|
+
- \`confluence_review_publish(reviewDraftId)\` - Apply changes to original page
|
|
51
|
+
- \`confluence_review_discard(reviewDraftId)\` - Discard without changes
|
|
52
|
+
- \`confluence_review_list()\` - Find all review drafts for cleanup
|
|
53
|
+
|
|
54
|
+
### Create NEW Confluence Page (Buffer-First)
|
|
55
|
+
\`\`\`
|
|
56
|
+
1. buffer_create(content="<h1>Title</h1><p>Content</p>", contentType="xhtml")
|
|
32
57
|
→ Returns: bufferId, structure (element IDs)
|
|
33
|
-
2.
|
|
34
|
-
→
|
|
35
|
-
3.
|
|
36
|
-
→ Returns:
|
|
37
|
-
4. User publishes via Confluence UI
|
|
58
|
+
2. buffer_validate_xhtml(bufferId)
|
|
59
|
+
→ If errors: use buffer_edit(bufferId, replace=elementId, ...) to fix
|
|
60
|
+
3. confluence_draft_create(spaceKey, title, bufferId)
|
|
61
|
+
→ Returns: draftId, draft URL for user review
|
|
62
|
+
4. User reviews and publishes via Confluence UI
|
|
38
63
|
\`\`\`
|
|
39
64
|
|
|
65
|
+
**Why buffer-first?** Enables validation and surgical error fixing with element IDs.
|
|
66
|
+
|
|
40
67
|
### Insert PlantUML Diagram
|
|
41
68
|
\`\`\`
|
|
42
69
|
1. plantuml_validate(code="@startuml...") ← Validate FIRST
|
|
@@ -121,7 +148,8 @@ const JQL_HELP = `# JQL Syntax Guide
|
|
|
121
148
|
- Date functions: startOfDay(), startOfWeek(), startOfMonth(), now()
|
|
122
149
|
- Relative dates: startOfDay(-7) = 7 days ago
|
|
123
150
|
- Always quote field values that contain spaces
|
|
124
|
-
- Issue type names may be localized (e.g., "Epopee" instead of "Epic")
|
|
151
|
+
- Issue type names may be localized (e.g., "Epopee" instead of "Epic")
|
|
152
|
+
- Results are always buffered - use buffer_get_chunk to read, buffer_grep to search`;
|
|
125
153
|
// CQL syntax guide
|
|
126
154
|
const CQL_HELP = `# CQL Syntax Guide
|
|
127
155
|
|
|
@@ -165,7 +193,7 @@ OK: (text~"term1" OR text~"term2") - Each term needs its own text~ operator
|
|
|
165
193
|
type=page AND title~"Sprint Review" ORDER BY created DESC
|
|
166
194
|
|
|
167
195
|
9. Find by creator name:
|
|
168
|
-
creator.fullname~"
|
|
196
|
+
creator.fullname~"Alex Morgan"
|
|
169
197
|
|
|
170
198
|
10. Pages created this week:
|
|
171
199
|
type=page AND created >= startOfWeek()
|
|
@@ -174,25 +202,48 @@ OK: (text~"term1" OR text~"term2") - Each term needs its own text~ operator
|
|
|
174
202
|
- Use space KEY (e.g., 'DOCS') not space name (e.g., 'Documentation')
|
|
175
203
|
- Date functions: now(), startOfDay(), startOfWeek(), startOfMonth()
|
|
176
204
|
- Relative dates: now("-7d") = 7 days ago
|
|
177
|
-
- Results are
|
|
205
|
+
- Results are always buffered - use buffer_get_chunk to read, buffer_grep to search`;
|
|
178
206
|
// Confluence storage format (XHTML syntax only)
|
|
179
207
|
const STORAGE_FORMAT_HELP = `# Confluence Storage Format (XHTML)
|
|
180
208
|
|
|
181
|
-
|
|
209
|
+
Confluence uses **XHTML** (strict XML), NOT loose HTML5. This matters!
|
|
182
210
|
|
|
183
|
-
## CRITICAL:
|
|
211
|
+
## CRITICAL: HTML vs XHTML Differences
|
|
184
212
|
|
|
185
|
-
|
|
213
|
+
| HTML (loose) | XHTML (strict) | Why |
|
|
214
|
+
|--------------|----------------|-----|
|
|
215
|
+
| \`<br>\` | \`<br/>\` | Self-closing required |
|
|
216
|
+
| \`<hr>\` | \`<hr/>\` | Self-closing required |
|
|
217
|
+
| \`<img src="x">\` | \`<img src="x"/>\` | Self-closing required |
|
|
218
|
+
| \`<p>text\` | \`<p>text</p>\` | All tags must close |
|
|
219
|
+
| \`<li>item\` | \`<li>item</li>\` | All tags must close |
|
|
220
|
+
| \`&\` in URLs | \`&\` | Must escape special chars |
|
|
221
|
+
| \`<LI>\` | \`<li>\` | Tags are lowercase |
|
|
186
222
|
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
</
|
|
223
|
+
## Common Mistakes to AVOID
|
|
224
|
+
|
|
225
|
+
| ❌ Wrong | ✅ Correct | Error |
|
|
226
|
+
|----------|-----------|-------|
|
|
227
|
+
| \`<br>\` | \`<br/>\` | Parser expects \`</br>\` |
|
|
228
|
+
| \`li>item</li>\` | \`<li>item</li>\` | Missing \`<\` before tag |
|
|
229
|
+
| \`h2. Title\` | \`<h2>Title</h2>\` | Wiki syntax not allowed |
|
|
230
|
+
| \`**bold**\` | \`<strong>bold</strong>\` | Markdown not allowed |
|
|
231
|
+
| \`<![CDATA[<p>...</p>]]>\` | \`<p>...</p>\` | CDATA only in macros |
|
|
232
|
+
|
|
233
|
+
## Workflow: Buffer-First Approach
|
|
193
234
|
|
|
194
|
-
|
|
195
|
-
|
|
235
|
+
\`\`\`
|
|
236
|
+
1. buffer_create(content="<h1>Title</h1><p>Text</p>", contentType="xhtml")
|
|
237
|
+
→ bufferId, structure (element IDs)
|
|
238
|
+
|
|
239
|
+
2. buffer_validate_xhtml(bufferId)
|
|
240
|
+
→ If errors: shows elementId to fix
|
|
241
|
+
|
|
242
|
+
3. buffer_edit(bufferId, replace=elementId, content="<p>Fixed</p>")
|
|
243
|
+
→ Surgical fix using element ID
|
|
244
|
+
|
|
245
|
+
4. confluence_draft_create(spaceKey, title, bufferId)
|
|
246
|
+
→ Creates draft for user review
|
|
196
247
|
\`\`\`
|
|
197
248
|
|
|
198
249
|
## Basic Elements
|
|
@@ -200,11 +251,13 @@ CDATA is ONLY used inside \`<ac:plain-text-body>\` elements (code blocks, PlantU
|
|
|
200
251
|
| Element | Syntax |
|
|
201
252
|
|---------|--------|
|
|
202
253
|
| Paragraph | \`<p>text</p>\` |
|
|
203
|
-
| Headings | \`<h1
|
|
204
|
-
| Bold/Italic | \`<strong>\`, \`<em>\` |
|
|
254
|
+
| Headings | \`<h1>...</h1>\` to \`<h6>...</h6>\` |
|
|
255
|
+
| Bold/Italic | \`<strong>text</strong>\`, \`<em>text</em>\` |
|
|
256
|
+
| Line break | \`<br/>\` (self-closing!) |
|
|
257
|
+
| Horizontal rule | \`<hr/>\` (self-closing!) |
|
|
205
258
|
| Code inline | \`<code>text</code>\` |
|
|
206
259
|
| Link | \`<a href="url">text</a>\` |
|
|
207
|
-
| List | \`<ul><li>item</li></ul>\` or \`<ol>\` |
|
|
260
|
+
| List | \`<ul><li>item</li></ul>\` or \`<ol><li>...</li></ol>\` |
|
|
208
261
|
|
|
209
262
|
## Tables
|
|
210
263
|
\`\`\`xml
|
|
@@ -247,10 +300,14 @@ Cross-space: add \`ri:space-key="KEY"\` to ri:page
|
|
|
247
300
|
</ac:task-list>
|
|
248
301
|
\`\`\`
|
|
249
302
|
|
|
250
|
-
##
|
|
303
|
+
## Status Indicators (use emoticons)
|
|
251
304
|
\`\`\`xml
|
|
252
|
-
<ac:emoticon ac:name="tick"/>
|
|
253
|
-
<ac:emoticon ac:name="
|
|
305
|
+
<ac:emoticon ac:name="tick"/> <!-- ✓ green checkmark -->
|
|
306
|
+
<ac:emoticon ac:name="cross"/> <!-- ✗ red X -->
|
|
307
|
+
<ac:emoticon ac:name="warning"/> <!-- ⚠ yellow warning -->
|
|
308
|
+
<ac:emoticon ac:name="information"/> <!-- ℹ blue info -->
|
|
309
|
+
<ac:emoticon ac:name="plus"/> <!-- + green plus -->
|
|
310
|
+
<ac:emoticon ac:name="minus"/> <!-- - red minus -->
|
|
254
311
|
\`\`\`
|
|
255
312
|
|
|
256
313
|
## Code Block Macro
|
|
@@ -269,18 +326,31 @@ Cross-space: add \`ri:space-key="KEY"\` to ri:page
|
|
|
269
326
|
\`\`\`
|
|
270
327
|
Types: \`info\`, \`note\`, \`warning\`, \`tip\`
|
|
271
328
|
|
|
272
|
-
##
|
|
329
|
+
## CDATA Rules
|
|
330
|
+
|
|
331
|
+
**CDATA is ONLY used inside \`<ac:plain-text-body>\`** (code blocks, PlantUML):
|
|
332
|
+
\`\`\`xml
|
|
333
|
+
<!-- CORRECT: CDATA inside ac:plain-text-body -->
|
|
334
|
+
<ac:structured-macro ac:name="code">
|
|
335
|
+
<ac:plain-text-body><![CDATA[code here]]></ac:plain-text-body>
|
|
336
|
+
</ac:structured-macro>
|
|
337
|
+
|
|
338
|
+
<!-- WRONG: CDATA wrapping regular content -->
|
|
339
|
+
<![CDATA[<h1>Title</h1>]]>
|
|
340
|
+
\`\`\`
|
|
341
|
+
|
|
342
|
+
## Macro Content Rules
|
|
273
343
|
|
|
274
344
|
| Element | Content Allowed |
|
|
275
345
|
|---------|-----------------|
|
|
276
346
|
| \`ac:parameter\` | Plain text only (no child elements) |
|
|
277
|
-
| \`ac:plain-text-body\` | Raw text
|
|
278
|
-
| \`ac:rich-text-body\` | XHTML for info/warning panels |
|
|
347
|
+
| \`ac:plain-text-body\` | Raw text wrapped in \`<![CDATA[...]]>\` |
|
|
348
|
+
| \`ac:rich-text-body\` | XHTML (for info/warning panels) |
|
|
279
349
|
|
|
280
350
|
---
|
|
281
351
|
|
|
282
|
-
For element ID editing
|
|
283
|
-
For PlantUML diagrams
|
|
352
|
+
For element ID editing: \`help(topic="buffers")\`
|
|
353
|
+
For PlantUML diagrams: \`help(topic="plantuml")\``;
|
|
284
354
|
// PlantUML syntax guide (Confluence-specific only - LLMs know PlantUML syntax)
|
|
285
355
|
const PLANTUML_HELP = `# PlantUML in Confluence
|
|
286
356
|
|
|
@@ -300,24 +370,21 @@ const PLANTUML_HELP = `# PlantUML in Confluence
|
|
|
300
370
|
| \`plantuml_render(code, format)\` | Preview: ascii, svg, png, eps |
|
|
301
371
|
| \`plantuml_status()\` | Check Docker container status |
|
|
302
372
|
|
|
303
|
-
##
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
@startuml
|
|
309
|
-
' diagram code
|
|
310
|
-
@enduml
|
|
311
|
-
]]></ac:plain-text-body>
|
|
312
|
-
</ac:structured-macro>
|
|
313
|
-
\`\`\`
|
|
373
|
+
## Critical Rules (MANDATORY)
|
|
374
|
+
|
|
375
|
+
1. **Always use \`plantuml\` parameter**: \`buffer_edit(..., plantuml="...")\` is REQUIRED
|
|
376
|
+
- The \`content\` parameter REJECTS PlantUML macros (returns error)
|
|
377
|
+
- This ensures all PlantUML is validated before insertion
|
|
314
378
|
|
|
315
|
-
|
|
379
|
+
2. **Validation is automatic**: \`buffer_edit\` validates PlantUML before inserting
|
|
380
|
+
- Pre-validate with \`plantuml_validate(code)\` to check syntax first
|
|
381
|
+
- Invalid syntax is rejected with detailed error messages
|
|
316
382
|
|
|
317
|
-
1. **Always validate first**: \`plantuml_validate(code)\` before inserting
|
|
318
|
-
2. **Use plantuml parameter**: \`buffer_edit(..., plantuml="...")\` not \`content\`
|
|
319
383
|
3. **Include markers**: Always use \`@startuml\` and \`@enduml\`
|
|
320
384
|
|
|
385
|
+
4. **One diagram per macro**: Each \`plantuml\` parameter = one diagram
|
|
386
|
+
- Multiple diagrams require multiple \`buffer_edit\` calls
|
|
387
|
+
|
|
321
388
|
## Stdlib Includes (C4, AWS, Azure)
|
|
322
389
|
|
|
323
390
|
C4-PlantUML, AWS icons, and Azure diagrams are supported via \`!include\`:
|
|
@@ -331,12 +398,16 @@ Rel(user, sys, "Uses")
|
|
|
331
398
|
@enduml
|
|
332
399
|
\`\`\`
|
|
333
400
|
|
|
334
|
-
**
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
401
|
+
**Requires \`plantumlInclude: true\`** (enabled by default in .jicon.json)
|
|
402
|
+
|
|
403
|
+
When enabled, \`!include\` from whitelisted URLs are authorized and expanded client-side
|
|
404
|
+
before validation and Confluence upload. Expanded includes are automatically collapsed
|
|
405
|
+
back to \`!include\` directives when reading pages.
|
|
338
406
|
|
|
339
|
-
**
|
|
407
|
+
**Whitelisted URL prefixes:**
|
|
408
|
+
${ALLOWED_INCLUDE_URLS.map((url) => `- \`${url}\``).join("\n")}
|
|
409
|
+
|
|
410
|
+
Non-whitelisted URLs are left unchanged (PlantUML server may reject them due to SSRF restrictions).
|
|
340
411
|
|
|
341
412
|
## Quick Examples
|
|
342
413
|
|
|
@@ -399,34 +470,19 @@ Rel(sys, pay, "Pays via")
|
|
|
399
470
|
| "Element not found" | Check \`buffer_get_structure\` for valid IDs |
|
|
400
471
|
| "XHTML invalid" | Create fresh buffer, insert diagram |
|
|
401
472
|
|
|
402
|
-
##
|
|
473
|
+
## Multiple Diagrams
|
|
403
474
|
|
|
404
|
-
For pages with
|
|
475
|
+
For pages with multiple diagrams, call \`buffer_edit\` multiple times:
|
|
405
476
|
|
|
406
477
|
\`\`\`
|
|
407
|
-
1. plantuml_validate(
|
|
408
|
-
2.
|
|
478
|
+
1. plantuml_validate(code1) ← Validate first diagram
|
|
479
|
+
2. plantuml_validate(code2) ← Validate second diagram (parallel)
|
|
480
|
+
3. buffer_edit(bufferId, after=5, plantuml=code1)
|
|
481
|
+
4. buffer_edit(bufferId, after=6, plantuml=code2)
|
|
482
|
+
5. confluence_draft_create(bufferId=...)
|
|
409
483
|
\`\`\`
|
|
410
484
|
|
|
411
|
-
|
|
412
|
-
<h2>Architecture</h2>
|
|
413
|
-
<ac:structured-macro ac:name="plantuml" ac:schema-version="1" ac:macro-id="diag-1">
|
|
414
|
-
<ac:parameter ac:name="atlassian-macro-output-type">INLINE</ac:parameter>
|
|
415
|
-
<ac:plain-text-body><![CDATA[@startuml
|
|
416
|
-
...validated code...
|
|
417
|
-
@enduml]]></ac:plain-text-body>
|
|
418
|
-
</ac:structured-macro>
|
|
419
|
-
<h2>Sequence Flow</h2>
|
|
420
|
-
<ac:structured-macro ac:name="plantuml" ac:schema-version="1" ac:macro-id="diag-2">
|
|
421
|
-
...second diagram...
|
|
422
|
-
</ac:structured-macro>
|
|
423
|
-
\`\`\`
|
|
424
|
-
|
|
425
|
-
\`\`\`
|
|
426
|
-
3. confluence_draft_create(bufferId=...)
|
|
427
|
-
\`\`\`
|
|
428
|
-
|
|
429
|
-
**Benefit**: 3 diagrams = 5 calls (vs 8 with buffer_edit per diagram)
|
|
485
|
+
Each \`plantuml\` parameter = one diagram. The macro wrapping is automatic.
|
|
430
486
|
|
|
431
487
|
For element ID editing: \`help(topic="buffers")\``;
|
|
432
488
|
// Buffers help guide (canonical element ID reference)
|
|
@@ -454,8 +510,9 @@ confluence_get_page(pageId) → structure: [
|
|
|
454
510
|
| Replace | \`replace=4, plantuml="@startuml..."\` | Replaces diagram, keeps id=4 |
|
|
455
511
|
| Remove | \`remove=3\` | Deletes paragraph |
|
|
456
512
|
| Append | \`append=true, content="<p>End</p>"\` | Adds at document end |
|
|
513
|
+
| From buffer | \`after=2, fromBufferId="buf_xxx"\` | Insert another buffer's content |
|
|
457
514
|
|
|
458
|
-
**Content options:** \`content="<xhtml>"
|
|
515
|
+
**Content options:** \`content="<xhtml>"\`, \`plantuml="@startuml..."\`, or \`fromBufferId="buf_xxx"\`
|
|
459
516
|
|
|
460
517
|
## Batch Operations (Efficient)
|
|
461
518
|
|
|
@@ -492,6 +549,29 @@ buffer_edit(bufferId, operations=[
|
|
|
492
549
|
→ url for preview
|
|
493
550
|
\`\`\`
|
|
494
551
|
|
|
552
|
+
## Buffer Composition (fromBufferId)
|
|
553
|
+
|
|
554
|
+
When editing existing pages, you can create content in a separate buffer and merge it:
|
|
555
|
+
|
|
556
|
+
\`\`\`
|
|
557
|
+
1. confluence_edit("URL or SPACE/Title")
|
|
558
|
+
→ bufferId_A (page content), pageId
|
|
559
|
+
|
|
560
|
+
2. buffer_create({ content: "<p>New content</p>", contentType: "xhtml" })
|
|
561
|
+
→ bufferId_B
|
|
562
|
+
|
|
563
|
+
3. buffer_edit(bufferId=bufferId_A, after=5, fromBufferId=bufferId_B)
|
|
564
|
+
→ Inserts B's content into A after element 5
|
|
565
|
+
|
|
566
|
+
4. confluence_draft_create(pageId=..., bufferId=bufferId_A)
|
|
567
|
+
→ Draft linked to original page (bufferId_A originated from pageId)
|
|
568
|
+
\`\`\`
|
|
569
|
+
|
|
570
|
+
**Why use fromBufferId?**
|
|
571
|
+
- Create content in isolation, then merge into page buffer
|
|
572
|
+
- Keeps the page buffer's resourceId metadata intact (required for pageId validation)
|
|
573
|
+
- Works with batch operations: \`operations=[{after:5, fromBufferId:"buf_B"}]\`
|
|
574
|
+
|
|
495
575
|
## Other Buffer Tools
|
|
496
576
|
|
|
497
577
|
| Tool | Use |
|
|
@@ -552,7 +632,7 @@ Available topics:
|
|
|
552
632
|
- cql: CQL (Confluence Query Language) syntax
|
|
553
633
|
- storage: Confluence storage format + structure editing (element IDs)
|
|
554
634
|
- plantuml: PlantUML diagram syntax for Confluence
|
|
555
|
-
- buffers: Buffer management and
|
|
635
|
+
- buffers: Buffer management and element ID editing
|
|
556
636
|
|
|
557
637
|
Examples:
|
|
558
638
|
help() -> Workflow guide
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"jicon-help.js","sourceRoot":"","sources":["../../src/utils/jicon-help.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;
|
|
1
|
+
{"version":3,"file":"jicon-help.js","sourceRoot":"","sources":["../../src/utils/jicon-help.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,CAAC,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,CAAC;AACJ,CAAC;AAED,0BAA0B;AAC1B,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,MAAM,CAAU,CAAC;AAElD,uCAAuC;AACvC,OAAO,EAAE,cAAc,EAAE,CAAC"}
|
|
@@ -25,7 +25,21 @@ export declare class PlantUmlClient {
|
|
|
25
25
|
private timeoutMs;
|
|
26
26
|
constructor(baseUrl: string, timeoutMs?: number);
|
|
27
27
|
/**
|
|
28
|
-
*
|
|
28
|
+
* Check for rendering errors by rendering to SVG.
|
|
29
|
+
* Uses HTTP headers for error detection (same as /check endpoint).
|
|
30
|
+
* PlantUML server's DiagramResponse class sets X-PlantUML-Diagram-* headers
|
|
31
|
+
* on all rendering endpoints (/svg, /png, /eps, etc.), not just /check.
|
|
32
|
+
*
|
|
33
|
+
* Called after /check validation passes to catch issues that syntax
|
|
34
|
+
* validation misses but actual rendering catches.
|
|
35
|
+
*/
|
|
36
|
+
private checkRenderingErrors;
|
|
37
|
+
/**
|
|
38
|
+
* Validate PlantUML syntax using /check endpoint, then verify rendering.
|
|
39
|
+
*
|
|
40
|
+
* Two-phase validation:
|
|
41
|
+
* 1. Syntax check via /check endpoint (fast)
|
|
42
|
+
* 2. Render check via /svg endpoint (catches issues /check misses)
|
|
29
43
|
*/
|
|
30
44
|
validate(code: string): Promise<PlantUmlValidationResult>;
|
|
31
45
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../src/utils/plantuml/client.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,KAAK,EACV,wBAAwB,EACxB,oBAAoB,EAEpB,YAAY,EACZ,WAAW,EACZ,MAAM,YAAY,CAAC;AAmCpB;;GAEG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAGnD;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAetD;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,WAAW,CA8E3D;AAoDD;;GAEG;AACH,qBAAa,cAAc;IACb,OAAO,CAAC,OAAO;IAAU,OAAO,CAAC,SAAS;gBAAlC,OAAO,EAAE,MAAM,EAAU,SAAS,GAAE,MAAc;IAEtE
|
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../src/utils/plantuml/client.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,KAAK,EACV,wBAAwB,EACxB,oBAAoB,EAEpB,YAAY,EACZ,WAAW,EACZ,MAAM,YAAY,CAAC;AAmCpB;;GAEG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAGnD;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAetD;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,WAAW,CA8E3D;AAoDD;;GAEG;AACH,qBAAa,cAAc;IACb,OAAO,CAAC,OAAO;IAAU,OAAO,CAAC,SAAS;gBAAlC,OAAO,EAAE,MAAM,EAAU,SAAS,GAAE,MAAc;IAEtE;;;;;;;;OAQG;YACW,oBAAoB;IA8BlC;;;;;;OAMG;IACG,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,wBAAwB,CAAC;IAmE/D;;OAEG;IACG,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,YAAY,GAAG,OAAO,CAAC,oBAAoB,CAAC;IA4C/E;;OAEG;IACG,WAAW,IAAI,OAAO,CAAC,OAAO,CAAC;CAWtC"}
|
|
@@ -175,14 +175,52 @@ export class PlantUmlClient {
|
|
|
175
175
|
this.timeoutMs = timeoutMs;
|
|
176
176
|
}
|
|
177
177
|
/**
|
|
178
|
-
*
|
|
178
|
+
* Check for rendering errors by rendering to SVG.
|
|
179
|
+
* Uses HTTP headers for error detection (same as /check endpoint).
|
|
180
|
+
* PlantUML server's DiagramResponse class sets X-PlantUML-Diagram-* headers
|
|
181
|
+
* on all rendering endpoints (/svg, /png, /eps, etc.), not just /check.
|
|
182
|
+
*
|
|
183
|
+
* Called after /check validation passes to catch issues that syntax
|
|
184
|
+
* validation misses but actual rendering catches.
|
|
185
|
+
*/
|
|
186
|
+
async checkRenderingErrors(encoded) {
|
|
187
|
+
try {
|
|
188
|
+
const response = await fetch(`${this.baseUrl}/svg/${encoded}`, {
|
|
189
|
+
method: "GET",
|
|
190
|
+
signal: AbortSignal.timeout(this.timeoutMs),
|
|
191
|
+
});
|
|
192
|
+
// Check error headers (same approach as /check endpoint)
|
|
193
|
+
const errorDesc = response.headers.get("X-PlantUML-Diagram-Description");
|
|
194
|
+
const errorMsg = response.headers.get("X-PlantUML-Diagram-Error");
|
|
195
|
+
if (errorDesc?.includes("Error") || errorMsg) {
|
|
196
|
+
return {
|
|
197
|
+
hasErrors: true,
|
|
198
|
+
errorMessage: errorMsg || "Diagram rendering failed",
|
|
199
|
+
};
|
|
200
|
+
}
|
|
201
|
+
// If no error headers, rendering succeeded
|
|
202
|
+
return { hasErrors: false };
|
|
203
|
+
}
|
|
204
|
+
catch (error) {
|
|
205
|
+
return {
|
|
206
|
+
hasErrors: true,
|
|
207
|
+
errorMessage: error instanceof Error ? error.message : String(error),
|
|
208
|
+
};
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
/**
|
|
212
|
+
* Validate PlantUML syntax using /check endpoint, then verify rendering.
|
|
213
|
+
*
|
|
214
|
+
* Two-phase validation:
|
|
215
|
+
* 1. Syntax check via /check endpoint (fast)
|
|
216
|
+
* 2. Render check via /svg endpoint (catches issues /check misses)
|
|
179
217
|
*/
|
|
180
218
|
async validate(code) {
|
|
181
219
|
const normalizedCode = normalizePlantUml(code);
|
|
182
220
|
const diagramType = detectDiagramType(normalizedCode);
|
|
183
221
|
const encoded = encodePlantUml(normalizedCode);
|
|
184
222
|
try {
|
|
185
|
-
//
|
|
223
|
+
// Phase 1: Syntax validation via /check endpoint (fast)
|
|
186
224
|
const response = await fetch(`${this.baseUrl}/check/${encoded}`, {
|
|
187
225
|
method: "GET",
|
|
188
226
|
signal: AbortSignal.timeout(this.timeoutMs),
|
|
@@ -201,7 +239,22 @@ export class PlantUmlClient {
|
|
|
201
239
|
errors,
|
|
202
240
|
};
|
|
203
241
|
}
|
|
204
|
-
//
|
|
242
|
+
// Phase 2: Render validation (catches issues /check misses)
|
|
243
|
+
const renderCheck = await this.checkRenderingErrors(encoded);
|
|
244
|
+
if (renderCheck.hasErrors) {
|
|
245
|
+
return {
|
|
246
|
+
valid: false,
|
|
247
|
+
normalizedCode,
|
|
248
|
+
diagramType,
|
|
249
|
+
errors: [
|
|
250
|
+
{
|
|
251
|
+
line: 1,
|
|
252
|
+
message: renderCheck.errorMessage || "Diagram failed render validation",
|
|
253
|
+
},
|
|
254
|
+
],
|
|
255
|
+
};
|
|
256
|
+
}
|
|
257
|
+
// Valid diagram (passed both syntax and render checks)
|
|
205
258
|
return {
|
|
206
259
|
valid: true,
|
|
207
260
|
normalizedCode,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.js","sourceRoot":"","sources":["../../../src/utils/plantuml/client.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AASnC;;;GAGG;AACH,SAAS,QAAQ,CAAC,IAAY;IAC5B,MAAM,KAAK,GACT,kEAAkE,CAAC;IACrE,IAAI,MAAM,GAAG,EAAE,CAAC;IAEhB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,MAAM,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC;QACxC,MAAM,EAAE,GAAG,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC;QACxB,MAAM,EAAE,GAAG,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC,IAAI,CAA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CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QAEvD,OAAO;YACL,MAAM;YACN,OAAO;YACP,WAAW;YACX,IAAI,EAAE,MAAM,CAAC,UAAU;SACxB,CAAC;IACJ,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,WAAW;QACf,IAAI,CAAC;YACH,MAAM,QAAQ,GAAG,MAAM,KAAK,CAAC,IAAI,CAAC,OAAO,EAAE;gBACzC,MAAM,EAAE,KAAK;gBACb,MAAM,EAAE,WAAW,CAAC,OAAO,CAAC,IAAI,CAAC;aAClC,CAAC,CAAC;YACH,OAAO,QAAQ,CAAC,EAAE,CAAC;QACrB,CAAC;QAAC,MAAM,CAAC;YACP,OAAO,KAAK,CAAC;QACf,CAAC;IACH,CAAC;CACF"}
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
* Expands !include directives by fetching whitelisted URLs client-side.
|
|
5
5
|
* This bypasses PlantUML server SSRF restrictions for trusted stdlib libraries.
|
|
6
6
|
*/
|
|
7
|
+
export declare const ALLOWED_INCLUDE_URLS: string[];
|
|
7
8
|
/**
|
|
8
9
|
* Expand !include directives in PlantUML code
|
|
9
10
|
*
|
|
@@ -29,4 +30,18 @@ export declare function getIncludeCacheStats(): {
|
|
|
29
30
|
size: number;
|
|
30
31
|
urls: string[];
|
|
31
32
|
};
|
|
33
|
+
/**
|
|
34
|
+
* Collapse expanded includes back to !include/!includeurl directives
|
|
35
|
+
*
|
|
36
|
+
* Reverses the expansion by finding the marker comments and replacing
|
|
37
|
+
* the entire block with the original include directive.
|
|
38
|
+
*/
|
|
39
|
+
export declare function collapseExpandedIncludes(code: string): string;
|
|
40
|
+
/**
|
|
41
|
+
* Collapse expanded includes within XHTML content
|
|
42
|
+
*
|
|
43
|
+
* Finds all PlantUML macros in XHTML and collapses expanded includes
|
|
44
|
+
* back to !include directives when reading from Confluence.
|
|
45
|
+
*/
|
|
46
|
+
export declare function collapseExpandedIncludesInXhtml(xhtml: string): string;
|
|
32
47
|
//# sourceMappingURL=include-expander.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"include-expander.d.ts","sourceRoot":"","sources":["../../../src/utils/plantuml/include-expander.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;
|
|
1
|
+
{"version":3,"file":"include-expander.d.ts","sourceRoot":"","sources":["../../../src/utils/plantuml/include-expander.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,eAAO,MAAM,oBAAoB,UAIhC,CAAC;AA8CF;;;;;GAKG;AACH,wBAAsB,cAAc,CAClC,IAAI,EAAE,MAAM,EACZ,KAAK,GAAE,MAAU,GAChB,OAAO,CAAC,MAAM,CAAC,CAwCjB;AAED;;;;;GAKG;AACH,wBAAsB,qBAAqB,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CA6B1E;AAED;;GAEG;AACH,wBAAgB,iBAAiB,IAAI,IAAI,CAExC;AAED;;GAEG;AACH,wBAAgB,oBAAoB,IAAI;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,EAAE,CAAA;CAAE,CAKvE;AAED;;;;;GAKG;AACH,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAM7D;AAED;;;;;GAKG;AACH,wBAAgB,+BAA+B,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAwBrE"}
|