@superdoc/sdk-linux-x64 2.3.0 → 2.4.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.
@@ -5,7 +5,7 @@
5
5
  "tools": [
6
6
  {
7
7
  "toolName": "superdoc_get_content",
8
- "description": "Read document content in various formats. Call this first in any workflow to understand document structure before making edits. Action \"blocks\" returns structured block data with nodeId, nodeType, textPreview, optional full text when includeText:true, formatting properties (fontFamily, fontSize, color, bold, underline, alignment), and ref handles for immediate use with superdoc_edit or superdoc_format. When you need to evaluate or rewrite existing paragraphs or clauses, prefer action \"blocks\" with includeText:true so you can identify the correct block and then target it by nodeId. Action \"text\" and \"markdown\" return the full document as plain text or Markdown. Action \"html\" returns HTML. Action \"info\" returns document metadata: word count, paragraph count, page count, outline, available styles, and capability flags. The \"blocks\" action supports pagination via \"offset\" and \"limit\", and filtering via \"nodeTypes\". Other actions ignore these parameters. This tool never modifies the document. Do NOT call superdoc_edit or superdoc_format without first reading blocks to get valid refs and formatting reference values.\n\nEXAMPLES:\n 1. {\"action\":\"blocks\"}\n 2. {\"action\":\"blocks\",\"includeText\":true,\"offset\":0,\"limit\":20}\n 3. {\"action\":\"blocks\",\"offset\":0,\"limit\":20,\"nodeTypes\":[\"heading\",\"paragraph\"]}\n 4. {\"action\":\"text\"}\n 5. {\"action\":\"info\"}",
8
+ "description": "Read document content in various formats. Call this first in any workflow to understand document structure before making edits. Action \"blocks\" returns structured block data with nodeId, nodeType, textPreview, optional full text when includeText:true, formatting properties (fontFamily, fontSize, color, bold, underline, alignment), and ref handles for immediate use with superdoc_edit or superdoc_format. When you need to evaluate or rewrite existing paragraphs or clauses, prefer action \"blocks\" with includeText:true so you can identify the correct block and then target it by nodeId. Actions \"text\", \"markdown\", and \"html\" return compact strings. Actions \"markdown_projection\" and \"html_projection\" return detailed async projections with review modes, scopes, diagnostics, annotations, block maps, and optional source maps. Projection source targets use tracked coordinates and are valid only at evaluatedRevision; after any mutation, reproject before using them. Treat omitted or partially emitted annotations according to their status instead of guessing an anchor from rendered text. Action \"info\" returns document metadata: word count, paragraph count, page count, outline, available styles, and capability flags. The \"blocks\" action supports pagination via \"offset\" and \"limit\", and filtering via \"nodeTypes\". Other actions ignore these parameters. This tool never modifies the document. Do NOT call superdoc_edit or superdoc_format without first reading blocks to get valid refs and formatting reference values.\n\nEXAMPLES:\n 1. {\"action\":\"blocks\"}\n 2. {\"action\":\"blocks\",\"includeText\":true,\"offset\":0,\"limit\":20}\n 3. {\"action\":\"blocks\",\"offset\":0,\"limit\":20,\"nodeTypes\":[\"heading\",\"paragraph\"]}\n 4. {\"action\":\"text\"}\n 5. {\"action\":\"info\"}\n 6. {\"action\":\"html_projection\",\"reviewMode\":\"redline\",\"includeSourceMap\":true}\n 7. {\"action\":\"markdown_projection\",\"reviewMode\":\"original\",\"scope\":{\"kind\":\"block\",\"nodeType\":\"paragraph\",\"nodeId\":\"paragraph-id\"},\"includeSourceMap\":true}",
9
9
  "inputSchema": {
10
10
  "type": "object",
11
11
  "properties": {
@@ -15,11 +15,13 @@
15
15
  "blocks",
16
16
  "extract",
17
17
  "html",
18
+ "html_projection",
18
19
  "info",
19
20
  "markdown",
21
+ "markdown_projection",
20
22
  "text"
21
23
  ],
22
- "description": "The action to perform. One of: blocks, extract, html, info, markdown, text."
24
+ "description": "The action to perform. One of: blocks, extract, html, html_projection, info, markdown, markdown_projection, text."
23
25
  },
24
26
  "in": {
25
27
  "$ref": "#/$defs/StoryLocator",
@@ -27,2318 +29,180 @@
27
29
  },
28
30
  "unflattenLists": {
29
31
  "type": "boolean",
30
- "description": "When true, flattens nested list structures in output. Default: false. Only for action 'html'. Omit for other actions."
32
+ "description": "Deprecated and ignored by V2. V2 always emits canonical nested semantic lists. Only for action 'html'. Omit for other actions."
31
33
  },
32
- "offset": {
33
- "type": "number",
34
- "minimum": 0,
35
- "description": "Number of blocks to skip. Default: 0. Only for action 'blocks'. Omit for other actions."
36
- },
37
- "limit": {
38
- "type": "number",
39
- "minimum": 1,
40
- "description": "Maximum blocks to return. Omit for all blocks. Only for action 'blocks'. Omit for other actions."
41
- },
42
- "nodeTypes": {
43
- "type": "array",
44
- "items": {
45
- "enum": [
46
- "paragraph",
47
- "heading",
48
- "listItem",
49
- "table",
50
- "tableRow",
51
- "tableCell",
52
- "tableOfContents",
53
- "image",
54
- "sdt"
55
- ]
56
- },
57
- "description": "Filter by block types (e.g. ['paragraph', 'heading']). Omit for all types. Only for action 'blocks'. Omit for other actions."
58
- },
59
- "includeText": {
60
- "type": "boolean",
61
- "description": "When true, includes the full flattened block text in each block entry. Only for action 'blocks'. Omit for other actions."
62
- }
63
- },
64
- "required": [
65
- "action"
66
- ],
67
- "additionalProperties": false
68
- },
69
- "mutates": false,
70
- "operations": [
71
- {
72
- "operationId": "doc.getText",
73
- "intentAction": "text"
74
- },
75
- {
76
- "operationId": "doc.getMarkdown",
77
- "intentAction": "markdown"
78
- },
79
- {
80
- "operationId": "doc.getHtml",
81
- "intentAction": "html"
82
- },
83
- {
84
- "operationId": "doc.info",
85
- "intentAction": "info"
86
- },
87
- {
88
- "operationId": "doc.extract",
89
- "intentAction": "extract"
90
- },
91
- {
92
- "operationId": "doc.blocks.list",
93
- "intentAction": "blocks"
94
- }
95
- ]
96
- },
97
- {
98
- "toolName": "superdoc_edit",
99
- "description": "The primary tool for inserting content into documents. ALWAYS use action \"insert\" with type \"markdown\" to create headings, paragraphs, or any block content: this is faster and creates proper document structure in one call. Do NOT use superdoc_create for headings or paragraphs. The markdown parser creates headings from # markers (# = Heading1, ## = Heading2), bold from **text**, italic from *text*, and numbered/bullet lists. Position markdown inserts with \"target\" (a BlockNodeAddress like {kind:\"block\", nodeType, nodeId}) and \"placement\" (before, after, insideStart, insideEnd). Without a target, content appends at the end of the document. IMPORTANT: After a markdown insert, analyze the document context (what kind of document, how titles and body text are styled) and follow up with ONE superdoc_mutations call to format inserted blocks so they look like they belong. Each format.apply step accepts \"inline\" (fontFamily, fontSize, bold, underline, color), \"alignment\", and \"scope\" in the same step. Use scope: \"block\" so formatting covers the entire paragraph. Copy the exact property values from the existing get_content blocks (fontFamily, fontSize, color, alignment, bold, underline). Do NOT invent values: use what the blocks show. Also supports replace, delete, and undo/redo. For replace and delete, pass a \"ref\" from superdoc_search or superdoc_get_content blocks. A search ref covers only the matched substring; a block ref covers the entire block text, so use block refs when rewriting or shortening whole paragraphs. For multi-step redlines or whole-clause rewrites, prefer superdoc_mutations with where:{by:\"block\", nodeType, nodeId} from superdoc_get_content action \"blocks\" includeText:true rather than relying on text selectors. Refs expire after any mutation; always re-search before the next edit. For 2+ edits that must succeed or fail atomically, use superdoc_mutations instead. Supports \"dryRun\" to preview changes and \"changeMode: tracked\" to record edits as tracked changes (not supported for markdown/html inserts). Do NOT build \"target\" objects manually when a ref is available; prefer \"ref\" for simpler, more reliable targeting.\n\nEXAMPLES:\n 1. {\"action\":\"insert\",\"type\":\"markdown\",\"target\":{\"kind\":\"block\",\"nodeType\":\"paragraph\",\"nodeId\":\"<nodeId>\"},\"placement\":\"before\",\"value\":\"# Executive Summary\\n\\nThis agreement sets forth the principal terms...\"}\n 2. {\"action\":\"insert\",\"type\":\"markdown\",\"value\":\"# Section Title\\n\\nParagraph content here.\\n\\n# Another Section\\n\\nMore content with **bold** and *italic*.\"}\n 3. {\"action\":\"replace\",\"ref\":\"<handle.ref>\",\"text\":\"new text here\"}\n 4. {\"action\":\"delete\",\"ref\":\"<handle.ref>\"}\n 5. {\"action\":\"undo\"}",
100
- "inputSchema": {
101
- "type": "object",
102
- "properties": {
103
- "action": {
104
- "type": "string",
105
- "enum": [
106
- "delete",
107
- "insert",
108
- "redo",
109
- "replace",
110
- "undo"
111
- ],
112
- "description": "The action to perform. One of: delete, insert, redo, replace, undo."
113
- },
114
- "force": {
115
- "type": "boolean",
116
- "description": "Bypass confirmation checks."
117
- },
118
- "changeMode": {
119
- "type": "string",
120
- "description": "Edit mode: \"direct\" applies changes immediately, \"tracked\" records as suggestions."
121
- },
122
- "dryRun": {
123
- "type": "boolean",
124
- "description": "Preview the result without applying changes."
125
- },
126
- "target": {
127
- "oneOf": [
128
- {
129
- "oneOf": [
130
- {
131
- "$ref": "#/$defs/BlockNodeAddress",
132
- "description": "Block address for structural insertion: {kind:'block', nodeType:'...', nodeId:'...'}."
133
- },
134
- {
135
- "oneOf": [
136
- {
137
- "type": "object",
138
- "properties": {
139
- "kind": {
140
- "const": "selection",
141
- "type": "string"
142
- },
143
- "start": {
144
- "oneOf": [
145
- {
146
- "type": "object",
147
- "properties": {
148
- "kind": {
149
- "const": "text",
150
- "type": "string"
151
- },
152
- "blockId": {
153
- "type": "string"
154
- },
155
- "offset": {
156
- "type": "number"
157
- },
158
- "story": {
159
- "oneOf": [
160
- {
161
- "type": "object",
162
- "properties": {
163
- "kind": {
164
- "const": "story",
165
- "type": "string"
166
- },
167
- "storyType": {
168
- "const": "body",
169
- "type": "string"
170
- }
171
- },
172
- "required": [
173
- "kind",
174
- "storyType"
175
- ]
176
- },
177
- {
178
- "type": "object",
179
- "properties": {
180
- "kind": {
181
- "const": "story",
182
- "type": "string"
183
- },
184
- "storyType": {
185
- "const": "headerFooterSlot",
186
- "type": "string"
187
- },
188
- "section": {
189
- "type": "object",
190
- "properties": {
191
- "kind": {
192
- "const": "section",
193
- "type": "string"
194
- },
195
- "sectionId": {
196
- "type": "string"
197
- }
198
- },
199
- "required": [
200
- "kind",
201
- "sectionId"
202
- ]
203
- },
204
- "headerFooterKind": {
205
- "enum": [
206
- "header",
207
- "footer"
208
- ]
209
- },
210
- "variant": {
211
- "enum": [
212
- "default",
213
- "first",
214
- "even"
215
- ]
216
- },
217
- "resolution": {
218
- "enum": [
219
- "effective",
220
- "explicit"
221
- ]
222
- },
223
- "onWrite": {
224
- "enum": [
225
- "materializeIfInherited",
226
- "editResolvedPart",
227
- "error"
228
- ]
229
- }
230
- },
231
- "required": [
232
- "kind",
233
- "storyType",
234
- "section",
235
- "headerFooterKind",
236
- "variant"
237
- ]
238
- },
239
- {
240
- "type": "object",
241
- "properties": {
242
- "kind": {
243
- "const": "story",
244
- "type": "string"
245
- },
246
- "storyType": {
247
- "const": "headerFooterPart",
248
- "type": "string"
249
- },
250
- "refId": {
251
- "type": "string"
252
- }
253
- },
254
- "required": [
255
- "kind",
256
- "storyType",
257
- "refId"
258
- ]
259
- },
260
- {
261
- "type": "object",
262
- "properties": {
263
- "kind": {
264
- "const": "story",
265
- "type": "string"
266
- },
267
- "storyType": {
268
- "const": "footnote",
269
- "type": "string"
270
- },
271
- "noteId": {
272
- "type": "string"
273
- }
274
- },
275
- "required": [
276
- "kind",
277
- "storyType",
278
- "noteId"
279
- ]
280
- },
281
- {
282
- "type": "object",
283
- "properties": {
284
- "kind": {
285
- "const": "story",
286
- "type": "string"
287
- },
288
- "storyType": {
289
- "const": "endnote",
290
- "type": "string"
291
- },
292
- "noteId": {
293
- "type": "string"
294
- }
295
- },
296
- "required": [
297
- "kind",
298
- "storyType",
299
- "noteId"
300
- ]
301
- },
302
- {
303
- "type": "object",
304
- "properties": {
305
- "kind": {
306
- "const": "story",
307
- "type": "string"
308
- },
309
- "storyType": {
310
- "const": "textbox",
311
- "type": "string"
312
- },
313
- "textboxId": {
314
- "type": "string"
315
- }
316
- },
317
- "required": [
318
- "kind",
319
- "storyType",
320
- "textboxId"
321
- ]
322
- }
323
- ],
324
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
325
- }
326
- },
327
- "required": [
328
- "kind",
329
- "blockId",
330
- "offset"
331
- ]
332
- },
333
- {
334
- "type": "object",
335
- "properties": {
336
- "kind": {
337
- "const": "nodeEdge",
338
- "type": "string"
339
- },
340
- "node": {
341
- "type": "object",
342
- "properties": {
343
- "kind": {
344
- "const": "block",
345
- "type": "string"
346
- },
347
- "nodeType": {
348
- "enum": [
349
- "paragraph",
350
- "heading",
351
- "table",
352
- "tableOfContents",
353
- "sdt",
354
- "image"
355
- ]
356
- },
357
- "nodeId": {
358
- "type": "string"
359
- },
360
- "story": {
361
- "oneOf": [
362
- {
363
- "type": "object",
364
- "properties": {
365
- "kind": {
366
- "const": "story",
367
- "type": "string"
368
- },
369
- "storyType": {
370
- "const": "body",
371
- "type": "string"
372
- }
373
- },
374
- "required": [
375
- "kind",
376
- "storyType"
377
- ]
378
- },
379
- {
380
- "type": "object",
381
- "properties": {
382
- "kind": {
383
- "const": "story",
384
- "type": "string"
385
- },
386
- "storyType": {
387
- "const": "headerFooterSlot",
388
- "type": "string"
389
- },
390
- "section": {
391
- "type": "object",
392
- "properties": {
393
- "kind": {
394
- "const": "section",
395
- "type": "string"
396
- },
397
- "sectionId": {
398
- "type": "string"
399
- }
400
- },
401
- "required": [
402
- "kind",
403
- "sectionId"
404
- ]
405
- },
406
- "headerFooterKind": {
407
- "enum": [
408
- "header",
409
- "footer"
410
- ]
411
- },
412
- "variant": {
413
- "enum": [
414
- "default",
415
- "first",
416
- "even"
417
- ]
418
- },
419
- "resolution": {
420
- "enum": [
421
- "effective",
422
- "explicit"
423
- ]
424
- },
425
- "onWrite": {
426
- "enum": [
427
- "materializeIfInherited",
428
- "editResolvedPart",
429
- "error"
430
- ]
431
- }
432
- },
433
- "required": [
434
- "kind",
435
- "storyType",
436
- "section",
437
- "headerFooterKind",
438
- "variant"
439
- ]
440
- },
441
- {
442
- "type": "object",
443
- "properties": {
444
- "kind": {
445
- "const": "story",
446
- "type": "string"
447
- },
448
- "storyType": {
449
- "const": "headerFooterPart",
450
- "type": "string"
451
- },
452
- "refId": {
453
- "type": "string"
454
- }
455
- },
456
- "required": [
457
- "kind",
458
- "storyType",
459
- "refId"
460
- ]
461
- },
462
- {
463
- "type": "object",
464
- "properties": {
465
- "kind": {
466
- "const": "story",
467
- "type": "string"
468
- },
469
- "storyType": {
470
- "const": "footnote",
471
- "type": "string"
472
- },
473
- "noteId": {
474
- "type": "string"
475
- }
476
- },
477
- "required": [
478
- "kind",
479
- "storyType",
480
- "noteId"
481
- ]
482
- },
483
- {
484
- "type": "object",
485
- "properties": {
486
- "kind": {
487
- "const": "story",
488
- "type": "string"
489
- },
490
- "storyType": {
491
- "const": "endnote",
492
- "type": "string"
493
- },
494
- "noteId": {
495
- "type": "string"
496
- }
497
- },
498
- "required": [
499
- "kind",
500
- "storyType",
501
- "noteId"
502
- ]
503
- },
504
- {
505
- "type": "object",
506
- "properties": {
507
- "kind": {
508
- "const": "story",
509
- "type": "string"
510
- },
511
- "storyType": {
512
- "const": "textbox",
513
- "type": "string"
514
- },
515
- "textboxId": {
516
- "type": "string"
517
- }
518
- },
519
- "required": [
520
- "kind",
521
- "storyType",
522
- "textboxId"
523
- ]
524
- }
525
- ],
526
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
527
- }
528
- },
529
- "required": [
530
- "kind",
531
- "nodeType",
532
- "nodeId"
533
- ]
534
- },
535
- "edge": {
536
- "enum": [
537
- "before",
538
- "after"
539
- ]
540
- }
541
- },
542
- "required": [
543
- "kind",
544
- "node",
545
- "edge"
546
- ]
547
- }
548
- ],
549
- "description": "A point in the document. Use {kind:'text', blockId, offset} for character positions or {kind:'nodeEdge', node:{kind:'block', nodeType, nodeId}, edge:'before'|'after'} for block boundaries."
550
- },
551
- "end": {
552
- "oneOf": [
553
- {
554
- "type": "object",
555
- "properties": {
556
- "kind": {
557
- "const": "text",
558
- "type": "string"
559
- },
560
- "blockId": {
561
- "type": "string"
562
- },
563
- "offset": {
564
- "type": "number"
565
- },
566
- "story": {
567
- "oneOf": [
568
- {
569
- "type": "object",
570
- "properties": {
571
- "kind": {
572
- "const": "story",
573
- "type": "string"
574
- },
575
- "storyType": {
576
- "const": "body",
577
- "type": "string"
578
- }
579
- },
580
- "required": [
581
- "kind",
582
- "storyType"
583
- ]
584
- },
585
- {
586
- "type": "object",
587
- "properties": {
588
- "kind": {
589
- "const": "story",
590
- "type": "string"
591
- },
592
- "storyType": {
593
- "const": "headerFooterSlot",
594
- "type": "string"
595
- },
596
- "section": {
597
- "type": "object",
598
- "properties": {
599
- "kind": {
600
- "const": "section",
601
- "type": "string"
602
- },
603
- "sectionId": {
604
- "type": "string"
605
- }
606
- },
607
- "required": [
608
- "kind",
609
- "sectionId"
610
- ]
611
- },
612
- "headerFooterKind": {
613
- "enum": [
614
- "header",
615
- "footer"
616
- ]
617
- },
618
- "variant": {
619
- "enum": [
620
- "default",
621
- "first",
622
- "even"
623
- ]
624
- },
625
- "resolution": {
626
- "enum": [
627
- "effective",
628
- "explicit"
629
- ]
630
- },
631
- "onWrite": {
632
- "enum": [
633
- "materializeIfInherited",
634
- "editResolvedPart",
635
- "error"
636
- ]
637
- }
638
- },
639
- "required": [
640
- "kind",
641
- "storyType",
642
- "section",
643
- "headerFooterKind",
644
- "variant"
645
- ]
646
- },
647
- {
648
- "type": "object",
649
- "properties": {
650
- "kind": {
651
- "const": "story",
652
- "type": "string"
653
- },
654
- "storyType": {
655
- "const": "headerFooterPart",
656
- "type": "string"
657
- },
658
- "refId": {
659
- "type": "string"
660
- }
661
- },
662
- "required": [
663
- "kind",
664
- "storyType",
665
- "refId"
666
- ]
667
- },
668
- {
669
- "type": "object",
670
- "properties": {
671
- "kind": {
672
- "const": "story",
673
- "type": "string"
674
- },
675
- "storyType": {
676
- "const": "footnote",
677
- "type": "string"
678
- },
679
- "noteId": {
680
- "type": "string"
681
- }
682
- },
683
- "required": [
684
- "kind",
685
- "storyType",
686
- "noteId"
687
- ]
688
- },
689
- {
690
- "type": "object",
691
- "properties": {
692
- "kind": {
693
- "const": "story",
694
- "type": "string"
695
- },
696
- "storyType": {
697
- "const": "endnote",
698
- "type": "string"
699
- },
700
- "noteId": {
701
- "type": "string"
702
- }
703
- },
704
- "required": [
705
- "kind",
706
- "storyType",
707
- "noteId"
708
- ]
709
- },
710
- {
711
- "type": "object",
712
- "properties": {
713
- "kind": {
714
- "const": "story",
715
- "type": "string"
716
- },
717
- "storyType": {
718
- "const": "textbox",
719
- "type": "string"
720
- },
721
- "textboxId": {
722
- "type": "string"
723
- }
724
- },
725
- "required": [
726
- "kind",
727
- "storyType",
728
- "textboxId"
729
- ]
730
- }
731
- ],
732
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
733
- }
734
- },
735
- "required": [
736
- "kind",
737
- "blockId",
738
- "offset"
739
- ]
740
- },
741
- {
742
- "type": "object",
743
- "properties": {
744
- "kind": {
745
- "const": "nodeEdge",
746
- "type": "string"
747
- },
748
- "node": {
749
- "type": "object",
750
- "properties": {
751
- "kind": {
752
- "const": "block",
753
- "type": "string"
754
- },
755
- "nodeType": {
756
- "enum": [
757
- "paragraph",
758
- "heading",
759
- "table",
760
- "tableOfContents",
761
- "sdt",
762
- "image"
763
- ]
764
- },
765
- "nodeId": {
766
- "type": "string"
767
- },
768
- "story": {
769
- "oneOf": [
770
- {
771
- "type": "object",
772
- "properties": {
773
- "kind": {
774
- "const": "story",
775
- "type": "string"
776
- },
777
- "storyType": {
778
- "const": "body",
779
- "type": "string"
780
- }
781
- },
782
- "required": [
783
- "kind",
784
- "storyType"
785
- ]
786
- },
787
- {
788
- "type": "object",
789
- "properties": {
790
- "kind": {
791
- "const": "story",
792
- "type": "string"
793
- },
794
- "storyType": {
795
- "const": "headerFooterSlot",
796
- "type": "string"
797
- },
798
- "section": {
799
- "type": "object",
800
- "properties": {
801
- "kind": {
802
- "const": "section",
803
- "type": "string"
804
- },
805
- "sectionId": {
806
- "type": "string"
807
- }
808
- },
809
- "required": [
810
- "kind",
811
- "sectionId"
812
- ]
813
- },
814
- "headerFooterKind": {
815
- "enum": [
816
- "header",
817
- "footer"
818
- ]
819
- },
820
- "variant": {
821
- "enum": [
822
- "default",
823
- "first",
824
- "even"
825
- ]
826
- },
827
- "resolution": {
828
- "enum": [
829
- "effective",
830
- "explicit"
831
- ]
832
- },
833
- "onWrite": {
834
- "enum": [
835
- "materializeIfInherited",
836
- "editResolvedPart",
837
- "error"
838
- ]
839
- }
840
- },
841
- "required": [
842
- "kind",
843
- "storyType",
844
- "section",
845
- "headerFooterKind",
846
- "variant"
847
- ]
848
- },
849
- {
850
- "type": "object",
851
- "properties": {
852
- "kind": {
853
- "const": "story",
854
- "type": "string"
855
- },
856
- "storyType": {
857
- "const": "headerFooterPart",
858
- "type": "string"
859
- },
860
- "refId": {
861
- "type": "string"
862
- }
863
- },
864
- "required": [
865
- "kind",
866
- "storyType",
867
- "refId"
868
- ]
869
- },
870
- {
871
- "type": "object",
872
- "properties": {
873
- "kind": {
874
- "const": "story",
875
- "type": "string"
876
- },
877
- "storyType": {
878
- "const": "footnote",
879
- "type": "string"
880
- },
881
- "noteId": {
882
- "type": "string"
883
- }
884
- },
885
- "required": [
886
- "kind",
887
- "storyType",
888
- "noteId"
889
- ]
890
- },
891
- {
892
- "type": "object",
893
- "properties": {
894
- "kind": {
895
- "const": "story",
896
- "type": "string"
897
- },
898
- "storyType": {
899
- "const": "endnote",
900
- "type": "string"
901
- },
902
- "noteId": {
903
- "type": "string"
904
- }
905
- },
906
- "required": [
907
- "kind",
908
- "storyType",
909
- "noteId"
910
- ]
911
- },
912
- {
913
- "type": "object",
914
- "properties": {
915
- "kind": {
916
- "const": "story",
917
- "type": "string"
918
- },
919
- "storyType": {
920
- "const": "textbox",
921
- "type": "string"
922
- },
923
- "textboxId": {
924
- "type": "string"
925
- }
926
- },
927
- "required": [
928
- "kind",
929
- "storyType",
930
- "textboxId"
931
- ]
932
- }
933
- ],
934
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
935
- }
936
- },
937
- "required": [
938
- "kind",
939
- "nodeType",
940
- "nodeId"
941
- ]
942
- },
943
- "edge": {
944
- "enum": [
945
- "before",
946
- "after"
947
- ]
948
- }
949
- },
950
- "required": [
951
- "kind",
952
- "node",
953
- "edge"
954
- ]
955
- }
956
- ],
957
- "description": "A point in the document. Use {kind:'text', blockId, offset} for character positions or {kind:'nodeEdge', node:{kind:'block', nodeType, nodeId}, edge:'before'|'after'} for block boundaries."
958
- },
959
- "story": {
960
- "oneOf": [
961
- {
962
- "type": "object",
963
- "properties": {
964
- "kind": {
965
- "const": "story",
966
- "type": "string"
967
- },
968
- "storyType": {
969
- "const": "body",
970
- "type": "string"
971
- }
972
- },
973
- "required": [
974
- "kind",
975
- "storyType"
976
- ]
977
- },
978
- {
979
- "type": "object",
980
- "properties": {
981
- "kind": {
982
- "const": "story",
983
- "type": "string"
984
- },
985
- "storyType": {
986
- "const": "headerFooterSlot",
987
- "type": "string"
988
- },
989
- "section": {
990
- "type": "object",
991
- "properties": {
992
- "kind": {
993
- "const": "section",
994
- "type": "string"
995
- },
996
- "sectionId": {
997
- "type": "string"
998
- }
999
- },
1000
- "required": [
1001
- "kind",
1002
- "sectionId"
1003
- ]
1004
- },
1005
- "headerFooterKind": {
1006
- "enum": [
1007
- "header",
1008
- "footer"
1009
- ]
1010
- },
1011
- "variant": {
1012
- "enum": [
1013
- "default",
1014
- "first",
1015
- "even"
1016
- ]
1017
- },
1018
- "resolution": {
1019
- "enum": [
1020
- "effective",
1021
- "explicit"
1022
- ]
1023
- },
1024
- "onWrite": {
1025
- "enum": [
1026
- "materializeIfInherited",
1027
- "editResolvedPart",
1028
- "error"
1029
- ]
1030
- }
1031
- },
1032
- "required": [
1033
- "kind",
1034
- "storyType",
1035
- "section",
1036
- "headerFooterKind",
1037
- "variant"
1038
- ]
1039
- },
1040
- {
1041
- "type": "object",
1042
- "properties": {
1043
- "kind": {
1044
- "const": "story",
1045
- "type": "string"
1046
- },
1047
- "storyType": {
1048
- "const": "headerFooterPart",
1049
- "type": "string"
1050
- },
1051
- "refId": {
1052
- "type": "string"
1053
- }
1054
- },
1055
- "required": [
1056
- "kind",
1057
- "storyType",
1058
- "refId"
1059
- ]
1060
- },
1061
- {
1062
- "type": "object",
1063
- "properties": {
1064
- "kind": {
1065
- "const": "story",
1066
- "type": "string"
1067
- },
1068
- "storyType": {
1069
- "const": "footnote",
1070
- "type": "string"
1071
- },
1072
- "noteId": {
1073
- "type": "string"
1074
- }
1075
- },
1076
- "required": [
1077
- "kind",
1078
- "storyType",
1079
- "noteId"
1080
- ]
1081
- },
1082
- {
1083
- "type": "object",
1084
- "properties": {
1085
- "kind": {
1086
- "const": "story",
1087
- "type": "string"
1088
- },
1089
- "storyType": {
1090
- "const": "endnote",
1091
- "type": "string"
1092
- },
1093
- "noteId": {
1094
- "type": "string"
1095
- }
1096
- },
1097
- "required": [
1098
- "kind",
1099
- "storyType",
1100
- "noteId"
1101
- ]
1102
- },
1103
- {
1104
- "type": "object",
1105
- "properties": {
1106
- "kind": {
1107
- "const": "story",
1108
- "type": "string"
1109
- },
1110
- "storyType": {
1111
- "const": "textbox",
1112
- "type": "string"
1113
- },
1114
- "textboxId": {
1115
- "type": "string"
1116
- }
1117
- },
1118
- "required": [
1119
- "kind",
1120
- "storyType",
1121
- "textboxId"
1122
- ]
1123
- }
1124
- ],
1125
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
1126
- },
1127
- "coordinateSpace": {
1128
- "enum": [
1129
- "visible",
1130
- "tracked"
1131
- ]
1132
- }
1133
- },
1134
- "required": [
1135
- "kind",
1136
- "start",
1137
- "end"
1138
- ]
1139
- },
1140
- {
1141
- "type": "object",
1142
- "properties": {
1143
- "kind": {
1144
- "const": "block",
1145
- "type": "string"
1146
- },
1147
- "nodeType": {
1148
- "enum": [
1149
- "paragraph",
1150
- "heading",
1151
- "listItem",
1152
- "table",
1153
- "tableRow",
1154
- "tableCell",
1155
- "tableOfContents",
1156
- "image",
1157
- "sdt"
1158
- ]
1159
- },
1160
- "nodeId": {
1161
- "type": "string"
1162
- },
1163
- "story": {
1164
- "oneOf": [
1165
- {
1166
- "type": "object",
1167
- "properties": {
1168
- "kind": {
1169
- "const": "story",
1170
- "type": "string"
1171
- },
1172
- "storyType": {
1173
- "const": "body",
1174
- "type": "string"
1175
- }
1176
- },
1177
- "required": [
1178
- "kind",
1179
- "storyType"
1180
- ]
1181
- },
1182
- {
1183
- "type": "object",
1184
- "properties": {
1185
- "kind": {
1186
- "const": "story",
1187
- "type": "string"
1188
- },
1189
- "storyType": {
1190
- "const": "headerFooterSlot",
1191
- "type": "string"
1192
- },
1193
- "section": {
1194
- "type": "object",
1195
- "properties": {
1196
- "kind": {
1197
- "const": "section",
1198
- "type": "string"
1199
- },
1200
- "sectionId": {
1201
- "type": "string"
1202
- }
1203
- },
1204
- "required": [
1205
- "kind",
1206
- "sectionId"
1207
- ]
1208
- },
1209
- "headerFooterKind": {
1210
- "enum": [
1211
- "header",
1212
- "footer"
1213
- ]
1214
- },
1215
- "variant": {
1216
- "enum": [
1217
- "default",
1218
- "first",
1219
- "even"
1220
- ]
1221
- },
1222
- "resolution": {
1223
- "enum": [
1224
- "effective",
1225
- "explicit"
1226
- ]
1227
- },
1228
- "onWrite": {
1229
- "enum": [
1230
- "materializeIfInherited",
1231
- "editResolvedPart",
1232
- "error"
1233
- ]
1234
- }
1235
- },
1236
- "required": [
1237
- "kind",
1238
- "storyType",
1239
- "section",
1240
- "headerFooterKind",
1241
- "variant"
1242
- ]
1243
- },
1244
- {
1245
- "type": "object",
1246
- "properties": {
1247
- "kind": {
1248
- "const": "story",
1249
- "type": "string"
1250
- },
1251
- "storyType": {
1252
- "const": "headerFooterPart",
1253
- "type": "string"
1254
- },
1255
- "refId": {
1256
- "type": "string"
1257
- }
1258
- },
1259
- "required": [
1260
- "kind",
1261
- "storyType",
1262
- "refId"
1263
- ]
1264
- },
1265
- {
1266
- "type": "object",
1267
- "properties": {
1268
- "kind": {
1269
- "const": "story",
1270
- "type": "string"
1271
- },
1272
- "storyType": {
1273
- "const": "footnote",
1274
- "type": "string"
1275
- },
1276
- "noteId": {
1277
- "type": "string"
1278
- }
1279
- },
1280
- "required": [
1281
- "kind",
1282
- "storyType",
1283
- "noteId"
1284
- ]
1285
- },
1286
- {
1287
- "type": "object",
1288
- "properties": {
1289
- "kind": {
1290
- "const": "story",
1291
- "type": "string"
1292
- },
1293
- "storyType": {
1294
- "const": "endnote",
1295
- "type": "string"
1296
- },
1297
- "noteId": {
1298
- "type": "string"
1299
- }
1300
- },
1301
- "required": [
1302
- "kind",
1303
- "storyType",
1304
- "noteId"
1305
- ]
1306
- },
1307
- {
1308
- "type": "object",
1309
- "properties": {
1310
- "kind": {
1311
- "const": "story",
1312
- "type": "string"
1313
- },
1314
- "storyType": {
1315
- "const": "textbox",
1316
- "type": "string"
1317
- },
1318
- "textboxId": {
1319
- "type": "string"
1320
- }
1321
- },
1322
- "required": [
1323
- "kind",
1324
- "storyType",
1325
- "textboxId"
1326
- ]
1327
- }
1328
- ],
1329
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
1330
- }
1331
- },
1332
- "required": [
1333
- "kind",
1334
- "nodeType",
1335
- "nodeId"
1336
- ]
1337
- },
1338
- {
1339
- "type": "object",
1340
- "properties": {
1341
- "kind": {
1342
- "const": "selection",
1343
- "type": "string"
1344
- },
1345
- "start": {
1346
- "oneOf": [
1347
- {
1348
- "type": "object",
1349
- "properties": {
1350
- "kind": {
1351
- "const": "text",
1352
- "type": "string"
1353
- },
1354
- "blockId": {
1355
- "type": "string"
1356
- },
1357
- "offset": {
1358
- "type": "number"
1359
- },
1360
- "story": {
1361
- "oneOf": [
1362
- {
1363
- "type": "object",
1364
- "properties": {
1365
- "kind": {
1366
- "const": "story",
1367
- "type": "string"
1368
- },
1369
- "storyType": {
1370
- "const": "body",
1371
- "type": "string"
1372
- }
1373
- },
1374
- "required": [
1375
- "kind",
1376
- "storyType"
1377
- ]
1378
- },
1379
- {
1380
- "type": "object",
1381
- "properties": {
1382
- "kind": {
1383
- "const": "story",
1384
- "type": "string"
1385
- },
1386
- "storyType": {
1387
- "const": "headerFooterSlot",
1388
- "type": "string"
1389
- },
1390
- "section": {
1391
- "type": "object",
1392
- "properties": {
1393
- "kind": {
1394
- "const": "section",
1395
- "type": "string"
1396
- },
1397
- "sectionId": {
1398
- "type": "string"
1399
- }
1400
- },
1401
- "required": [
1402
- "kind",
1403
- "sectionId"
1404
- ]
1405
- },
1406
- "headerFooterKind": {
1407
- "enum": [
1408
- "header",
1409
- "footer"
1410
- ]
1411
- },
1412
- "variant": {
1413
- "enum": [
1414
- "default",
1415
- "first",
1416
- "even"
1417
- ]
1418
- },
1419
- "resolution": {
1420
- "enum": [
1421
- "effective",
1422
- "explicit"
1423
- ]
1424
- },
1425
- "onWrite": {
1426
- "enum": [
1427
- "materializeIfInherited",
1428
- "editResolvedPart",
1429
- "error"
1430
- ]
1431
- }
1432
- },
1433
- "required": [
1434
- "kind",
1435
- "storyType",
1436
- "section",
1437
- "headerFooterKind",
1438
- "variant"
1439
- ]
1440
- },
1441
- {
1442
- "type": "object",
1443
- "properties": {
1444
- "kind": {
1445
- "const": "story",
1446
- "type": "string"
1447
- },
1448
- "storyType": {
1449
- "const": "headerFooterPart",
1450
- "type": "string"
1451
- },
1452
- "refId": {
1453
- "type": "string"
1454
- }
1455
- },
1456
- "required": [
1457
- "kind",
1458
- "storyType",
1459
- "refId"
1460
- ]
1461
- },
1462
- {
1463
- "type": "object",
1464
- "properties": {
1465
- "kind": {
1466
- "const": "story",
1467
- "type": "string"
1468
- },
1469
- "storyType": {
1470
- "const": "footnote",
1471
- "type": "string"
1472
- },
1473
- "noteId": {
1474
- "type": "string"
1475
- }
1476
- },
1477
- "required": [
1478
- "kind",
1479
- "storyType",
1480
- "noteId"
1481
- ]
1482
- },
1483
- {
1484
- "type": "object",
1485
- "properties": {
1486
- "kind": {
1487
- "const": "story",
1488
- "type": "string"
1489
- },
1490
- "storyType": {
1491
- "const": "endnote",
1492
- "type": "string"
1493
- },
1494
- "noteId": {
1495
- "type": "string"
1496
- }
1497
- },
1498
- "required": [
1499
- "kind",
1500
- "storyType",
1501
- "noteId"
1502
- ]
1503
- },
1504
- {
1505
- "type": "object",
1506
- "properties": {
1507
- "kind": {
1508
- "const": "story",
1509
- "type": "string"
1510
- },
1511
- "storyType": {
1512
- "const": "textbox",
1513
- "type": "string"
1514
- },
1515
- "textboxId": {
1516
- "type": "string"
1517
- }
1518
- },
1519
- "required": [
1520
- "kind",
1521
- "storyType",
1522
- "textboxId"
1523
- ]
1524
- }
1525
- ],
1526
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
1527
- }
1528
- },
1529
- "required": [
1530
- "kind",
1531
- "blockId",
1532
- "offset"
1533
- ]
1534
- },
1535
- {
1536
- "type": "object",
1537
- "properties": {
1538
- "kind": {
1539
- "const": "nodeEdge",
1540
- "type": "string"
1541
- },
1542
- "node": {
1543
- "type": "object",
1544
- "properties": {
1545
- "kind": {
1546
- "const": "block",
1547
- "type": "string"
1548
- },
1549
- "nodeType": {
1550
- "enum": [
1551
- "paragraph",
1552
- "heading",
1553
- "table",
1554
- "tableOfContents",
1555
- "sdt",
1556
- "image"
1557
- ]
1558
- },
1559
- "nodeId": {
1560
- "type": "string"
1561
- },
1562
- "story": {
1563
- "oneOf": [
1564
- {
1565
- "type": "object",
1566
- "properties": {
1567
- "kind": {
1568
- "const": "story",
1569
- "type": "string"
1570
- },
1571
- "storyType": {
1572
- "const": "body",
1573
- "type": "string"
1574
- }
1575
- },
1576
- "required": [
1577
- "kind",
1578
- "storyType"
1579
- ]
1580
- },
1581
- {
1582
- "type": "object",
1583
- "properties": {
1584
- "kind": {
1585
- "const": "story",
1586
- "type": "string"
1587
- },
1588
- "storyType": {
1589
- "const": "headerFooterSlot",
1590
- "type": "string"
1591
- },
1592
- "section": {
1593
- "type": "object",
1594
- "properties": {
1595
- "kind": {
1596
- "const": "section",
1597
- "type": "string"
1598
- },
1599
- "sectionId": {
1600
- "type": "string"
1601
- }
1602
- },
1603
- "required": [
1604
- "kind",
1605
- "sectionId"
1606
- ]
1607
- },
1608
- "headerFooterKind": {
1609
- "enum": [
1610
- "header",
1611
- "footer"
1612
- ]
1613
- },
1614
- "variant": {
1615
- "enum": [
1616
- "default",
1617
- "first",
1618
- "even"
1619
- ]
1620
- },
1621
- "resolution": {
1622
- "enum": [
1623
- "effective",
1624
- "explicit"
1625
- ]
1626
- },
1627
- "onWrite": {
1628
- "enum": [
1629
- "materializeIfInherited",
1630
- "editResolvedPart",
1631
- "error"
1632
- ]
1633
- }
1634
- },
1635
- "required": [
1636
- "kind",
1637
- "storyType",
1638
- "section",
1639
- "headerFooterKind",
1640
- "variant"
1641
- ]
1642
- },
1643
- {
1644
- "type": "object",
1645
- "properties": {
1646
- "kind": {
1647
- "const": "story",
1648
- "type": "string"
1649
- },
1650
- "storyType": {
1651
- "const": "headerFooterPart",
1652
- "type": "string"
1653
- },
1654
- "refId": {
1655
- "type": "string"
1656
- }
1657
- },
1658
- "required": [
1659
- "kind",
1660
- "storyType",
1661
- "refId"
1662
- ]
1663
- },
1664
- {
1665
- "type": "object",
1666
- "properties": {
1667
- "kind": {
1668
- "const": "story",
1669
- "type": "string"
1670
- },
1671
- "storyType": {
1672
- "const": "footnote",
1673
- "type": "string"
1674
- },
1675
- "noteId": {
1676
- "type": "string"
1677
- }
1678
- },
1679
- "required": [
1680
- "kind",
1681
- "storyType",
1682
- "noteId"
1683
- ]
1684
- },
1685
- {
1686
- "type": "object",
1687
- "properties": {
1688
- "kind": {
1689
- "const": "story",
1690
- "type": "string"
1691
- },
1692
- "storyType": {
1693
- "const": "endnote",
1694
- "type": "string"
1695
- },
1696
- "noteId": {
1697
- "type": "string"
1698
- }
1699
- },
1700
- "required": [
1701
- "kind",
1702
- "storyType",
1703
- "noteId"
1704
- ]
1705
- },
1706
- {
1707
- "type": "object",
1708
- "properties": {
1709
- "kind": {
1710
- "const": "story",
1711
- "type": "string"
1712
- },
1713
- "storyType": {
1714
- "const": "textbox",
1715
- "type": "string"
1716
- },
1717
- "textboxId": {
1718
- "type": "string"
1719
- }
1720
- },
1721
- "required": [
1722
- "kind",
1723
- "storyType",
1724
- "textboxId"
1725
- ]
1726
- }
1727
- ],
1728
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
1729
- }
1730
- },
1731
- "required": [
1732
- "kind",
1733
- "nodeType",
1734
- "nodeId"
1735
- ]
1736
- },
1737
- "edge": {
1738
- "enum": [
1739
- "before",
1740
- "after"
1741
- ]
1742
- }
1743
- },
1744
- "required": [
1745
- "kind",
1746
- "node",
1747
- "edge"
1748
- ]
1749
- }
1750
- ],
1751
- "description": "A point in the document. Use {kind:'text', blockId, offset} for character positions or {kind:'nodeEdge', node:{kind:'block', nodeType, nodeId}, edge:'before'|'after'} for block boundaries."
1752
- },
1753
- "end": {
1754
- "oneOf": [
1755
- {
1756
- "type": "object",
1757
- "properties": {
1758
- "kind": {
1759
- "const": "text",
1760
- "type": "string"
1761
- },
1762
- "blockId": {
1763
- "type": "string"
1764
- },
1765
- "offset": {
1766
- "type": "number"
1767
- },
1768
- "story": {
1769
- "oneOf": [
1770
- {
1771
- "type": "object",
1772
- "properties": {
1773
- "kind": {
1774
- "const": "story",
1775
- "type": "string"
1776
- },
1777
- "storyType": {
1778
- "const": "body",
1779
- "type": "string"
1780
- }
1781
- },
1782
- "required": [
1783
- "kind",
1784
- "storyType"
1785
- ]
1786
- },
1787
- {
1788
- "type": "object",
1789
- "properties": {
1790
- "kind": {
1791
- "const": "story",
1792
- "type": "string"
1793
- },
1794
- "storyType": {
1795
- "const": "headerFooterSlot",
1796
- "type": "string"
1797
- },
1798
- "section": {
1799
- "type": "object",
1800
- "properties": {
1801
- "kind": {
1802
- "const": "section",
1803
- "type": "string"
1804
- },
1805
- "sectionId": {
1806
- "type": "string"
1807
- }
1808
- },
1809
- "required": [
1810
- "kind",
1811
- "sectionId"
1812
- ]
1813
- },
1814
- "headerFooterKind": {
1815
- "enum": [
1816
- "header",
1817
- "footer"
1818
- ]
1819
- },
1820
- "variant": {
1821
- "enum": [
1822
- "default",
1823
- "first",
1824
- "even"
1825
- ]
1826
- },
1827
- "resolution": {
1828
- "enum": [
1829
- "effective",
1830
- "explicit"
1831
- ]
1832
- },
1833
- "onWrite": {
1834
- "enum": [
1835
- "materializeIfInherited",
1836
- "editResolvedPart",
1837
- "error"
1838
- ]
1839
- }
1840
- },
1841
- "required": [
1842
- "kind",
1843
- "storyType",
1844
- "section",
1845
- "headerFooterKind",
1846
- "variant"
1847
- ]
1848
- },
1849
- {
1850
- "type": "object",
1851
- "properties": {
1852
- "kind": {
1853
- "const": "story",
1854
- "type": "string"
1855
- },
1856
- "storyType": {
1857
- "const": "headerFooterPart",
1858
- "type": "string"
1859
- },
1860
- "refId": {
1861
- "type": "string"
1862
- }
1863
- },
1864
- "required": [
1865
- "kind",
1866
- "storyType",
1867
- "refId"
1868
- ]
1869
- },
1870
- {
1871
- "type": "object",
1872
- "properties": {
1873
- "kind": {
1874
- "const": "story",
1875
- "type": "string"
1876
- },
1877
- "storyType": {
1878
- "const": "footnote",
1879
- "type": "string"
1880
- },
1881
- "noteId": {
1882
- "type": "string"
1883
- }
1884
- },
1885
- "required": [
1886
- "kind",
1887
- "storyType",
1888
- "noteId"
1889
- ]
1890
- },
1891
- {
1892
- "type": "object",
1893
- "properties": {
1894
- "kind": {
1895
- "const": "story",
1896
- "type": "string"
1897
- },
1898
- "storyType": {
1899
- "const": "endnote",
1900
- "type": "string"
1901
- },
1902
- "noteId": {
1903
- "type": "string"
1904
- }
1905
- },
1906
- "required": [
1907
- "kind",
1908
- "storyType",
1909
- "noteId"
1910
- ]
1911
- },
1912
- {
1913
- "type": "object",
1914
- "properties": {
1915
- "kind": {
1916
- "const": "story",
1917
- "type": "string"
1918
- },
1919
- "storyType": {
1920
- "const": "textbox",
1921
- "type": "string"
1922
- },
1923
- "textboxId": {
1924
- "type": "string"
1925
- }
1926
- },
1927
- "required": [
1928
- "kind",
1929
- "storyType",
1930
- "textboxId"
1931
- ]
1932
- }
1933
- ],
1934
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
1935
- }
1936
- },
1937
- "required": [
1938
- "kind",
1939
- "blockId",
1940
- "offset"
1941
- ]
1942
- },
1943
- {
1944
- "type": "object",
1945
- "properties": {
1946
- "kind": {
1947
- "const": "nodeEdge",
1948
- "type": "string"
1949
- },
1950
- "node": {
1951
- "type": "object",
1952
- "properties": {
1953
- "kind": {
1954
- "const": "block",
1955
- "type": "string"
1956
- },
1957
- "nodeType": {
1958
- "enum": [
1959
- "paragraph",
1960
- "heading",
1961
- "table",
1962
- "tableOfContents",
1963
- "sdt",
1964
- "image"
1965
- ]
1966
- },
1967
- "nodeId": {
1968
- "type": "string"
1969
- },
1970
- "story": {
1971
- "oneOf": [
1972
- {
1973
- "type": "object",
1974
- "properties": {
1975
- "kind": {
1976
- "const": "story",
1977
- "type": "string"
1978
- },
1979
- "storyType": {
1980
- "const": "body",
1981
- "type": "string"
1982
- }
1983
- },
1984
- "required": [
1985
- "kind",
1986
- "storyType"
1987
- ]
1988
- },
1989
- {
1990
- "type": "object",
1991
- "properties": {
1992
- "kind": {
1993
- "const": "story",
1994
- "type": "string"
1995
- },
1996
- "storyType": {
1997
- "const": "headerFooterSlot",
1998
- "type": "string"
1999
- },
2000
- "section": {
2001
- "type": "object",
2002
- "properties": {
2003
- "kind": {
2004
- "const": "section",
2005
- "type": "string"
2006
- },
2007
- "sectionId": {
2008
- "type": "string"
2009
- }
2010
- },
2011
- "required": [
2012
- "kind",
2013
- "sectionId"
2014
- ]
2015
- },
2016
- "headerFooterKind": {
2017
- "enum": [
2018
- "header",
2019
- "footer"
2020
- ]
2021
- },
2022
- "variant": {
2023
- "enum": [
2024
- "default",
2025
- "first",
2026
- "even"
2027
- ]
2028
- },
2029
- "resolution": {
2030
- "enum": [
2031
- "effective",
2032
- "explicit"
2033
- ]
2034
- },
2035
- "onWrite": {
2036
- "enum": [
2037
- "materializeIfInherited",
2038
- "editResolvedPart",
2039
- "error"
2040
- ]
2041
- }
2042
- },
2043
- "required": [
2044
- "kind",
2045
- "storyType",
2046
- "section",
2047
- "headerFooterKind",
2048
- "variant"
2049
- ]
2050
- },
2051
- {
2052
- "type": "object",
2053
- "properties": {
2054
- "kind": {
2055
- "const": "story",
2056
- "type": "string"
2057
- },
2058
- "storyType": {
2059
- "const": "headerFooterPart",
2060
- "type": "string"
2061
- },
2062
- "refId": {
2063
- "type": "string"
2064
- }
2065
- },
2066
- "required": [
2067
- "kind",
2068
- "storyType",
2069
- "refId"
2070
- ]
2071
- },
2072
- {
2073
- "type": "object",
2074
- "properties": {
2075
- "kind": {
2076
- "const": "story",
2077
- "type": "string"
2078
- },
2079
- "storyType": {
2080
- "const": "footnote",
2081
- "type": "string"
2082
- },
2083
- "noteId": {
2084
- "type": "string"
2085
- }
2086
- },
2087
- "required": [
2088
- "kind",
2089
- "storyType",
2090
- "noteId"
2091
- ]
2092
- },
2093
- {
2094
- "type": "object",
2095
- "properties": {
2096
- "kind": {
2097
- "const": "story",
2098
- "type": "string"
2099
- },
2100
- "storyType": {
2101
- "const": "endnote",
2102
- "type": "string"
2103
- },
2104
- "noteId": {
2105
- "type": "string"
2106
- }
2107
- },
2108
- "required": [
2109
- "kind",
2110
- "storyType",
2111
- "noteId"
2112
- ]
2113
- },
2114
- {
2115
- "type": "object",
2116
- "properties": {
2117
- "kind": {
2118
- "const": "story",
2119
- "type": "string"
2120
- },
2121
- "storyType": {
2122
- "const": "textbox",
2123
- "type": "string"
2124
- },
2125
- "textboxId": {
2126
- "type": "string"
2127
- }
2128
- },
2129
- "required": [
2130
- "kind",
2131
- "storyType",
2132
- "textboxId"
2133
- ]
2134
- }
2135
- ],
2136
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
2137
- }
2138
- },
2139
- "required": [
2140
- "kind",
2141
- "nodeType",
2142
- "nodeId"
2143
- ]
2144
- },
2145
- "edge": {
2146
- "enum": [
2147
- "before",
2148
- "after"
2149
- ]
2150
- }
2151
- },
2152
- "required": [
2153
- "kind",
2154
- "node",
2155
- "edge"
2156
- ]
2157
- }
2158
- ],
2159
- "description": "A point in the document. Use {kind:'text', blockId, offset} for character positions or {kind:'nodeEdge', node:{kind:'block', nodeType, nodeId}, edge:'before'|'after'} for block boundaries."
2160
- },
2161
- "story": {
2162
- "oneOf": [
2163
- {
2164
- "type": "object",
2165
- "properties": {
2166
- "kind": {
2167
- "const": "story",
2168
- "type": "string"
2169
- },
2170
- "storyType": {
2171
- "const": "body",
2172
- "type": "string"
2173
- }
2174
- },
2175
- "required": [
2176
- "kind",
2177
- "storyType"
2178
- ]
2179
- },
2180
- {
2181
- "type": "object",
2182
- "properties": {
2183
- "kind": {
2184
- "const": "story",
2185
- "type": "string"
2186
- },
2187
- "storyType": {
2188
- "const": "headerFooterSlot",
2189
- "type": "string"
2190
- },
2191
- "section": {
2192
- "type": "object",
2193
- "properties": {
2194
- "kind": {
2195
- "const": "section",
2196
- "type": "string"
2197
- },
2198
- "sectionId": {
2199
- "type": "string"
2200
- }
2201
- },
2202
- "required": [
2203
- "kind",
2204
- "sectionId"
2205
- ]
2206
- },
2207
- "headerFooterKind": {
2208
- "enum": [
2209
- "header",
2210
- "footer"
2211
- ]
2212
- },
2213
- "variant": {
2214
- "enum": [
2215
- "default",
2216
- "first",
2217
- "even"
2218
- ]
2219
- },
2220
- "resolution": {
2221
- "enum": [
2222
- "effective",
2223
- "explicit"
2224
- ]
2225
- },
2226
- "onWrite": {
2227
- "enum": [
2228
- "materializeIfInherited",
2229
- "editResolvedPart",
2230
- "error"
2231
- ]
2232
- }
2233
- },
2234
- "required": [
2235
- "kind",
2236
- "storyType",
2237
- "section",
2238
- "headerFooterKind",
2239
- "variant"
2240
- ]
2241
- },
2242
- {
2243
- "type": "object",
2244
- "properties": {
2245
- "kind": {
2246
- "const": "story",
2247
- "type": "string"
2248
- },
2249
- "storyType": {
2250
- "const": "headerFooterPart",
2251
- "type": "string"
2252
- },
2253
- "refId": {
2254
- "type": "string"
2255
- }
2256
- },
2257
- "required": [
2258
- "kind",
2259
- "storyType",
2260
- "refId"
2261
- ]
2262
- },
2263
- {
2264
- "type": "object",
2265
- "properties": {
2266
- "kind": {
2267
- "const": "story",
2268
- "type": "string"
2269
- },
2270
- "storyType": {
2271
- "const": "footnote",
2272
- "type": "string"
2273
- },
2274
- "noteId": {
2275
- "type": "string"
2276
- }
2277
- },
2278
- "required": [
2279
- "kind",
2280
- "storyType",
2281
- "noteId"
2282
- ]
2283
- },
2284
- {
2285
- "type": "object",
2286
- "properties": {
2287
- "kind": {
2288
- "const": "story",
2289
- "type": "string"
2290
- },
2291
- "storyType": {
2292
- "const": "endnote",
2293
- "type": "string"
2294
- },
2295
- "noteId": {
2296
- "type": "string"
2297
- }
2298
- },
2299
- "required": [
2300
- "kind",
2301
- "storyType",
2302
- "noteId"
2303
- ]
2304
- },
2305
- {
2306
- "type": "object",
2307
- "properties": {
2308
- "kind": {
2309
- "const": "story",
2310
- "type": "string"
2311
- },
2312
- "storyType": {
2313
- "const": "textbox",
2314
- "type": "string"
2315
- },
2316
- "textboxId": {
2317
- "type": "string"
2318
- }
2319
- },
2320
- "required": [
2321
- "kind",
2322
- "storyType",
2323
- "textboxId"
2324
- ]
2325
- }
2326
- ],
2327
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
2328
- },
2329
- "coordinateSpace": {
2330
- "enum": [
2331
- "visible",
2332
- "tracked"
2333
- ]
2334
- }
2335
- },
2336
- "required": [
2337
- "kind",
2338
- "start",
2339
- "end"
2340
- ]
34
+ "reviewMode": {
35
+ "$ref": "#/$defs/SDProjectionReviewMode",
36
+ "description": "Only for actions 'markdown_projection', 'html_projection'. Omit for other actions."
37
+ },
38
+ "scope": {
39
+ "$ref": "#/$defs/SDProjectionScope",
40
+ "description": "Only for actions 'markdown_projection', 'html_projection'. Omit for other actions."
41
+ },
42
+ "includeSourceMap": {
43
+ "type": "boolean",
44
+ "description": "Only for actions 'markdown_projection', 'html_projection'. Omit for other actions."
45
+ },
46
+ "offset": {
47
+ "type": "number",
48
+ "minimum": 0,
49
+ "description": "Number of blocks to skip. Default: 0. Only for action 'blocks'. Omit for other actions."
50
+ },
51
+ "limit": {
52
+ "type": "number",
53
+ "minimum": 1,
54
+ "description": "Maximum blocks to return. Omit for all blocks. Only for action 'blocks'. Omit for other actions."
55
+ },
56
+ "nodeTypes": {
57
+ "type": "array",
58
+ "items": {
59
+ "enum": [
60
+ "paragraph",
61
+ "heading",
62
+ "listItem",
63
+ "table",
64
+ "tableRow",
65
+ "tableCell",
66
+ "tableOfContents",
67
+ "image",
68
+ "sdt"
69
+ ]
70
+ },
71
+ "description": "Filter by block types (e.g. ['paragraph', 'heading']). Omit for all types. Only for action 'blocks'. Omit for other actions."
72
+ },
73
+ "includeText": {
74
+ "type": "boolean",
75
+ "description": "When true, includes the full flattened block text in each block entry. Only for action 'blocks'. Omit for other actions."
76
+ }
77
+ },
78
+ "required": [
79
+ "action"
80
+ ],
81
+ "additionalProperties": false
82
+ },
83
+ "mutates": false,
84
+ "operations": [
85
+ {
86
+ "operationId": "doc.getText",
87
+ "intentAction": "text"
88
+ },
89
+ {
90
+ "operationId": "doc.getMarkdown",
91
+ "intentAction": "markdown"
92
+ },
93
+ {
94
+ "operationId": "doc.getHtml",
95
+ "intentAction": "html"
96
+ },
97
+ {
98
+ "operationId": "doc.projectMarkdown",
99
+ "intentAction": "markdown_projection"
100
+ },
101
+ {
102
+ "operationId": "doc.projectHtml",
103
+ "intentAction": "html_projection"
104
+ },
105
+ {
106
+ "operationId": "doc.info",
107
+ "intentAction": "info"
108
+ },
109
+ {
110
+ "operationId": "doc.extract",
111
+ "intentAction": "extract"
112
+ },
113
+ {
114
+ "operationId": "doc.blocks.list",
115
+ "intentAction": "blocks"
116
+ }
117
+ ]
118
+ },
119
+ {
120
+ "toolName": "superdoc_edit",
121
+ "description": "The primary tool for inserting content into documents. ALWAYS use action \"insert\" with type \"markdown\" to create headings, paragraphs, or any block content: this is faster and creates proper document structure in one call. Do NOT use superdoc_create for headings or paragraphs. The markdown parser creates headings from # markers (# = Heading1, ## = Heading2), bold from **text**, italic from *text*, and numbered/bullet lists. Position markdown inserts with \"target\" (a BlockNodeAddress like {kind:\"block\", nodeType, nodeId}) and \"placement\" (before, after, insideStart, insideEnd). Without a target, content appends at the end of the document. IMPORTANT: After a markdown insert, analyze the document context (what kind of document, how titles and body text are styled) and follow up with ONE superdoc_mutations call to format inserted blocks so they look like they belong. Each format.apply step accepts \"inline\" (fontFamily, fontSize, bold, underline, color), \"alignment\", and \"scope\" in the same step. Use scope: \"block\" so formatting covers the entire paragraph. Copy the exact property values from the existing get_content blocks (fontFamily, fontSize, color, alignment, bold, underline). Do NOT invent values: use what the blocks show. Also supports replace, delete, and undo/redo. For ordinary replace and delete, pass a \"ref\" from superdoc_search or superdoc_get_content blocks. A search ref covers only the matched substring; a block ref covers the entire block text, so use block refs when rewriting or shortening whole paragraphs. To replace every block in the main body, use action \"replace\" with target:{kind:\"story\",storyType:\"body\"}, one text/value/content payload, and changeMode:\"direct\". This replaces body content, not the DOCX package, and does not require a search first. Tracked whole-body replacement is unsupported. For multi-step redlines or whole-clause rewrites, prefer superdoc_mutations with where:{by:\"block\", nodeType, nodeId} from superdoc_get_content action \"blocks\" includeText:true rather than relying on text selectors. Refs expire after any mutation; always re-search before the next edit. For 2+ edits that must succeed or fail atomically, use superdoc_mutations instead. Before an exact HTML or Markdown insert/replace that must be fidelity-checked, use action \"check_support\", review its outcome and diagnostics, then pass its guard back as \"supportCheck\" on the unchanged write. Supports \"dryRun\" to preview changes and \"changeMode: tracked\" to record edits as tracked changes. Do NOT build \"target\" objects manually when a ref is available; prefer \"ref\" for simpler, more reliable targeting.\n\nEXAMPLES:\n 1. {\"action\":\"insert\",\"type\":\"markdown\",\"target\":{\"kind\":\"block\",\"nodeType\":\"paragraph\",\"nodeId\":\"<nodeId>\"},\"placement\":\"before\",\"value\":\"# Executive Summary\\n\\nThis agreement sets forth the principal terms...\",\"changeMode\":\"direct\"}\n 2. {\"action\":\"insert\",\"type\":\"html\",\"value\":\"<h2>Review heading</h2><p>Tracked rich content.</p>\",\"changeMode\":\"tracked\"}\n 3. {\"action\":\"insert\",\"type\":\"markdown\",\"value\":\"# Section Title\\n\\nParagraph content here.\\n\\n# Another Section\\n\\nMore content with **bold** and *italic*.\"}\n 4. {\"action\":\"replace\",\"ref\":\"<handle.ref>\",\"text\":\"new text here\"}\n 5. {\"action\":\"replace\",\"ref\":\"<handle.ref>\",\"value\":\"**Direct rich replacement**\",\"type\":\"markdown\",\"changeMode\":\"direct\"}\n 6. {\"action\":\"replace\",\"ref\":\"<handle.ref>\",\"value\":\"<strong>Tracked rich replacement</strong>\",\"type\":\"html\",\"changeMode\":\"tracked\"}\n 7. {\"action\":\"check_support\",\"operation\":\"insert\",\"input\":{\"type\":\"markdown\",\"value\":\"# Checked section\"},\"options\":{\"changeMode\":\"direct\"}}\n 8. {\"action\":\"replace\",\"target\":{\"kind\":\"story\",\"storyType\":\"body\"},\"value\":\"# Replacement\\n\\nComplete new body.\",\"type\":\"markdown\",\"changeMode\":\"direct\"}\n 9. {\"action\":\"delete\",\"ref\":\"<handle.ref>\"}\n 10. {\"action\":\"undo\"}",
122
+ "inputSchema": {
123
+ "type": "object",
124
+ "properties": {
125
+ "action": {
126
+ "type": "string",
127
+ "enum": [
128
+ "check_support",
129
+ "delete",
130
+ "insert",
131
+ "redo",
132
+ "replace",
133
+ "undo"
134
+ ],
135
+ "description": "The action to perform. One of: check_support, delete, insert, redo, replace, undo."
136
+ },
137
+ "force": {
138
+ "type": "boolean",
139
+ "description": "Bypass confirmation checks."
140
+ },
141
+ "changeMode": {
142
+ "type": "string",
143
+ "description": "Edit mode: \"direct\" applies changes immediately, \"tracked\" records as suggestions."
144
+ },
145
+ "dryRun": {
146
+ "type": "boolean",
147
+ "description": "Preview the result without applying changes. Only for actions 'insert', 'replace', 'delete'. Omit for other actions."
148
+ },
149
+ "supportCheck": {
150
+ "type": "object",
151
+ "properties": {
152
+ "version": {
153
+ "const": "sd-html-markdown-check/1",
154
+ "type": "string"
155
+ },
156
+ "operation": {
157
+ "enum": [
158
+ "insert",
159
+ "replace"
160
+ ]
161
+ },
162
+ "evaluatedRevision": {
163
+ "type": "string"
164
+ },
165
+ "requestSha256": {
166
+ "type": "string"
167
+ },
168
+ "analysisSha256": {
169
+ "type": "string"
170
+ }
171
+ },
172
+ "required": [
173
+ "version",
174
+ "operation",
175
+ "evaluatedRevision",
176
+ "requestSha256",
177
+ "analysisSha256"
178
+ ],
179
+ "additionalProperties": false,
180
+ "description": "Guard returned by capabilities check for this exact HTML or Markdown write. Only for actions 'insert', 'replace'. Omit for other actions."
181
+ },
182
+ "target": {
183
+ "oneOf": [
184
+ {
185
+ "oneOf": [
186
+ {
187
+ "$ref": "#/$defs/BlockNodeAddress",
188
+ "description": "Block address for structural insertion: {kind:'block', nodeType:'...', nodeId:'...'}."
189
+ },
190
+ {
191
+ "type": "object",
192
+ "properties": {
193
+ "kind": {
194
+ "const": "story",
195
+ "type": "string"
196
+ },
197
+ "storyType": {
198
+ "const": "body",
199
+ "type": "string"
2341
200
  }
201
+ },
202
+ "additionalProperties": false,
203
+ "required": [
204
+ "kind",
205
+ "storyType"
2342
206
  ]
2343
207
  }
2344
208
  ],
@@ -2349,7 +213,7 @@
2349
213
  "description": "Selection target: {kind:'selection', start:{kind:'text', blockId, offset}, end:{kind:'text', blockId, offset}}. Use 'ref' instead when you have a search result handle."
2350
214
  }
2351
215
  ],
2352
- "description": "Block address for structural insertion: {kind:'block', nodeType:'...', nodeId:'...'}."
216
+ "description": "Block address for structural insertion: {kind:'block', nodeType:'...', nodeId:'...'}. Only for actions 'insert', 'replace', 'delete'. Omit for other actions."
2353
217
  },
2354
218
  "in": {
2355
219
  "oneOf": [
@@ -2527,28 +391,56 @@
2527
391
  ],
2528
392
  "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
2529
393
  }
2530
- ],
2531
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
394
+ ],
395
+ "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
396
+ },
397
+ {
398
+ "$ref": "#/$defs/StoryLocator",
399
+ "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
400
+ }
401
+ ],
402
+ "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes. Only for actions 'insert', 'replace', 'delete'. Omit for other actions."
403
+ },
404
+ "value": {
405
+ "oneOf": [
406
+ {
407
+ "type": "string",
408
+ "description": "HTML or Markdown content to convert and insert."
409
+ },
410
+ {
411
+ "type": "string",
412
+ "description": "HTML or Markdown that replaces the complete main body."
413
+ }
414
+ ],
415
+ "description": "HTML or Markdown content to convert and insert. Only for actions 'insert', 'replace'. Omit for other actions."
416
+ },
417
+ "type": {
418
+ "oneOf": [
419
+ {
420
+ "type": "string",
421
+ "oneOf": [
422
+ {
423
+ "const": "text",
424
+ "description": "Plain-text content format. Omit for the same 'text' default.",
425
+ "type": "string"
426
+ },
427
+ {
428
+ "enum": [
429
+ "markdown",
430
+ "html"
431
+ ]
432
+ }
433
+ ]
2532
434
  },
2533
435
  {
2534
- "$ref": "#/$defs/StoryLocator",
2535
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
436
+ "type": "string",
437
+ "enum": [
438
+ "html",
439
+ "markdown"
440
+ ]
2536
441
  }
2537
442
  ],
2538
- "description": "Story scope. Defaults to document body when omitted. Use {kind:'story', storyType:'body'} for body, or other storyType values for headers, footers, footnotes, endnotes."
2539
- },
2540
- "value": {
2541
- "type": "string",
2542
- "description": "Text content to insert. Only for action 'insert'. Omit for other actions."
2543
- },
2544
- "type": {
2545
- "type": "string",
2546
- "description": "Content format: 'text' (default), 'markdown', or 'html'. Only for action 'insert'. Omit for other actions.",
2547
- "enum": [
2548
- "text",
2549
- "markdown",
2550
- "html"
2551
- ]
443
+ "description": "Only for actions 'insert', 'replace'. Omit for other actions."
2552
444
  },
2553
445
  "ref": {
2554
446
  "oneOf": [
@@ -2570,7 +462,16 @@
2570
462
  "description": "Handle ref string from a superdoc_search result. Pass the handle.ref value directly (e.g. 'text:eyJ...'). Preferred over 'target' for inline formatting."
2571
463
  }
2572
464
  ],
2573
- "description": "Handle ref from superdoc_search result (pass handle.ref value directly). Preferred over building a target object."
465
+ "description": "Handle ref from superdoc_search result (pass handle.ref value directly). Preferred over building a target object. Only for actions 'insert', 'replace', 'delete'. Omit for other actions."
466
+ },
467
+ "placement": {
468
+ "enum": [
469
+ "before",
470
+ "after",
471
+ "insideStart",
472
+ "insideEnd"
473
+ ],
474
+ "description": "Where to place content relative to target: 'before', 'after', 'insideStart', or 'insideEnd'. Only for action 'insert'. Omit for other actions."
2574
475
  },
2575
476
  "content": {
2576
477
  "oneOf": [
@@ -2601,21 +502,11 @@
2601
502
  "properties": {}
2602
503
  }
2603
504
  }
2604
- ],
2605
- "description": "Document fragment to replace with (structured content)."
505
+ ]
2606
506
  }
2607
507
  ],
