@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.
Files changed (79) hide show
  1. package/PROMPT.md +214 -0
  2. package/README.md +77 -8
  3. package/TOOL_LIST.md +319 -101
  4. package/crypto512-jicon-mcp-1.3.0.tgz +0 -0
  5. package/dist/confluence/client.d.ts +7 -2
  6. package/dist/confluence/client.d.ts.map +1 -1
  7. package/dist/confluence/client.js +28 -10
  8. package/dist/confluence/client.js.map +1 -1
  9. package/dist/confluence/tools.d.ts +68 -20
  10. package/dist/confluence/tools.d.ts.map +1 -1
  11. package/dist/confluence/tools.js +682 -131
  12. package/dist/confluence/tools.js.map +1 -1
  13. package/dist/jira/tools.d.ts.map +1 -1
  14. package/dist/jira/tools.js +76 -25
  15. package/dist/jira/tools.js.map +1 -1
  16. package/dist/permissions/tool-registry.d.ts +9 -9
  17. package/dist/permissions/tool-registry.d.ts.map +1 -1
  18. package/dist/permissions/tool-registry.js +10 -3
  19. package/dist/permissions/tool-registry.js.map +1 -1
  20. package/dist/permissions/write-home-validator.d.ts.map +1 -1
  21. package/dist/permissions/write-home-validator.js +23 -3
  22. package/dist/permissions/write-home-validator.js.map +1 -1
  23. package/dist/tempo/client.js +1 -1
  24. package/dist/tempo/client.js.map +1 -1
  25. package/dist/tempo/tools.d.ts.map +1 -1
  26. package/dist/tempo/tools.js +75 -23
  27. package/dist/tempo/tools.js.map +1 -1
  28. package/dist/utils/buffer-tools.d.ts +10 -0
  29. package/dist/utils/buffer-tools.d.ts.map +1 -1
  30. package/dist/utils/buffer-tools.js +139 -28
  31. package/dist/utils/buffer-tools.js.map +1 -1
  32. package/dist/utils/content-buffer.d.ts +5 -1
  33. package/dist/utils/content-buffer.d.ts.map +1 -1
  34. package/dist/utils/content-buffer.js +6 -3
  35. package/dist/utils/content-buffer.js.map +1 -1
  36. package/dist/utils/jicon-help.d.ts +1 -1
  37. package/dist/utils/jicon-help.d.ts.map +1 -1
  38. package/dist/utils/jicon-help.js +158 -78
  39. package/dist/utils/jicon-help.js.map +1 -1
  40. package/dist/utils/plantuml/client.d.ts +15 -1
  41. package/dist/utils/plantuml/client.d.ts.map +1 -1
  42. package/dist/utils/plantuml/client.js +56 -3
  43. package/dist/utils/plantuml/client.js.map +1 -1
  44. package/dist/utils/plantuml/include-expander.d.ts +15 -0
  45. package/dist/utils/plantuml/include-expander.d.ts.map +1 -1
  46. package/dist/utils/plantuml/include-expander.js +47 -8
  47. package/dist/utils/plantuml/include-expander.js.map +1 -1
  48. package/dist/utils/plantuml/index.d.ts +1 -1
  49. package/dist/utils/plantuml/index.d.ts.map +1 -1
  50. package/dist/utils/plantuml/index.js +1 -1
  51. package/dist/utils/plantuml/index.js.map +1 -1
  52. package/dist/utils/plantuml/service.d.ts +1 -1
  53. package/dist/utils/plantuml/service.d.ts.map +1 -1
  54. package/dist/utils/plantuml/service.js +1 -1
  55. package/dist/utils/plantuml/service.js.map +1 -1
  56. package/dist/utils/plantuml/tools.d.ts.map +1 -1
  57. package/dist/utils/plantuml/tools.js +5 -2
  58. package/dist/utils/plantuml/tools.js.map +1 -1
  59. package/dist/utils/response-formatter.d.ts +13 -0
  60. package/dist/utils/response-formatter.d.ts.map +1 -1
  61. package/dist/utils/response-formatter.js +25 -0
  62. package/dist/utils/response-formatter.js.map +1 -1
  63. package/dist/utils/url-tools.d.ts +27 -1
  64. package/dist/utils/url-tools.d.ts.map +1 -1
  65. package/dist/utils/url-tools.js +142 -1
  66. package/dist/utils/url-tools.js.map +1 -1
  67. package/dist/utils/xhtml/index.d.ts +1 -1
  68. package/dist/utils/xhtml/index.d.ts.map +1 -1
  69. package/dist/utils/xhtml/index.js +1 -1
  70. package/dist/utils/xhtml/index.js.map +1 -1
  71. package/dist/utils/xhtml/plantuml.d.ts +24 -6
  72. package/dist/utils/xhtml/plantuml.d.ts.map +1 -1
  73. package/dist/utils/xhtml/plantuml.js +70 -12
  74. package/dist/utils/xhtml/plantuml.js.map +1 -1
  75. package/dist/utils/xhtml/types.d.ts +1 -0
  76. package/dist/utils/xhtml/types.d.ts.map +1 -1
  77. package/dist/utils/xhtml/validator.js +2 -2
  78. package/dist/utils/xhtml/validator.js.map +1 -1
  79. package/package.json +2 -2
package/TOOL_LIST.md CHANGED
@@ -5,24 +5,24 @@ This document provides a comprehensive reference of all available tools in the J
5
5
 
6
6
  ## Summary
7
7
 
8
- **Total Tools**: 64
8
+ **Total Tools**: 69
9
9
  - **Jira Tools**: 18 (13 read + 5 write)
10
- - **Confluence Tools**: 17 (11 read + 6 write)
10
+ - **Confluence Tools**: 21 (13 read + 8 write)
11
11
  - **Tempo Tools**: 12 (9 read + 3 write)
12
12
  - **Buffer Tools**: 10
13
13
  - **Workload Tools**: 2
14
- - **URL Tools**: 1
14
+ - **URL Tools**: 2
15
15
  - **Jicon Help Tools**: 1
16
16
  - **PlantUML Tools**: 3
17
17
 
18
- **Note**: Tools that return large content use in-memory buffering with pagination support. See the Buffer Tools section for content retrieval.
18
+ **Note**: All data-heavy tools (search, list, get) **always** return buffered responses with metadata for origin tracking. Use `buffer_get_chunk` to read and `buffer_grep` to search. See the Buffer Tools section for details.
19
19
 
