@supportpages.io/wtfm 0.0.0-stage → 0.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 (275) hide show
  1. package/LICENSE +201 -0
  2. package/NOTICE +23 -0
  3. package/README.md +392 -2
  4. package/dist/actions.d.ts +98 -0
  5. package/dist/actions.js +86 -0
  6. package/dist/actions.js.map +1 -0
  7. package/dist/agent-settings.d.ts +22 -0
  8. package/dist/agent-settings.js +35 -0
  9. package/dist/agent-settings.js.map +1 -0
  10. package/dist/api.d.ts +14 -0
  11. package/dist/api.js +159 -0
  12. package/dist/api.js.map +1 -0
  13. package/dist/article-link.d.ts +16 -0
  14. package/dist/article-link.js +25 -0
  15. package/dist/article-link.js.map +1 -0
  16. package/dist/artifacts.d.ts +45 -0
  17. package/dist/artifacts.js +144 -0
  18. package/dist/artifacts.js.map +1 -0
  19. package/dist/brand.d.ts +4 -0
  20. package/dist/brand.js +9 -0
  21. package/dist/brand.js.map +1 -0
  22. package/dist/bridge.d.ts +2964 -0
  23. package/dist/bridge.js +1036 -0
  24. package/dist/bridge.js.map +1 -0
  25. package/dist/capacity.d.ts +5 -0
  26. package/dist/capacity.js +11 -0
  27. package/dist/capacity.js.map +1 -0
  28. package/dist/credentials.d.ts +13 -0
  29. package/dist/credentials.js +88 -0
  30. package/dist/credentials.js.map +1 -0
  31. package/dist/development-tls.d.ts +8 -0
  32. package/dist/development-tls.js +38 -0
  33. package/dist/development-tls.js.map +1 -0
  34. package/dist/errors.d.ts +15 -0
  35. package/dist/errors.js +18 -0
  36. package/dist/errors.js.map +1 -0
  37. package/dist/export.d.ts +11 -0
  38. package/dist/export.js +91 -0
  39. package/dist/export.js.map +1 -0
  40. package/dist/hosted-operations.d.ts +108 -0
  41. package/dist/hosted-operations.js +120 -0
  42. package/dist/hosted-operations.js.map +1 -0
  43. package/dist/hosting-benefits.d.ts +66 -0
  44. package/dist/hosting-benefits.js +67 -0
  45. package/dist/hosting-benefits.js.map +1 -0
  46. package/dist/index.d.ts +2 -0
  47. package/dist/index.js +49 -0
  48. package/dist/index.js.map +1 -0
  49. package/dist/local-inventory.d.ts +22 -0
  50. package/dist/local-inventory.js +59 -0
  51. package/dist/local-inventory.js.map +1 -0
  52. package/dist/local-setup.d.ts +208 -0
  53. package/dist/local-setup.js +140 -0
  54. package/dist/local-setup.js.map +1 -0
  55. package/dist/pairing.d.ts +71 -0
  56. package/dist/pairing.js +235 -0
  57. package/dist/pairing.js.map +1 -0
  58. package/dist/preferences.d.ts +18 -0
  59. package/dist/preferences.js +44 -0
  60. package/dist/preferences.js.map +1 -0
  61. package/dist/progress.d.ts +205 -0
  62. package/dist/progress.js +224 -0
  63. package/dist/progress.js.map +1 -0
  64. package/dist/reminders.d.ts +31 -0
  65. package/dist/reminders.js +73 -0
  66. package/dist/reminders.js.map +1 -0
  67. package/dist/replace-connection.d.ts +6 -0
  68. package/dist/replace-connection.js +77 -0
  69. package/dist/replace-connection.js.map +1 -0
  70. package/dist/repository-actions.d.ts +18 -0
  71. package/dist/repository-actions.js +9 -0
  72. package/dist/repository-actions.js.map +1 -0
  73. package/dist/repository-benefits.d.ts +96 -0
  74. package/dist/repository-benefits.js +64 -0
  75. package/dist/repository-benefits.js.map +1 -0
  76. package/dist/run-update.d.ts +17 -0
  77. package/dist/run-update.js +27 -0
  78. package/dist/run-update.js.map +1 -0
  79. package/dist/runs.d.ts +541 -0
  80. package/dist/runs.js +146 -0
  81. package/dist/runs.js.map +1 -0
  82. package/dist/runtime.d.ts +12 -0
  83. package/dist/runtime.js +58 -0
  84. package/dist/runtime.js.map +1 -0
  85. package/dist/schema.d.ts +277 -0
  86. package/dist/schema.js +66 -0
  87. package/dist/schema.js.map +1 -0
  88. package/dist/server.d.ts +4 -0
  89. package/dist/server.js +298 -0
  90. package/dist/server.js.map +1 -0
  91. package/dist/session.d.ts +1714 -0
  92. package/dist/session.js +619 -0
  93. package/dist/session.js.map +1 -0
  94. package/dist/settings.d.ts +9 -0
  95. package/dist/settings.js +21 -0
  96. package/dist/settings.js.map +1 -0
  97. package/dist/sync.d.ts +495 -0
  98. package/dist/sync.js +191 -0
  99. package/dist/sync.js.map +1 -0
  100. package/dist/telemetry-scrub.d.ts +13 -0
  101. package/dist/telemetry-scrub.js +51 -0
  102. package/dist/telemetry-scrub.js.map +1 -0
  103. package/dist/telemetry.d.ts +73 -0
  104. package/dist/telemetry.js +173 -0
  105. package/dist/telemetry.js.map +1 -0
  106. package/dist/walkthroughs.d.ts +224 -0
  107. package/dist/walkthroughs.js +109 -0
  108. package/dist/walkthroughs.js.map +1 -0
  109. package/dist/workspace.d.ts +14 -0
  110. package/dist/workspace.js +127 -0
  111. package/dist/workspace.js.map +1 -0
  112. package/dist/writer-agent.d.ts +21 -0
  113. package/dist/writer-agent.js +27 -0
  114. package/dist/writer-agent.js.map +1 -0
  115. package/dist/writer-entry.d.ts +171 -0
  116. package/dist/writer-entry.js +233 -0
  117. package/dist/writer-entry.js.map +1 -0
  118. package/dist/writing-style.d.ts +7 -0
  119. package/dist/writing-style.js +52 -0
  120. package/dist/writing-style.js.map +1 -0
  121. package/engine/SYNC.json +4 -0
  122. package/engine/VERSION +1 -0
  123. package/engine/detect-project/README.md +141 -0
  124. package/engine/detect-project/SKILL.md +1421 -0
  125. package/engine/detect-project/assets/desktop/desktop-frame.css +428 -0
  126. package/engine/detect-project/assets/game/game-frame.css +132 -0
  127. package/engine/detect-project/assets/macosui/LICENSE-puppertino.txt +21 -0
  128. package/engine/detect-project/assets/macosui/VERSIONS.txt +1 -0
  129. package/engine/detect-project/assets/macosui/fonts.css +15 -0
  130. package/engine/detect-project/assets/macosui/macos-frame.css +481 -0
  131. package/engine/detect-project/assets/macosui/puppertino.css +2153 -0
  132. package/engine/detect-project/assets/mobileui/LICENSE-fonts.txt +13 -0
  133. package/engine/detect-project/assets/mobileui/LICENSE-framework7.txt +52 -0
  134. package/engine/detect-project/assets/mobileui/VERSIONS.txt +6 -0
  135. package/engine/detect-project/assets/mobileui/device-frame.css +316 -0
  136. package/engine/detect-project/assets/mobileui/f7-color-theme.mjs +1345 -0
  137. package/engine/detect-project/assets/mobileui/f7-icons-names.json +1254 -0
  138. package/engine/detect-project/assets/mobileui/fonts.css +16 -0
  139. package/engine/detect-project/assets/mobileui/framework7-components.css +39 -0
  140. package/engine/detect-project/assets/mobileui/framework7-core.css +5245 -0
  141. package/engine/detect-project/assets/mobileui/icons.css +31 -0
  142. package/engine/detect-project/assets/mobileui/md3-defaults.css +89 -0
  143. package/engine/detect-project/assets/mobileui/platforms.json +46 -0
  144. package/engine/detect-project/assets/tailwind-fallback.css +1729 -0
  145. package/engine/detect-project/assets/webtui/LICENSE-webtui.txt +28 -0
  146. package/engine/detect-project/assets/webtui/VERSIONS.txt +7 -0
  147. package/engine/detect-project/assets/webtui/terminal-frame.css +195 -0
  148. package/engine/detect-project/assets/webtui/theme-catppuccin.css +1 -0
  149. package/engine/detect-project/assets/webtui/theme-everforest.css +1 -0
  150. package/engine/detect-project/assets/webtui/theme-gruvbox.css +1 -0
  151. package/engine/detect-project/assets/webtui/theme-nord.css +1 -0
  152. package/engine/detect-project/assets/webtui/theme-vitesse.css +1 -0
  153. package/engine/detect-project/assets/webtui/themes.json +37 -0
  154. package/engine/detect-project/assets/webtui/webtui-core.css +1 -0
  155. package/engine/detect-project/assets/win32ui/7css.css +2 -0
  156. package/engine/detect-project/assets/win32ui/LICENSE-7css.txt +21 -0
  157. package/engine/detect-project/assets/win32ui/VERSIONS.txt +1 -0
  158. package/engine/detect-project/assets/win32ui/win32-frame.css +278 -0
  159. package/engine/detect-project/package-lock.json +12 -0
  160. package/engine/detect-project/package.json +10 -0
  161. package/engine/detect-project/scripts/apply_runtime_profiles.js +313 -0
  162. package/engine/detect-project/scripts/check_css_health.js +412 -0
  163. package/engine/detect-project/scripts/check_project_map.js +150 -0
  164. package/engine/detect-project/scripts/check_runtime_coverage.js +311 -0
  165. package/engine/detect-project/scripts/check_runtime_recipe_quality.js +184 -0
  166. package/engine/detect-project/scripts/classify_app_type.sh +246 -0
  167. package/engine/detect-project/scripts/classify_surface.sh +95 -0
  168. package/engine/detect-project/scripts/classify_workspace.js +39 -0
  169. package/engine/detect-project/scripts/compile_css.sh +447 -0
  170. package/engine/detect-project/scripts/detect_static.js +645 -0
  171. package/engine/detect-project/scripts/detect_structure.js +187 -0
  172. package/engine/detect-project/scripts/include_census.js +451 -0
  173. package/engine/detect-project/scripts/json_get.js +142 -0
  174. package/engine/detect-project/scripts/merge_json.js +52 -0
  175. package/engine/detect-project/scripts/recommend_model_tier.js +252 -0
  176. package/engine/detect-project/scripts/resolve_route_chains.js +135 -0
  177. package/engine/detect-project/scripts/run_css_build.sh +40 -0
  178. package/engine/detect-project/scripts/sanitize_css.js +83 -0
  179. package/engine/detect-project/scripts/test_classify_surface.js +108 -0
  180. package/engine/detect-project/scripts/test_node_helpers.js +142 -0
  181. package/engine/detect-project/scripts/test_recommend_model_tier.js +119 -0
  182. package/engine/detect-project/scripts/test_resolve_route_chains.js +182 -0
  183. package/engine/detect-project/scripts/test_runtime_coverage.js +323 -0
  184. package/engine/detect-project/scripts/test_runtime_recipe_quality.js +187 -0
  185. package/engine/detect-project/scripts/theme_overrides.js +169 -0
  186. package/engine/detect-project/scripts/write_branding.js +129 -0
  187. package/engine/generate-illustrated-article/SKILL.md +461 -0
  188. package/engine/generate-illustrated-article/contracts/desktop.md +90 -0
  189. package/engine/generate-illustrated-article/contracts/game.md +38 -0
  190. package/engine/generate-illustrated-article/contracts/label-evidence.md +38 -0
  191. package/engine/generate-illustrated-article/contracts/macos.md +79 -0
  192. package/engine/generate-illustrated-article/contracts/mobile.md +40 -0
  193. package/engine/generate-illustrated-article/contracts/terminal.md +29 -0
  194. package/engine/generate-illustrated-article/contracts/win32.md +43 -0
  195. package/engine/generate-illustrated-article/package-lock.json +366 -0
  196. package/engine/generate-illustrated-article/package.json +15 -0
  197. package/engine/generate-illustrated-article/scripts/article_blocks.js +34 -0
  198. package/engine/generate-illustrated-article/scripts/check_article_json.js +105 -0
  199. package/engine/generate-illustrated-article/scripts/emit_walkthrough_signals.js +100 -0
  200. package/engine/generate-illustrated-article/scripts/extract_images.js +187 -0
  201. package/engine/generate-illustrated-article/scripts/generate_content_images.js +376 -0
  202. package/engine/generate-illustrated-article/scripts/include_census.js +451 -0
  203. package/engine/generate-illustrated-article/scripts/inject_assets.js +1691 -0
  204. package/engine/generate-illustrated-article/scripts/jit_mockup_css.js +191 -0
  205. package/engine/generate-illustrated-article/scripts/label_evidence.js +87 -0
  206. package/engine/generate-illustrated-article/scripts/lint_article_copy.js +252 -0
  207. package/engine/generate-illustrated-article/scripts/lint_mockup_fidelity.js +2403 -0
  208. package/engine/generate-illustrated-article/scripts/polish_tickets.js +1148 -0
  209. package/engine/generate-illustrated-article/scripts/related_repos.sh +52 -0
  210. package/engine/generate-illustrated-article/scripts/render_all.js +177 -0
  211. package/engine/generate-illustrated-article/scripts/render_mockup.js +665 -0
  212. package/engine/generate-illustrated-article/scripts/render_ready.js +164 -0
  213. package/engine/generate-illustrated-article/scripts/resolve_workspace.sh +86 -0
  214. package/engine/generate-illustrated-article/scripts/runtime_region_geometry.js +55 -0
  215. package/engine/generate-illustrated-article/scripts/source_paths.js +49 -0
  216. package/engine/generate-illustrated-article/scripts/test_control_visibility.js +30 -0
  217. package/engine/generate-illustrated-article/scripts/test_emit_walkthrough_signals.js +157 -0
  218. package/engine/generate-illustrated-article/scripts/test_generate_content_images.js +168 -0
  219. package/engine/generate-illustrated-article/scripts/test_include_census.js +126 -0
  220. package/engine/generate-illustrated-article/scripts/test_label_evidence.js +49 -0
  221. package/engine/generate-illustrated-article/scripts/test_lint_article_copy.js +138 -0
  222. package/engine/generate-illustrated-article/scripts/test_lint_mockup_fidelity.js +653 -0
  223. package/engine/generate-illustrated-article/scripts/test_node_ports.js +152 -0
  224. package/engine/generate-illustrated-article/scripts/test_polish_tickets.js +481 -0
  225. package/engine/generate-illustrated-article/scripts/test_related_repos.js +64 -0
  226. package/engine/generate-illustrated-article/scripts/test_render_ready.js +85 -0
  227. package/engine/generate-illustrated-article/scripts/test_source_paths.js +68 -0
  228. package/engine/generate-illustrated-article/scripts/trace_hook.js +79 -0
  229. package/engine/generate-illustrated-article/scripts/trace_hook.sh +4 -0
  230. package/engine/generate-illustrated-article/scripts/validate_html.js +114 -0
  231. package/engine/generate-illustrated-article/scripts/watermark.js +69 -0
  232. package/install.sh +14 -0
  233. package/package.json +57 -4
  234. package/scripts/auth.mjs +33 -0
  235. package/scripts/auto-update.mjs +7 -0
  236. package/scripts/build-plugin.mjs +58 -0
  237. package/scripts/build-release.mjs +94 -0
  238. package/scripts/check-release.mjs +40 -0
  239. package/scripts/check-runtime.mjs +10 -0
  240. package/scripts/cli.mjs +8 -0
  241. package/scripts/install.mjs +64 -0
  242. package/scripts/lib/agent-runner.mjs +181 -0
  243. package/scripts/lib/agent-settings.mjs +215 -0
  244. package/scripts/lib/article-skills.mjs +82 -0
  245. package/scripts/lib/auto-update.mjs +50 -0
  246. package/scripts/lib/brand.mjs +9 -0
  247. package/scripts/lib/browser.mjs +12 -0
  248. package/scripts/lib/claude-connection.mjs +33 -0
  249. package/scripts/lib/claude-permissions.mjs +47 -0
  250. package/scripts/lib/claude-plugin.mjs +15 -0
  251. package/scripts/lib/claude-writer.mjs +10 -0
  252. package/scripts/lib/cli-main.mjs +85 -0
  253. package/scripts/lib/cli.mjs +888 -0
  254. package/scripts/lib/codex-config.mjs +51 -0
  255. package/scripts/lib/codex-integration.mjs +61 -0
  256. package/scripts/lib/codex-skill.mjs +34 -0
  257. package/scripts/lib/harness-models.mjs +109 -0
  258. package/scripts/lib/install.mjs +269 -0
  259. package/scripts/lib/managed-writer.mjs +38 -0
  260. package/scripts/lib/planning.mjs +263 -0
  261. package/scripts/lib/prepare-update.mjs +85 -0
  262. package/scripts/lib/refresh-writers.mjs +12 -0
  263. package/scripts/lib/remove.mjs +167 -0
  264. package/scripts/lib/renderer.mjs +34 -0
  265. package/scripts/lib/terminal.mjs +252 -0
  266. package/scripts/lib/uninit.mjs +72 -0
  267. package/scripts/lib/update.mjs +55 -0
  268. package/scripts/lib/writer-recovery.mjs +35 -0
  269. package/scripts/lib/yolo.mjs +362 -0
  270. package/scripts/plugin-session.mjs +65 -0
  271. package/scripts/prepare-update.mjs +12 -0
  272. package/scripts/publish-release.mjs +92 -0
  273. package/scripts/skills/supportpages/SKILL.md +120 -0
  274. package/scripts/smoke-release.mjs +101 -0
  275. package/server.json +27 -0