2608
508
  "description": "Document fragment to insert (structured content). Only for actions 'insert', 'replace'. Omit for other actions."
2609
509
  },
2610
- "placement": {
2611
- "enum": [
2612
- "before",
2613
- "after",
2614
- "insideStart",
2615
- "insideEnd"
2616
- ],
2617
- "description": "Where to place content relative to target: 'before', 'after', 'insideStart', or 'insideEnd'. Only for action 'insert'. Omit for other actions."
2618
- },
2619
510
  "nestingPolicy": {
2620
511
  "oneOf": [
2621
512
  {
@@ -2648,11 +539,296 @@
2648
539
  },
2649
540
  "text": {
2650
541
  "type": "string",
2651
- "description": "Replacement text content. Only for action 'replace'. Omit for other actions."
542
+ "description": "Complete replacement text for the main body. Only for action 'replace'. Omit for other actions."
2652
543
  },
2653
544
  "behavior": {
2654
545
  "$ref": "#/$defs/DeleteBehavior",
2655
546
  "description": "Delete behavior: 'selection' (default) or 'exact'. Only for action 'delete'. Omit for other actions."
547
+ },
548
+ "operation": {
549
+ "oneOf": [
550
+ {
551
+ "oneOf": [
552
+ {
553
+ "enum": [
554
+ "insert",
555
+ "replace"
556
+ ]
557
+ },
558
+ {
559
+ "const": "projectHtml",
560
+ "type": "string"
561
+ }
562
+ ]
563
+ },
564
+ {
565
+ "const": "projectMarkdown",
566
+ "type": "string"
567
+ }
568
+ ],
569
+ "description": "Required for action 'check_support'."
570
+ },
571
+ "input": {
572
+ "oneOf": [
573
+ {
574
+ "oneOf": [
575
+ {
576
+ "oneOf": [
577
+ {
578
+ "oneOf": [
579
+ {
580
+ "type": "object",
581
+ "properties": {
582
+ "in": {
583
+ "$ref": "#/$defs/StoryLocator"
584
+ },
585
+ "target": {
586
+ "oneOf": [
587
+ {
588
+ "$ref": "#/$defs/SelectionTarget"
589
+ },
590
+ {
591
+ "$ref": "#/$defs/BlockNodeAddress"
592
+ }
593
+ ]
594
+ },
595
+ "value": {
596
+ "type": "string"
597
+ },
598
+ "type": {
599
+ "enum": [
600
+ "html",
601
+ "markdown"
602
+ ]
603
+ },
604
+ "placement": {
605
+ "enum": [
606
+ "before",
607
+ "after",
608
+ "insideStart",
609
+ "insideEnd"
610
+ ]
611
+ }
612
+ },
613
+ "additionalProperties": false,
614
+ "required": [
615
+ "target",
616
+ "value",
617
+ "type"
618
+ ]
619
+ },
620
+ {
621
+ "type": "object",
622
+ "properties": {
623
+ "in": {
624
+ "$ref": "#/$defs/StoryLocator"
625
+ },
626
+ "ref": {
627
+ "type": "string",
628
+ "minLength": 1
629
+ },
630
+ "value": {
631
+ "type": "string"
632
+ },
633
+ "type": {
634
+ "enum": [
635
+ "html",
636
+ "markdown"
637
+ ]
638
+ },
639
+ "placement": {
640
+ "enum": [
641
+ "before",
642
+ "after",
643
+ "insideStart",
644
+ "insideEnd"
645
+ ]
646
+ }
647
+ },
648
+ "additionalProperties": false,
649
+ "required": [
650
+ "ref",
651
+ "value",
652
+ "type"
653
+ ]
654
+ },
655
+ {
656
+ "type": "object",
657
+ "properties": {
658
+ "in": {
659
+ "$ref": "#/$defs/StoryLocator"
660
+ },
661
+ "value": {
662
+ "type": "string"
663
+ },
664
+ "type": {
665
+ "enum": [
666
+ "html",
667
+ "markdown"
668
+ ]
669
+ },
670
+ "placement": {
671
+ "enum": [
672
+ "before",
673
+ "after",
674
+ "insideStart",
675
+ "insideEnd"
676
+ ]
677
+ }
678
+ },
679
+ "additionalProperties": false,
680
+ "required": [
681
+ "value",
682
+ "type"
683
+ ]
684
+ }
685
+ ]
686
+ },
687
+ {
688
+ "oneOf": [
689
+ {
690
+ "type": "object",
691
+ "properties": {
692
+ "in": {
693
+ "$ref": "#/$defs/StoryLocator"
694
+ },
695
+ "target": {
696
+ "oneOf": [
697
+ {
698
+ "$ref": "#/$defs/SelectionTarget"
699
+ },
700
+ {
701
+ "$ref": "#/$defs/BlockNodeAddress"
702
+ }
703
+ ]
704
+ },
705
+ "value": {
706
+ "type": "string"
707
+ },
708
+ "type": {
709
+ "enum": [
710
+ "html",
711
+ "markdown"
712
+ ]
713
+ },
714
+ "nestingPolicy": {
715
+ "type": "object",
716
+ "properties": {
717
+ "tables": {
718
+ "enum": [
719
+ "forbid",
720
+ "allow"
721
+ ]
722
+ }
723
+ },
724
+ "additionalProperties": false,
725
+ "description": "Controls nesting behavior. tables: 'allow' permits inserting tables inside other tables."
726
+ }
727
+ },
728
+ "additionalProperties": false,
729
+ "required": [
730
+ "target",
731
+ "value",
732
+ "type"
733
+ ]
734
+ },
735
+ {
736
+ "type": "object",
737
+ "properties": {
738
+ "in": {
739
+ "$ref": "#/$defs/StoryLocator"
740
+ },
741
+ "ref": {
742
+ "type": "string",
743
+ "minLength": 1
744
+ },
745
+ "value": {
746
+ "type": "string"
747
+ },
748
+ "type": {
749
+ "enum": [
750
+ "html",
751
+ "markdown"
752
+ ]
753
+ },
754
+ "nestingPolicy": {
755
+ "type": "object",
756
+ "properties": {
757
+ "tables": {
758
+ "enum": [
759
+ "forbid",
760
+ "allow"
761
+ ]
762
+ }
763
+ },
764
+ "additionalProperties": false,
765
+ "description": "Controls nesting behavior. tables: 'allow' permits inserting tables inside other tables."
766
+ }
767
+ },
768
+ "additionalProperties": false,
769
+ "required": [
770
+ "ref",
771
+ "value",
772
+ "type"
773
+ ]
774
+ }
775
+ ]
776
+ }
777
+ ]
778
+ },
779
+ {
780
+ "type": "object",
781
+ "properties": {
782
+ "in": {
783
+ "$ref": "#/$defs/StoryLocator"
784
+ },
785
+ "reviewMode": {
786
+ "$ref": "#/$defs/SDProjectionReviewMode"
787
+ },
788
+ "scope": {
789
+ "$ref": "#/$defs/SDProjectionScope"
790
+ },
791
+ "includeSourceMap": {
792
+ "type": "boolean"
793
+ }
794
+ },
795
+ "additionalProperties": false
796
+ }
797
+ ]
798
+ },
799
+ {
800
+ "type": "object",
801
+ "properties": {
802
+ "in": {
803
+ "$ref": "#/$defs/StoryLocator"
804
+ },
805
+ "reviewMode": {
806
+ "$ref": "#/$defs/SDProjectionReviewMode"
807
+ },
808
+ "scope": {
809
+ "$ref": "#/$defs/SDProjectionScope"
810
+ },
811
+ "includeSourceMap": {
812
+ "type": "boolean"
813
+ }
814
+ },
815
+ "additionalProperties": false
816
+ }
817
+ ],
818
+ "description": "Only for action 'check_support'. Omit for other actions."
819
+ },
820
+ "options": {
821
+ "type": "object",
822
+ "properties": {
823
+ "changeMode": {
824
+ "enum": [
825
+ "direct",
826
+ "tracked"
827
+ ]
828
+ }
829
+ },
830
+ "additionalProperties": false,
831
+ "description": "Only for action 'check_support'. Omit for other actions."
2656
832
  }
2657
833
  },
2658
834
  "required": [
@@ -2677,6 +853,20 @@
2677
853
  [
2678
854
  "value"
2679
855
  ],
856
+ [
857
+ "target",
858
+ "value",
859
+ "type"
860
+ ],
861
+ [
862
+ "ref",
863
+ "value",
864
+ "type"
865
+ ],
866
+ [
867
+ "value",
868
+ "type"
869
+ ],
2680
870
  [
2681
871
  "content"
2682
872
  ]
@@ -2694,6 +884,10 @@
2694
884
  "ref",
2695
885
  "text"
2696
886
  ],
887
+ [
888
+ "target",
889
+ "text"
890
+ ],
2697
891
  [
2698
892
  "target",
2699
893
  "content"
@@ -2701,6 +895,25 @@
2701
895
  [
2702
896
  "ref",
2703
897
  "content"
898
+ ],
899
+ [
900
+ "target",
901
+ "content"
902
+ ],
903
+ [
904
+ "target",
905
+ "value",
906
+ "type"
907
+ ],
908
+ [
909
+ "ref",
910
+ "value",
911
+ "type"
912
+ ],
913
+ [
914
+ "target",
915
+ "value",
916
+ "type"
2704
917
  ]
2705
918
  ]
2706
919
  },
@@ -2716,6 +929,26 @@
2716
929
  ]
2717
930
  ]
2718
931
  },
932
+ {
933
+ "operationId": "doc.capabilities.check",
934
+ "intentAction": "check_support",
935
+ "requiredOneOf": [
936
+ [
937
+ "operation",
938
+ "input"
939
+ ],
940
+ [
941
+ "operation",
942
+ "input"
943
+ ],
944
+ [
945
+ "operation"
946
+ ],
947
+ [
948
+ "operation"
949
+ ]
950
+ ]
951
+ },
2719
952
  {
2720
953
  "operationId": "doc.history.undo",
2721
954
  "intentAction": "undo"