20
20
  ---
21
21
 
22
22
  ## Jira Tools (18)
23
23
 
24
24
  ### 1. jira_search_issues
25
- **Description**: Search for Jira issues using JQL. Auto-fetches all results (up to 5000).
25
+ **Description**: Search for Jira issues using JQL. Auto-fetches all results.
26
26
  **Use Cases**: Find bugs, filter by status, search by assignee, complex queries
27
27
 
28
28
  | Parameter | Type | Required | Description |
@@ -30,7 +30,7 @@ This document provides a comprehensive reference of all available tools in the J
30
30
  | jql | string | ✓ | JQL query string |
31
31
  | fields | string[] | ✗ | Specific fields to return |
32
32
 
33
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
33
+ **Returns**: `bufferId` with metadata `{resourceType: "jira_search", title: "JQL: ..."}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
34
34
 
35
35
  ---
36
36
 
@@ -44,7 +44,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
44
44
  | fields | string[] | ✗ | Specific fields to return |
45
45
  | expand | string[] | ✗ | Additional data (e.g., "changelog", "renderedFields") |
46
46
 
47
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
47
+ **Returns**: `bufferId` with metadata `{resourceType: "jira_issue", title: "PROJ-123: Summary", issueId, projectKey}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
48
48
 
49
49
  ---
50
50
 
@@ -112,7 +112,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
112
112
  | issueKey | string | ✓ | Issue key |
113
113
  | orderBy | string | ✗ | Sort order ("created" or "-created") |
114
114
 
115
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
115
+ **Returns**: `bufferId` with metadata `{resourceType: "jira_comments", title: "PROJ-123 comments", issueKey}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
116
116
 
117
117
  ---
118
118
 
@@ -125,6 +125,8 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
125
125
  | recent | boolean | ✗ | Only recent projects |
126
126
  | expand | string[] | ✗ | Additional data to expand |
127
127
 
128
+ **Returns**: `bufferId` with metadata `{resourceType: "jira_projects", title: "All Projects"}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
129
+
128
130
  ---
129
131
 
130
132
  ### 9. jira_get_project
@@ -136,6 +138,8 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
136
138
  | projectKey | string | ✓ | Project key |
137
139
  | expand | string[] | ✗ | Additional data to expand |
138
140
 
141
+ **Returns**: `bufferId` with metadata `{resourceType: "jira_project", title: "Project Name", projectKey}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
142
+
139
143
  ---
140
144
 
141
145
  ### 10. jira_get_issue_types
@@ -181,6 +185,8 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
181
185
  |-----------|------|----------|-------------|
182
186
  | boardId | number | ✓ | Board ID |
183
187
 
188
+ **Returns**: `bufferId` with metadata `{resourceType: "jira_board", title: "Board Name", boardId}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
189
+
184
190
  ---
185
191
 
186
192
  ### 14. jira_get_sprints
@@ -192,7 +198,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
192
198
  | boardId | number | ✓ | Board ID |
193
199
  | state | string | ✗ | Sprint state ("active", "future", "closed") |
194
200
 
195
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
201
+ **Returns**: `bufferId` with metadata `{resourceType: "jira_sprints", title: "Board #123 sprints", boardId}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
196
202
 
197
203
  ---
198
204
 
@@ -204,7 +210,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
204
210
  |-----------|------|----------|-------------|
205
211
  | sprintId | number | ✓ | Sprint ID |
206
212
 
207
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
213
+ **Returns**: `bufferId` with metadata `{resourceType: "jira_sprint_issues", title: "Sprint #456 issues", sprintId}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
208
214
 
209
215
  ---
210
216
 
@@ -226,9 +232,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
226
232
  |-----------|------|----------|-------------|
227
233
  | issueKey | string | ✓ | Issue key (e.g., PROJ-123) |
228
234
 
229
- **Response includes**: `worklogCount`, `totalTimeSpentSeconds`, `totalTimeSpent`, `worklogs`
230
-
231
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
235
+ **Returns**: `bufferId` with metadata `{resourceType: "jira_worklogs", title: "PROJ-123 worklogs", issueKey}`. Includes `worklogCount`, `totalTimeSpentSeconds`, `totalTimeSpent`, `worklogs`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
232
236
 
233
237
  ---
234
238
 
@@ -240,17 +244,14 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
240
244
  |-----------|------|----------|-------------|
241
245
  | issueKey | string | ✓ | Issue key (e.g., PROJ-123) |
242
246
 
243
- **Response includes**: Breakdown by issue and grand total including:
244
- - The specified issue
245
- - All sub-tasks
246
- - All issues in the Epic (if the issue is an Epic)
247
+ **Returns**: `bufferId` with metadata `{resourceType: "jira_worklogs_total", title: "PROJ-123 total worklogs (recursive)", issueKey}`. Includes breakdown by issue and grand total for the issue, sub-tasks, and Epic children.
247
248
 
248
249
  ---
249
250
 
250
- ## Confluence Tools (17)
251
+ ## Confluence Tools (21)
251
252
 
252
253
  ### 1. confluence_search_content
253
- **Description**: Search Confluence content using CQL. Auto-fetches all results (up to 5000).
254
+ **Description**: Search Confluence content using CQL. Auto-fetches all results.
254
255
  **Use Cases**: Find pages, search by keyword, filter by space
255
256
 
256
257
  | Parameter | Type | Required | Description |
@@ -258,7 +259,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
258
259
  | cql | string | ✓ | CQL query string |
259
260
  | expand | string[] | ✗ | Additional data to expand |
260
261
 