@@ -0,0 +1,2964 @@
1
+ import { HostedOperations } from './hosted-operations.js';
2
+ import { z } from 'zod';
3
+ import { ApiClient } from './api.js';
4
+ import { Workspace } from './workspace.js';
5
+ import { contextSchema, remoteArticleSchema, articleType, type Binding, type LocalSettings } from './schema.js';
6
+ import { publicError } from './errors.js';
7
+ import { LocalSetup } from './local-setup.js';
8
+ import { ProgressRelay } from './progress.js';
9
+ import { Runs, type Run } from './runs.js';
10
+ /** What to do about an analysis that is missing or was rejected by validation. */
11
+ export declare function analysisInstruction(analysis: {
12
+ status: string;
13
+ app_type?: unknown;
14
+ error?: {
15
+ message?: string;
16
+ };
17
+ }): string | undefined;
18
+ export declare class Bridge {
19
+ ws: Workspace;
20
+ api: ApiClient;
21
+ skillsDir: string;
22
+ private sessionId;
23
+ private source?;
24
+ private configDir?;
25
+ readonly relay: ProgressRelay;
26
+ private operations;
27
+ lock<T>(operation: () => Promise<T>): Promise<T>;
28
+ close(): Promise<unknown>;
29
+ get stateRoot(): string;
30
+ constructor(ws: Workspace, api: ApiClient, skillsDir: string, sessionId?: `${string}-${string}-${string}-${string}-${string}`, source?: {
31
+ source_commit: string | null;
32
+ source_dirty: boolean;
33
+ } | undefined, configDir?: string | undefined);
34
+ repositoryReminders(enabled?: boolean): Promise<{
35
+ enabled: boolean;
36
+ api_origin: string;
37
+ project_id: string;
38
+ scope: string;
39
+ }>;
40
+ /** Needs no help centre or sign-in: the preference belongs to this device's local folders. */
41
+ hostingReminders(enabled?: boolean): Promise<{
42
+ enabled: boolean;
43
+ api_origin: string;
44
+ scope: string;
45
+ }>;
46
+ get runs(): Runs;
47
+ resumeWriterCompletion(): Promise<void>;
48
+ get setup(): LocalSetup;
49
+ sync(): Promise<{
50
+ version: number;
51
+ status: "ready";
52
+ project: {
53
+ name: string;
54
+ id?: string | undefined;
55
+ help_centre_url?: string | undefined;
56
+ };
57
+ api_origin: string;
58
+ walkthroughs: {
59
+ status: "unsupported";
60
+ instructions: string;
61
+ synced_at?: undefined;
62
+ project_id?: undefined;
63
+ api_origin?: undefined;
64
+ items?: undefined;
65
+ counts?: undefined;
66
+ } | {
67
+ status: "ready";
68
+ synced_at: string;
69
+ project_id: string;
70
+ api_origin: string;
71
+ items: {
72
+ id: string;
73
+ remote: {
74
+ id: string;
75
+ project_id: string;
76
+ article_id: string;
77
+ title: string;
78
+ slug: string;
79
+ revision: string;
80
+ generation_status: "running" | "failed" | "pending" | "completed";
81
+ ready: boolean;
82
+ narrated: boolean;
83
+ publication_pending: boolean;
84
+ shared: boolean;
85
+ public_on_article: boolean;
86
+ review_url: string;
87
+ playback_url: string | null;
88
+ public_url: string | null;
89
+ article_public_url: string | null;
90
+ assets: {
91
+ video: boolean;
92
+ narrated_video: boolean;
93
+ subtitles: boolean;
94
+ transcript: boolean;
95
+ poster: boolean;
96
+ };
97
+ created_at: string;
98
+ updated_at: string;
99
+ generated_at: string | null;
100
+ shared_at: string | null;
101
+ error: {
102
+ code: string;
103
+ message: string;
104
+ } | null;
105
+ transcript_text?: string | null | undefined;
106
+ transcript_omitted?: boolean | undefined;
107
+ } | null;
108
+ sync_status: "remote_only" | "synced" | "remote_changed" | "unavailable";
109
+ last_known?: {
110
+ id: string;
111
+ project_id: string;
112
+ article_id: string;
113
+ title: string;
114
+ slug: string;
115
+ revision: string;
116
+ generation_status: "running" | "failed" | "pending" | "completed";
117
+ ready: boolean;
118
+ narrated: boolean;
119
+ publication_pending: boolean;
120
+ shared: boolean;
121
+ public_on_article: boolean;
122
+ review_url: string;
123
+ playback_url: string | null;
124
+ public_url: string | null;
125
+ article_public_url: string | null;
126
+ assets: {
127
+ video: boolean;
128
+ narrated_video: boolean;
129
+ subtitles: boolean;
130
+ transcript: boolean;
131
+ poster: boolean;
132
+ };
133
+ created_at: string;
134
+ updated_at: string;
135
+ generated_at: string | null;
136
+ shared_at: string | null;
137
+ error: {
138
+ code: string;
139
+ message: string;
140
+ } | null;
141
+ transcript_text?: string | null | undefined;
142
+ transcript_omitted?: boolean | undefined;
143
+ } | undefined;
144
+ }[];
145
+ counts: {
146
+ remote: number;
147
+ changed: number;
148
+ unavailable: number;
149
+ };
150
+ instructions: string;
151
+ } | undefined;
152
+ synced_at: string;
153
+ product_context: Record<string, string | string[] | null> | undefined;
154
+ writing_style: string | undefined;
155
+ articles: ({
156
+ identity_mismatch?: true | undefined;
157
+ remote: {
158
+ revision: string;
159
+ status: "draft" | "published";
160
+ editor_url: string;
161
+ public_url: string | null;
162
+ deleted_at: null;
163
+ id: string;
164
+ local_article_id: string | null;
165
+ title: string;
166
+ section_id: string | null;
167
+ repository_connection?: {
168
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
169
+ connect_url: string;
170
+ capabilities: {
171
+ sections: boolean;
172
+ suggestions: boolean;
173
+ code_analysis: boolean;
174
+ maintenance: boolean;
175
+ };
176
+ writer?: {
177
+ version: 1;
178
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
179
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
180
+ allowed: boolean;
181
+ execution: "local" | "remote" | "hosted";
182
+ required_scopes: string[];
183
+ next_step: {
184
+ code: string;
185
+ message: string;
186
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
187
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
188
+ url?: string | undefined;
189
+ } | null;
190
+ }>>;
191
+ } | undefined;
192
+ } | undefined;
193
+ accepted_bundle_hash?: string | null | undefined;
194
+ generation?: {
195
+ run_id: string;
196
+ attempt: string;
197
+ state: "running" | "failed" | "cancelled" | "interrupted" | "complete" | "kept" | "discarded";
198
+ } | null | undefined;
199
+ } | {
200
+ deleted_at: string;
201
+ id: string;
202
+ local_article_id: string | null;
203
+ title: string;
204
+ section_id: string | null;
205
+ } | undefined;
206
+ sync_status: string;
207
+ local_article_id: string;
208
+ artifact_dir: string;
209
+ title?: string;
210
+ run_id?: string;
211
+ phase?: string;
212
+ baseline?: z.infer<typeof remoteArticleSchema>;
213
+ changed: boolean;
214
+ content_changed: boolean;
215
+ bundle_hash?: string;
216
+ generation_attempt?: string;
217
+ } | {
218
+ remote: {
219
+ revision: string;
220
+ status: "draft" | "published";
221
+ editor_url: string;
222
+ public_url: string | null;
223
+ deleted_at: null;
224
+ id: string;
225
+ local_article_id: string | null;
226
+ title: string;
227
+ section_id: string | null;
228
+ repository_connection?: {
229
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
230
+ connect_url: string;
231
+ capabilities: {
232
+ sections: boolean;
233
+ suggestions: boolean;
234
+ code_analysis: boolean;
235
+ maintenance: boolean;
236
+ };
237
+ writer?: {
238
+ version: 1;
239
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
240
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
241
+ allowed: boolean;
242
+ execution: "local" | "remote" | "hosted";
243
+ required_scopes: string[];
244
+ next_step: {
245
+ code: string;
246
+ message: string;
247
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
248
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
249
+ url?: string | undefined;
250
+ } | null;
251
+ }>>;
252
+ } | undefined;
253
+ } | undefined;
254
+ accepted_bundle_hash?: string | null | undefined;
255
+ generation?: {
256
+ run_id: string;
257
+ attempt: string;
258
+ state: "running" | "failed" | "cancelled" | "interrupted" | "complete" | "kept" | "discarded";
259
+ } | null | undefined;
260
+ } | {
261
+ deleted_at: string;
262
+ id: string;
263
+ local_article_id: string | null;
264
+ title: string;
265
+ section_id: string | null;
266
+ };
267
+ sync_status: "remote_only";
268
+ })[];
269
+ counts: {
270
+ local: number;
271
+ remote: number;
272
+ conflicts: number;
273
+ deleted: number;
274
+ };
275
+ instructions: string;
276
+ } | {
277
+ status: "unsupported";
278
+ project: {
279
+ name: string;
280
+ id?: string | undefined;
281
+ help_centre_url?: string | undefined;
282
+ };
283
+ instructions: string;
284
+ }>;
285
+ localPlan(): Promise<{
286
+ analysis: {
287
+ status: "required";
288
+ completed_at?: undefined;
289
+ skills_version?: undefined;
290
+ output_dir?: undefined;
291
+ source_commit?: undefined;
292
+ codebase_dir?: undefined;
293
+ summary?: undefined;
294
+ overview?: undefined;
295
+ app_type?: undefined;
296
+ framework?: undefined;
297
+ } | {
298
+ status: "invalid";
299
+ completed_at?: undefined;
300
+ skills_version?: undefined;
301
+ output_dir?: undefined;
302
+ source_commit?: undefined;
303
+ codebase_dir?: undefined;
304
+ summary?: undefined;
305
+ overview?: undefined;
306
+ app_type?: undefined;
307
+ framework?: undefined;
308
+ } | {
309
+ status: "ready";
310
+ completed_at: string;
311
+ skills_version: string;
312
+ output_dir: string;
313
+ source_commit: string | null;
314
+ codebase_dir: string;
315
+ summary: string;
316
+ overview: string;
317
+ app_type: "win32" | "web" | "terminal" | "mobile" | "desktop" | "macos" | "game";
318
+ framework: string;
319
+ } | {
320
+ status: "invalid";
321
+ error: {
322
+ code: string;
323
+ message: string;
324
+ details: unknown;
325
+ } | {
326
+ code: string;
327
+ message: string;
328
+ details?: undefined;
329
+ };
330
+ completed_at?: undefined;
331
+ skills_version?: undefined;
332
+ output_dir?: undefined;
333
+ source_commit?: undefined;
334
+ codebase_dir?: undefined;
335
+ summary?: undefined;
336
+ overview?: undefined;
337
+ app_type?: undefined;
338
+ framework?: undefined;
339
+ };
340
+ }>;
341
+ /** Settings of a workspace that saves articles locally; undefined when never set up that way. */
342
+ local(): Promise<LocalSettings | undefined>;
343
+ saveLocal(settings: LocalSettings): Promise<{
344
+ version: 1;
345
+ export_dir: string;
346
+ writing_style?: string | undefined;
347
+ preferences?: {
348
+ prefer_background: boolean;
349
+ open_when_ready: boolean;
350
+ } | undefined;
351
+ }>;
352
+ /** A saved help-centre link always wins over local settings left behind by publish. */
353
+ destination(): Promise<'hosted' | 'local' | 'none'>;
354
+ /** Context for a local workspace: no sections, inventory or capacity; writing style composed here. */
355
+ localContext(): Promise<z.infer<typeof contextSchema>>;
356
+ contextFor(destination: 'hosted' | 'local' | 'none'): Promise<{
357
+ project: {
358
+ name: string;
359
+ id?: string | undefined;
360
+ help_centre_url?: string | undefined;
361
+ };
362
+ supported_bundle_versions: number[];
363
+ sections: {
364
+ id: string;
365
+ name: string;
366
+ slug: string;
367
+ description?: string | null | undefined;
368
+ icon?: string | null | undefined;
369
+ }[];
370
+ articles: {
371
+ id: string;
372
+ title: string;
373
+ section_id: string | null;
374
+ }[];
375
+ inventory_truncated: boolean;
376
+ local?: boolean | undefined;
377
+ article_sync?: boolean | undefined;
378
+ walkthrough_sync?: boolean | undefined;
379
+ article_capacity?: {
380
+ used: number;
381
+ limit: number | null;
382
+ can_create: boolean;
383
+ upgrade_url: string;
384
+ manage_articles_url: string;
385
+ } | undefined;
386
+ progressive_articles?: boolean | undefined;
387
+ repository_connection?: {
388
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
389
+ connect_url: string;
390
+ capabilities: {
391
+ sections: boolean;
392
+ suggestions: boolean;
393
+ code_analysis: boolean;
394
+ maintenance: boolean;
395
+ };
396
+ writer?: {
397
+ version: 1;
398
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
399
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
400
+ allowed: boolean;
401
+ execution: "local" | "remote" | "hosted";
402
+ required_scopes: string[];
403
+ next_step: {
404
+ code: string;
405
+ message: string;
406
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
407
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
408
+ url?: string | undefined;
409
+ } | null;
410
+ }>>;
411
+ } | undefined;
412
+ } | undefined;
413
+ product_context?: Record<string, string | string[] | null> | undefined;
414
+ project_overview?: string | null | undefined;
415
+ analysis_summary?: string | null | undefined;
416
+ writing_style?: string | undefined;
417
+ }>;
418
+ binding(): Promise<Binding>;
419
+ /** Plugin installs download Chromium in the background when a session starts
420
+ * (scripts/plugin-session.mjs). Say so, rather than failing mid-render. */
421
+ private requirePluginRenderer;
422
+ version(): Promise<string>;
423
+ doctor(): Promise<{
424
+ workspace: string;
425
+ api_origin: string;
426
+ dev_mode: boolean;
427
+ state_directory: string;
428
+ credentials_configured: boolean;
429
+ skills_path: string;
430
+ skills_version: string;
431
+ skills_installed: boolean;
432
+ dependencies: ({
433
+ command: string;
434
+ available: boolean;
435
+ version: string;
436
+ } | {
437
+ command: string;
438
+ available: boolean;
439
+ version?: undefined;
440
+ })[];
441
+ telemetry: unknown;
442
+ notes: string[];
443
+ }>;
444
+ listProjects(): Promise<unknown>;
445
+ status(runId?: string): Promise<{
446
+ status: string;
447
+ export_dir: string;
448
+ writing_style: string | undefined;
449
+ generation_ready: boolean;
450
+ instructions: string;
451
+ workspace: string;
452
+ api_origin: string;
453
+ dev_mode: boolean;
454
+ credentials_configured: boolean;
455
+ article_run: {
456
+ open_when_ready: boolean;
457
+ browser_opened: boolean | undefined;
458
+ instructions: string | undefined;
459
+ editor_url: string | null;
460
+ link_message: string;
461
+ link_instructions: string;
462
+ run_id: string;
463
+ title: string | undefined;
464
+ phase: "published" | "failed" | "prepared" | "cancelled" | "interrupted" | "writing" | "finalizing" | "uploading" | "upload_failed" | "ready_for_review" | "saved";
465
+ generation_completed_locally: boolean;
466
+ delivery_pending: boolean;
467
+ recovery: string | undefined;
468
+ artifact_dir: string;
469
+ execution_mode: "background" | "foreground" | undefined;
470
+ host_task_id: string | undefined;
471
+ progress_source: string;
472
+ session_current: boolean;
473
+ started_at: string;
474
+ updated_at: string;
475
+ project_id: string | undefined;
476
+ error: {
477
+ code: string;
478
+ message: string;
479
+ } | undefined;
480
+ article: {
481
+ id: string;
482
+ revision: string;
483
+ status: "draft" | "published";
484
+ editor_url: string;
485
+ public_url: string | null;
486
+ repository_connection?: {
487
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
488
+ connect_url: string;
489
+ capabilities: {
490
+ sections: boolean;
491
+ suggestions: boolean;
492
+ code_analysis: boolean;
493
+ maintenance: boolean;
494
+ };
495
+ writer?: {
496
+ version: 1;
497
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
498
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
499
+ allowed: boolean;
500
+ execution: "local" | "remote" | "hosted";
501
+ required_scopes: string[];
502
+ next_step: {
503
+ code: string;
504
+ message: string;
505
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
506
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
507
+ url?: string | undefined;
508
+ } | null;
509
+ }>>;
510
+ } | undefined;
511
+ } | undefined;
512
+ } | undefined;
513
+ export_path: string | undefined;
514
+ preview: {
515
+ id: string;
516
+ revision: string;
517
+ status: "draft" | "published";
518
+ editor_url: string;
519
+ public_url: string | null;
520
+ repository_connection?: {
521
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
522
+ connect_url: string;
523
+ capabilities: {
524
+ sections: boolean;
525
+ suggestions: boolean;
526
+ code_analysis: boolean;
527
+ maintenance: boolean;
528
+ };
529
+ writer?: {
530
+ version: 1;
531
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
532
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
533
+ allowed: boolean;
534
+ execution: "local" | "remote" | "hosted";
535
+ required_scopes: string[];
536
+ next_step: {
537
+ code: string;
538
+ message: string;
539
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
540
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
541
+ url?: string | undefined;
542
+ } | null;
543
+ }>>;
544
+ } | undefined;
545
+ } | undefined;
546
+ } | undefined;
547
+ local_preview_path: string | undefined;
548
+ synchronization_error: string | undefined;
549
+ } | null;
550
+ analysis: {
551
+ status: "required";
552
+ completed_at?: undefined;
553
+ skills_version?: undefined;
554
+ output_dir?: undefined;
555
+ source_commit?: undefined;
556
+ codebase_dir?: undefined;
557
+ summary?: undefined;
558
+ overview?: undefined;
559
+ app_type?: undefined;
560
+ framework?: undefined;
561
+ } | {
562
+ status: "invalid";
563
+ completed_at?: undefined;
564
+ skills_version?: undefined;
565
+ output_dir?: undefined;
566
+ source_commit?: undefined;
567
+ codebase_dir?: undefined;
568
+ summary?: undefined;
569
+ overview?: undefined;
570
+ app_type?: undefined;
571
+ framework?: undefined;
572
+ } | {
573
+ status: "ready";
574
+ completed_at: string;
575
+ skills_version: string;
576
+ output_dir: string;
577
+ source_commit: string | null;
578
+ codebase_dir: string;
579
+ summary: string;
580
+ overview: string;
581
+ app_type: "win32" | "web" | "terminal" | "mobile" | "desktop" | "macos" | "game";
582
+ framework: string;
583
+ } | {
584
+ status: "invalid";
585
+ error: {
586
+ code: string;
587
+ message: string;
588
+ details: unknown;
589
+ } | {
590
+ code: string;
591
+ message: string;
592
+ details?: undefined;
593
+ };
594
+ completed_at?: undefined;
595
+ skills_version?: undefined;
596
+ output_dir?: undefined;
597
+ source_commit?: undefined;
598
+ codebase_dir?: undefined;
599
+ summary?: undefined;
600
+ overview?: undefined;
601
+ app_type?: undefined;
602
+ framework?: undefined;
603
+ };
604
+ setup_task: {
605
+ progress_source: "last_reported";
606
+ skill: "generate-illustrated-article" | "detect-project" | "suggest-sections" | "recommend-articles";
607
+ status: "running" | "failed" | "cancelled" | "completed";
608
+ started_at: string;
609
+ finished_at?: string | undefined;
610
+ total?: number | undefined;
611
+ completed?: number | undefined;
612
+ failed?: number | undefined;
613
+ } | null;
614
+ } | {
615
+ status: string;
616
+ instructions: string;
617
+ workspace: string;
618
+ api_origin: string;
619
+ dev_mode: boolean;
620
+ credentials_configured: boolean;
621
+ article_run: {
622
+ open_when_ready: boolean;
623
+ browser_opened: boolean | undefined;
624
+ instructions: string | undefined;
625
+ editor_url: string | null;
626
+ link_message: string;
627
+ link_instructions: string;
628
+ run_id: string;
629
+ title: string | undefined;
630
+ phase: "published" | "failed" | "prepared" | "cancelled" | "interrupted" | "writing" | "finalizing" | "uploading" | "upload_failed" | "ready_for_review" | "saved";
631
+ generation_completed_locally: boolean;
632
+ delivery_pending: boolean;
633
+ recovery: string | undefined;
634
+ artifact_dir: string;
635
+ execution_mode: "background" | "foreground" | undefined;
636
+ host_task_id: string | undefined;
637
+ progress_source: string;
638
+ session_current: boolean;
639
+ started_at: string;
640
+ updated_at: string;
641
+ project_id: string | undefined;
642
+ error: {
643
+ code: string;
644
+ message: string;
645
+ } | undefined;
646
+ article: {
647
+ id: string;
648
+ revision: string;
649
+ status: "draft" | "published";
650
+ editor_url: string;
651
+ public_url: string | null;
652
+ repository_connection?: {
653
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
654
+ connect_url: string;
655
+ capabilities: {
656
+ sections: boolean;
657
+ suggestions: boolean;
658
+ code_analysis: boolean;
659
+ maintenance: boolean;
660
+ };
661
+ writer?: {
662
+ version: 1;
663
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
664
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
665
+ allowed: boolean;
666
+ execution: "local" | "remote" | "hosted";
667
+ required_scopes: string[];
668
+ next_step: {
669
+ code: string;
670
+ message: string;
671
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
672
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
673
+ url?: string | undefined;
674
+ } | null;
675
+ }>>;
676
+ } | undefined;
677
+ } | undefined;
678
+ } | undefined;
679
+ export_path: string | undefined;
680
+ preview: {
681
+ id: string;
682
+ revision: string;
683
+ status: "draft" | "published";
684
+ editor_url: string;
685
+ public_url: string | null;
686
+ repository_connection?: {
687
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
688
+ connect_url: string;
689
+ capabilities: {
690
+ sections: boolean;
691
+ suggestions: boolean;
692
+ code_analysis: boolean;
693
+ maintenance: boolean;
694
+ };
695
+ writer?: {
696
+ version: 1;
697
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
698
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
699
+ allowed: boolean;
700
+ execution: "local" | "remote" | "hosted";
701
+ required_scopes: string[];
702
+ next_step: {
703
+ code: string;
704
+ message: string;
705
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
706
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
707
+ url?: string | undefined;
708
+ } | null;
709
+ }>>;
710
+ } | undefined;
711
+ } | undefined;
712
+ } | undefined;
713
+ local_preview_path: string | undefined;
714
+ synchronization_error: string | undefined;
715
+ } | null;
716
+ analysis: {
717
+ status: "required";
718
+ completed_at?: undefined;
719
+ skills_version?: undefined;
720
+ output_dir?: undefined;
721
+ source_commit?: undefined;
722
+ codebase_dir?: undefined;
723
+ summary?: undefined;
724
+ overview?: undefined;
725
+ app_type?: undefined;
726
+ framework?: undefined;
727
+ } | {
728
+ status: "invalid";
729
+ completed_at?: undefined;
730
+ skills_version?: undefined;
731
+ output_dir?: undefined;
732
+ source_commit?: undefined;
733
+ codebase_dir?: undefined;
734
+ summary?: undefined;
735
+ overview?: undefined;
736
+ app_type?: undefined;
737
+ framework?: undefined;
738
+ } | {
739
+ status: "ready";
740
+ completed_at: string;
741
+ skills_version: string;
742
+ output_dir: string;
743
+ source_commit: string | null;
744
+ codebase_dir: string;
745
+ summary: string;
746
+ overview: string;
747
+ app_type: "win32" | "web" | "terminal" | "mobile" | "desktop" | "macos" | "game";
748
+ framework: string;
749
+ } | {
750
+ status: "invalid";
751
+ error: {
752
+ code: string;
753
+ message: string;
754
+ details: unknown;
755
+ } | {
756
+ code: string;
757
+ message: string;
758
+ details?: undefined;
759
+ };
760
+ completed_at?: undefined;
761
+ skills_version?: undefined;
762
+ output_dir?: undefined;
763
+ source_commit?: undefined;
764
+ codebase_dir?: undefined;
765
+ summary?: undefined;
766
+ overview?: undefined;
767
+ app_type?: undefined;
768
+ framework?: undefined;
769
+ };
770
+ setup_task: {
771
+ progress_source: "last_reported";
772
+ skill: "generate-illustrated-article" | "detect-project" | "suggest-sections" | "recommend-articles";
773
+ status: "running" | "failed" | "cancelled" | "completed";
774
+ started_at: string;
775
+ finished_at?: string | undefined;
776
+ total?: number | undefined;
777
+ completed?: number | undefined;
778
+ failed?: number | undefined;
779
+ } | null;
780
+ generation_ready: boolean;
781
+ } | {
782
+ status: string;
783
+ projects: {
784
+ id: string;
785
+ name: string;
786
+ help_centre_url?: string | undefined;
787
+ repository_connection?: {
788
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
789
+ connect_url: string;
790
+ capabilities: {
791
+ sections: boolean;
792
+ suggestions: boolean;
793
+ code_analysis: boolean;
794
+ maintenance: boolean;
795
+ };
796
+ writer?: {
797
+ version: 1;
798
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
799
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
800
+ allowed: boolean;
801
+ execution: "local" | "remote" | "hosted";
802
+ required_scopes: string[];
803
+ next_step: {
804
+ code: string;
805
+ message: string;
806
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
807
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
808
+ url?: string | undefined;
809
+ } | null;
810
+ }>>;
811
+ } | undefined;
812
+ } | undefined;
813
+ }[];
814
+ instructions: string;
815
+ workspace: string;
816
+ api_origin: string;
817
+ dev_mode: boolean;
818
+ credentials_configured: boolean;
819
+ article_run: {
820
+ open_when_ready: boolean;
821
+ browser_opened: boolean | undefined;
822
+ instructions: string | undefined;
823
+ editor_url: string | null;
824
+ link_message: string;
825
+ link_instructions: string;
826
+ run_id: string;
827
+ title: string | undefined;
828
+ phase: "published" | "failed" | "prepared" | "cancelled" | "interrupted" | "writing" | "finalizing" | "uploading" | "upload_failed" | "ready_for_review" | "saved";
829
+ generation_completed_locally: boolean;
830
+ delivery_pending: boolean;
831
+ recovery: string | undefined;
832
+ artifact_dir: string;
833
+ execution_mode: "background" | "foreground" | undefined;
834
+ host_task_id: string | undefined;
835
+ progress_source: string;
836
+ session_current: boolean;
837
+ started_at: string;
838
+ updated_at: string;
839
+ project_id: string | undefined;
840
+ error: {
841
+ code: string;
842
+ message: string;
843
+ } | undefined;
844
+ article: {
845
+ id: string;
846
+ revision: string;
847
+ status: "draft" | "published";
848
+ editor_url: string;
849
+ public_url: string | null;
850
+ repository_connection?: {
851
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
852
+ connect_url: string;
853
+ capabilities: {
854
+ sections: boolean;
855
+ suggestions: boolean;
856
+ code_analysis: boolean;
857
+ maintenance: boolean;
858
+ };
859
+ writer?: {
860
+ version: 1;
861
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
862
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
863
+ allowed: boolean;
864
+ execution: "local" | "remote" | "hosted";
865
+ required_scopes: string[];
866
+ next_step: {
867
+ code: string;
868
+ message: string;
869
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
870
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
871
+ url?: string | undefined;
872
+ } | null;
873
+ }>>;
874
+ } | undefined;
875
+ } | undefined;
876
+ } | undefined;
877
+ export_path: string | undefined;
878
+ preview: {
879
+ id: string;
880
+ revision: string;
881
+ status: "draft" | "published";
882
+ editor_url: string;
883
+ public_url: string | null;
884
+ repository_connection?: {
885
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
886
+ connect_url: string;
887
+ capabilities: {
888
+ sections: boolean;
889
+ suggestions: boolean;
890
+ code_analysis: boolean;
891
+ maintenance: boolean;
892
+ };
893
+ writer?: {
894
+ version: 1;
895
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
896
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
897
+ allowed: boolean;
898
+ execution: "local" | "remote" | "hosted";
899
+ required_scopes: string[];
900
+ next_step: {
901
+ code: string;
902
+ message: string;
903
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
904
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
905
+ url?: string | undefined;
906
+ } | null;
907
+ }>>;
908
+ } | undefined;
909
+ } | undefined;
910
+ } | undefined;
911
+ local_preview_path: string | undefined;
912
+ synchronization_error: string | undefined;
913
+ } | null;
914
+ analysis: {
915
+ status: "required";
916
+ completed_at?: undefined;
917
+ skills_version?: undefined;
918
+ output_dir?: undefined;
919
+ source_commit?: undefined;
920
+ codebase_dir?: undefined;
921
+ summary?: undefined;
922
+ overview?: undefined;
923
+ app_type?: undefined;
924
+ framework?: undefined;
925
+ } | {
926
+ status: "invalid";
927
+ completed_at?: undefined;
928
+ skills_version?: undefined;
929
+ output_dir?: undefined;
930
+ source_commit?: undefined;
931
+ codebase_dir?: undefined;
932
+ summary?: undefined;
933
+ overview?: undefined;
934
+ app_type?: undefined;
935
+ framework?: undefined;
936
+ } | {
937
+ status: "ready";
938
+ completed_at: string;
939
+ skills_version: string;
940
+ output_dir: string;
941
+ source_commit: string | null;
942
+ codebase_dir: string;
943
+ summary: string;
944
+ overview: string;
945
+ app_type: "win32" | "web" | "terminal" | "mobile" | "desktop" | "macos" | "game";
946
+ framework: string;
947
+ } | {
948
+ status: "invalid";
949
+ error: {
950
+ code: string;
951
+ message: string;
952
+ details: unknown;
953
+ } | {
954
+ code: string;
955
+ message: string;
956
+ details?: undefined;
957
+ };
958
+ completed_at?: undefined;
959
+ skills_version?: undefined;
960
+ output_dir?: undefined;
961
+ source_commit?: undefined;
962
+ codebase_dir?: undefined;
963
+ summary?: undefined;
964
+ overview?: undefined;
965
+ app_type?: undefined;
966
+ framework?: undefined;
967
+ };
968
+ setup_task: {
969
+ progress_source: "last_reported";
970
+ skill: "generate-illustrated-article" | "detect-project" | "suggest-sections" | "recommend-articles";
971
+ status: "running" | "failed" | "cancelled" | "completed";
972
+ started_at: string;
973
+ finished_at?: string | undefined;
974
+ total?: number | undefined;
975
+ completed?: number | undefined;
976
+ failed?: number | undefined;
977
+ } | null;
978
+ generation_ready: boolean;
979
+ } | {
980
+ status: string;
981
+ project_id: string;
982
+ instructions: string;
983
+ workspace: string;
984
+ api_origin: string;
985
+ dev_mode: boolean;
986
+ credentials_configured: boolean;
987
+ article_run: {
988
+ open_when_ready: boolean;
989
+ browser_opened: boolean | undefined;
990
+ instructions: string | undefined;
991
+ editor_url: string | null;
992
+ link_message: string;
993
+ link_instructions: string;
994
+ run_id: string;
995
+ title: string | undefined;
996
+ phase: "published" | "failed" | "prepared" | "cancelled" | "interrupted" | "writing" | "finalizing" | "uploading" | "upload_failed" | "ready_for_review" | "saved";
997
+ generation_completed_locally: boolean;
998
+ delivery_pending: boolean;
999
+ recovery: string | undefined;
1000
+ artifact_dir: string;
1001
+ execution_mode: "background" | "foreground" | undefined;
1002
+ host_task_id: string | undefined;
1003
+ progress_source: string;
1004
+ session_current: boolean;
1005
+ started_at: string;
1006
+ updated_at: string;
1007
+ project_id: string | undefined;
1008
+ error: {
1009
+ code: string;
1010
+ message: string;
1011
+ } | undefined;
1012
+ article: {
1013
+ id: string;
1014
+ revision: string;
1015
+ status: "draft" | "published";
1016
+ editor_url: string;
1017
+ public_url: string | null;
1018
+ repository_connection?: {
1019
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1020
+ connect_url: string;
1021
+ capabilities: {
1022
+ sections: boolean;
1023
+ suggestions: boolean;
1024
+ code_analysis: boolean;
1025
+ maintenance: boolean;
1026
+ };
1027
+ writer?: {
1028
+ version: 1;
1029
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1030
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1031
+ allowed: boolean;
1032
+ execution: "local" | "remote" | "hosted";
1033
+ required_scopes: string[];
1034
+ next_step: {
1035
+ code: string;
1036
+ message: string;
1037
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1038
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1039
+ url?: string | undefined;
1040
+ } | null;
1041
+ }>>;
1042
+ } | undefined;
1043
+ } | undefined;
1044
+ } | undefined;
1045
+ export_path: string | undefined;
1046
+ preview: {
1047
+ id: string;
1048
+ revision: string;
1049
+ status: "draft" | "published";
1050
+ editor_url: string;
1051
+ public_url: string | null;
1052
+ repository_connection?: {
1053
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1054
+ connect_url: string;
1055
+ capabilities: {
1056
+ sections: boolean;
1057
+ suggestions: boolean;
1058
+ code_analysis: boolean;
1059
+ maintenance: boolean;
1060
+ };
1061
+ writer?: {
1062
+ version: 1;
1063
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1064
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1065
+ allowed: boolean;
1066
+ execution: "local" | "remote" | "hosted";
1067
+ required_scopes: string[];
1068
+ next_step: {
1069
+ code: string;
1070
+ message: string;
1071
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1072
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1073
+ url?: string | undefined;
1074
+ } | null;
1075
+ }>>;
1076
+ } | undefined;
1077
+ } | undefined;
1078
+ } | undefined;
1079
+ local_preview_path: string | undefined;
1080
+ synchronization_error: string | undefined;
1081
+ } | null;
1082
+ analysis: {
1083
+ status: "required";
1084
+ completed_at?: undefined;
1085
+ skills_version?: undefined;
1086
+ output_dir?: undefined;
1087
+ source_commit?: undefined;
1088
+ codebase_dir?: undefined;
1089
+ summary?: undefined;
1090
+ overview?: undefined;
1091
+ app_type?: undefined;
1092
+ framework?: undefined;
1093
+ } | {
1094
+ status: "invalid";
1095
+ completed_at?: undefined;
1096
+ skills_version?: undefined;
1097
+ output_dir?: undefined;
1098
+ source_commit?: undefined;
1099
+ codebase_dir?: undefined;
1100
+ summary?: undefined;
1101
+ overview?: undefined;
1102
+ app_type?: undefined;
1103
+ framework?: undefined;
1104
+ } | {
1105
+ status: "ready";
1106
+ completed_at: string;
1107
+ skills_version: string;
1108
+ output_dir: string;
1109
+ source_commit: string | null;
1110
+ codebase_dir: string;
1111
+ summary: string;
1112
+ overview: string;
1113
+ app_type: "win32" | "web" | "terminal" | "mobile" | "desktop" | "macos" | "game";
1114
+ framework: string;
1115
+ } | {
1116
+ status: "invalid";
1117
+ error: {
1118
+ code: string;
1119
+ message: string;
1120
+ details: unknown;
1121
+ } | {
1122
+ code: string;
1123
+ message: string;
1124
+ details?: undefined;
1125
+ };
1126
+ completed_at?: undefined;
1127
+ skills_version?: undefined;
1128
+ output_dir?: undefined;
1129
+ source_commit?: undefined;
1130
+ codebase_dir?: undefined;
1131
+ summary?: undefined;
1132
+ overview?: undefined;
1133
+ app_type?: undefined;
1134
+ framework?: undefined;
1135
+ };
1136
+ setup_task: {
1137
+ progress_source: "last_reported";
1138
+ skill: "generate-illustrated-article" | "detect-project" | "suggest-sections" | "recommend-articles";
1139
+ status: "running" | "failed" | "cancelled" | "completed";
1140
+ started_at: string;
1141
+ finished_at?: string | undefined;
1142
+ total?: number | undefined;
1143
+ completed?: number | undefined;
1144
+ failed?: number | undefined;
1145
+ } | null;
1146
+ generation_ready: boolean;
1147
+ } | {
1148
+ instructions?: string | undefined;
1149
+ status: string;
1150
+ project_id: string;
1151
+ project: {
1152
+ id: string;
1153
+ name: string;
1154
+ help_centre_url?: string | undefined;
1155
+ repository_connection?: {
1156
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1157
+ connect_url: string;
1158
+ capabilities: {
1159
+ sections: boolean;
1160
+ suggestions: boolean;
1161
+ code_analysis: boolean;
1162
+ maintenance: boolean;
1163
+ };
1164
+ writer?: {
1165
+ version: 1;
1166
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1167
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1168
+ allowed: boolean;
1169
+ execution: "local" | "remote" | "hosted";
1170
+ required_scopes: string[];
1171
+ next_step: {
1172
+ code: string;
1173
+ message: string;
1174
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1175
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1176
+ url?: string | undefined;
1177
+ } | null;
1178
+ }>>;
1179
+ } | undefined;
1180
+ } | undefined;
1181
+ };
1182
+ repository_connection: {
1183
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1184
+ connect_url: string;
1185
+ capabilities: {
1186
+ sections: boolean;
1187
+ suggestions: boolean;
1188
+ code_analysis: boolean;
1189
+ maintenance: boolean;
1190
+ };
1191
+ writer?: {
1192
+ version: 1;
1193
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1194
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1195
+ allowed: boolean;
1196
+ execution: "local" | "remote" | "hosted";
1197
+ required_scopes: string[];
1198
+ next_step: {
1199
+ code: string;
1200
+ message: string;
1201
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1202
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1203
+ url?: string | undefined;
1204
+ } | null;
1205
+ }>>;
1206
+ } | undefined;
1207
+ } | undefined;
1208
+ hosted_operation: {
1209
+ operation_id: string;
1210
+ open_when_ready: boolean;
1211
+ instructions: string;
1212
+ id: string;
1213
+ project_id: string;
1214
+ action: string;
1215
+ execution: "hosted";
1216
+ attempt: number;
1217
+ status: "queued" | "running" | "succeeded" | "failed";
1218
+ article_id: string | null;
1219
+ result: Record<string, unknown>;
1220
+ error: {
1221
+ code: string;
1222
+ message: string;
1223
+ } | null;
1224
+ review_url: string | null;
1225
+ created_at: string;
1226
+ started_at: string | null;
1227
+ finished_at: string | null;
1228
+ walkthrough_id?: string | null | undefined;
1229
+ } | undefined;
1230
+ generation_ready: boolean;
1231
+ writer_action: {
1232
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1233
+ allowed: boolean;
1234
+ execution: "local" | "remote" | "hosted";
1235
+ required_scopes: string[];
1236
+ next_step: {
1237
+ code: string;
1238
+ message: string;
1239
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1240
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1241
+ url?: string | undefined;
1242
+ } | null;
1243
+ } | undefined;
1244
+ workspace: string;
1245
+ api_origin: string;
1246
+ dev_mode: boolean;
1247
+ credentials_configured: boolean;
1248
+ article_run: {
1249
+ open_when_ready: boolean;
1250
+ browser_opened: boolean | undefined;
1251
+ instructions: string | undefined;
1252
+ editor_url: string | null;
1253
+ link_message: string;
1254
+ link_instructions: string;
1255
+ run_id: string;
1256
+ title: string | undefined;
1257
+ phase: "published" | "failed" | "prepared" | "cancelled" | "interrupted" | "writing" | "finalizing" | "uploading" | "upload_failed" | "ready_for_review" | "saved";
1258
+ generation_completed_locally: boolean;
1259
+ delivery_pending: boolean;
1260
+ recovery: string | undefined;
1261
+ artifact_dir: string;
1262
+ execution_mode: "background" | "foreground" | undefined;
1263
+ host_task_id: string | undefined;
1264
+ progress_source: string;
1265
+ session_current: boolean;
1266
+ started_at: string;
1267
+ updated_at: string;
1268
+ project_id: string | undefined;
1269
+ error: {
1270
+ code: string;
1271
+ message: string;
1272
+ } | undefined;
1273
+ article: {
1274
+ id: string;
1275
+ revision: string;
1276
+ status: "draft" | "published";
1277
+ editor_url: string;
1278
+ public_url: string | null;
1279
+ repository_connection?: {
1280
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1281
+ connect_url: string;
1282
+ capabilities: {
1283
+ sections: boolean;
1284
+ suggestions: boolean;
1285
+ code_analysis: boolean;
1286
+ maintenance: boolean;
1287
+ };
1288
+ writer?: {
1289
+ version: 1;
1290
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1291
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1292
+ allowed: boolean;
1293
+ execution: "local" | "remote" | "hosted";
1294
+ required_scopes: string[];
1295
+ next_step: {
1296
+ code: string;
1297
+ message: string;
1298
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1299
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1300
+ url?: string | undefined;
1301
+ } | null;
1302
+ }>>;
1303
+ } | undefined;
1304
+ } | undefined;
1305
+ } | undefined;
1306
+ export_path: string | undefined;
1307
+ preview: {
1308
+ id: string;
1309
+ revision: string;
1310
+ status: "draft" | "published";
1311
+ editor_url: string;
1312
+ public_url: string | null;
1313
+ repository_connection?: {
1314
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1315
+ connect_url: string;
1316
+ capabilities: {
1317
+ sections: boolean;
1318
+ suggestions: boolean;
1319
+ code_analysis: boolean;
1320
+ maintenance: boolean;
1321
+ };
1322
+ writer?: {
1323
+ version: 1;
1324
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1325
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1326
+ allowed: boolean;
1327
+ execution: "local" | "remote" | "hosted";
1328
+ required_scopes: string[];
1329
+ next_step: {
1330
+ code: string;
1331
+ message: string;
1332
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1333
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1334
+ url?: string | undefined;
1335
+ } | null;
1336
+ }>>;
1337
+ } | undefined;
1338
+ } | undefined;
1339
+ } | undefined;
1340
+ local_preview_path: string | undefined;
1341
+ synchronization_error: string | undefined;
1342
+ } | null;
1343
+ analysis: {
1344
+ status: "required";
1345
+ completed_at?: undefined;
1346
+ skills_version?: undefined;
1347
+ output_dir?: undefined;
1348
+ source_commit?: undefined;
1349
+ codebase_dir?: undefined;
1350
+ summary?: undefined;
1351
+ overview?: undefined;
1352
+ app_type?: undefined;
1353
+ framework?: undefined;
1354
+ } | {
1355
+ status: "invalid";
1356
+ completed_at?: undefined;
1357
+ skills_version?: undefined;
1358
+ output_dir?: undefined;
1359
+ source_commit?: undefined;
1360
+ codebase_dir?: undefined;
1361
+ summary?: undefined;
1362
+ overview?: undefined;
1363
+ app_type?: undefined;
1364
+ framework?: undefined;
1365
+ } | {
1366
+ status: "ready";
1367
+ completed_at: string;
1368
+ skills_version: string;
1369
+ output_dir: string;
1370
+ source_commit: string | null;
1371
+ codebase_dir: string;
1372
+ summary: string;
1373
+ overview: string;
1374
+ app_type: "win32" | "web" | "terminal" | "mobile" | "desktop" | "macos" | "game";
1375
+ framework: string;
1376
+ } | {
1377
+ status: "invalid";
1378
+ error: {
1379
+ code: string;
1380
+ message: string;
1381
+ details: unknown;
1382
+ } | {
1383
+ code: string;
1384
+ message: string;
1385
+ details?: undefined;
1386
+ };
1387
+ completed_at?: undefined;
1388
+ skills_version?: undefined;
1389
+ output_dir?: undefined;
1390
+ source_commit?: undefined;
1391
+ codebase_dir?: undefined;
1392
+ summary?: undefined;
1393
+ overview?: undefined;
1394
+ app_type?: undefined;
1395
+ framework?: undefined;
1396
+ };
1397
+ setup_task: {
1398
+ progress_source: "last_reported";
1399
+ skill: "generate-illustrated-article" | "detect-project" | "suggest-sections" | "recommend-articles";
1400
+ status: "running" | "failed" | "cancelled" | "completed";
1401
+ started_at: string;
1402
+ finished_at?: string | undefined;
1403
+ total?: number | undefined;
1404
+ completed?: number | undefined;
1405
+ failed?: number | undefined;
1406
+ } | null;
1407
+ } | {
1408
+ status: string;
1409
+ error: {
1410
+ code: string;
1411
+ message: string;
1412
+ details: unknown;
1413
+ } | {
1414
+ code: string;
1415
+ message: string;
1416
+ details?: undefined;
1417
+ };
1418
+ instructions: string;
1419
+ workspace: string;
1420
+ api_origin: string;
1421
+ dev_mode: boolean;
1422
+ credentials_configured: boolean;
1423
+ article_run: {
1424
+ open_when_ready: boolean;
1425
+ browser_opened: boolean | undefined;
1426
+ instructions: string | undefined;
1427
+ editor_url: string | null;
1428
+ link_message: string;
1429
+ link_instructions: string;
1430
+ run_id: string;
1431
+ title: string | undefined;
1432
+ phase: "published" | "failed" | "prepared" | "cancelled" | "interrupted" | "writing" | "finalizing" | "uploading" | "upload_failed" | "ready_for_review" | "saved";
1433
+ generation_completed_locally: boolean;
1434
+ delivery_pending: boolean;
1435
+ recovery: string | undefined;
1436
+ artifact_dir: string;
1437
+ execution_mode: "background" | "foreground" | undefined;
1438
+ host_task_id: string | undefined;
1439
+ progress_source: string;
1440
+ session_current: boolean;
1441
+ started_at: string;
1442
+ updated_at: string;
1443
+ project_id: string | undefined;
1444
+ error: {
1445
+ code: string;
1446
+ message: string;
1447
+ } | undefined;
1448
+ article: {
1449
+ id: string;
1450
+ revision: string;
1451
+ status: "draft" | "published";
1452
+ editor_url: string;
1453
+ public_url: string | null;
1454
+ repository_connection?: {
1455
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1456
+ connect_url: string;
1457
+ capabilities: {
1458
+ sections: boolean;
1459
+ suggestions: boolean;
1460
+ code_analysis: boolean;
1461
+ maintenance: boolean;
1462
+ };
1463
+ writer?: {
1464
+ version: 1;
1465
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1466
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1467
+ allowed: boolean;
1468
+ execution: "local" | "remote" | "hosted";
1469
+ required_scopes: string[];
1470
+ next_step: {
1471
+ code: string;
1472
+ message: string;
1473
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1474
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1475
+ url?: string | undefined;
1476
+ } | null;
1477
+ }>>;
1478
+ } | undefined;
1479
+ } | undefined;
1480
+ } | undefined;
1481
+ export_path: string | undefined;
1482
+ preview: {
1483
+ id: string;
1484
+ revision: string;
1485
+ status: "draft" | "published";
1486
+ editor_url: string;
1487
+ public_url: string | null;
1488
+ repository_connection?: {
1489
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1490
+ connect_url: string;
1491
+ capabilities: {
1492
+ sections: boolean;
1493
+ suggestions: boolean;
1494
+ code_analysis: boolean;
1495
+ maintenance: boolean;
1496
+ };
1497
+ writer?: {
1498
+ version: 1;
1499
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1500
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1501
+ allowed: boolean;
1502
+ execution: "local" | "remote" | "hosted";
1503
+ required_scopes: string[];
1504
+ next_step: {
1505
+ code: string;
1506
+ message: string;
1507
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1508
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1509
+ url?: string | undefined;
1510
+ } | null;
1511
+ }>>;
1512
+ } | undefined;
1513
+ } | undefined;
1514
+ } | undefined;
1515
+ local_preview_path: string | undefined;
1516
+ synchronization_error: string | undefined;
1517
+ } | null;
1518
+ analysis: {
1519
+ status: "required";
1520
+ completed_at?: undefined;
1521
+ skills_version?: undefined;
1522
+ output_dir?: undefined;
1523
+ source_commit?: undefined;
1524
+ codebase_dir?: undefined;
1525
+ summary?: undefined;
1526
+ overview?: undefined;
1527
+ app_type?: undefined;
1528
+ framework?: undefined;
1529
+ } | {
1530
+ status: "invalid";
1531
+ completed_at?: undefined;
1532
+ skills_version?: undefined;
1533
+ output_dir?: undefined;
1534
+ source_commit?: undefined;
1535
+ codebase_dir?: undefined;
1536
+ summary?: undefined;
1537
+ overview?: undefined;
1538
+ app_type?: undefined;
1539
+ framework?: undefined;
1540
+ } | {
1541
+ status: "ready";
1542
+ completed_at: string;
1543
+ skills_version: string;
1544
+ output_dir: string;
1545
+ source_commit: string | null;
1546
+ codebase_dir: string;
1547
+ summary: string;
1548
+ overview: string;
1549
+ app_type: "win32" | "web" | "terminal" | "mobile" | "desktop" | "macos" | "game";
1550
+ framework: string;
1551
+ } | {
1552
+ status: "invalid";
1553
+ error: {
1554
+ code: string;
1555
+ message: string;
1556
+ details: unknown;
1557
+ } | {
1558
+ code: string;
1559
+ message: string;
1560
+ details?: undefined;
1561
+ };
1562
+ completed_at?: undefined;
1563
+ skills_version?: undefined;
1564
+ output_dir?: undefined;
1565
+ source_commit?: undefined;
1566
+ codebase_dir?: undefined;
1567
+ summary?: undefined;
1568
+ overview?: undefined;
1569
+ app_type?: undefined;
1570
+ framework?: undefined;
1571
+ };
1572
+ setup_task: {
1573
+ progress_source: "last_reported";
1574
+ skill: "generate-illustrated-article" | "detect-project" | "suggest-sections" | "recommend-articles";
1575
+ status: "running" | "failed" | "cancelled" | "completed";
1576
+ started_at: string;
1577
+ finished_at?: string | undefined;
1578
+ total?: number | undefined;
1579
+ completed?: number | undefined;
1580
+ failed?: number | undefined;
1581
+ } | null;
1582
+ generation_ready: boolean;
1583
+ }>;
1584
+ createProject(name: string, subdomain: string): Promise<unknown>;
1585
+ bind(projectId: string, options?: {
1586
+ requireIdle?: boolean;
1587
+ }): Promise<{
1588
+ project: {
1589
+ name: string;
1590
+ id?: string | undefined;
1591
+ help_centre_url?: string | undefined;
1592
+ };
1593
+ version: 1;
1594
+ project_id: string;
1595
+ api_origin: string;
1596
+ }>;
1597
+ context(): Promise<{
1598
+ project: {
1599
+ name: string;
1600
+ id?: string | undefined;
1601
+ help_centre_url?: string | undefined;
1602
+ };
1603
+ supported_bundle_versions: number[];
1604
+ sections: {
1605
+ id: string;
1606
+ name: string;
1607
+ slug: string;
1608
+ description?: string | null | undefined;
1609
+ icon?: string | null | undefined;
1610
+ }[];
1611
+ articles: {
1612
+ id: string;
1613
+ title: string;
1614
+ section_id: string | null;
1615
+ }[];
1616
+ inventory_truncated: boolean;
1617
+ local?: boolean | undefined;
1618
+ article_sync?: boolean | undefined;
1619
+ walkthrough_sync?: boolean | undefined;
1620
+ article_capacity?: {
1621
+ used: number;
1622
+ limit: number | null;
1623
+ can_create: boolean;
1624
+ upgrade_url: string;
1625
+ manage_articles_url: string;
1626
+ } | undefined;
1627
+ progressive_articles?: boolean | undefined;
1628
+ repository_connection?: {
1629
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1630
+ connect_url: string;
1631
+ capabilities: {
1632
+ sections: boolean;
1633
+ suggestions: boolean;
1634
+ code_analysis: boolean;
1635
+ maintenance: boolean;
1636
+ };
1637
+ writer?: {
1638
+ version: 1;
1639
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1640
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1641
+ allowed: boolean;
1642
+ execution: "local" | "remote" | "hosted";
1643
+ required_scopes: string[];
1644
+ next_step: {
1645
+ code: string;
1646
+ message: string;
1647
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1648
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1649
+ url?: string | undefined;
1650
+ } | null;
1651
+ }>>;
1652
+ } | undefined;
1653
+ } | undefined;
1654
+ product_context?: Record<string, string | string[] | null> | undefined;
1655
+ project_overview?: string | null | undefined;
1656
+ analysis_summary?: string | null | undefined;
1657
+ writing_style?: string | undefined;
1658
+ }>;
1659
+ /** Recover a confirmed link from local journals without requiring a working API. */
1660
+ articleErrorContext(input: {
1661
+ run_id?: unknown;
1662
+ title?: unknown;
1663
+ artifact_dir?: unknown;
1664
+ }): Promise<{
1665
+ recovery: string;
1666
+ editor_url: string | null;
1667
+ link_message: string;
1668
+ link_instructions: string;
1669
+ run_id: string;
1670
+ title: string | undefined;
1671
+ phase: "published" | "failed" | "prepared" | "cancelled" | "interrupted" | "writing" | "finalizing" | "uploading" | "upload_failed" | "ready_for_review" | "saved" | undefined;
1672
+ } | undefined>;
1673
+ prepare(input: {
1674
+ title: string;
1675
+ description?: string;
1676
+ article_type: z.infer<typeof articleType>;
1677
+ section_id?: string;
1678
+ prefer_background?: boolean;
1679
+ open_when_ready?: boolean;
1680
+ allow_duplicate?: boolean;
1681
+ }): Promise<{
1682
+ prefer_background: boolean;
1683
+ open_when_ready: boolean;
1684
+ task_brief: {
1685
+ name: string;
1686
+ claude_model: string | null;
1687
+ codex_model: string | null;
1688
+ codex_reasoning_effort: string | null;
1689
+ prefer_background: boolean;
1690
+ reporting_instructions: string;
1691
+ writer_instructions: string;
1692
+ workspace: string;
1693
+ run_id: `${string}-${string}-${string}-${string}-${string}`;
1694
+ artifact_dir: string;
1695
+ environment: {
1696
+ RTFM_WORKSPACE: string;
1697
+ RTFM_CONTEXT_FILE: string;
1698
+ RTFM_OUTPUT_DIR: string;
1699
+ RTFM_SKILLS_DIR: string;
1700
+ RTFM_MAX_IMAGES: string;
1701
+ PATH: string;
1702
+ };
1703
+ entrypoint: {
1704
+ command: string;
1705
+ args: string[];
1706
+ shell_command: string;
1707
+ execution: {
1708
+ command: string;
1709
+ args: string[];
1710
+ shell_command: string;
1711
+ instruction: string;
1712
+ };
1713
+ completion: {
1714
+ command: string;
1715
+ args: string[];
1716
+ shell_command: string;
1717
+ instruction: string;
1718
+ };
1719
+ instruction: string;
1720
+ };
1721
+ execution: {
1722
+ command: string;
1723
+ args: string[];
1724
+ shell_command: string;
1725
+ instruction: string;
1726
+ };
1727
+ completion: {
1728
+ command: string;
1729
+ args: string[];
1730
+ shell_command: string;
1731
+ instruction: string;
1732
+ };
1733
+ editor_url: string | null;
1734
+ instructions: string[];
1735
+ };
1736
+ instructions: string[];
1737
+ writer_entrypoint: {
1738
+ command: string;
1739
+ args: string[];
1740
+ shell_command: string;
1741
+ execution: {
1742
+ command: string;
1743
+ args: string[];
1744
+ shell_command: string;
1745
+ instruction: string;
1746
+ };
1747
+ completion: {
1748
+ command: string;
1749
+ args: string[];
1750
+ shell_command: string;
1751
+ instruction: string;
1752
+ };
1753
+ instruction: string;
1754
+ };
1755
+ local?: boolean | undefined;
1756
+ saved_to?: string | undefined;
1757
+ link_message: string;
1758
+ link_instructions: string;
1759
+ editor_url: string | null;
1760
+ status: string;
1761
+ run_id: `${string}-${string}-${string}-${string}-${string}`;
1762
+ artifact_dir: string;
1763
+ environment: {
1764
+ RTFM_WORKSPACE: string;
1765
+ RTFM_CONTEXT_FILE: string;
1766
+ RTFM_OUTPUT_DIR: string;
1767
+ RTFM_SKILLS_DIR: string;
1768
+ RTFM_MAX_IMAGES: string;
1769
+ PATH: string;
1770
+ };
1771
+ }>;
1772
+ updateRun(input: {
1773
+ run_id: string;
1774
+ event: 'started' | 'failed' | 'interrupted' | 'cancelled';
1775
+ execution_mode?: 'foreground' | 'background';
1776
+ host_task_id?: string;
1777
+ stopped?: boolean;
1778
+ }): Promise<{
1779
+ open_when_ready: boolean;
1780
+ browser_opened: boolean | undefined;
1781
+ instructions: string | undefined;
1782
+ editor_url: string | null;
1783
+ link_message: string;
1784
+ link_instructions: string;
1785
+ run_id: string;
1786
+ title: string | undefined;
1787
+ phase: "published" | "failed" | "prepared" | "cancelled" | "interrupted" | "writing" | "finalizing" | "uploading" | "upload_failed" | "ready_for_review" | "saved";
1788
+ generation_completed_locally: boolean;
1789
+ delivery_pending: boolean;
1790
+ recovery: string | undefined;
1791
+ artifact_dir: string;
1792
+ execution_mode: "background" | "foreground" | undefined;
1793
+ host_task_id: string | undefined;
1794
+ progress_source: string;
1795
+ session_current: boolean;
1796
+ started_at: string;
1797
+ updated_at: string;
1798
+ project_id: string | undefined;
1799
+ error: {
1800
+ code: string;
1801
+ message: string;
1802
+ } | undefined;
1803
+ article: {
1804
+ id: string;
1805
+ revision: string;
1806
+ status: "draft" | "published";
1807
+ editor_url: string;
1808
+ public_url: string | null;
1809
+ repository_connection?: {
1810
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1811
+ connect_url: string;
1812
+ capabilities: {
1813
+ sections: boolean;
1814
+ suggestions: boolean;
1815
+ code_analysis: boolean;
1816
+ maintenance: boolean;
1817
+ };
1818
+ writer?: {
1819
+ version: 1;
1820
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1821
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1822
+ allowed: boolean;
1823
+ execution: "local" | "remote" | "hosted";
1824
+ required_scopes: string[];
1825
+ next_step: {
1826
+ code: string;
1827
+ message: string;
1828
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1829
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1830
+ url?: string | undefined;
1831
+ } | null;
1832
+ }>>;
1833
+ } | undefined;
1834
+ } | undefined;
1835
+ } | undefined;
1836
+ export_path: string | undefined;
1837
+ preview: {
1838
+ id: string;
1839
+ revision: string;
1840
+ status: "draft" | "published";
1841
+ editor_url: string;
1842
+ public_url: string | null;
1843
+ repository_connection?: {
1844
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1845
+ connect_url: string;
1846
+ capabilities: {
1847
+ sections: boolean;
1848
+ suggestions: boolean;
1849
+ code_analysis: boolean;
1850
+ maintenance: boolean;
1851
+ };
1852
+ writer?: {
1853
+ version: 1;
1854
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1855
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1856
+ allowed: boolean;
1857
+ execution: "local" | "remote" | "hosted";
1858
+ required_scopes: string[];
1859
+ next_step: {
1860
+ code: string;
1861
+ message: string;
1862
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1863
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1864
+ url?: string | undefined;
1865
+ } | null;
1866
+ }>>;
1867
+ } | undefined;
1868
+ } | undefined;
1869
+ } | undefined;
1870
+ local_preview_path: string | undefined;
1871
+ synchronization_error: string | undefined;
1872
+ } | null>;
1873
+ cancel(runId: string, stopped?: boolean, expectedRun?: Run): Promise<{
1874
+ note: string;
1875
+ editor_url: string | null;
1876
+ link_message: string;
1877
+ link_instructions: string;
1878
+ status: string;
1879
+ }>;
1880
+ validate(dir: string): Promise<{
1881
+ valid: boolean;
1882
+ title: string;
1883
+ blocks: number;
1884
+ images: number;
1885
+ warnings: string[];
1886
+ finalized: boolean;
1887
+ }>;
1888
+ preview(dir: string): Promise<{
1889
+ path: string;
1890
+ uri: string;
1891
+ title: string;
1892
+ warnings: string[];
1893
+ }>;
1894
+ finalize(input: {
1895
+ artifact_dir: string;
1896
+ completed: true;
1897
+ run_id?: string;
1898
+ section_id?: string;
1899
+ }): Promise<{
1900
+ warnings: string[];
1901
+ remote: {
1902
+ id: string;
1903
+ revision: string;
1904
+ status: "draft" | "published";
1905
+ editor_url: string;
1906
+ public_url: string | null;
1907
+ repository_connection?: {
1908
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1909
+ connect_url: string;
1910
+ capabilities: {
1911
+ sections: boolean;
1912
+ suggestions: boolean;
1913
+ code_analysis: boolean;
1914
+ maintenance: boolean;
1915
+ };
1916
+ writer?: {
1917
+ version: 1;
1918
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1919
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1920
+ allowed: boolean;
1921
+ execution: "local" | "remote" | "hosted";
1922
+ required_scopes: string[];
1923
+ next_step: {
1924
+ code: string;
1925
+ message: string;
1926
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1927
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1928
+ url?: string | undefined;
1929
+ } | null;
1930
+ }>>;
1931
+ } | undefined;
1932
+ } | undefined;
1933
+ };
1934
+ uploaded_bundle_hash: string | undefined;
1935
+ local_article_id: string;
1936
+ artifact_dir: string;
1937
+ bundle_dir: string;
1938
+ bundle_hash: string;
1939
+ project_id?: string | undefined;
1940
+ api_origin?: string | undefined;
1941
+ status: string;
1942
+ } | {
1943
+ warnings: string[];
1944
+ remote: {
1945
+ id: string;
1946
+ revision: string;
1947
+ status: "draft" | "published";
1948
+ editor_url: string;
1949
+ public_url: string | null;
1950
+ repository_connection?: {
1951
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
1952
+ connect_url: string;
1953
+ capabilities: {
1954
+ sections: boolean;
1955
+ suggestions: boolean;
1956
+ code_analysis: boolean;
1957
+ maintenance: boolean;
1958
+ };
1959
+ writer?: {
1960
+ version: 1;
1961
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
1962
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1963
+ allowed: boolean;
1964
+ execution: "local" | "remote" | "hosted";
1965
+ required_scopes: string[];
1966
+ next_step: {
1967
+ code: string;
1968
+ message: string;
1969
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
1970
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
1971
+ url?: string | undefined;
1972
+ } | null;
1973
+ }>>;
1974
+ } | undefined;
1975
+ } | undefined;
1976
+ };
1977
+ local_article_id: string;
1978
+ artifact_dir: string;
1979
+ bundle_dir: string;
1980
+ bundle_hash: string;
1981
+ project_id?: string | undefined;
1982
+ api_origin?: string | undefined;
1983
+ status: string;
1984
+ } | {
1985
+ warnings: string[];
1986
+ local_article_id: string;
1987
+ artifact_dir: string;
1988
+ bundle_dir: string;
1989
+ bundle_hash: string;
1990
+ project_id?: string | undefined;
1991
+ api_origin?: string | undefined;
1992
+ status: string;
1993
+ }>;
1994
+ private finalizeUnlocked;
1995
+ /** Saved local articles, newest first: state files without a help centre plus their run titles. */
1996
+ localArticles(): Promise<{
1997
+ slug: string;
1998
+ title: string;
1999
+ local_article_id: string;
2000
+ artifact_dir: string;
2001
+ export_path?: string;
2002
+ run_id?: string;
2003
+ }[]>;
2004
+ listLocal(): Promise<{
2005
+ status: "local";
2006
+ source: "local";
2007
+ articles: {
2008
+ slug: string;
2009
+ title: string;
2010
+ artifact_dir: string;
2011
+ article_path?: string;
2012
+ export_path?: string;
2013
+ local_article_id?: string;
2014
+ run_id?: string;
2015
+ }[];
2016
+ next_cursor: null;
2017
+ searched_directories: string[];
2018
+ warnings: {
2019
+ path: string;
2020
+ message: string;
2021
+ }[];
2022
+ instructions: string;
2023
+ } | {
2024
+ version: number;
2025
+ status: "ready";
2026
+ project: {
2027
+ name: string;
2028
+ id?: string | undefined;
2029
+ help_centre_url?: string | undefined;
2030
+ };
2031
+ api_origin: string;
2032
+ walkthroughs: {
2033
+ status: "unsupported";
2034
+ instructions: string;
2035
+ synced_at?: undefined;
2036
+ project_id?: undefined;
2037
+ api_origin?: undefined;
2038
+ items?: undefined;
2039
+ counts?: undefined;
2040
+ } | {
2041
+ status: "ready";
2042
+ synced_at: string;
2043
+ project_id: string;
2044
+ api_origin: string;
2045
+ items: {
2046
+ id: string;
2047
+ remote: {
2048
+ id: string;
2049
+ project_id: string;
2050
+ article_id: string;
2051
+ title: string;
2052
+ slug: string;
2053
+ revision: string;
2054
+ generation_status: "running" | "failed" | "pending" | "completed";
2055
+ ready: boolean;
2056
+ narrated: boolean;
2057
+ publication_pending: boolean;
2058
+ shared: boolean;
2059
+ public_on_article: boolean;
2060
+ review_url: string;
2061
+ playback_url: string | null;
2062
+ public_url: string | null;
2063
+ article_public_url: string | null;
2064
+ assets: {
2065
+ video: boolean;
2066
+ narrated_video: boolean;
2067
+ subtitles: boolean;
2068
+ transcript: boolean;
2069
+ poster: boolean;
2070
+ };
2071
+ created_at: string;
2072
+ updated_at: string;
2073
+ generated_at: string | null;
2074
+ shared_at: string | null;
2075
+ error: {
2076
+ code: string;
2077
+ message: string;
2078
+ } | null;
2079
+ transcript_text?: string | null | undefined;
2080
+ transcript_omitted?: boolean | undefined;
2081
+ } | null;
2082
+ sync_status: "remote_only" | "synced" | "remote_changed" | "unavailable";
2083
+ last_known?: {
2084
+ id: string;
2085
+ project_id: string;
2086
+ article_id: string;
2087
+ title: string;
2088
+ slug: string;
2089
+ revision: string;
2090
+ generation_status: "running" | "failed" | "pending" | "completed";
2091
+ ready: boolean;
2092
+ narrated: boolean;
2093
+ publication_pending: boolean;
2094
+ shared: boolean;
2095
+ public_on_article: boolean;
2096
+ review_url: string;
2097
+ playback_url: string | null;
2098
+ public_url: string | null;
2099
+ article_public_url: string | null;
2100
+ assets: {
2101
+ video: boolean;
2102
+ narrated_video: boolean;
2103
+ subtitles: boolean;
2104
+ transcript: boolean;
2105
+ poster: boolean;
2106
+ };
2107
+ created_at: string;
2108
+ updated_at: string;
2109
+ generated_at: string | null;
2110
+ shared_at: string | null;
2111
+ error: {
2112
+ code: string;
2113
+ message: string;
2114
+ } | null;
2115
+ transcript_text?: string | null | undefined;
2116
+ transcript_omitted?: boolean | undefined;
2117
+ } | undefined;
2118
+ }[];
2119
+ counts: {
2120
+ remote: number;
2121
+ changed: number;
2122
+ unavailable: number;
2123
+ };
2124
+ instructions: string;
2125
+ } | undefined;
2126
+ synced_at: string;
2127
+ product_context: Record<string, string | string[] | null> | undefined;
2128
+ writing_style: string | undefined;
2129
+ articles: ({
2130
+ identity_mismatch?: true | undefined;
2131
+ remote: {
2132
+ revision: string;
2133
+ status: "draft" | "published";
2134
+ editor_url: string;
2135
+ public_url: string | null;
2136
+ deleted_at: null;
2137
+ id: string;
2138
+ local_article_id: string | null;
2139
+ title: string;
2140
+ section_id: string | null;
2141
+ repository_connection?: {
2142
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
2143
+ connect_url: string;
2144
+ capabilities: {
2145
+ sections: boolean;
2146
+ suggestions: boolean;
2147
+ code_analysis: boolean;
2148
+ maintenance: boolean;
2149
+ };
2150
+ writer?: {
2151
+ version: 1;
2152
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
2153
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2154
+ allowed: boolean;
2155
+ execution: "local" | "remote" | "hosted";
2156
+ required_scopes: string[];
2157
+ next_step: {
2158
+ code: string;
2159
+ message: string;
2160
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2161
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2162
+ url?: string | undefined;
2163
+ } | null;
2164
+ }>>;
2165
+ } | undefined;
2166
+ } | undefined;
2167
+ accepted_bundle_hash?: string | null | undefined;
2168
+ generation?: {
2169
+ run_id: string;
2170
+ attempt: string;
2171
+ state: "running" | "failed" | "cancelled" | "interrupted" | "complete" | "kept" | "discarded";
2172
+ } | null | undefined;
2173
+ } | {
2174
+ deleted_at: string;
2175
+ id: string;
2176
+ local_article_id: string | null;
2177
+ title: string;
2178
+ section_id: string | null;
2179
+ } | undefined;
2180
+ sync_status: string;
2181
+ local_article_id: string;
2182
+ artifact_dir: string;
2183
+ title?: string;
2184
+ run_id?: string;
2185
+ phase?: string;
2186
+ baseline?: z.infer<typeof remoteArticleSchema>;
2187
+ changed: boolean;
2188
+ content_changed: boolean;
2189
+ bundle_hash?: string;
2190
+ generation_attempt?: string;
2191
+ } | {
2192
+ remote: {
2193
+ revision: string;
2194
+ status: "draft" | "published";
2195
+ editor_url: string;
2196
+ public_url: string | null;
2197
+ deleted_at: null;
2198
+ id: string;
2199
+ local_article_id: string | null;
2200
+ title: string;
2201
+ section_id: string | null;
2202
+ repository_connection?: {
2203
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
2204
+ connect_url: string;
2205
+ capabilities: {
2206
+ sections: boolean;
2207
+ suggestions: boolean;
2208
+ code_analysis: boolean;
2209
+ maintenance: boolean;
2210
+ };
2211
+ writer?: {
2212
+ version: 1;
2213
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
2214
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2215
+ allowed: boolean;
2216
+ execution: "local" | "remote" | "hosted";
2217
+ required_scopes: string[];
2218
+ next_step: {
2219
+ code: string;
2220
+ message: string;
2221
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2222
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2223
+ url?: string | undefined;
2224
+ } | null;
2225
+ }>>;
2226
+ } | undefined;
2227
+ } | undefined;
2228
+ accepted_bundle_hash?: string | null | undefined;
2229
+ generation?: {
2230
+ run_id: string;
2231
+ attempt: string;
2232
+ state: "running" | "failed" | "cancelled" | "interrupted" | "complete" | "kept" | "discarded";
2233
+ } | null | undefined;
2234
+ } | {
2235
+ deleted_at: string;
2236
+ id: string;
2237
+ local_article_id: string | null;
2238
+ title: string;
2239
+ section_id: string | null;
2240
+ };
2241
+ sync_status: "remote_only";
2242
+ })[];
2243
+ counts: {
2244
+ local: number;
2245
+ remote: number;
2246
+ conflicts: number;
2247
+ deleted: number;
2248
+ };
2249
+ instructions: string;
2250
+ } | {
2251
+ articles: {
2252
+ local_article_id: string;
2253
+ artifact_dir: string;
2254
+ title?: string;
2255
+ run_id?: string;
2256
+ phase?: string;
2257
+ baseline?: z.infer<typeof remoteArticleSchema>;
2258
+ changed: boolean;
2259
+ content_changed: boolean;
2260
+ bundle_hash?: string;
2261
+ generation_attempt?: string;
2262
+ }[];
2263
+ status: "unsupported";
2264
+ project: {
2265
+ name: string;
2266
+ id?: string | undefined;
2267
+ help_centre_url?: string | undefined;
2268
+ };
2269
+ instructions: string;
2270
+ }>;
2271
+ upload(slug: string): Promise<{
2272
+ import_id: string;
2273
+ article: {
2274
+ id: string;
2275
+ revision: string;
2276
+ status: "draft" | "published";
2277
+ editor_url: string;
2278
+ public_url: string | null;
2279
+ repository_connection?: {
2280
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
2281
+ connect_url: string;
2282
+ capabilities: {
2283
+ sections: boolean;
2284
+ suggestions: boolean;
2285
+ code_analysis: boolean;
2286
+ maintenance: boolean;
2287
+ };
2288
+ writer?: {
2289
+ version: 1;
2290
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
2291
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2292
+ allowed: boolean;
2293
+ execution: "local" | "remote" | "hosted";
2294
+ required_scopes: string[];
2295
+ next_step: {
2296
+ code: string;
2297
+ message: string;
2298
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2299
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2300
+ url?: string | undefined;
2301
+ } | null;
2302
+ }>>;
2303
+ } | undefined;
2304
+ } | undefined;
2305
+ };
2306
+ }>;
2307
+ /** Shared CLI/MCP saved-article upload; the lock keeps the destination stable for the batch. */
2308
+ uploadLocalArticles(slugs?: string[], onEvent?: (event: {
2309
+ slug: string;
2310
+ title: string;
2311
+ editor_url?: string;
2312
+ error?: ReturnType<typeof publicError>;
2313
+ }) => void): Promise<{
2314
+ status: string;
2315
+ project_id: string;
2316
+ articles: {
2317
+ slug: string;
2318
+ title: string;
2319
+ local_article_id: string;
2320
+ artifact_dir: string;
2321
+ export_path?: string;
2322
+ run_id?: string;
2323
+ }[];
2324
+ instructions: string;
2325
+ uploaded?: undefined;
2326
+ already_uploaded?: undefined;
2327
+ failed?: undefined;
2328
+ skipped?: undefined;
2329
+ } | {
2330
+ status: string;
2331
+ project_id: string;
2332
+ uploaded: {
2333
+ slug: string;
2334
+ title: string;
2335
+ editor_url: string;
2336
+ }[];
2337
+ already_uploaded: {
2338
+ slug: string;
2339
+ editor_url: string;
2340
+ }[];
2341
+ failed: {
2342
+ slug: string;
2343
+ title: string;
2344
+ error: ReturnType<typeof publicError>;
2345
+ }[];
2346
+ skipped: string[];
2347
+ instructions: string;
2348
+ articles?: undefined;
2349
+ }>;
2350
+ private uploadUnlocked;
2351
+ complete(input: {
2352
+ run_id: string;
2353
+ completed: true;
2354
+ }, options?: {
2355
+ deliver?: boolean;
2356
+ }): Promise<{
2357
+ instructions: string[];
2358
+ hosting_invitation?: {
2359
+ id: string;
2360
+ message: string;
2361
+ } | undefined;
2362
+ show_to_user?: string | undefined;
2363
+ local: boolean;
2364
+ editor_url: string | null;
2365
+ link_message: string;
2366
+ link_instructions: string;
2367
+ status: "saved";
2368
+ run_id: string;
2369
+ slug: string;
2370
+ artifact_dir: string;
2371
+ markdown_path: string;
2372
+ export_dir: string;
2373
+ image_count: number | undefined;
2374
+ preview_uri: string | undefined;
2375
+ } | {
2376
+ open_when_ready: boolean;
2377
+ instructions: string[];
2378
+ repository_invitation?: {
2379
+ id: string;
2380
+ message: string;
2381
+ connect_url: string;
2382
+ } | undefined;
2383
+ show_to_user?: string | undefined;
2384
+ status: string;
2385
+ run_id: string;
2386
+ slug: string | undefined;
2387
+ article: {
2388
+ id: string;
2389
+ revision: string;
2390
+ status: "draft" | "published";
2391
+ editor_url: string;
2392
+ public_url: string | null;
2393
+ repository_connection?: {
2394
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
2395
+ connect_url: string;
2396
+ capabilities: {
2397
+ sections: boolean;
2398
+ suggestions: boolean;
2399
+ code_analysis: boolean;
2400
+ maintenance: boolean;
2401
+ };
2402
+ writer?: {
2403
+ version: 1;
2404
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
2405
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2406
+ allowed: boolean;
2407
+ execution: "local" | "remote" | "hosted";
2408
+ required_scopes: string[];
2409
+ next_step: {
2410
+ code: string;
2411
+ message: string;
2412
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2413
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2414
+ url?: string | undefined;
2415
+ } | null;
2416
+ }>>;
2417
+ } | undefined;
2418
+ } | undefined;
2419
+ };
2420
+ editor_url: string;
2421
+ repository_connection: {
2422
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
2423
+ connect_url: string;
2424
+ capabilities: {
2425
+ sections: boolean;
2426
+ suggestions: boolean;
2427
+ code_analysis: boolean;
2428
+ maintenance: boolean;
2429
+ };
2430
+ writer?: {
2431
+ version: 1;
2432
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
2433
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2434
+ allowed: boolean;
2435
+ execution: "local" | "remote" | "hosted";
2436
+ required_scopes: string[];
2437
+ next_step: {
2438
+ code: string;
2439
+ message: string;
2440
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2441
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2442
+ url?: string | undefined;
2443
+ } | null;
2444
+ }>>;
2445
+ } | undefined;
2446
+ } | undefined;
2447
+ } | {
2448
+ status: string;
2449
+ editor_url: string;
2450
+ }>;
2451
+ /** A run written without a help centre is finalized and exported instead of uploaded. Safe to repeat. */
2452
+ private completeLocallyUnlocked;
2453
+ private savedLocally;
2454
+ private delivery;
2455
+ private reportProgressEvent;
2456
+ retryArticle(input: {
2457
+ run_id: string;
2458
+ stopped: true;
2459
+ }): Promise<{
2460
+ task_brief: {
2461
+ name: string;
2462
+ claude_model: string | null;
2463
+ codex_model: string | null;
2464
+ codex_reasoning_effort: string | null;
2465
+ prefer_background: boolean | undefined;
2466
+ reporting_instructions: string;
2467
+ run_id: string;
2468
+ entrypoint: {
2469
+ command: string;
2470
+ args: string[];
2471
+ shell_command: string;
2472
+ execution: {
2473
+ command: string;
2474
+ args: string[];
2475
+ shell_command: string;
2476
+ instruction: string;
2477
+ };
2478
+ completion: {
2479
+ command: string;
2480
+ args: string[];
2481
+ shell_command: string;
2482
+ instruction: string;
2483
+ };
2484
+ instruction: string;
2485
+ };
2486
+ execution: {
2487
+ command: string;
2488
+ args: string[];
2489
+ shell_command: string;
2490
+ instruction: string;
2491
+ };
2492
+ completion: {
2493
+ command: string;
2494
+ args: string[];
2495
+ shell_command: string;
2496
+ instruction: string;
2497
+ };
2498
+ editor_url: string | null;
2499
+ writer_instructions: string;
2500
+ workspace: string;
2501
+ artifact_dir: string;
2502
+ environment: {
2503
+ RTFM_WORKSPACE: string;
2504
+ RTFM_CONTEXT_FILE: string;
2505
+ RTFM_OUTPUT_DIR: string;
2506
+ RTFM_SKILLS_DIR: string;
2507
+ RTFM_MAX_IMAGES: string;
2508
+ PATH: string;
2509
+ };
2510
+ instructions: string[];
2511
+ };
2512
+ instructions: string;
2513
+ local?: boolean | undefined;
2514
+ link_instructions: string;
2515
+ prefer_background: boolean | undefined;
2516
+ editor_url: string | null;
2517
+ link_message: string;
2518
+ run_id: string;
2519
+ }>;
2520
+ get hosted(): HostedOperations;
2521
+ createArticle(input: {
2522
+ title?: string;
2523
+ recommendation_id?: string;
2524
+ description?: string;
2525
+ article_type: z.infer<typeof articleType>;
2526
+ publish?: boolean;
2527
+ request_id?: string;
2528
+ prefer_background?: boolean;
2529
+ open_when_ready?: boolean;
2530
+ }): Promise<{
2531
+ operation_id: string;
2532
+ open_when_ready: boolean;
2533
+ instructions: string;
2534
+ id: string;
2535
+ project_id: string;
2536
+ action: string;
2537
+ execution: "hosted";
2538
+ attempt: number;
2539
+ status: "queued" | "running" | "succeeded" | "failed";
2540
+ article_id: string | null;
2541
+ result: Record<string, unknown>;
2542
+ error: {
2543
+ code: string;
2544
+ message: string;
2545
+ } | null;
2546
+ review_url: string | null;
2547
+ created_at: string;
2548
+ started_at: string | null;
2549
+ finished_at: string | null;
2550
+ walkthrough_id?: string | null | undefined;
2551
+ } | {
2552
+ publication_requested: boolean;
2553
+ prefer_background: boolean;
2554
+ open_when_ready: boolean;
2555
+ task_brief: {
2556
+ name: string;
2557
+ claude_model: string | null;
2558
+ codex_model: string | null;
2559
+ codex_reasoning_effort: string | null;
2560
+ prefer_background: boolean;
2561
+ reporting_instructions: string;
2562
+ writer_instructions: string;
2563
+ workspace: string;
2564
+ run_id: `${string}-${string}-${string}-${string}-${string}`;
2565
+ artifact_dir: string;
2566
+ environment: {
2567
+ RTFM_WORKSPACE: string;
2568
+ RTFM_CONTEXT_FILE: string;
2569
+ RTFM_OUTPUT_DIR: string;
2570
+ RTFM_SKILLS_DIR: string;
2571
+ RTFM_MAX_IMAGES: string;
2572
+ PATH: string;
2573
+ };
2574
+ entrypoint: {
2575
+ command: string;
2576
+ args: string[];
2577
+ shell_command: string;
2578
+ execution: {
2579
+ command: string;
2580
+ args: string[];
2581
+ shell_command: string;
2582
+ instruction: string;
2583
+ };
2584
+ completion: {
2585
+ command: string;
2586
+ args: string[];
2587
+ shell_command: string;
2588
+ instruction: string;
2589
+ };
2590
+ instruction: string;
2591
+ };
2592
+ execution: {
2593
+ command: string;
2594
+ args: string[];
2595
+ shell_command: string;
2596
+ instruction: string;
2597
+ };
2598
+ completion: {
2599
+ command: string;
2600
+ args: string[];
2601
+ shell_command: string;
2602
+ instruction: string;
2603
+ };
2604
+ editor_url: string | null;
2605
+ instructions: string[];
2606
+ };
2607
+ instructions: string[];
2608
+ writer_entrypoint: {
2609
+ command: string;
2610
+ args: string[];
2611
+ shell_command: string;
2612
+ execution: {
2613
+ command: string;
2614
+ args: string[];
2615
+ shell_command: string;
2616
+ instruction: string;
2617
+ };
2618
+ completion: {
2619
+ command: string;
2620
+ args: string[];
2621
+ shell_command: string;
2622
+ instruction: string;
2623
+ };
2624
+ instruction: string;
2625
+ };
2626
+ local?: boolean | undefined;
2627
+ saved_to?: string | undefined;
2628
+ link_message: string;
2629
+ link_instructions: string;
2630
+ editor_url: string | null;
2631
+ status: string;
2632
+ run_id: `${string}-${string}-${string}-${string}-${string}`;
2633
+ artifact_dir: string;
2634
+ environment: {
2635
+ RTFM_WORKSPACE: string;
2636
+ RTFM_CONTEXT_FILE: string;
2637
+ RTFM_OUTPUT_DIR: string;
2638
+ RTFM_SKILLS_DIR: string;
2639
+ RTFM_MAX_IMAGES: string;
2640
+ PATH: string;
2641
+ };
2642
+ }>;
2643
+ editArticle(input: {
2644
+ article_id: string;
2645
+ expected_revision: string;
2646
+ instructions: string;
2647
+ request_id?: string;
2648
+ prefer_background?: boolean;
2649
+ open_when_ready?: boolean;
2650
+ }): Promise<{
2651
+ operation_id: string;
2652
+ open_when_ready: boolean;
2653
+ instructions: string;
2654
+ id: string;
2655
+ project_id: string;
2656
+ action: string;
2657
+ execution: "hosted";
2658
+ attempt: number;
2659
+ status: "queued" | "running" | "succeeded" | "failed";
2660
+ article_id: string | null;
2661
+ result: Record<string, unknown>;
2662
+ error: {
2663
+ code: string;
2664
+ message: string;
2665
+ } | null;
2666
+ review_url: string | null;
2667
+ created_at: string;
2668
+ started_at: string | null;
2669
+ finished_at: string | null;
2670
+ walkthrough_id?: string | null | undefined;
2671
+ } | {
2672
+ status: string;
2673
+ execution: string;
2674
+ article: {
2675
+ [x: string]: unknown;
2676
+ id: string;
2677
+ revision: string;
2678
+ status: "draft" | "published";
2679
+ editor_url: string;
2680
+ public_url: string | null;
2681
+ repository_connection?: {
2682
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
2683
+ connect_url: string;
2684
+ capabilities: {
2685
+ sections: boolean;
2686
+ suggestions: boolean;
2687
+ code_analysis: boolean;
2688
+ maintenance: boolean;
2689
+ };
2690
+ writer?: {
2691
+ version: 1;
2692
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
2693
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2694
+ allowed: boolean;
2695
+ execution: "local" | "remote" | "hosted";
2696
+ required_scopes: string[];
2697
+ next_step: {
2698
+ code: string;
2699
+ message: string;
2700
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2701
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2702
+ url?: string | undefined;
2703
+ } | null;
2704
+ }>>;
2705
+ } | undefined;
2706
+ } | undefined;
2707
+ };
2708
+ editing_instructions: string;
2709
+ next_tool: string;
2710
+ expected_revision: string;
2711
+ instructions: string;
2712
+ }>;
2713
+ createWalkthrough(input: {
2714
+ article_id?: string;
2715
+ expected_revision?: string;
2716
+ request_id?: string;
2717
+ prefer_background?: boolean;
2718
+ open_when_ready?: boolean;
2719
+ }): Promise<{
2720
+ operation_id: string;
2721
+ open_when_ready: boolean;
2722
+ instructions: string;
2723
+ id: string;
2724
+ project_id: string;
2725
+ action: string;
2726
+ execution: "hosted";
2727
+ attempt: number;
2728
+ status: "queued" | "running" | "succeeded" | "failed";
2729
+ article_id: string | null;
2730
+ result: Record<string, unknown>;
2731
+ error: {
2732
+ code: string;
2733
+ message: string;
2734
+ } | null;
2735
+ review_url: string | null;
2736
+ created_at: string;
2737
+ started_at: string | null;
2738
+ finished_at: string | null;
2739
+ walkthrough_id?: string | null | undefined;
2740
+ } | {
2741
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2742
+ allowed: boolean;
2743
+ execution: "local" | "remote" | "hosted";
2744
+ required_scopes: string[];
2745
+ next_step: {
2746
+ code: string;
2747
+ message: string;
2748
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2749
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2750
+ url?: string | undefined;
2751
+ } | null;
2752
+ status: string;
2753
+ instructions?: undefined;
2754
+ } | {
2755
+ status: string;
2756
+ instructions: string;
2757
+ }>;
2758
+ listSuggestions(kind: 'sections' | 'recommendations', afterId?: string): Promise<{
2759
+ kind: "sections" | "recommendations";
2760
+ items: ({
2761
+ id: string;
2762
+ name: string;
2763
+ slug: string;
2764
+ description: string | null;
2765
+ justification: string | null;
2766
+ status: "pending" | "accepted" | "rejected";
2767
+ visible: boolean;
2768
+ } | {
2769
+ id: string;
2770
+ section_id: string | null;
2771
+ title: string;
2772
+ description: string | null;
2773
+ justification: string | null;
2774
+ article_type: "how-to" | "troubleshooting" | "concept" | "faq";
2775
+ status: "pending" | "accepted" | "rejected" | "generated";
2776
+ article_id: string | null;
2777
+ })[];
2778
+ next_cursor: string | null;
2779
+ }>;
2780
+ reviewSuggestion(kind: 'sections' | 'recommendations', id: string, decision: 'accept' | 'reject'): Promise<{
2781
+ id: string;
2782
+ name: string;
2783
+ slug: string;
2784
+ description: string | null;
2785
+ justification: string | null;
2786
+ status: "pending" | "accepted" | "rejected";
2787
+ visible: boolean;
2788
+ } | {
2789
+ id: string;
2790
+ section_id: string | null;
2791
+ title: string;
2792
+ description: string | null;
2793
+ justification: string | null;
2794
+ article_type: "how-to" | "troubleshooting" | "concept" | "faq";
2795
+ status: "pending" | "accepted" | "rejected" | "generated";
2796
+ article_id: string | null;
2797
+ }>;
2798
+ listArticles(afterId?: string, source?: 'auto' | 'local' | 'hosted'): Promise<{
2799
+ status: "local";
2800
+ source: "local";
2801
+ articles: {
2802
+ slug: string;
2803
+ title: string;
2804
+ artifact_dir: string;
2805
+ article_path?: string;
2806
+ export_path?: string;
2807
+ local_article_id?: string;
2808
+ run_id?: string;
2809
+ }[];
2810
+ next_cursor: null;
2811
+ searched_directories: string[];
2812
+ warnings: {
2813
+ path: string;
2814
+ message: string;
2815
+ }[];
2816
+ instructions: string;
2817
+ } | {
2818
+ articles: {
2819
+ [x: string]: unknown;
2820
+ id: string;
2821
+ revision: string;
2822
+ status: "draft" | "published";
2823
+ editor_url: string;
2824
+ public_url: string | null;
2825
+ repository_connection?: {
2826
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
2827
+ connect_url: string;
2828
+ capabilities: {
2829
+ sections: boolean;
2830
+ suggestions: boolean;
2831
+ code_analysis: boolean;
2832
+ maintenance: boolean;
2833
+ };
2834
+ writer?: {
2835
+ version: 1;
2836
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
2837
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2838
+ allowed: boolean;
2839
+ execution: "local" | "remote" | "hosted";
2840
+ required_scopes: string[];
2841
+ next_step: {
2842
+ code: string;
2843
+ message: string;
2844
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2845
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2846
+ url?: string | undefined;
2847
+ } | null;
2848
+ }>>;
2849
+ } | undefined;
2850
+ } | undefined;
2851
+ }[];
2852
+ next_cursor: string | null;
2853
+ }>;
2854
+ mutateArticle(action: 'update_article' | 'publish_article' | 'unpublish_article' | 'delete_article', input: {
2855
+ article_id: string;
2856
+ expected_revision: string;
2857
+ structured_content?: unknown;
2858
+ body?: string;
2859
+ title?: string;
2860
+ }): Promise<{
2861
+ [x: string]: unknown;
2862
+ id: string;
2863
+ revision: string;
2864
+ status: "draft" | "published";
2865
+ editor_url: string;
2866
+ public_url: string | null;
2867
+ repository_connection?: {
2868
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
2869
+ connect_url: string;
2870
+ capabilities: {
2871
+ sections: boolean;
2872
+ suggestions: boolean;
2873
+ code_analysis: boolean;
2874
+ maintenance: boolean;
2875
+ };
2876
+ writer?: {
2877
+ version: 1;
2878
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
2879
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2880
+ allowed: boolean;
2881
+ execution: "local" | "remote" | "hosted";
2882
+ required_scopes: string[];
2883
+ next_step: {
2884
+ code: string;
2885
+ message: string;
2886
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2887
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2888
+ url?: string | undefined;
2889
+ } | null;
2890
+ }>>;
2891
+ } | undefined;
2892
+ } | undefined;
2893
+ } | {
2894
+ id: string;
2895
+ deleted_at: string;
2896
+ }>;
2897
+ getArticle(articleId: string): Promise<{
2898
+ [x: string]: unknown;
2899
+ id: string;
2900
+ revision: string;
2901
+ status: "draft" | "published";
2902
+ editor_url: string;
2903
+ public_url: string | null;
2904
+ repository_connection?: {
2905
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
2906
+ connect_url: string;
2907
+ capabilities: {
2908
+ sections: boolean;
2909
+ suggestions: boolean;
2910
+ code_analysis: boolean;
2911
+ maintenance: boolean;
2912
+ };
2913
+ writer?: {
2914
+ version: 1;
2915
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
2916
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2917
+ allowed: boolean;
2918
+ execution: "local" | "remote" | "hosted";
2919
+ required_scopes: string[];
2920
+ next_step: {
2921
+ code: string;
2922
+ message: string;
2923
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2924
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2925
+ url?: string | undefined;
2926
+ } | null;
2927
+ }>>;
2928
+ } | undefined;
2929
+ } | undefined;
2930
+ }>;
2931
+ publish(slug: string, expectedRevision: string): Promise<{
2932
+ id: string;
2933
+ revision: string;
2934
+ status: "draft" | "published";
2935
+ editor_url: string;
2936
+ public_url: string | null;
2937
+ repository_connection?: {
2938
+ state: "not_connected" | "connected" | "disconnected" | "suspended";
2939
+ connect_url: string;
2940
+ capabilities: {
2941
+ sections: boolean;
2942
+ suggestions: boolean;
2943
+ code_analysis: boolean;
2944
+ maintenance: boolean;
2945
+ };
2946
+ writer?: {
2947
+ version: 1;
2948
+ actions: Partial<Record<"read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre", {
2949
+ action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2950
+ allowed: boolean;
2951
+ execution: "local" | "remote" | "hosted";
2952
+ required_scopes: string[];
2953
+ next_step: {
2954
+ code: string;
2955
+ message: string;
2956
+ requested_action: "read_articles" | "create_article" | "update_article" | "edit_article" | "publish_article" | "unpublish_article" | "delete_article" | "find_article_gaps" | "suggest_sections" | "recommend_articles" | "review_sections" | "review_recommendations" | "create_video_walkthrough" | "get_operation" | "generate_help_centre";
2957
+ missing_scopes?: ("read" | "import" | "publish" | "manage" | "generate")[] | undefined;
2958
+ url?: string | undefined;
2959
+ } | null;
2960
+ }>>;
2961
+ } | undefined;
2962
+ } | undefined;
2963
+ }>;
2964
+ }