261
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
262
+ **Returns**: `bufferId` with metadata `{resourceType: "confluence_search", title: "CQL: ..."}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
262
263
 
263
264
  ---
264
265
 
@@ -273,7 +274,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
273
274
 
274
275
  **Response includes**: `pageId`, `version`, `bufferId`, `contentSize`, metadata
275
276
 
276
- **Usage**: Content is stored in buffer with `contentType: "xhtml"` and returns `structure` with element IDs. Use `buffer_edit` with element IDs to modify, then `confluence_draft_create` for user review.
277
+ **Usage**: Content is stored in buffer with `contentType: "xhtml"` and returns `structure` with element IDs. Use `buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId)` to add content, then `confluence_draft_create(pageId, bufferId)` for user review.
277
278
 
278
279
  ---
279
280
 
@@ -289,18 +290,61 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
289
290
 
290
291
  **Response includes**: `pageId`, `version`, `bufferId`, `contentSize`, metadata
291
292
 
292
- **Usage**: Content is stored in buffer with `contentType: "xhtml"` and returns `structure` with element IDs. Use `buffer_edit` with element IDs to modify, then `confluence_draft_create` for user review.
293
+ **Usage**: Content is stored in buffer with `contentType: "xhtml"` and returns `structure` with element IDs. Use `buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId)` to add content, then `confluence_draft_create(pageId, bufferId)` for user review.
294
+
295
+ ---
296
+
297
+ ### 4. confluence_edit (RECOMMENDED)
298
+ **Description**: Smart page/draft loader - auto-resolves URLs, pageIds, draftIds, or SPACE/Title
299
+ **Use Cases**: Edit any Confluence content with a single tool, handle URL input from users
300
+
301
+ | Parameter | Type | Required | Description |
302
+ |-----------|------|----------|-------------|
303
+ | input | string | ✓ | URL, pageId, "draft:ID", or "SPACE/Title" |
304
+
305
+ **Input formats supported**:
306
+ | Input | Behavior |
307
+ |-------|----------|
308
+ | `https://confluence.example.com/pages/viewpage.action?pageId=123` | Parse URL, load page |
309
+ | `https://confluence.example.com/pages/resumedraft.action?draftId=456` | Parse URL, try draft (fallback to page) |
310
+ | `https://confluence.example.com/display/DOCS/Page+Title` | Parse URL, find by space/title |
311
+ | `123456` (numeric) | Load page directly by ID |
312
+ | `draft:123456` | Try draft; if 404 (published), find page by title |
313
+ | `DOCS/API Guide` | Find page by space key and title |
314
+
315
+ **Response includes**: `bufferId`, `structure`, `pageId` or `draftId`, `spaceKey`, `title`
316
+
317
+ **Smart behavior**:
318
+ - URLs are parsed automatically to extract pageId or draftId
319
+ - Draft IDs: tries to load draft; if 404 (user published), finds page by title
320
+ - Returns bufferId + structure for editing
321
+
322
+ **Workflow**:
323
+ ```
324
+ 1. confluence_edit("URL or SPACE/Title") → bufferId, structure, pageId
325
+ 2. buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId) → add content
326
+ 3. confluence_draft_create(pageId=..., bufferId=...) → draft for review (links to original page)
327
+ 4. User publishes via Confluence UI (updates original page)
328
+ 5. For more edits: confluence_edit(same input) → auto-resolves
329
+ ```
330
+
331
+ **TIP**: If you created content in a separate buffer, use `fromBufferId` to merge it:
332
+ ```
333
+ buffer_edit(bufferId=pageBuffer, after=5, fromBufferId=newContentBuffer)
334
+ ```
293
335
 
294
336
  ---
295
337
 
296
338
  > **Note**: All page content changes go through the draft workflow.
297
339
  > AI creates/edits drafts; user publishes manually via Confluence UI:
298
- > - New pages: `confluence_draft_create` → user review → user publishes
299
- > - Existing pages: `confluence_get_page` → edit → `confluence_draft_create` user review → user publishes
340
+ > - **Edit existing**: `confluence_edit(input)` → `buffer_edit(bufferId, ...)``buffer_validate_xhtml(bufferId)` → `confluence_draft_create(pageId, bufferId)` → user publishes
341
+ > - **Create new**: `buffer_create(content, contentType="xhtml")` → `buffer_validate_xhtml(bufferId)` → `confluence_draft_create(spaceKey, title, bufferId)` → user publishes
342
+ > - **After publish**: Draft ID becomes invalid; use `confluence_edit("SPACE/Title")` to edit again
343
+ > - **XHTML syntax**: Call `help(topic="storage")` for HTML vs XHTML differences
300
344
 
301
345
  ---
302
346
 
303
- ### 4. confluence_delete_page
347
+ ### 5. confluence_delete_page
304
348
  **Description**: Delete a Confluence page
305
349
  **Use Cases**: Remove outdated content
306
350
 
@@ -310,7 +354,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
310
354
 
311
355
  ---
312
356
 
313
- ### 5. confluence_list_spaces
357
+ ### 6. confluence_list_spaces
314
358
  **Description**: List all accessible Confluence spaces
315
359
  **Use Cases**: Discover available spaces, get space keys
316
360
 
@@ -318,11 +362,11 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
318
362
  |-----------|------|----------|-------------|
319
363
  | type | string | ✗ | Space type filter ("global" or "personal") |
320
364
 
321
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
365
+ **Returns**: `bufferId` with metadata `{resourceType: "confluence_spaces", title: "All Spaces"}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
322
366
 
323
367
  ---
324
368
 
325
- ### 6. confluence_get_space
369
+ ### 7. confluence_get_space
326
370
  **Description**: Get detailed information about a space
327
371
  **Use Cases**: View space details, get homepage
328
372
 
@@ -331,9 +375,11 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
331
375
  | spaceKey | string | ✓ | Space key |
332
376
  | expand | string[] | ✗ | Additional data to expand |
333
377
 
378
+ **Returns**: `bufferId` with metadata `{resourceType: "confluence_space", title: "Space Name", spaceKey}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
379
+
334
380
  ---
335
381
 
336
- ### 7. confluence_get_page_children
382
+ ### 8. confluence_get_page_children
337
383
  **Description**: Get all child pages of a page
338
384
  **Use Cases**: Navigate page hierarchy, list subpages
339
385
 
@@ -342,11 +388,11 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
342
388
  | pageId | string | ✓ | Parent page ID (accepts string or number) |
343
389
  | expand | string[] | ✗ | Additional data to expand |
344
390
 
345
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
391
+ **Returns**: `bufferId` with metadata `{resourceType: "confluence_page_children", title: "Page 123 children", pageId}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
346
392
 
347
393
  ---
348
394
 
349
- ### 8. confluence_add_comment
395
+ ### 9. confluence_add_comment
350
396
  **Description**: Add a comment to a Confluence page
351
397
  **Use Cases**: Provide feedback, ask questions
352
398
 
@@ -357,7 +403,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
357
403
 
358
404
  ---
359
405
 
360
- ### 9. confluence_get_comments
406
+ ### 10. confluence_get_comments
361
407
  **Description**: Get all comments on a Confluence page
362
408
  **Use Cases**: Read feedback, review discussions
363
409
 
@@ -365,11 +411,11 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
365
411
  |-----------|------|----------|-------------|
366
412
  | pageId | string | ✓ | Page ID (accepts string or number) |
367
413
 
368
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
414
+ **Returns**: `bufferId` with metadata `{resourceType: "confluence_comments", title: "Page 123 comments", pageId}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
369
415
 
370
416
  ---
371
417
 
372
- ### 10. confluence_upload_attachment
418
+ ### 11. confluence_upload_attachment
373
419
  **Description**: Upload an attachment to a Confluence page
374
420
  **Use Cases**: Attach documents, upload images
375
421
 
@@ -381,7 +427,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
381
427
 
382
428
  ---
383
429
 
384
- ### 11. confluence_list_attachments
430
+ ### 12. confluence_list_attachments
385
431
  **Description**: List all attachments on a Confluence page
386
432
  **Use Cases**: View uploaded files, check attachments
387
433
 
@@ -389,11 +435,11 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
389
435
  |-----------|------|----------|-------------|
390
436
  | pageId | string | ✓ | Page ID (accepts string or number) |
391
437
 
392
- Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_grep` to access.
438
+ **Returns**: `bufferId` with metadata `{resourceType: "confluence_attachments", title: "Page 123 attachments", pageId}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
393
439
 
394
440
  ---
395
441
 
396
- ### 12. confluence_get_current_user_space
442
+ ### 13. confluence_get_current_user_space
397
443
  **Description**: Get the current user's personal Confluence space
398
444
  **Use Cases**: Verify personal space before write operations, check space key for write-home restriction
399
445
 
@@ -407,20 +453,19 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
407
453
 
408
454
  ---
409
455
 
410
- ### 13. confluence_draft_list
456
+ ### 14. confluence_draft_list
411
457
  **Description**: List user's draft pages
412
458
  **Use Cases**: View pending drafts, find drafts to continue editing
413
459
 
414
460
  | Parameter | Type | Required | Description |
415
461
  |-----------|------|----------|-------------|
416
462
  | spaceKey | string | ✗ | Filter by space key |
417
- | limit | number | ✗ | Maximum results (default: 25) |
418
463
 
419
- **Response includes**: `drafts` array with `draftId`, `title`, `spaceKey`, `spaceName`, `created`, `url`
464
+ **Returns**: `bufferId` with metadata `{resourceType: "confluence_drafts", title: "All Drafts"}`. Includes `drafts` array with `draftId`, `title`, `spaceKey`, `spaceName`, `created`, `url`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
420
465
 
421
466
  ---
422
467
 
423
- ### 14. confluence_draft_open
468
+ ### 15. confluence_draft_open
424
469
  **Description**: Load existing draft into buffer for editing
425
470
  **Use Cases**: Continue editing a draft, prepare draft for publishing
426
471
 
@@ -430,31 +475,71 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
430
475
 
431
476
  **Response includes**: `draftId`, `bufferId`, `structure` (element IDs), `title`, `spaceKey`, `version`, `url`, `contentPreview`
432
477
 
433
- **Usage**: Content is stored in buffer with element IDs. Use `buffer_edit` with element IDs (e.g., `after=2`, `replace=5`) to modify, then `confluence_draft_save` to checkpoint.
478
+ **Usage**: Content is stored in buffer with element IDs. Use `buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId)` to modify, then `confluence_draft_save` to checkpoint.
434
479
 
435
480
  ---
436
481
 
437
- ### 15. confluence_draft_create
438
- **Description**: Create a new server-side draft with local buffer
439
- **Use Cases**: Start new page as draft, iterative content development
482
+ ### 16. confluence_draft_create
483
+ **Description**: Create a draft for user review - either a new page or as an edit to an existing page
484
+ **Use Cases**: Start new page as draft, edit existing page through draft workflow
440
485
 
441
- | Parameter | Type | Required | Description |
442
- |-----------|------|----------|-------------|
443
- | spaceKey | string | ✓ | Space key |
444
- | title | string | ✓ | Draft title |
445
- | content | string | | Initial content (storage format) |
446
- | parentId | string | | Parent page ID |
447
- | labels | string[] | ✗ | Array of labels |
486
+ **REQUIRES `bufferId`** - content must be in a buffer for validation and error recovery.
487
+
488
+ **Two Modes:**
489
+
490
+ 1. **NEW PAGE**: Create a standalone draft
491
+ | Parameter | Type | Required | Description |
492
+ |-----------|------|----------|-------------|
493
+ | spaceKey | string | ✓ | Space key |
494
+ | title | string | ✓ | Draft title |
495
+ | bufferId | string | ✓ | Buffer ID from `buffer_create(contentType="xhtml")` |
496
+ | parentId | string | ✗ | Parent page ID |
497
+ | labels | string[] | ✗ | Array of labels |
498
+
499
+ 2. **EDIT EXISTING PAGE**: Create a draft to edit an existing page
500
+ | Parameter | Type | Required | Description |
501
+ |-----------|------|----------|-------------|
502
+ | pageId | string | ✓ | Existing page ID to edit |
503
+ | bufferId | string | ✓ | Buffer ID from `confluence_get_page(pageId)` or `confluence_edit(pageId)` |
504
+ | title | string | ✗ | Optional new title (defaults to original) |
505
+
506
+ **Important**: When `pageId` is provided, `bufferId` must originate from that page (validated). Space, title, and parent are auto-populated from the original page.
507
+
508
+ **Response includes**: `draftId`, `bufferId`, `structure` (element IDs), `title`, `spaceKey`, `version`, `url` (clickable to preview), `contentSummary`, `editingExistingPage` (when editing)
448
509
 
449
- **Response includes**: `draftId`, `bufferId`, `structure` (element IDs), `title`, `spaceKey`, `version`, `url` (clickable to preview), `contentSummary`
510
+ **On validation error**: Returns `bufferId`, `errorElementId`, and `errorContext` for surgical fix with `buffer_edit`.
450
511
 
451
512
  **PlantUML**: Raw @startuml blocks are not supported. Use `buffer_edit` with `plantuml` parameter.
452
513
 
453
- **Workflow**: Create draft returns `structure` with element IDs → Click URL to preview → Use `buffer_edit` with element IDs (e.g., `after=2`) → Use `confluence_draft_save` to checkpoint
514
+ **Workflow for new page (buffer-first)**:
515
+ ```
516
+ 1. buffer_create(content="<h1>Title</h1><p>Content</p>", contentType="xhtml")
517
+ → bufferId, structure (element IDs)
518
+ 2. buffer_validate_xhtml(bufferId)
519
+ → If errors: buffer_edit(bufferId, replace=errorElementId, content="<fixed>")
520
+ 3. confluence_draft_create(spaceKey, title, bufferId)
521
+ → draftId, url for preview
522
+ 4. User reviews and publishes via Confluence UI
523
+ ```
524
+
525
+ **Workflow for editing existing page**:
526
+ ```
527
+ 1. confluence_get_page(pageId) or confluence_edit(input)
528
+ → bufferId, structure
529
+ 2. buffer_edit(bufferId, after=ID, content/plantuml)
530
+ → modify content
531
+ 3. buffer_validate_xhtml(bufferId)
532
+ → check for errors
533
+ 4. confluence_draft_create(pageId=..., bufferId=...)
534
+ → draft for review
535
+ 5. User reviews and publishes in Confluence UI (updates original page)
536
+ ```
537
+
538
+ **Why buffer-first?** Enables validation with element IDs for surgical error fixing. Call `help(topic="storage")` for XHTML syntax (HTML vs XHTML differences).
454
539
 
455
540
  ---
456
541
 
457
- ### 16. confluence_draft_save
542
+ ### 17. confluence_draft_save
458
543
  **Description**: Save buffer content to draft (delete + recreate pattern)
459
544
  **Use Cases**: Checkpoint work, persist edits before publishing
460
545
 
@@ -472,7 +557,7 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
472
557
 
473
558
  ---
474
559
 
475
- ### 17. confluence_draft_delete
560
+ ### 18. confluence_draft_delete
476
561
  **Description**: Permanently delete a draft
477
562
  **Use Cases**: Clean up abandoned drafts, remove unwanted content
478
563
 
@@ -484,6 +569,54 @@ Large responses are automatically buffered - use `buffer_get_chunk` or `buffer_g
484
569
 
485
570
  ---
486
571
 
572
+ ### 19. confluence_review_list
573
+ **Description**: List all "[jicon-mcp REVIEW]" drafts for cleanup or management
574
+ **Use Cases**: Find abandoned review drafts, manage multiple review workflows, clean up after publishing
575
+
576
+ | Parameter | Type | Required | Description |
577
+ |-----------|------|----------|-------------|
578
+ | spaceKey | string | ✗ | Filter by space key |
579
+
580
+ **Response includes**: `reviewDrafts` array with `reviewDraftId`, `title`, `originalTitle`, `originalPageId`, `spaceKey`, `spaceName`, `createdDate`, `editUrl`; `total`, `message`
581
+
582
+ **Note**: Review drafts are created when using `confluence_draft_create` with a `pageId` parameter to edit an existing page. They are linked to the original page via a label.
583
+
584
+ ---
585
+
586
+ ### 20. confluence_review_publish
587
+ **Description**: Publish a review draft to apply changes to the original page
588
+ **Use Cases**: Apply reviewed changes to the original page, complete the review workflow
589
+
590
+ | Parameter | Type | Required | Description |
591
+ |-----------|------|----------|-------------|
592
+ | reviewDraftId | string | ✓ | ID of the [jicon-mcp REVIEW] draft to publish |
593
+
594
+ **Workflow**:
595
+ 1. Validates the draft is a "[jicon-mcp REVIEW]" draft with proper label
596
+ 2. Copies the draft content to the original page (creates new version)
597
+ 3. Deletes the review draft
598
+
599
+ **Response includes**: `success`, `originalPageId`, `originalTitle`, `newVersion`, `reviewDraftDeleted`, `viewUrl`, `message`
600
+
601
+ ---
602
+
603
+ ### 21. confluence_review_discard
604
+ **Description**: Discard a review draft without applying changes to the original page
605
+ **Use Cases**: Cancel a review, abandon changes, clean up unwanted review drafts
606
+
607
+ | Parameter | Type | Required | Description |
608
+ |-----------|------|----------|-------------|
609
+ | reviewDraftId | string | ✓ | ID of the [jicon-mcp REVIEW] draft to discard |
610
+
611
+ **Workflow**:
612
+ 1. Validates the draft is a "[jicon-mcp REVIEW]" draft
613
+ 2. Deletes the review draft permanently
614
+ 3. Original page remains unchanged
615
+
616
+ **Response includes**: `success`, `discarded`, `reviewDraftId`, `originalTitle`, `message`
617
+
618
+ ---
619
+
487
620
  ## Query Language Reference
488
621
 
489
622
  ### JQL (Jira Query Language) Examples
@@ -600,7 +733,9 @@ AND lastModified >= now("-30d")
600
733
  | issueKey | string | ✗ | Filter by issue key (e.g., PROJ-123) |
601
734
  | workerKey | string | ✗ | Filter by worker username (get from tempo_get_user_info). Leave empty for ALL worklogs. |
602
735
 
603
- **WARNING**: No workerKey = returns ALL worklogs. Large responses are buffered.
736
+ **WARNING**: No workerKey = returns ALL worklogs.
737
+
738
+ **Returns**: `bufferId` with metadata `{resourceType: "tempo_worklogs", title: "Worklogs 2024-01-01 to 2024-01-31"}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
604
739
 
605
740
  ---
606
741
 
@@ -612,6 +747,8 @@ AND lastModified >= now("-30d")
612
747
  |-----------|------|----------|-------------|
613
748
  | worklogId | number | ✓ | Tempo worklog ID |
614
749
 
750
+ **Returns**: `bufferId` with metadata `{resourceType: "tempo_worklog", title: "PROJ-123 worklog #456", resourceId, issueKey}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
751
+
615
752
  ---
616
753
 
617
754
  ### 3. tempo_log_work
@@ -660,6 +797,8 @@ AND lastModified >= now("-30d")
660
797
  |-----------|------|----------|-------------|
661
798
  | (none) | | | |
662
799
 
800
+ **Returns**: `bufferId` with metadata `{resourceType: "tempo_accounts", title: "All Tempo Accounts"}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
801
+
663
802
  ---
664
803
 
665
804
  ### 7. tempo_get_account
@@ -670,6 +809,8 @@ AND lastModified >= now("-30d")
670
809
  |-----------|------|----------|-------------|
671
810
  | accountKey | string | ✓ | Account key |
672
811
 
812
+ **Returns**: `bufferId` with metadata `{resourceType: "tempo_account", title: "Account Name", accountKey}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
813
+
673
814
  ---
674
815
 
675
816
  ### 8. tempo_get_teams
@@ -680,6 +821,8 @@ AND lastModified >= now("-30d")
680
821
  |-----------|------|----------|-------------|
681
822
  | (none) | | | |
682
823
 
824
+ **Returns**: `bufferId` with metadata `{resourceType: "tempo_teams", title: "All Tempo Teams"}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
825
+
683
826
  ---
684
827
 
685
828
  ### 9. tempo_get_team
@@ -690,6 +833,8 @@ AND lastModified >= now("-30d")
690
833
  |-----------|------|----------|-------------|
691
834
  | teamId | number | ✓ | Team ID |
692
835
 
836
+ **Returns**: `bufferId` with metadata `{resourceType: "tempo_team", title: "Team Name", teamId}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
837
+
693
838
  ---
694
839
 
695
840
  ### 10. tempo_get_team_worklogs
@@ -702,7 +847,7 @@ AND lastModified >= now("-30d")
702
847
  | dateFrom | string | ✓ | Start date (YYYY-MM-DD) |
703
848
  | dateTo | string | ✓ | End date (YYYY-MM-DD) |
704
849
 
705
- Large responses are buffered - use `buffer_get_chunk` or `buffer_grep` to access.
850
+ **Returns**: `bufferId` with metadata `{resourceType: "tempo_team_worklogs", title: "Team #123 worklogs 2024-01-01 to 2024-01-31", teamId}`. Use `buffer_get_chunk` to read, `buffer_grep` to search.
706
851
 
707
852
  ---
708
853
 
@@ -728,9 +873,7 @@ Large responses are buffered - use `buffer_get_chunk` or `buffer_grep` to access
728
873
  | dateFrom | string | ✗ | Start date filter (YYYY-MM-DD) |
729
874
  | dateTo | string | ✗ | End date filter (YYYY-MM-DD) |
730
875
 
731
- **Response includes**: `totalTimeSpent`, `totalWorklogCount`, `issueCount`, breakdown by issue, and full worklog list.
732
-
733
- More efficient than `jira_get_total_worklogs` for Tempo instances. Large responses are buffered.
876
+ **Returns**: `bufferId` with metadata `{resourceType: "tempo_epic_worklogs", title: "PROJ-100 epic worklogs", epicKey}`. Includes `totalTimeSpent`, `totalWorklogCount`, `issueCount`, breakdown by issue, and full worklog list. Use `buffer_get_chunk` to read, `buffer_grep` to search. More efficient than `jira_get_total_worklogs` for Tempo instances.
734
877
 
735
878
  ---
736
879
 
@@ -766,17 +909,16 @@ Buffer tools are used for local content management. All buffer operations are in
766
909
  // 4. User publishes via Confluence UI (click "Publish" button)
767
910
  ```
768
911
 
769
- **Multi-diagram optimization**: Embed PlantUML macros directly in initial content:
912
+ **Multi-diagram workflow**: Use batch operations with plantuml parameter:
770
913
  ```typescript
771
- // 1. plantuml_validate(...) for each diagram (can run in parallel)
772
- // 2. buffer_create({ contentType: "xhtml", content: `
773
- // <h1>Design</h1>
774
- // <ac:structured-macro ac:name="plantuml" ac:schema-version="1" ac:macro-id="d1">
775
- // <ac:parameter ac:name="atlassian-macro-output-type">INLINE</ac:parameter>
776
- // <ac:plain-text-body><![CDATA[@startuml...@enduml]]></ac:plain-text-body>
777
- // </ac:structured-macro>` })
914
+ // 1. buffer_create({ contentType: "xhtml", content: "<h1>Design</h1><p>Introduction</p>" })
915
+ // 2. buffer_edit({ bufferId, operations: [
916
+ // { after: 1, plantuml: "@startuml\nA -> B\n@enduml" },
917
+ // { after: 2, plantuml: "@startuml\nclass User\n@enduml" }
918
+ // ]})
919
+ // -> All PlantUML validated in batch before any changes, rolled back on error
778
920
  // 3. confluence_draft_create({ spaceKey, title, bufferId })
779
- // Saves tool calls vs placeholder-then-edit pattern. See help(topic="plantuml").
921
+ // NOTE: Embedding PlantUML macros directly in content is NOT allowed - use plantuml parameter.
780
922
  ```
781
923
 
782
924
  ---
@@ -871,7 +1013,7 @@ buffer_get_element({
871
1013
 
872
1014
  ### 7. buffer_edit
873
1015
  **Description**: Edit buffer content. For XHTML: use element IDs (single or batch). For plain/json: use string replacement.
874
- **Use Cases**: Insert/replace/remove elements in Confluence pages, modify Jira/Tempo content
1016
+ **Use Cases**: Insert/replace/remove elements in Confluence pages, modify Jira/Tempo content, compose content from multiple buffers
875
1017
 
876
1018
  **XHTML Parameters (single operation):**
877
1019
 
@@ -883,15 +1025,18 @@ buffer_get_element({
883
1025
  | replace | number | ✗ | Replace element with this ID |
884
1026
  | remove | number | ✗ | Remove element with this ID |
885
1027
  | append | boolean | ✗ | Append at document end |
886
- | content | string | ✗ | XHTML content to insert/replace |
887
- | plantuml | string | ✗ | PlantUML code (auto-wrapped in macro, validated) |
1028
+ | content | string | ✗ | XHTML content to insert/replace (**NO PlantUML macros allowed**) |
1029
+ | plantuml | string | ✗ | PlantUML code (**REQUIRED** for diagrams - auto-validated and wrapped) |
1030
+ | fromBufferId | string | ✗ | Insert content from another buffer (useful for composing content) |
1031
+
1032
+ **IMPORTANT**: The `content` parameter **rejects** PlantUML macros. All PlantUML must use the `plantuml` parameter for mandatory validation.
888
1033
 
889
1034
  **XHTML Batch Operations (multiple edits in one call):**
890
1035
 
891
1036
  | Parameter | Type | Required | Description |
892
1037
  |-----------|------|----------|-------------|
893
1038
  | bufferId | string | ✓ | Buffer ID to modify |
894
- | operations | array | ✓ | Array of `{after?, before?, replace?, append?, remove?, content?, plantuml?}` |
1039
+ | operations | array | ✓ | Array of `{after?, before?, replace?, append?, remove?, content?, plantuml?, fromBufferId?}` |
895
1040
 
896
1041
  **Batch operations** are executed sequentially, stopping on first error. Much more efficient than multiple tool calls (parse once, serialize once).
897
1042
 
@@ -920,14 +1065,15 @@ buffer_edit({
920
1065
  // Returns: { success: true, insertedIds: [5], structure: [...], nextId: 6 }
921
1066
  ```
922
1067
 
923
- **Example - Insert PlantUML diagram:**
1068
+ **Example - Insert PlantUML diagram (REQUIRED method):**
924
1069
  ```typescript
925
1070
  buffer_edit({
926
1071
  bufferId: "buf_xxx",
927
1072
  after: 3,
928
1073
  plantuml: "@startuml\nA -> B: message\n@enduml"
929
1074
  })
930
- // Automatically validates and wraps in Confluence macro
1075
+ // Automatically validates syntax, rejects invalid code, and wraps in Confluence macro
1076
+ // NOTE: Using content parameter with PlantUML macros will be REJECTED
931
1077
  ```
932
1078
 
933
1079
  **Example - Batch operations (EFFICIENT for multiple diagrams):**
@@ -962,6 +1108,31 @@ buffer_edit({
962
1108
  })
963
1109
  ```
964
1110
 
1111
+ **Example - Insert content from another buffer (buffer composition):**
1112
+ ```typescript
1113
+ // EDITING EXISTING PAGES: When you have created content in a separate buffer
1114
+ // and want to insert it into the page's buffer:
1115
+
1116
+ // 1. Load existing page
1117
+ confluence_edit("https://confluence.example.com/pages/viewpage.action?pageId=123")
1118
+ // -> returns bufferId_A (page content), pageId
1119
+
1120
+ // 2. Create new content in a separate buffer
1121
+ buffer_create({ content: "<p>New content to add</p>", contentType: "xhtml" })
1122
+ // -> returns bufferId_B
1123
+
1124
+ // 3. Insert bufferId_B's content into bufferId_A
1125
+ buffer_edit({
1126
+ bufferId: "buf_A",
1127
+ after: 5, // Insert after element 5 in the page
1128
+ fromBufferId: "buf_B" // Takes content from this buffer
1129
+ })
1130
+
1131
+ // 4. Create draft linked to original page
1132
+ confluence_draft_create({ pageId: "123", bufferId: "buf_A" })
1133
+ // -> Works! bufferId_A originated from pageId 123
1134
+ ```
1135
+
965
1136
  ---
966
1137
 
967
1138
  ### 8. buffer_get_structure
@@ -1081,9 +1252,9 @@ Utility tools for time calculations. Always available with any Jira, Confluence,
1081
1252
 
1082
1253
  ---
1083
1254
 
1084
- ## URL Tools (1)
1255
+ ## URL Tools (2)
1085
1256
 
1086
- Utility tools for URL construction. Always available with any Jira, Confluence, or Tempo action.
1257
+ Utility tools for URL construction and parsing. Always available with any Jira, Confluence, or Tempo action.
1087
1258
 
1088
1259
  ### 1. fullurl
1089
1260
  **Description**: Convert Jira issue keys, Confluence page IDs, or relative paths into full URLs
@@ -1114,6 +1285,35 @@ fullurl("/display/DOCS/Home") // → https://confluence.example.com/display/DOCS
1114
1285
 
1115
1286
  ---
1116
1287
 
1288
+ ### 2. parseurl
1289
+ **Description**: Parse a Jira or Confluence URL to extract identifiers (pageId, issueKey, draftId, etc.)
1290
+ **Use Cases**: Extract IDs from URLs users share, prepare input for other tools
1291
+
1292
+ | Parameter | Type | Required | Description |
1293
+ |-----------|------|----------|-------------|
1294
+ | url | string | ✓ | Full URL to parse (Jira or Confluence) |
1295
+
1296
+ **Supported URL formats**:
1297
+ | URL Pattern | Extracted Fields |
1298
+ |-------------|------------------|
1299
+ | `https://jira.example.com/browse/PROJ-123` | `{type: "jira_issue", issueKey: "PROJ-123"}` |
1300
+ | `https://confluence.example.com/pages/viewpage.action?pageId=123` | `{type: "confluence_page", pageId: "123"}` |
1301
+ | `https://confluence.example.com/pages/resumedraft.action?draftId=456` | `{type: "confluence_draft", draftId: "456"}` |
1302
+ | `https://confluence.example.com/display/SPACE/Page+Title` | `{type: "confluence_space_path", spaceKey: "SPACE", title: "Page Title"}` |
1303
+ | `https://confluence.example.com/spaces/SPACE/pages/123/Title` | `{type: "confluence_page", pageId: "123", spaceKey: "SPACE", title: "Title"}` |
1304
+
1305
+ **Response includes**: `url`, `type`, and extracted fields (`issueKey`, `pageId`, `draftId`, `spaceKey`, `title`)
1306
+
1307
+ **Workflow**:
1308
+ ```
1309
+ 1. parseurl(url) → extract identifier
1310
+ 2. Use extracted ID with appropriate tool (jira_get_issue, confluence_get_page, confluence_edit, etc.)
1311
+ ```
1312
+
1313
+ **Tip**: `confluence_edit` can accept URLs directly and parses them internally, so you can often skip `parseurl` for Confluence workflows.
1314
+
1315
+ ---
1316
+
1117
1317
  ## Jicon Help Tools (1)
1118
1318
 
1119
1319
  Unified help system for all Jicon workflows and syntax guides. Always available with any Jira, Confluence, or Tempo action.
@@ -1251,28 +1451,37 @@ When using Jicon with AI assistants (Claude, GPT, etc.), follow these patterns f
1251
1451
 
1252
1452
  ### Content Buffering
1253
1453
 
1254
- Tools that return large content (Confluence pages, Jira issues, Tempo worklogs) use an in-memory buffering system for efficient content pagination.
1454
+ All data-heavy tools (search, list, get) **always** return buffered responses with metadata for origin tracking.
1455
+
1456
+ **Response Format:**
1457
+ ```json
1458
+ {
1459
+ "bufferId": "buf_abc123",
1460
+ "metadata": {
1461
+ "resourceType": "jira_search",
1462
+ "title": "JQL: project = PROJ AND status = 'In Progress'"
1463
+ },
1464
+ "totalSize": 125000,
1465
+ "hint": "Use buffer_get_chunk(bufferId) to read, buffer_grep(bufferId, pattern) to search"
1466
+ }
1467
+ ```
1255
1468
 
1256
- **How It Works:**
1257
- 1. **Initial Call**: When you call a tool like `confluence_get_page`, it fetches the full content and stores it in a buffer
1258
- 2. **Chunked Response**: The response includes a `bufferId`, the first chunk of content (default 5000 chars), and pagination info
1259
- 3. **Retrieve More**: Use `buffer_get_chunk` with the `bufferId` to get subsequent chunks
1469
+ **Metadata Fields:**
1470
+ - `resourceType`: Type of resource (e.g., `jira_issue`, `confluence_page`, `tempo_worklogs`)
1471
+ - `title`: Human-readable description of the buffered content origin
1260
1472
 
1261
- **Buffered Response Format:**
1262
- - `bufferId`: Unique identifier for retrieving more content
1263
- - `content`: The current chunk of content
1264
- - `offset`: Starting position of this chunk
1265
- - `limit`: Maximum characters returned
1266
- - `totalSize`: Total size of buffered content
1267
- - `hasMore`: Whether more content is available
1473
+ **Working with Buffers:**
1474
+ - `buffer_get_chunk(bufferId, offset, limit)` - Read data in chunks
1475
+ - `buffer_grep(bufferId, pattern)` - Search within buffered data
1476
+ - `buffer_list()` - List all active buffers with their metadata
1268
1477
 
1269
- **Auto-Buffered Tools:**
1270
- - `confluence_get_page`, `confluence_get_page_by_title`
1271
- - `jira_get_issue`, `jira_search_issues`
1272
- - `tempo_get_worklogs`, `tempo_get_team_worklogs`
1478
+ **Always-Buffered Tools:**
1479
+ - **Jira**: `jira_search_issues`, `jira_get_issue`, `jira_list_projects`, `jira_get_project`, `jira_get_board`, `jira_get_sprints`, `jira_get_sprint_issues`, `jira_get_issue_comments`, `jira_get_issue_worklogs`, `jira_get_total_worklogs`
1480
+ - **Confluence**: `confluence_search_content`, `confluence_list_spaces`, `confluence_get_space`, `confluence_get_page_children`, `confluence_get_comments`, `confluence_list_attachments`, `confluence_draft_list`
1481
+ - **Tempo**: `tempo_get_worklogs`, `tempo_get_worklog`, `tempo_get_accounts`, `tempo_get_account`, `tempo_get_teams`, `tempo_get_team`, `tempo_get_team_worklogs`, `tempo_get_epic_worklogs`
1273
1482
 
1274
1483
  **Buffer Management:**
1275
- - **TTL**: Buffers expire after 10 minutes by default; edited buffers reset to 1 day TTL
1484
+ - **TTL**: Buffers expire after 1 hour by default; edited buffers reset to 1 day TTL
1276
1485
  - **List Buffers**: Use `buffer_list` to see active buffers
1277
1486
  - **Clear Buffers**: Use `buffer_clear` to free memory
1278
1487
 
@@ -1282,19 +1491,26 @@ Tools that return large content (Confluence pages, Jira issues, Tempo worklogs)
1282
1491
  1. `confluence_draft_create` → creates server draft + buffer with `structure` (element IDs), returns clickable preview URL
1283
1492
  2. User clicks URL to review draft in Confluence UI (can edit there)
1284
1493
  3. If changes needed: `confluence_draft_open` → re-reads user's edits into buffer with updated structure
1285
- 4. `buffer_edit` → edit using element IDs (e.g., `after=2`, `replace=5`, `plantuml="..."`)
1494
+ 4. `buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId)` → edit using element IDs
1286
1495
  5. `confluence_draft_save` → checkpoint: deletes old draft, creates new with buffer content, returns new URL
1287
1496
  6. Repeat steps 2-5 until user approves
1288
1497
  7. User publishes via Confluence UI (click "Publish" button)
1289
1498
 
1290
1499
  **Editing existing Confluence pages (draft workflow):**
1291
- 1. `confluence_get_page` → page content is buffered, returns `bufferId`, `pageId`, `version`, and `structure`
1292
- 2. `buffer_edit` → edit using element IDs (e.g., `after=2`, `replace=5`, `plantuml="..."`)
1293
- 3. `confluence_draft_create` → creates draft with modified content for user review
1500
+ 1. `confluence_edit(URL or pageId)` → page content is buffered, returns `bufferId`, `pageId`, `version`, and `structure`
1501
+ 2. `buffer_edit(bufferId, after=ID, content/plantuml/fromBufferId)` → edit using element IDs
1502
+ 3. `confluence_draft_create(pageId, bufferId)` → creates draft linked to original page for user review
1294
1503
  4. User reviews draft at URL
1295
1504
  5. If changes needed: repeat via `confluence_draft_open` → edit → `confluence_draft_save`
1296
1505
  6. User publishes via Confluence UI (click "Publish" button)
1297
1506
 
1507
+ **Buffer composition (when content created separately):**
1508
+ If you created content in a separate buffer and need to insert it into a page:
1509
+ 1. `confluence_edit(pageId)` → `bufferId_A` (page buffer with structure)
1510
+ 2. `buffer_create(content, contentType="xhtml")` → `bufferId_B` (new content)
1511
+ 3. `buffer_edit(bufferId=bufferId_A, after=5, fromBufferId=bufferId_B)` → merges B into A
1512
+ 4. `confluence_draft_create(pageId, bufferId=bufferId_A)` → works because bufferId_A originated from pageId
1513
+
1298
1514
  **Saving buffer content to files:**
1299
1515
  - `buffer_save_to_file(bufferId, outputPath)` - Save buffer content to a local file
1300
1516
  - Security: Files can only be saved within project directory (must contain `.jicon.json`)
@@ -1334,8 +1550,10 @@ Use `buffer_edit` with element IDs for precise editing of Confluence storage for
1334
1550
 
1335
1551
  | Parameter | Description |
1336
1552
  |-----------|-------------|
1337
- | `content` | XHTML content to insert/replace |
1338
- | `plantuml` | PlantUML code (auto-validated and wrapped in Confluence macro) |
1553
+ | `content` | XHTML content to insert/replace (**REJECTS PlantUML macros**) |
1554
+ | `plantuml` | PlantUML code (**REQUIRED for diagrams** - auto-validated and wrapped in Confluence macro) |
1555
+
1556
+ **MANDATORY**: All PlantUML diagrams MUST use the `plantuml` parameter. The `content` parameter will reject any PlantUML macros to ensure validation.
1339
1557
 
1340
1558
  **Element Structure Example:**
1341
1559