@crowi/api 2.0.0-alpha.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 (887) hide show
  1. package/LICENSE +21 -0
  2. package/dist/app.d.ts +8 -0
  3. package/dist/app.js +65 -0
  4. package/dist/app.js.map +1 -0
  5. package/dist/collab/attach.d.ts +33 -0
  6. package/dist/collab/attach.js +341 -0
  7. package/dist/collab/attach.js.map +1 -0
  8. package/dist/collab/extension-redis.d.ts +25 -0
  9. package/dist/collab/extension-redis.js +133 -0
  10. package/dist/collab/extension-redis.js.map +1 -0
  11. package/dist/common/functions/path2name.d.ts +1 -0
  12. package/dist/common/functions/path2name.js +22 -0
  13. package/dist/common/functions/path2name.js.map +1 -0
  14. package/dist/common/functions/renderIcon.d.ts +1 -0
  15. package/dist/common/functions/renderIcon.js +9 -0
  16. package/dist/common/functions/renderIcon.js.map +1 -0
  17. package/dist/controllers/admin.d.ts +3 -0
  18. package/dist/controllers/admin.js +474 -0
  19. package/dist/controllers/admin.js.map +1 -0
  20. package/dist/controllers/attachment.d.ts +4 -0
  21. package/dist/controllers/attachment.js +200 -0
  22. package/dist/controllers/attachment.js.map +1 -0
  23. package/dist/controllers/backlink.d.ts +3 -0
  24. package/dist/controllers/backlink.js +42 -0
  25. package/dist/controllers/backlink.js.map +1 -0
  26. package/dist/controllers/bookmark.d.ts +3 -0
  27. package/dist/controllers/bookmark.js +100 -0
  28. package/dist/controllers/bookmark.js.map +1 -0
  29. package/dist/controllers/comment.d.ts +3 -0
  30. package/dist/controllers/comment.js +111 -0
  31. package/dist/controllers/comment.js.map +1 -0
  32. package/dist/controllers/index.d.ts +25 -0
  33. package/dist/controllers/index.js +44 -0
  34. package/dist/controllers/index.js.map +1 -0
  35. package/dist/controllers/installer.d.ts +3 -0
  36. package/dist/controllers/installer.js +48 -0
  37. package/dist/controllers/installer.js.map +1 -0
  38. package/dist/controllers/login.d.ts +4 -0
  39. package/dist/controllers/login.js +438 -0
  40. package/dist/controllers/login.js.map +1 -0
  41. package/dist/controllers/logout.d.ts +5 -0
  42. package/dist/controllers/logout.js +11 -0
  43. package/dist/controllers/logout.js.map +1 -0
  44. package/dist/controllers/me.d.ts +4 -0
  45. package/dist/controllers/me.js +369 -0
  46. package/dist/controllers/me.js.map +1 -0
  47. package/dist/controllers/notification.d.ts +3 -0
  48. package/dist/controllers/notification.js +88 -0
  49. package/dist/controllers/notification.js.map +1 -0
  50. package/dist/controllers/page.d.ts +3 -0
  51. package/dist/controllers/page.js +881 -0
  52. package/dist/controllers/page.js.map +1 -0
  53. package/dist/controllers/revision.d.ts +3 -0
  54. package/dist/controllers/revision.js +91 -0
  55. package/dist/controllers/revision.js.map +1 -0
  56. package/dist/controllers/search.d.ts +3 -0
  57. package/dist/controllers/search.js +93 -0
  58. package/dist/controllers/search.js.map +1 -0
  59. package/dist/controllers/share.d.ts +3 -0
  60. package/dist/controllers/share.js +207 -0
  61. package/dist/controllers/share.js.map +1 -0
  62. package/dist/controllers/shareAccess.d.ts +3 -0
  63. package/dist/controllers/shareAccess.js +28 -0
  64. package/dist/controllers/shareAccess.js.map +1 -0
  65. package/dist/controllers/slack.d.ts +3 -0
  66. package/dist/controllers/slack.js +87 -0
  67. package/dist/controllers/slack.js.map +1 -0
  68. package/dist/controllers/tokenAuth.d.ts +10 -0
  69. package/dist/controllers/tokenAuth.js +292 -0
  70. package/dist/controllers/tokenAuth.js.map +1 -0
  71. package/dist/controllers/user.d.ts +3 -0
  72. package/dist/controllers/user.js +67 -0
  73. package/dist/controllers/user.js.map +1 -0
  74. package/dist/controllers/version.d.ts +4 -0
  75. package/dist/controllers/version.js +19 -0
  76. package/dist/controllers/version.js.map +1 -0
  77. package/dist/crowi/express-init.d.ts +4 -0
  78. package/dist/crowi/express-init.js +101 -0
  79. package/dist/crowi/express-init.js.map +1 -0
  80. package/dist/crowi/index.d.ts +245 -0
  81. package/dist/crowi/index.js +726 -0
  82. package/dist/crowi/index.js.map +1 -0
  83. package/dist/events/activity.d.ts +7 -0
  84. package/dist/events/activity.js +15 -0
  85. package/dist/events/activity.js.map +1 -0
  86. package/dist/events/bookmark.d.ts +8 -0
  87. package/dist/events/bookmark.js +16 -0
  88. package/dist/events/bookmark.js.map +1 -0
  89. package/dist/events/comment.d.ts +6 -0
  90. package/dist/events/comment.js +14 -0
  91. package/dist/events/comment.js.map +1 -0
  92. package/dist/events/config.d.ts +6 -0
  93. package/dist/events/config.js +12 -0
  94. package/dist/events/config.js.map +1 -0
  95. package/dist/events/index.d.ts +17 -0
  96. package/dist/events/index.js +22 -0
  97. package/dist/events/index.js.map +1 -0
  98. package/dist/events/mention-dispatch.d.ts +44 -0
  99. package/dist/events/mention-dispatch.js +151 -0
  100. package/dist/events/mention-dispatch.js.map +1 -0
  101. package/dist/events/notification.d.ts +7 -0
  102. package/dist/events/notification.js +15 -0
  103. package/dist/events/notification.js.map +1 -0
  104. package/dist/events/page.d.ts +44 -0
  105. package/dist/events/page.js +134 -0
  106. package/dist/events/page.js.map +1 -0
  107. package/dist/events/render-cache.d.ts +24 -0
  108. package/dist/events/render-cache.js +63 -0
  109. package/dist/events/render-cache.js.map +1 -0
  110. package/dist/events/user.d.ts +9 -0
  111. package/dist/events/user.js +39 -0
  112. package/dist/events/user.js.map +1 -0
  113. package/dist/form/admin/app.d.ts +2 -0
  114. package/dist/form/admin/app.js +9 -0
  115. package/dist/form/admin/app.js.map +1 -0
  116. package/dist/form/admin/auth.d.ts +2 -0
  117. package/dist/form/admin/auth.js +9 -0
  118. package/dist/form/admin/auth.js.map +1 -0
  119. package/dist/form/admin/aws.d.ts +2 -0
  120. package/dist/form/admin/aws.js +13 -0
  121. package/dist/form/admin/aws.js.map +1 -0
  122. package/dist/form/admin/github.d.ts +2 -0
  123. package/dist/form/admin/github.js +15 -0
  124. package/dist/form/admin/github.js.map +1 -0
  125. package/dist/form/admin/google.d.ts +2 -0
  126. package/dist/form/admin/google.js +13 -0
  127. package/dist/form/admin/google.js.map +1 -0
  128. package/dist/form/admin/mail.d.ts +2 -0
  129. package/dist/form/admin/mail.js +13 -0
  130. package/dist/form/admin/mail.js.map +1 -0
  131. package/dist/form/admin/sec.d.ts +2 -0
  132. package/dist/form/admin/sec.js +10 -0
  133. package/dist/form/admin/sec.js.map +1 -0
  134. package/dist/form/admin/slackSetting.d.ts +2 -0
  135. package/dist/form/admin/slackSetting.js +13 -0
  136. package/dist/form/admin/slackSetting.js.map +1 -0
  137. package/dist/form/admin/userEdit.d.ts +2 -0
  138. package/dist/form/admin/userEdit.js +9 -0
  139. package/dist/form/admin/userEdit.js.map +1 -0
  140. package/dist/form/admin/userInvite.d.ts +2 -0
  141. package/dist/form/admin/userInvite.js +9 -0
  142. package/dist/form/admin/userInvite.js.map +1 -0
  143. package/dist/form/comment.d.ts +2 -0
  144. package/dist/form/comment.js +9 -0
  145. package/dist/form/comment.js.map +1 -0
  146. package/dist/form/index.d.ts +25 -0
  147. package/dist/form/index.js +48 -0
  148. package/dist/form/index.js.map +1 -0
  149. package/dist/form/invited.d.ts +2 -0
  150. package/dist/form/invited.js +13 -0
  151. package/dist/form/invited.js.map +1 -0
  152. package/dist/form/login.d.ts +2 -0
  153. package/dist/form/login.js +11 -0
  154. package/dist/form/login.js.map +1 -0
  155. package/dist/form/me/apiToken.d.ts +2 -0
  156. package/dist/form/me/apiToken.js +9 -0
  157. package/dist/form/me/apiToken.js.map +1 -0
  158. package/dist/form/me/password.d.ts +2 -0
  159. package/dist/form/me/password.js +11 -0
  160. package/dist/form/me/password.js.map +1 -0
  161. package/dist/form/me/user.d.ts +2 -0
  162. package/dist/form/me/user.js +9 -0
  163. package/dist/form/me/user.js.map +1 -0
  164. package/dist/form/register.d.ts +2 -0
  165. package/dist/form/register.js +13 -0
  166. package/dist/form/register.js.map +1 -0
  167. package/dist/form/revision.d.ts +2 -0
  168. package/dist/form/revision.js +13 -0
  169. package/dist/form/revision.js.map +1 -0
  170. package/dist/hono/app.d.ts +19 -0
  171. package/dist/hono/app.js +21 -0
  172. package/dist/hono/app.js.map +1 -0
  173. package/dist/hono/handlers/_helpers/errors.d.ts +61 -0
  174. package/dist/hono/handlers/_helpers/errors.js +51 -0
  175. package/dist/hono/handlers/_helpers/errors.js.map +1 -0
  176. package/dist/hono/handlers/_helpers/user-shape.d.ts +46 -0
  177. package/dist/hono/handlers/_helpers/user-shape.js +23 -0
  178. package/dist/hono/handlers/_helpers/user-shape.js.map +1 -0
  179. package/dist/hono/handlers/access-token.d.ts +221 -0
  180. package/dist/hono/handlers/access-token.js +113 -0
  181. package/dist/hono/handlers/access-token.js.map +1 -0
  182. package/dist/hono/handlers/activation.d.ts +117 -0
  183. package/dist/hono/handlers/activation.js +77 -0
  184. package/dist/hono/handlers/activation.js.map +1 -0
  185. package/dist/hono/handlers/admin/app.d.ts +123 -0
  186. package/dist/hono/handlers/admin/app.js +76 -0
  187. package/dist/hono/handlers/admin/app.js.map +1 -0
  188. package/dist/hono/handlers/admin/auth.d.ts +127 -0
  189. package/dist/hono/handlers/admin/auth.js +91 -0
  190. package/dist/hono/handlers/admin/auth.js.map +1 -0
  191. package/dist/hono/handlers/admin/mail.d.ts +168 -0
  192. package/dist/hono/handlers/admin/mail.js +76 -0
  193. package/dist/hono/handlers/admin/mail.js.map +1 -0
  194. package/dist/hono/handlers/admin/plugins.d.ts +409 -0
  195. package/dist/hono/handlers/admin/plugins.js +257 -0
  196. package/dist/hono/handlers/admin/plugins.js.map +1 -0
  197. package/dist/hono/handlers/admin/search.d.ts +57 -0
  198. package/dist/hono/handlers/admin/search.js +55 -0
  199. package/dist/hono/handlers/admin/search.js.map +1 -0
  200. package/dist/hono/handlers/admin/security.d.ts +112 -0
  201. package/dist/hono/handlers/admin/security.js +71 -0
  202. package/dist/hono/handlers/admin/security.js.map +1 -0
  203. package/dist/hono/handlers/admin/share.d.ts +106 -0
  204. package/dist/hono/handlers/admin/share.js +55 -0
  205. package/dist/hono/handlers/admin/share.js.map +1 -0
  206. package/dist/hono/handlers/admin/storage.d.ts +55 -0
  207. package/dist/hono/handlers/admin/storage.js +40 -0
  208. package/dist/hono/handlers/admin/storage.js.map +1 -0
  209. package/dist/hono/handlers/admin/users.d.ts +1230 -0
  210. package/dist/hono/handlers/admin/users.js +316 -0
  211. package/dist/hono/handlers/admin/users.js.map +1 -0
  212. package/dist/hono/handlers/adminCrypto.d.ts +110 -0
  213. package/dist/hono/handlers/adminCrypto.js +151 -0
  214. package/dist/hono/handlers/adminCrypto.js.map +1 -0
  215. package/dist/hono/handlers/app.d.ts +26 -0
  216. package/dist/hono/handlers/app.js +34 -0
  217. package/dist/hono/handlers/app.js.map +1 -0
  218. package/dist/hono/handlers/attachment-stream.d.ts +4 -0
  219. package/dist/hono/handlers/attachment-stream.js +211 -0
  220. package/dist/hono/handlers/attachment-stream.js.map +1 -0
  221. package/dist/hono/handlers/attachment.d.ts +687 -0
  222. package/dist/hono/handlers/attachment.js +566 -0
  223. package/dist/hono/handlers/attachment.js.map +1 -0
  224. package/dist/hono/handlers/autocomplete.d.ts +160 -0
  225. package/dist/hono/handlers/autocomplete.js +181 -0
  226. package/dist/hono/handlers/autocomplete.js.map +1 -0
  227. package/dist/hono/handlers/backlink.d.ts +78 -0
  228. package/dist/hono/handlers/backlink.js +93 -0
  229. package/dist/hono/handlers/backlink.js.map +1 -0
  230. package/dist/hono/handlers/bookmark.d.ts +558 -0
  231. package/dist/hono/handlers/bookmark.js +166 -0
  232. package/dist/hono/handlers/bookmark.js.map +1 -0
  233. package/dist/hono/handlers/comment.d.ts +231 -0
  234. package/dist/hono/handlers/comment.js +191 -0
  235. package/dist/hono/handlers/comment.js.map +1 -0
  236. package/dist/hono/handlers/draft.d.ts +136 -0
  237. package/dist/hono/handlers/draft.js +191 -0
  238. package/dist/hono/handlers/draft.js.map +1 -0
  239. package/dist/hono/handlers/emailChange.d.ts +124 -0
  240. package/dist/hono/handlers/emailChange.js +79 -0
  241. package/dist/hono/handlers/emailChange.js.map +1 -0
  242. package/dist/hono/handlers/installer.d.ts +94 -0
  243. package/dist/hono/handlers/installer.js +93 -0
  244. package/dist/hono/handlers/installer.js.map +1 -0
  245. package/dist/hono/handlers/inviteAccept.d.ts +180 -0
  246. package/dist/hono/handlers/inviteAccept.js +94 -0
  247. package/dist/hono/handlers/inviteAccept.js.map +1 -0
  248. package/dist/hono/handlers/me.d.ts +401 -0
  249. package/dist/hono/handlers/me.js +390 -0
  250. package/dist/hono/handlers/me.js.map +1 -0
  251. package/dist/hono/handlers/notification.d.ts +274 -0
  252. package/dist/hono/handlers/notification.js +224 -0
  253. package/dist/hono/handlers/notification.js.map +1 -0
  254. package/dist/hono/handlers/oauth.d.ts +299 -0
  255. package/dist/hono/handlers/oauth.js +443 -0
  256. package/dist/hono/handlers/oauth.js.map +1 -0
  257. package/dist/hono/handlers/page-collab.d.ts +79 -0
  258. package/dist/hono/handlers/page-collab.js +98 -0
  259. package/dist/hono/handlers/page-collab.js.map +1 -0
  260. package/dist/hono/handlers/page-preview.d.ts +48 -0
  261. package/dist/hono/handlers/page-preview.js +83 -0
  262. package/dist/hono/handlers/page-preview.js.map +1 -0
  263. package/dist/hono/handlers/page.d.ts +2059 -0
  264. package/dist/hono/handlers/page.js +793 -0
  265. package/dist/hono/handlers/page.js.map +1 -0
  266. package/dist/hono/handlers/passwordReset.d.ts +181 -0
  267. package/dist/hono/handlers/passwordReset.js +101 -0
  268. package/dist/hono/handlers/passwordReset.js.map +1 -0
  269. package/dist/hono/handlers/presence.d.ts +178 -0
  270. package/dist/hono/handlers/presence.js +163 -0
  271. package/dist/hono/handlers/presence.js.map +1 -0
  272. package/dist/hono/handlers/revision.d.ts +345 -0
  273. package/dist/hono/handlers/revision.js +202 -0
  274. package/dist/hono/handlers/revision.js.map +1 -0
  275. package/dist/hono/handlers/search.d.ts +208 -0
  276. package/dist/hono/handlers/search.js +152 -0
  277. package/dist/hono/handlers/search.js.map +1 -0
  278. package/dist/hono/handlers/tokenAuth.d.ts +369 -0
  279. package/dist/hono/handlers/tokenAuth.js +240 -0
  280. package/dist/hono/handlers/tokenAuth.js.map +1 -0
  281. package/dist/hono/handlers/user.d.ts +710 -0
  282. package/dist/hono/handlers/user.js +212 -0
  283. package/dist/hono/handlers/user.js.map +1 -0
  284. package/dist/hono/index.d.ts +289 -0
  285. package/dist/hono/index.js +240 -0
  286. package/dist/hono/index.js.map +1 -0
  287. package/dist/hono/middleware/admin.d.ts +5 -0
  288. package/dist/hono/middleware/admin.js +34 -0
  289. package/dist/hono/middleware/admin.js.map +1 -0
  290. package/dist/hono/middleware/auth.d.ts +54 -0
  291. package/dist/hono/middleware/auth.js +142 -0
  292. package/dist/hono/middleware/auth.js.map +1 -0
  293. package/dist/hono/middleware/cors.d.ts +3 -0
  294. package/dist/hono/middleware/cors.js +86 -0
  295. package/dist/hono/middleware/cors.js.map +1 -0
  296. package/dist/hono/middleware/default-hook.d.ts +8 -0
  297. package/dist/hono/middleware/default-hook.js +17 -0
  298. package/dist/hono/middleware/default-hook.js.map +1 -0
  299. package/dist/hono/middleware/error-handler.d.ts +2 -0
  300. package/dist/hono/middleware/error-handler.js +20 -0
  301. package/dist/hono/middleware/error-handler.js.map +1 -0
  302. package/dist/hono/middleware/rate-limit.d.ts +57 -0
  303. package/dist/hono/middleware/rate-limit.js +42 -0
  304. package/dist/hono/middleware/rate-limit.js.map +1 -0
  305. package/dist/hono/middleware/require-scope.d.ts +50 -0
  306. package/dist/hono/middleware/require-scope.js +64 -0
  307. package/dist/hono/middleware/require-scope.js.map +1 -0
  308. package/dist/hono/path-rewrite.d.ts +15 -0
  309. package/dist/hono/path-rewrite.js +59 -0
  310. package/dist/hono/path-rewrite.js.map +1 -0
  311. package/dist/mail/i18n/en.d.ts +2 -0
  312. package/dist/mail/i18n/en.js +66 -0
  313. package/dist/mail/i18n/en.js.map +1 -0
  314. package/dist/mail/i18n/index.d.ts +46 -0
  315. package/dist/mail/i18n/index.js +31 -0
  316. package/dist/mail/i18n/index.js.map +1 -0
  317. package/dist/mail/i18n/ja.d.ts +2 -0
  318. package/dist/mail/i18n/ja.js +66 -0
  319. package/dist/mail/i18n/ja.js.map +1 -0
  320. package/dist/mcp/attach.d.ts +25 -0
  321. package/dist/mcp/attach.js +104 -0
  322. package/dist/mcp/attach.js.map +1 -0
  323. package/dist/mcp/dispatch.d.ts +59 -0
  324. package/dist/mcp/dispatch.js +70 -0
  325. package/dist/mcp/dispatch.js.map +1 -0
  326. package/dist/mcp/result.d.ts +40 -0
  327. package/dist/mcp/result.js +78 -0
  328. package/dist/mcp/result.js.map +1 -0
  329. package/dist/mcp/server.d.ts +67 -0
  330. package/dist/mcp/server.js +113 -0
  331. package/dist/mcp/server.js.map +1 -0
  332. package/dist/mcp/tools/page.d.ts +2 -0
  333. package/dist/mcp/tools/page.js +256 -0
  334. package/dist/mcp/tools/page.js.map +1 -0
  335. package/dist/mcp/tools/search.d.ts +2 -0
  336. package/dist/mcp/tools/search.js +36 -0
  337. package/dist/mcp/tools/search.js.map +1 -0
  338. package/dist/middlewares/accessTokenParser.d.ts +4 -0
  339. package/dist/middlewares/accessTokenParser.js +29 -0
  340. package/dist/middlewares/accessTokenParser.js.map +1 -0
  341. package/dist/middlewares/adminRequired.d.ts +10 -0
  342. package/dist/middlewares/adminRequired.js +35 -0
  343. package/dist/middlewares/adminRequired.js.map +1 -0
  344. package/dist/middlewares/applicationInstalled.d.ts +3 -0
  345. package/dist/middlewares/applicationInstalled.js +20 -0
  346. package/dist/middlewares/applicationInstalled.js.map +1 -0
  347. package/dist/middlewares/applicationNotInstalled.d.ts +3 -0
  348. package/dist/middlewares/applicationNotInstalled.js +13 -0
  349. package/dist/middlewares/applicationNotInstalled.js.map +1 -0
  350. package/dist/middlewares/basicAuth.d.ts +4 -0
  351. package/dist/middlewares/basicAuth.js +23 -0
  352. package/dist/middlewares/basicAuth.js.map +1 -0
  353. package/dist/middlewares/csrfVerify.d.ts +4 -0
  354. package/dist/middlewares/csrfVerify.js +24 -0
  355. package/dist/middlewares/csrfVerify.js.map +1 -0
  356. package/dist/middlewares/encodeSpace.d.ts +3 -0
  357. package/dist/middlewares/encodeSpace.js +14 -0
  358. package/dist/middlewares/encodeSpace.js.map +1 -0
  359. package/dist/middlewares/fileAccessRightOrLoginRequired.d.ts +4 -0
  360. package/dist/middlewares/fileAccessRightOrLoginRequired.js +29 -0
  361. package/dist/middlewares/fileAccessRightOrLoginRequired.js.map +1 -0
  362. package/dist/middlewares/index.d.ts +16 -0
  363. package/dist/middlewares/index.js +30 -0
  364. package/dist/middlewares/index.js.map +1 -0
  365. package/dist/middlewares/jwtAdminRequired.d.ts +8 -0
  366. package/dist/middlewares/jwtAdminRequired.js +35 -0
  367. package/dist/middlewares/jwtAdminRequired.js.map +1 -0
  368. package/dist/middlewares/jwtAuth.d.ts +4 -0
  369. package/dist/middlewares/jwtAuth.js +104 -0
  370. package/dist/middlewares/jwtAuth.js.map +1 -0
  371. package/dist/middlewares/loginChecker.d.ts +4 -0
  372. package/dist/middlewares/loginChecker.js +32 -0
  373. package/dist/middlewares/loginChecker.js.map +1 -0
  374. package/dist/middlewares/loginRequired.d.ts +4 -0
  375. package/dist/middlewares/loginRequired.js +88 -0
  376. package/dist/middlewares/loginRequired.js.map +1 -0
  377. package/dist/migration/cli-api.d.ts +83 -0
  378. package/dist/migration/cli-api.js +128 -0
  379. package/dist/migration/cli-api.js.map +1 -0
  380. package/dist/migration/migrations/index.d.ts +12 -0
  381. package/dist/migration/migrations/index.js +24 -0
  382. package/dist/migration/migrations/index.js.map +1 -0
  383. package/dist/migration/migrations/page-status-default.d.ts +25 -0
  384. package/dist/migration/migrations/page-status-default.js +79 -0
  385. package/dist/migration/migrations/page-status-default.js.map +1 -0
  386. package/dist/migration/migrations/revisions-schema-unify.d.ts +33 -0
  387. package/dist/migration/migrations/revisions-schema-unify.js +88 -0
  388. package/dist/migration/migrations/revisions-schema-unify.js.map +1 -0
  389. package/dist/migration/migrations/user-unique-prepare.d.ts +1 -0
  390. package/dist/migration/migrations/user-unique-prepare.js +214 -0
  391. package/dist/migration/migrations/user-unique-prepare.js.map +1 -0
  392. package/dist/migration/migrations/wikilink-format.d.ts +97 -0
  393. package/dist/migration/migrations/wikilink-format.js +418 -0
  394. package/dist/migration/migrations/wikilink-format.js.map +1 -0
  395. package/dist/migration/rebuild-api.d.ts +50 -0
  396. package/dist/migration/rebuild-api.js +45 -0
  397. package/dist/migration/rebuild-api.js.map +1 -0
  398. package/dist/migration/rebuild-runner.d.ts +64 -0
  399. package/dist/migration/rebuild-runner.js +42 -0
  400. package/dist/migration/rebuild-runner.js.map +1 -0
  401. package/dist/migration/rebuilds/index.d.ts +26 -0
  402. package/dist/migration/rebuilds/index.js +69 -0
  403. package/dist/migration/rebuilds/index.js.map +1 -0
  404. package/dist/migration/registry.d.ts +15 -0
  405. package/dist/migration/registry.js +96 -0
  406. package/dist/migration/registry.js.map +1 -0
  407. package/dist/migration/run-boot-migrations.d.ts +31 -0
  408. package/dist/migration/run-boot-migrations.js +95 -0
  409. package/dist/migration/run-boot-migrations.js.map +1 -0
  410. package/dist/migration/runner.d.ts +120 -0
  411. package/dist/migration/runner.js +276 -0
  412. package/dist/migration/runner.js.map +1 -0
  413. package/dist/migration/types.d.ts +153 -0
  414. package/dist/migration/types.js +13 -0
  415. package/dist/migration/types.js.map +1 -0
  416. package/dist/models/activity.d.ts +34 -0
  417. package/dist/models/activity.js +263 -0
  418. package/dist/models/activity.js.map +1 -0
  419. package/dist/models/attachment.d.ts +25 -0
  420. package/dist/models/attachment.js +82 -0
  421. package/dist/models/attachment.js.map +1 -0
  422. package/dist/models/backlink.d.ts +19 -0
  423. package/dist/models/backlink.js +138 -0
  424. package/dist/models/backlink.js.map +1 -0
  425. package/dist/models/bookmark.d.ts +28 -0
  426. package/dist/models/bookmark.js +136 -0
  427. package/dist/models/bookmark.js.map +1 -0
  428. package/dist/models/comment.d.ts +21 -0
  429. package/dist/models/comment.js +87 -0
  430. package/dist/models/comment.js.map +1 -0
  431. package/dist/models/config-sensitive.d.ts +21 -0
  432. package/dist/models/config-sensitive.js +71 -0
  433. package/dist/models/config-sensitive.js.map +1 -0
  434. package/dist/models/config.d.ts +34 -0
  435. package/dist/models/config.js +161 -0
  436. package/dist/models/config.js.map +1 -0
  437. package/dist/models/index.d.ts +30 -0
  438. package/dist/models/index.js +55 -0
  439. package/dist/models/index.js.map +1 -0
  440. package/dist/models/migration-application.d.ts +54 -0
  441. package/dist/models/migration-application.js +36 -0
  442. package/dist/models/migration-application.js.map +1 -0
  443. package/dist/models/notification.d.ts +28 -0
  444. package/dist/models/notification.js +285 -0
  445. package/dist/models/notification.js.map +1 -0
  446. package/dist/models/oauth-authorization-code.d.ts +34 -0
  447. package/dist/models/oauth-authorization-code.js +100 -0
  448. package/dist/models/oauth-authorization-code.js.map +1 -0
  449. package/dist/models/oauth-client.d.ts +36 -0
  450. package/dist/models/oauth-client.js +56 -0
  451. package/dist/models/oauth-client.js.map +1 -0
  452. package/dist/models/oauth-device-code.d.ts +55 -0
  453. package/dist/models/oauth-device-code.js +158 -0
  454. package/dist/models/oauth-device-code.js.map +1 -0
  455. package/dist/models/oauth-refresh-token.d.ts +31 -0
  456. package/dist/models/oauth-refresh-token.js +118 -0
  457. package/dist/models/oauth-refresh-token.js.map +1 -0
  458. package/dist/models/page-yjs-update.d.ts +35 -0
  459. package/dist/models/page-yjs-update.js +33 -0
  460. package/dist/models/page-yjs-update.js.map +1 -0
  461. package/dist/models/page.d.ts +200 -0
  462. package/dist/models/page.js +1117 -0
  463. package/dist/models/page.js.map +1 -0
  464. package/dist/models/personal-access-token.d.ts +30 -0
  465. package/dist/models/personal-access-token.js +107 -0
  466. package/dist/models/personal-access-token.js.map +1 -0
  467. package/dist/models/plugin-render-cache.d.ts +40 -0
  468. package/dist/models/plugin-render-cache.js +39 -0
  469. package/dist/models/plugin-render-cache.js.map +1 -0
  470. package/dist/models/revision.d.ts +145 -0
  471. package/dist/models/revision.js +241 -0
  472. package/dist/models/revision.js.map +1 -0
  473. package/dist/models/share.d.ts +38 -0
  474. package/dist/models/share.js +137 -0
  475. package/dist/models/share.js.map +1 -0
  476. package/dist/models/shareAccess.d.ts +20 -0
  477. package/dist/models/shareAccess.js +45 -0
  478. package/dist/models/shareAccess.js.map +1 -0
  479. package/dist/models/tracking.d.ts +14 -0
  480. package/dist/models/tracking.js +14 -0
  481. package/dist/models/tracking.js.map +1 -0
  482. package/dist/models/updatePost.d.ts +25 -0
  483. package/dist/models/updatePost.js +87 -0
  484. package/dist/models/updatePost.js.map +1 -0
  485. package/dist/models/user.d.ts +144 -0
  486. package/dist/models/user.js +681 -0
  487. package/dist/models/user.js.map +1 -0
  488. package/dist/models/watcher.d.ts +23 -0
  489. package/dist/models/watcher.js +75 -0
  490. package/dist/models/watcher.js.map +1 -0
  491. package/dist/notifications/attach.d.ts +63 -0
  492. package/dist/notifications/attach.js +426 -0
  493. package/dist/notifications/attach.js.map +1 -0
  494. package/dist/notifications/channel.d.ts +13 -0
  495. package/dist/notifications/channel.js +18 -0
  496. package/dist/notifications/channel.js.map +1 -0
  497. package/dist/plugin/index.d.ts +2 -0
  498. package/dist/plugin/index.js +6 -0
  499. package/dist/plugin/index.js.map +1 -0
  500. package/dist/plugin/plugin-context.d.ts +22 -0
  501. package/dist/plugin/plugin-context.js +126 -0
  502. package/dist/plugin/plugin-context.js.map +1 -0
  503. package/dist/plugin/plugin-manager.d.ts +164 -0
  504. package/dist/plugin/plugin-manager.js +328 -0
  505. package/dist/plugin/plugin-manager.js.map +1 -0
  506. package/dist/plugin/plugin-namespace.d.ts +28 -0
  507. package/dist/plugin/plugin-namespace.js +53 -0
  508. package/dist/plugin/plugin-namespace.js.map +1 -0
  509. package/dist/plugin/registries.d.ts +38 -0
  510. package/dist/plugin/registries.js +71 -0
  511. package/dist/plugin/registries.js.map +1 -0
  512. package/dist/plugin/schema-serializer.d.ts +34 -0
  513. package/dist/plugin/schema-serializer.js +122 -0
  514. package/dist/plugin/schema-serializer.js.map +1 -0
  515. package/dist/plugin/topo-sort.d.ts +15 -0
  516. package/dist/plugin/topo-sort.js +59 -0
  517. package/dist/plugin/topo-sort.js.map +1 -0
  518. package/dist/presence/attach.d.ts +36 -0
  519. package/dist/presence/attach.js +399 -0
  520. package/dist/presence/attach.js.map +1 -0
  521. package/dist/renderer/__fixtures__/echo-embed.d.ts +27 -0
  522. package/dist/renderer/__fixtures__/echo-embed.js +24 -0
  523. package/dist/renderer/__fixtures__/echo-embed.js.map +1 -0
  524. package/dist/renderer/cache/index.d.ts +60 -0
  525. package/dist/renderer/cache/index.js +219 -0
  526. package/dist/renderer/cache/index.js.map +1 -0
  527. package/dist/renderer/cache/mongodb-cache.d.ts +82 -0
  528. package/dist/renderer/cache/mongodb-cache.js +180 -0
  529. package/dist/renderer/cache/mongodb-cache.js.map +1 -0
  530. package/dist/renderer/cache/reservation.d.ts +20 -0
  531. package/dist/renderer/cache/reservation.js +115 -0
  532. package/dist/renderer/cache/reservation.js.map +1 -0
  533. package/dist/renderer/core/_mdast-walk.d.ts +35 -0
  534. package/dist/renderer/core/_mdast-walk.js +45 -0
  535. package/dist/renderer/core/_mdast-walk.js.map +1 -0
  536. package/dist/renderer/core/code-block-dispatch.d.ts +31 -0
  537. package/dist/renderer/core/code-block-dispatch.js +166 -0
  538. package/dist/renderer/core/code-block-dispatch.js.map +1 -0
  539. package/dist/renderer/core/code-blocks.d.ts +12 -0
  540. package/dist/renderer/core/code-blocks.js +32 -0
  541. package/dist/renderer/core/code-blocks.js.map +1 -0
  542. package/dist/renderer/core/embed-tags.d.ts +14 -0
  543. package/dist/renderer/core/embed-tags.js +154 -0
  544. package/dist/renderer/core/embed-tags.js.map +1 -0
  545. package/dist/renderer/core/headings.d.ts +16 -0
  546. package/dist/renderer/core/headings.js +31 -0
  547. package/dist/renderer/core/headings.js.map +1 -0
  548. package/dist/renderer/core/index.d.ts +65 -0
  549. package/dist/renderer/core/index.js +83 -0
  550. package/dist/renderer/core/index.js.map +1 -0
  551. package/dist/renderer/core/mention-resolve.d.ts +39 -0
  552. package/dist/renderer/core/mention-resolve.js +75 -0
  553. package/dist/renderer/core/mention-resolve.js.map +1 -0
  554. package/dist/renderer/core/mentions.d.ts +2 -0
  555. package/dist/renderer/core/mentions.js +83 -0
  556. package/dist/renderer/core/mentions.js.map +1 -0
  557. package/dist/renderer/core/syntax-highlight.d.ts +21 -0
  558. package/dist/renderer/core/syntax-highlight.js +64 -0
  559. package/dist/renderer/core/syntax-highlight.js.map +1 -0
  560. package/dist/renderer/core/url-inline-expand.d.ts +9 -0
  561. package/dist/renderer/core/url-inline-expand.js +157 -0
  562. package/dist/renderer/core/url-inline-expand.js.map +1 -0
  563. package/dist/renderer/core/wikilinks.d.ts +2 -0
  564. package/dist/renderer/core/wikilinks.js +118 -0
  565. package/dist/renderer/core/wikilinks.js.map +1 -0
  566. package/dist/renderer/index.d.ts +67 -0
  567. package/dist/renderer/index.js +99 -0
  568. package/dist/renderer/index.js.map +1 -0
  569. package/dist/renderer/pipeline.d.ts +134 -0
  570. package/dist/renderer/pipeline.js +203 -0
  571. package/dist/renderer/pipeline.js.map +1 -0
  572. package/dist/renderer/registry.d.ts +83 -0
  573. package/dist/renderer/registry.js +130 -0
  574. package/dist/renderer/registry.js.map +1 -0
  575. package/dist/renderer/serialize.d.ts +27 -0
  576. package/dist/renderer/serialize.js +46 -0
  577. package/dist/renderer/serialize.js.map +1 -0
  578. package/dist/renderer/version.d.ts +30 -0
  579. package/dist/renderer/version.js +34 -0
  580. package/dist/renderer/version.js.map +1 -0
  581. package/dist/routes/admin.d.ts +4 -0
  582. package/dist/routes/admin.js +17 -0
  583. package/dist/routes/admin.js.map +1 -0
  584. package/dist/routes/api/admin.d.ts +4 -0
  585. package/dist/routes/api/admin.js +37 -0
  586. package/dist/routes/api/admin.js.map +1 -0
  587. package/dist/routes/api/attachment.d.ts +4 -0
  588. package/dist/routes/api/attachment.js +19 -0
  589. package/dist/routes/api/attachment.js.map +1 -0
  590. package/dist/routes/api/bookmark.d.ts +4 -0
  591. package/dist/routes/api/bookmark.js +15 -0
  592. package/dist/routes/api/bookmark.js.map +1 -0
  593. package/dist/routes/api/comment.d.ts +4 -0
  594. package/dist/routes/api/comment.js +14 -0
  595. package/dist/routes/api/comment.js.map +1 -0
  596. package/dist/routes/api/index.d.ts +4 -0
  597. package/dist/routes/api/index.js +36 -0
  598. package/dist/routes/api/index.js.map +1 -0
  599. package/dist/routes/api/like.d.ts +4 -0
  600. package/dist/routes/api/like.js +13 -0
  601. package/dist/routes/api/like.js.map +1 -0
  602. package/dist/routes/api/notification.d.ts +4 -0
  603. package/dist/routes/api/notification.js +15 -0
  604. package/dist/routes/api/notification.js.map +1 -0
  605. package/dist/routes/api/page.d.ts +4 -0
  606. package/dist/routes/api/page.js +24 -0
  607. package/dist/routes/api/page.js.map +1 -0
  608. package/dist/routes/api/revision.d.ts +4 -0
  609. package/dist/routes/api/revision.js +14 -0
  610. package/dist/routes/api/revision.js.map +1 -0
  611. package/dist/routes/api/share.d.ts +4 -0
  612. package/dist/routes/api/share.js +16 -0
  613. package/dist/routes/api/share.js.map +1 -0
  614. package/dist/routes/api/version.d.ts +4 -0
  615. package/dist/routes/api/version.js +10 -0
  616. package/dist/routes/api/version.js.map +1 -0
  617. package/dist/routes/index.d.ts +4 -0
  618. package/dist/routes/index.js +71 -0
  619. package/dist/routes/index.js.map +1 -0
  620. package/dist/routes/login.d.ts +4 -0
  621. package/dist/routes/login.js +18 -0
  622. package/dist/routes/login.js.map +1 -0
  623. package/dist/routes/me.d.ts +4 -0
  624. package/dist/routes/me.js +24 -0
  625. package/dist/routes/me.js.map +1 -0
  626. package/dist/routes/ts-rest/admin/app.d.ts +4 -0
  627. package/dist/routes/ts-rest/admin/app.js +67 -0
  628. package/dist/routes/ts-rest/admin/app.js.map +1 -0
  629. package/dist/routes/ts-rest/admin/auth.d.ts +4 -0
  630. package/dist/routes/ts-rest/admin/auth.js +95 -0
  631. package/dist/routes/ts-rest/admin/auth.js.map +1 -0
  632. package/dist/routes/ts-rest/admin/index.d.ts +10 -0
  633. package/dist/routes/ts-rest/admin/index.js +35 -0
  634. package/dist/routes/ts-rest/admin/index.js.map +1 -0
  635. package/dist/routes/ts-rest/admin/mail.d.ts +4 -0
  636. package/dist/routes/ts-rest/admin/mail.js +156 -0
  637. package/dist/routes/ts-rest/admin/mail.js.map +1 -0
  638. package/dist/routes/ts-rest/admin/plugins.d.ts +4 -0
  639. package/dist/routes/ts-rest/admin/plugins.js +317 -0
  640. package/dist/routes/ts-rest/admin/plugins.js.map +1 -0
  641. package/dist/routes/ts-rest/admin/search.d.ts +4 -0
  642. package/dist/routes/ts-rest/admin/search.js +67 -0
  643. package/dist/routes/ts-rest/admin/search.js.map +1 -0
  644. package/dist/routes/ts-rest/admin/security.d.ts +4 -0
  645. package/dist/routes/ts-rest/admin/security.js +114 -0
  646. package/dist/routes/ts-rest/admin/security.js.map +1 -0
  647. package/dist/routes/ts-rest/admin/share.d.ts +4 -0
  648. package/dist/routes/ts-rest/admin/share.js +69 -0
  649. package/dist/routes/ts-rest/admin/share.js.map +1 -0
  650. package/dist/routes/ts-rest/admin/storage.d.ts +4 -0
  651. package/dist/routes/ts-rest/admin/storage.js +59 -0
  652. package/dist/routes/ts-rest/admin/storage.js.map +1 -0
  653. package/dist/routes/ts-rest/admin/users.d.ts +4 -0
  654. package/dist/routes/ts-rest/admin/users.js +215 -0
  655. package/dist/routes/ts-rest/admin/users.js.map +1 -0
  656. package/dist/routes/ts-rest/adminCrypto.d.ts +4 -0
  657. package/dist/routes/ts-rest/adminCrypto.js +111 -0
  658. package/dist/routes/ts-rest/adminCrypto.js.map +1 -0
  659. package/dist/routes/ts-rest/app.d.ts +4 -0
  660. package/dist/routes/ts-rest/app.js +23 -0
  661. package/dist/routes/ts-rest/app.js.map +1 -0
  662. package/dist/routes/ts-rest/attachment.d.ts +4 -0
  663. package/dist/routes/ts-rest/attachment.js +830 -0
  664. package/dist/routes/ts-rest/attachment.js.map +1 -0
  665. package/dist/routes/ts-rest/auth.d.ts +4 -0
  666. package/dist/routes/ts-rest/auth.js +70 -0
  667. package/dist/routes/ts-rest/auth.js.map +1 -0
  668. package/dist/routes/ts-rest/autocomplete.d.ts +30 -0
  669. package/dist/routes/ts-rest/autocomplete.js +189 -0
  670. package/dist/routes/ts-rest/autocomplete.js.map +1 -0
  671. package/dist/routes/ts-rest/backlink.d.ts +4 -0
  672. package/dist/routes/ts-rest/backlink.js +106 -0
  673. package/dist/routes/ts-rest/backlink.js.map +1 -0
  674. package/dist/routes/ts-rest/bookmark.d.ts +4 -0
  675. package/dist/routes/ts-rest/bookmark.js +189 -0
  676. package/dist/routes/ts-rest/bookmark.js.map +1 -0
  677. package/dist/routes/ts-rest/comment.d.ts +4 -0
  678. package/dist/routes/ts-rest/comment.js +217 -0
  679. package/dist/routes/ts-rest/comment.js.map +1 -0
  680. package/dist/routes/ts-rest/draft.d.ts +22 -0
  681. package/dist/routes/ts-rest/draft.js +200 -0
  682. package/dist/routes/ts-rest/draft.js.map +1 -0
  683. package/dist/routes/ts-rest/index.d.ts +4 -0
  684. package/dist/routes/ts-rest/index.js +103 -0
  685. package/dist/routes/ts-rest/index.js.map +1 -0
  686. package/dist/routes/ts-rest/installer.d.ts +4 -0
  687. package/dist/routes/ts-rest/installer.js +77 -0
  688. package/dist/routes/ts-rest/installer.js.map +1 -0
  689. package/dist/routes/ts-rest/me.d.ts +4 -0
  690. package/dist/routes/ts-rest/me.js +410 -0
  691. package/dist/routes/ts-rest/me.js.map +1 -0
  692. package/dist/routes/ts-rest/notification.d.ts +4 -0
  693. package/dist/routes/ts-rest/notification.js +241 -0
  694. package/dist/routes/ts-rest/notification.js.map +1 -0
  695. package/dist/routes/ts-rest/page-collab.d.ts +29 -0
  696. package/dist/routes/ts-rest/page-collab.js +90 -0
  697. package/dist/routes/ts-rest/page-collab.js.map +1 -0
  698. package/dist/routes/ts-rest/page-preview.d.ts +26 -0
  699. package/dist/routes/ts-rest/page-preview.js +80 -0
  700. package/dist/routes/ts-rest/page-preview.js.map +1 -0
  701. package/dist/routes/ts-rest/page.d.ts +4 -0
  702. package/dist/routes/ts-rest/page.js +676 -0
  703. package/dist/routes/ts-rest/page.js.map +1 -0
  704. package/dist/routes/ts-rest/presence.d.ts +30 -0
  705. package/dist/routes/ts-rest/presence.js +155 -0
  706. package/dist/routes/ts-rest/presence.js.map +1 -0
  707. package/dist/routes/ts-rest/revision.d.ts +4 -0
  708. package/dist/routes/ts-rest/revision.js +240 -0
  709. package/dist/routes/ts-rest/revision.js.map +1 -0
  710. package/dist/routes/ts-rest/search.d.ts +4 -0
  711. package/dist/routes/ts-rest/search.js +121 -0
  712. package/dist/routes/ts-rest/search.js.map +1 -0
  713. package/dist/routes/ts-rest/tokenAuth.d.ts +4 -0
  714. package/dist/routes/ts-rest/tokenAuth.js +94 -0
  715. package/dist/routes/ts-rest/tokenAuth.js.map +1 -0
  716. package/dist/routes/ts-rest/user.d.ts +4 -0
  717. package/dist/routes/ts-rest/user.js +307 -0
  718. package/dist/routes/ts-rest/user.js.map +1 -0
  719. package/dist/service/config.d.ts +50 -0
  720. package/dist/service/config.js +202 -0
  721. package/dist/service/config.js.map +1 -0
  722. package/dist/service/lru.d.ts +11 -0
  723. package/dist/service/lru.js +47 -0
  724. package/dist/service/lru.js.map +1 -0
  725. package/dist/service/mail.d.ts +107 -0
  726. package/dist/service/mail.js +220 -0
  727. package/dist/service/mail.js.map +1 -0
  728. package/dist/service/notification.d.ts +9 -0
  729. package/dist/service/notification.js +19 -0
  730. package/dist/service/notification.js.map +1 -0
  731. package/dist/service/presence.d.ts +219 -0
  732. package/dist/service/presence.js +602 -0
  733. package/dist/service/presence.js.map +1 -0
  734. package/dist/types/error.d.ts +13 -0
  735. package/dist/types/error.js +13 -0
  736. package/dist/types/error.js.map +1 -0
  737. package/dist/types/express.d.ts +34 -0
  738. package/dist/types/express.js +50 -0
  739. package/dist/types/express.js.map +1 -0
  740. package/dist/types/mongoose-extensions.d.ts +8 -0
  741. package/dist/types/mongoose-extensions.js +24 -0
  742. package/dist/types/mongoose-extensions.js.map +1 -0
  743. package/dist/util/accessTokenParser.d.ts +1 -0
  744. package/dist/util/accessTokenParser.js +34 -0
  745. package/dist/util/accessTokenParser.js.map +1 -0
  746. package/dist/util/activityDefine.d.ts +15 -0
  747. package/dist/util/activityDefine.js +52 -0
  748. package/dist/util/activityDefine.js.map +1 -0
  749. package/dist/util/admin-config.d.ts +57 -0
  750. package/dist/util/admin-config.js +99 -0
  751. package/dist/util/admin-config.js.map +1 -0
  752. package/dist/util/admin-pager.d.ts +24 -0
  753. package/dist/util/admin-pager.js +73 -0
  754. package/dist/util/admin-pager.js.map +1 -0
  755. package/dist/util/apiPaginate.d.ts +11 -0
  756. package/dist/util/apiPaginate.js +33 -0
  757. package/dist/util/apiPaginate.js.map +1 -0
  758. package/dist/util/apiResponse.d.ts +9 -0
  759. package/dist/util/apiResponse.js +23 -0
  760. package/dist/util/apiResponse.js.map +1 -0
  761. package/dist/util/auth.d.ts +11 -0
  762. package/dist/util/auth.js +48 -0
  763. package/dist/util/auth.js.map +1 -0
  764. package/dist/util/auto-watch.d.ts +35 -0
  765. package/dist/util/auto-watch.js +24 -0
  766. package/dist/util/auto-watch.js.map +1 -0
  767. package/dist/util/autocomplete-match.d.ts +44 -0
  768. package/dist/util/autocomplete-match.js +80 -0
  769. package/dist/util/autocomplete-match.js.map +1 -0
  770. package/dist/util/aws-config-migration.d.ts +11 -0
  771. package/dist/util/aws-config-migration.js +68 -0
  772. package/dist/util/aws-config-migration.js.map +1 -0
  773. package/dist/util/boot-reporter.d.ts +130 -0
  774. package/dist/util/boot-reporter.js +242 -0
  775. package/dist/util/boot-reporter.js.map +1 -0
  776. package/dist/util/collab-cap.d.ts +39 -0
  777. package/dist/util/collab-cap.js +90 -0
  778. package/dist/util/collab-cap.js.map +1 -0
  779. package/dist/util/crypto.d.ts +39 -0
  780. package/dist/util/crypto.js +105 -0
  781. package/dist/util/crypto.js.map +1 -0
  782. package/dist/util/dedup-users.d.ts +96 -0
  783. package/dist/util/dedup-users.js +149 -0
  784. package/dist/util/dedup-users.js.map +1 -0
  785. package/dist/util/editor-cap-counter.d.ts +90 -0
  786. package/dist/util/editor-cap-counter.js +175 -0
  787. package/dist/util/editor-cap-counter.js.map +1 -0
  788. package/dist/util/fileUploader.d.ts +55 -0
  789. package/dist/util/fileUploader.js +70 -0
  790. package/dist/util/fileUploader.js.map +1 -0
  791. package/dist/util/formUtil.d.ts +2 -0
  792. package/dist/util/formUtil.js +15 -0
  793. package/dist/util/formUtil.js.map +1 -0
  794. package/dist/util/githubAuth.d.ts +2 -0
  795. package/dist/util/githubAuth.js +82 -0
  796. package/dist/util/githubAuth.js.map +1 -0
  797. package/dist/util/googleAuth.d.ts +2 -0
  798. package/dist/util/googleAuth.js +85 -0
  799. package/dist/util/googleAuth.js.map +1 -0
  800. package/dist/util/jwt.d.ts +50 -0
  801. package/dist/util/jwt.js +127 -0
  802. package/dist/util/jwt.js.map +1 -0
  803. package/dist/util/linkDetector.d.ts +3 -0
  804. package/dist/util/linkDetector.js +91 -0
  805. package/dist/util/linkDetector.js.map +1 -0
  806. package/dist/util/mail-token.d.ts +24 -0
  807. package/dist/util/mail-token.js +117 -0
  808. package/dist/util/mail-token.js.map +1 -0
  809. package/dist/util/mailer.d.ts +7 -0
  810. package/dist/util/mailer.js +98 -0
  811. package/dist/util/mailer.js.map +1 -0
  812. package/dist/util/map-duplicate-key-error.d.ts +26 -0
  813. package/dist/util/map-duplicate-key-error.js +41 -0
  814. package/dist/util/map-duplicate-key-error.js.map +1 -0
  815. package/dist/util/mongoose-paginate.d.ts +10 -0
  816. package/dist/util/mongoose-paginate.js +23 -0
  817. package/dist/util/mongoose-paginate.js.map +1 -0
  818. package/dist/util/notifications-token.d.ts +35 -0
  819. package/dist/util/notifications-token.js +140 -0
  820. package/dist/util/notifications-token.js.map +1 -0
  821. package/dist/util/oauth-client-seed.d.ts +2 -0
  822. package/dist/util/oauth-client-seed.js +48 -0
  823. package/dist/util/oauth-client-seed.js.map +1 -0
  824. package/dist/util/oauth-redirect-uri.d.ts +2 -0
  825. package/dist/util/oauth-redirect-uri.js +55 -0
  826. package/dist/util/oauth-redirect-uri.js.map +1 -0
  827. package/dist/util/page-response.d.ts +113 -0
  828. package/dist/util/page-response.js +154 -0
  829. package/dist/util/page-response.js.map +1 -0
  830. package/dist/util/page-search-index.d.ts +19 -0
  831. package/dist/util/page-search-index.js +91 -0
  832. package/dist/util/page-search-index.js.map +1 -0
  833. package/dist/util/page-status-migration.d.ts +23 -0
  834. package/dist/util/page-status-migration.js +48 -0
  835. package/dist/util/page-status-migration.js.map +1 -0
  836. package/dist/util/path.d.ts +2 -0
  837. package/dist/util/path.js +12 -0
  838. package/dist/util/path.js.map +1 -0
  839. package/dist/util/pkce.d.ts +13 -0
  840. package/dist/util/pkce.js +30 -0
  841. package/dist/util/pkce.js.map +1 -0
  842. package/dist/util/presence-token.d.ts +21 -0
  843. package/dist/util/presence-token.js +120 -0
  844. package/dist/util/presence-token.js.map +1 -0
  845. package/dist/util/rate-limit.d.ts +67 -0
  846. package/dist/util/rate-limit.js +87 -0
  847. package/dist/util/rate-limit.js.map +1 -0
  848. package/dist/util/rebuild-backlink.d.ts +25 -0
  849. package/dist/util/rebuild-backlink.js +7 -0
  850. package/dist/util/rebuild-backlink.js.map +1 -0
  851. package/dist/util/rebuild-renderer.d.ts +31 -0
  852. package/dist/util/rebuild-renderer.js +7 -0
  853. package/dist/util/rebuild-renderer.js.map +1 -0
  854. package/dist/util/redis-opts.d.ts +17 -0
  855. package/dist/util/redis-opts.js +40 -0
  856. package/dist/util/redis-opts.js.map +1 -0
  857. package/dist/util/regex.d.ts +2 -0
  858. package/dist/util/regex.js +8 -0
  859. package/dist/util/regex.js.map +1 -0
  860. package/dist/util/search-rebuild.d.ts +18 -0
  861. package/dist/util/search-rebuild.js +28 -0
  862. package/dist/util/search-rebuild.js.map +1 -0
  863. package/dist/util/ssr.d.ts +3 -0
  864. package/dist/util/ssr.js +9 -0
  865. package/dist/util/ssr.js.map +1 -0
  866. package/dist/util/storage-copy.d.ts +40 -0
  867. package/dist/util/storage-copy.js +123 -0
  868. package/dist/util/storage-copy.js.map +1 -0
  869. package/dist/util/ts-rest-helpers.d.ts +110 -0
  870. package/dist/util/ts-rest-helpers.js +110 -0
  871. package/dist/util/ts-rest-helpers.js.map +1 -0
  872. package/dist/util/url.d.ts +1 -0
  873. package/dist/util/url.js +11 -0
  874. package/dist/util/url.js.map +1 -0
  875. package/dist/util/user-code.d.ts +10 -0
  876. package/dist/util/user-code.js +55 -0
  877. package/dist/util/user-code.js.map +1 -0
  878. package/dist/util/view.d.ts +10 -0
  879. package/dist/util/view.js +99 -0
  880. package/dist/util/view.js.map +1 -0
  881. package/dist/util/watcher-backfill.d.ts +30 -0
  882. package/dist/util/watcher-backfill.js +43 -0
  883. package/dist/util/watcher-backfill.js.map +1 -0
  884. package/dist/util/ws-token.d.ts +24 -0
  885. package/dist/util/ws-token.js +134 -0
  886. package/dist/util/ws-token.js.map +1 -0
  887. package/package.json +106 -0
@@ -0,0 +1,2059 @@
1
+ import type { OpenAPIHono } from '@hono/zod-openapi';
2
+ import type Crowi from '../../crowi';
3
+ import type { CrowiHonoBindings } from '../app';
4
+ export declare const registerPageRoutes: <E extends OpenAPIHono<CrowiHonoBindings>>(app: E, crowi: Crowi) => OpenAPIHono<CrowiHonoBindings, {
5
+ "/pages": {
6
+ $get: {
7
+ input: {
8
+ query: {
9
+ path?: string | undefined;
10
+ page_id?: string | undefined;
11
+ revision_id?: string | undefined;
12
+ };
13
+ };
14
+ output: {
15
+ page: {
16
+ _id: string;
17
+ path: string;
18
+ commentCount: number;
19
+ createdAt: string;
20
+ revision: {
21
+ _id: string;
22
+ path: string;
23
+ body: string;
24
+ format: string;
25
+ createdAt: string;
26
+ author?: {
27
+ _id: string;
28
+ username: string;
29
+ name: string;
30
+ email: string;
31
+ createdAt: string;
32
+ id?: string | undefined;
33
+ image?: string | null | undefined;
34
+ } | null | undefined;
35
+ meta?: {
36
+ toc?: {
37
+ level: number;
38
+ text: string;
39
+ anchorId: string;
40
+ }[] | undefined;
41
+ wikiLinks?: {
42
+ raw: string;
43
+ target: string;
44
+ displayText?: string | undefined;
45
+ }[] | undefined;
46
+ mentions?: {
47
+ username: string;
48
+ }[] | undefined;
49
+ codeBlockLanguages?: string[] | undefined;
50
+ } | undefined;
51
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
52
+ rendererVersion?: string | undefined;
53
+ parentRevisionId?: string | null | undefined;
54
+ type?: "snapshot" | "incremental" | undefined;
55
+ savedBy?: string | {
56
+ _id: string;
57
+ username: string;
58
+ name: string;
59
+ email: string;
60
+ createdAt: string;
61
+ id?: string | undefined;
62
+ image?: string | null | undefined;
63
+ } | null | undefined;
64
+ contributors?: (string | {
65
+ _id: string;
66
+ username: string;
67
+ name: string;
68
+ email: string;
69
+ createdAt: string;
70
+ id?: string | undefined;
71
+ image?: string | null | undefined;
72
+ })[] | undefined;
73
+ message?: string | undefined;
74
+ editVia?: "web" | "oauth" | "pat" | undefined;
75
+ };
76
+ redirectTo?: string | null | undefined;
77
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
78
+ grant?: number | undefined;
79
+ grantedUsers?: string[] | undefined;
80
+ liker?: string[] | undefined;
81
+ extended?: {
82
+ [x: string]: any;
83
+ } | undefined;
84
+ updatedAt?: string | undefined;
85
+ currentRevision?: string | null | undefined;
86
+ yjsCheckpointAt?: string | null | undefined;
87
+ latestRevision?: string | undefined;
88
+ likerCount?: number | undefined;
89
+ seenUsersCount?: number | undefined;
90
+ creator?: {
91
+ _id: string;
92
+ username: string;
93
+ name: string;
94
+ email: string;
95
+ createdAt: string;
96
+ id?: string | undefined;
97
+ image?: string | null | undefined;
98
+ } | null | undefined;
99
+ lastUpdateUser?: {
100
+ _id: string;
101
+ username: string;
102
+ name: string;
103
+ email: string;
104
+ createdAt: string;
105
+ id?: string | undefined;
106
+ image?: string | null | undefined;
107
+ } | null | undefined;
108
+ };
109
+ };
110
+ outputFormat: "json";
111
+ status: 200;
112
+ } | {
113
+ input: {
114
+ query: {
115
+ path?: string | undefined;
116
+ page_id?: string | undefined;
117
+ revision_id?: string | undefined;
118
+ };
119
+ };
120
+ output: {
121
+ error: {
122
+ code: "AUTHENTICATION_REQUIRED";
123
+ message: "Authentication is required";
124
+ redirectTo?: string | undefined;
125
+ };
126
+ };
127
+ outputFormat: "json";
128
+ status: 401;
129
+ } | {
130
+ input: {
131
+ query: {
132
+ path?: string | undefined;
133
+ page_id?: string | undefined;
134
+ revision_id?: string | undefined;
135
+ };
136
+ };
137
+ output: {
138
+ error: {
139
+ code: "PAGE_NOT_GRANTED";
140
+ message: "Page is not granted for the user";
141
+ };
142
+ };
143
+ outputFormat: "json";
144
+ status: 403;
145
+ } | {
146
+ input: {
147
+ query: {
148
+ path?: string | undefined;
149
+ page_id?: string | undefined;
150
+ revision_id?: string | undefined;
151
+ };
152
+ };
153
+ output: {
154
+ error: {
155
+ code: "PAGE_NOT_FOUND";
156
+ message: "Page not found";
157
+ };
158
+ };
159
+ outputFormat: "json";
160
+ status: 404;
161
+ };
162
+ };
163
+ } & {
164
+ "/pages/list": {
165
+ $get: {
166
+ input: {
167
+ query: {
168
+ path?: string | undefined;
169
+ user?: string | undefined;
170
+ limit?: unknown;
171
+ offset?: unknown;
172
+ include_deleted?: unknown;
173
+ sort?: "path" | "createdAt" | "updatedAt" | undefined;
174
+ order?: "asc" | "desc" | undefined;
175
+ };
176
+ };
177
+ output: {
178
+ pages: {
179
+ _id: string;
180
+ path: string;
181
+ commentCount: number;
182
+ createdAt: string;
183
+ revision?: string | {
184
+ _id: string;
185
+ path: string;
186
+ body: string;
187
+ format: string;
188
+ createdAt: string;
189
+ author?: {
190
+ _id: string;
191
+ username: string;
192
+ name: string;
193
+ email: string;
194
+ createdAt: string;
195
+ id?: string | undefined;
196
+ image?: string | null | undefined;
197
+ } | null | undefined;
198
+ meta?: {
199
+ toc?: {
200
+ level: number;
201
+ text: string;
202
+ anchorId: string;
203
+ }[] | undefined;
204
+ wikiLinks?: {
205
+ raw: string;
206
+ target: string;
207
+ displayText?: string | undefined;
208
+ }[] | undefined;
209
+ mentions?: {
210
+ username: string;
211
+ }[] | undefined;
212
+ codeBlockLanguages?: string[] | undefined;
213
+ } | undefined;
214
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
215
+ rendererVersion?: string | undefined;
216
+ parentRevisionId?: string | null | undefined;
217
+ type?: "snapshot" | "incremental" | undefined;
218
+ savedBy?: string | {
219
+ _id: string;
220
+ username: string;
221
+ name: string;
222
+ email: string;
223
+ createdAt: string;
224
+ id?: string | undefined;
225
+ image?: string | null | undefined;
226
+ } | null | undefined;
227
+ contributors?: (string | {
228
+ _id: string;
229
+ username: string;
230
+ name: string;
231
+ email: string;
232
+ createdAt: string;
233
+ id?: string | undefined;
234
+ image?: string | null | undefined;
235
+ })[] | undefined;
236
+ message?: string | undefined;
237
+ editVia?: "web" | "oauth" | "pat" | undefined;
238
+ } | undefined;
239
+ redirectTo?: string | null | undefined;
240
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
241
+ grant?: number | undefined;
242
+ grantedUsers?: string[] | undefined;
243
+ creator?: string | {
244
+ _id: string;
245
+ username: string;
246
+ name: string;
247
+ email: string;
248
+ createdAt: string;
249
+ id?: string | undefined;
250
+ image?: string | null | undefined;
251
+ } | null | undefined;
252
+ lastUpdateUser?: string | {
253
+ _id: string;
254
+ username: string;
255
+ name: string;
256
+ email: string;
257
+ createdAt: string;
258
+ id?: string | undefined;
259
+ image?: string | null | undefined;
260
+ } | null | undefined;
261
+ liker?: string[] | undefined;
262
+ extended?: {
263
+ [x: string]: any;
264
+ } | undefined;
265
+ updatedAt?: string | undefined;
266
+ currentRevision?: string | null | undefined;
267
+ yjsCheckpointAt?: string | null | undefined;
268
+ latestRevision?: string | undefined;
269
+ likerCount?: number | undefined;
270
+ seenUsersCount?: number | undefined;
271
+ }[];
272
+ pager: {
273
+ prev: number | null;
274
+ next: number | null;
275
+ offset: number;
276
+ };
277
+ portalPage?: {
278
+ _id: string;
279
+ path: string;
280
+ commentCount: number;
281
+ createdAt: string;
282
+ revision?: string | {
283
+ _id: string;
284
+ path: string;
285
+ body: string;
286
+ format: string;
287
+ createdAt: string;
288
+ author?: {
289
+ _id: string;
290
+ username: string;
291
+ name: string;
292
+ email: string;
293
+ createdAt: string;
294
+ id?: string | undefined;
295
+ image?: string | null | undefined;
296
+ } | null | undefined;
297
+ meta?: {
298
+ toc?: {
299
+ level: number;
300
+ text: string;
301
+ anchorId: string;
302
+ }[] | undefined;
303
+ wikiLinks?: {
304
+ raw: string;
305
+ target: string;
306
+ displayText?: string | undefined;
307
+ }[] | undefined;
308
+ mentions?: {
309
+ username: string;
310
+ }[] | undefined;
311
+ codeBlockLanguages?: string[] | undefined;
312
+ } | undefined;
313
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
314
+ rendererVersion?: string | undefined;
315
+ parentRevisionId?: string | null | undefined;
316
+ type?: "snapshot" | "incremental" | undefined;
317
+ savedBy?: string | {
318
+ _id: string;
319
+ username: string;
320
+ name: string;
321
+ email: string;
322
+ createdAt: string;
323
+ id?: string | undefined;
324
+ image?: string | null | undefined;
325
+ } | null | undefined;
326
+ contributors?: (string | {
327
+ _id: string;
328
+ username: string;
329
+ name: string;
330
+ email: string;
331
+ createdAt: string;
332
+ id?: string | undefined;
333
+ image?: string | null | undefined;
334
+ })[] | undefined;
335
+ message?: string | undefined;
336
+ editVia?: "web" | "oauth" | "pat" | undefined;
337
+ } | undefined;
338
+ redirectTo?: string | null | undefined;
339
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
340
+ grant?: number | undefined;
341
+ grantedUsers?: string[] | undefined;
342
+ creator?: string | {
343
+ _id: string;
344
+ username: string;
345
+ name: string;
346
+ email: string;
347
+ createdAt: string;
348
+ id?: string | undefined;
349
+ image?: string | null | undefined;
350
+ } | null | undefined;
351
+ lastUpdateUser?: string | {
352
+ _id: string;
353
+ username: string;
354
+ name: string;
355
+ email: string;
356
+ createdAt: string;
357
+ id?: string | undefined;
358
+ image?: string | null | undefined;
359
+ } | null | undefined;
360
+ liker?: string[] | undefined;
361
+ extended?: {
362
+ [x: string]: any;
363
+ } | undefined;
364
+ updatedAt?: string | undefined;
365
+ currentRevision?: string | null | undefined;
366
+ yjsCheckpointAt?: string | null | undefined;
367
+ latestRevision?: string | undefined;
368
+ likerCount?: number | undefined;
369
+ seenUsersCount?: number | undefined;
370
+ } | null | undefined;
371
+ };
372
+ outputFormat: "json";
373
+ status: 200;
374
+ } | {
375
+ input: {
376
+ query: {
377
+ path?: string | undefined;
378
+ user?: string | undefined;
379
+ limit?: unknown;
380
+ offset?: unknown;
381
+ include_deleted?: unknown;
382
+ sort?: "path" | "createdAt" | "updatedAt" | undefined;
383
+ order?: "asc" | "desc" | undefined;
384
+ };
385
+ };
386
+ output: {
387
+ error: {
388
+ code: "AUTHENTICATION_REQUIRED";
389
+ message: "Authentication is required";
390
+ redirectTo?: string | undefined;
391
+ };
392
+ };
393
+ outputFormat: "json";
394
+ status: 401;
395
+ };
396
+ };
397
+ } & {
398
+ "/pages/children": {
399
+ $get: {
400
+ input: {
401
+ query: {
402
+ path: string;
403
+ };
404
+ };
405
+ output: {
406
+ children: {
407
+ segment: string;
408
+ path: string;
409
+ isPage: boolean;
410
+ hasPortal: boolean;
411
+ count: number;
412
+ }[];
413
+ };
414
+ outputFormat: "json";
415
+ status: 200;
416
+ } | {
417
+ input: {
418
+ query: {
419
+ path: string;
420
+ };
421
+ };
422
+ output: {
423
+ error: {
424
+ code: "AUTHENTICATION_REQUIRED";
425
+ message: "Authentication is required";
426
+ redirectTo?: string | undefined;
427
+ };
428
+ };
429
+ outputFormat: "json";
430
+ status: 401;
431
+ };
432
+ };
433
+ } & {
434
+ "/pages": {
435
+ $post: {
436
+ input: {
437
+ json: {
438
+ path: string;
439
+ body: string;
440
+ grant?: number | undefined;
441
+ };
442
+ };
443
+ output: {
444
+ page: {
445
+ _id: string;
446
+ path: string;
447
+ commentCount: number;
448
+ createdAt: string;
449
+ revision?: string | {
450
+ _id: string;
451
+ path: string;
452
+ body: string;
453
+ format: string;
454
+ createdAt: string;
455
+ author?: {
456
+ _id: string;
457
+ username: string;
458
+ name: string;
459
+ email: string;
460
+ createdAt: string;
461
+ id?: string | undefined;
462
+ image?: string | null | undefined;
463
+ } | null | undefined;
464
+ meta?: {
465
+ toc?: {
466
+ level: number;
467
+ text: string;
468
+ anchorId: string;
469
+ }[] | undefined;
470
+ wikiLinks?: {
471
+ raw: string;
472
+ target: string;
473
+ displayText?: string | undefined;
474
+ }[] | undefined;
475
+ mentions?: {
476
+ username: string;
477
+ }[] | undefined;
478
+ codeBlockLanguages?: string[] | undefined;
479
+ } | undefined;
480
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
481
+ rendererVersion?: string | undefined;
482
+ parentRevisionId?: string | null | undefined;
483
+ type?: "snapshot" | "incremental" | undefined;
484
+ savedBy?: string | {
485
+ _id: string;
486
+ username: string;
487
+ name: string;
488
+ email: string;
489
+ createdAt: string;
490
+ id?: string | undefined;
491
+ image?: string | null | undefined;
492
+ } | null | undefined;
493
+ contributors?: (string | {
494
+ _id: string;
495
+ username: string;
496
+ name: string;
497
+ email: string;
498
+ createdAt: string;
499
+ id?: string | undefined;
500
+ image?: string | null | undefined;
501
+ })[] | undefined;
502
+ message?: string | undefined;
503
+ editVia?: "web" | "oauth" | "pat" | undefined;
504
+ } | undefined;
505
+ redirectTo?: string | null | undefined;
506
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
507
+ grant?: number | undefined;
508
+ grantedUsers?: string[] | undefined;
509
+ creator?: string | {
510
+ _id: string;
511
+ username: string;
512
+ name: string;
513
+ email: string;
514
+ createdAt: string;
515
+ id?: string | undefined;
516
+ image?: string | null | undefined;
517
+ } | null | undefined;
518
+ lastUpdateUser?: string | {
519
+ _id: string;
520
+ username: string;
521
+ name: string;
522
+ email: string;
523
+ createdAt: string;
524
+ id?: string | undefined;
525
+ image?: string | null | undefined;
526
+ } | null | undefined;
527
+ liker?: string[] | undefined;
528
+ extended?: {
529
+ [x: string]: any;
530
+ } | undefined;
531
+ updatedAt?: string | undefined;
532
+ currentRevision?: string | null | undefined;
533
+ yjsCheckpointAt?: string | null | undefined;
534
+ latestRevision?: string | undefined;
535
+ likerCount?: number | undefined;
536
+ seenUsersCount?: number | undefined;
537
+ };
538
+ };
539
+ outputFormat: "json";
540
+ status: 200;
541
+ } | {
542
+ input: {
543
+ json: {
544
+ path: string;
545
+ body: string;
546
+ grant?: number | undefined;
547
+ };
548
+ };
549
+ output: {
550
+ error: {
551
+ code: string;
552
+ message: string;
553
+ };
554
+ };
555
+ outputFormat: "json";
556
+ status: 400;
557
+ } | {
558
+ input: {
559
+ json: {
560
+ path: string;
561
+ body: string;
562
+ grant?: number | undefined;
563
+ };
564
+ };
565
+ output: {
566
+ error: {
567
+ code: "AUTHENTICATION_REQUIRED";
568
+ message: "Authentication is required";
569
+ redirectTo?: string | undefined;
570
+ };
571
+ };
572
+ outputFormat: "json";
573
+ status: 401;
574
+ };
575
+ };
576
+ } & {
577
+ "/pages": {
578
+ $put: {
579
+ input: {
580
+ json: {
581
+ page_id: string;
582
+ body: string;
583
+ revision_id?: string | undefined;
584
+ grant?: number | undefined;
585
+ };
586
+ };
587
+ output: {
588
+ page: {
589
+ _id: string;
590
+ path: string;
591
+ commentCount: number;
592
+ createdAt: string;
593
+ revision?: string | {
594
+ _id: string;
595
+ path: string;
596
+ body: string;
597
+ format: string;
598
+ createdAt: string;
599
+ author?: {
600
+ _id: string;
601
+ username: string;
602
+ name: string;
603
+ email: string;
604
+ createdAt: string;
605
+ id?: string | undefined;
606
+ image?: string | null | undefined;
607
+ } | null | undefined;
608
+ meta?: {
609
+ toc?: {
610
+ level: number;
611
+ text: string;
612
+ anchorId: string;
613
+ }[] | undefined;
614
+ wikiLinks?: {
615
+ raw: string;
616
+ target: string;
617
+ displayText?: string | undefined;
618
+ }[] | undefined;
619
+ mentions?: {
620
+ username: string;
621
+ }[] | undefined;
622
+ codeBlockLanguages?: string[] | undefined;
623
+ } | undefined;
624
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
625
+ rendererVersion?: string | undefined;
626
+ parentRevisionId?: string | null | undefined;
627
+ type?: "snapshot" | "incremental" | undefined;
628
+ savedBy?: string | {
629
+ _id: string;
630
+ username: string;
631
+ name: string;
632
+ email: string;
633
+ createdAt: string;
634
+ id?: string | undefined;
635
+ image?: string | null | undefined;
636
+ } | null | undefined;
637
+ contributors?: (string | {
638
+ _id: string;
639
+ username: string;
640
+ name: string;
641
+ email: string;
642
+ createdAt: string;
643
+ id?: string | undefined;
644
+ image?: string | null | undefined;
645
+ })[] | undefined;
646
+ message?: string | undefined;
647
+ editVia?: "web" | "oauth" | "pat" | undefined;
648
+ } | undefined;
649
+ redirectTo?: string | null | undefined;
650
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
651
+ grant?: number | undefined;
652
+ grantedUsers?: string[] | undefined;
653
+ creator?: string | {
654
+ _id: string;
655
+ username: string;
656
+ name: string;
657
+ email: string;
658
+ createdAt: string;
659
+ id?: string | undefined;
660
+ image?: string | null | undefined;
661
+ } | null | undefined;
662
+ lastUpdateUser?: string | {
663
+ _id: string;
664
+ username: string;
665
+ name: string;
666
+ email: string;
667
+ createdAt: string;
668
+ id?: string | undefined;
669
+ image?: string | null | undefined;
670
+ } | null | undefined;
671
+ liker?: string[] | undefined;
672
+ extended?: {
673
+ [x: string]: any;
674
+ } | undefined;
675
+ updatedAt?: string | undefined;
676
+ currentRevision?: string | null | undefined;
677
+ yjsCheckpointAt?: string | null | undefined;
678
+ latestRevision?: string | undefined;
679
+ likerCount?: number | undefined;
680
+ seenUsersCount?: number | undefined;
681
+ };
682
+ };
683
+ outputFormat: "json";
684
+ status: 200;
685
+ } | {
686
+ input: {
687
+ json: {
688
+ page_id: string;
689
+ body: string;
690
+ revision_id?: string | undefined;
691
+ grant?: number | undefined;
692
+ };
693
+ };
694
+ output: {
695
+ error: {
696
+ code: string;
697
+ message: string;
698
+ };
699
+ };
700
+ outputFormat: "json";
701
+ status: 400;
702
+ } | {
703
+ input: {
704
+ json: {
705
+ page_id: string;
706
+ body: string;
707
+ revision_id?: string | undefined;
708
+ grant?: number | undefined;
709
+ };
710
+ };
711
+ output: {
712
+ error: {
713
+ code: "AUTHENTICATION_REQUIRED";
714
+ message: "Authentication is required";
715
+ redirectTo?: string | undefined;
716
+ };
717
+ };
718
+ outputFormat: "json";
719
+ status: 401;
720
+ } | {
721
+ input: {
722
+ json: {
723
+ page_id: string;
724
+ body: string;
725
+ revision_id?: string | undefined;
726
+ grant?: number | undefined;
727
+ };
728
+ };
729
+ output: {
730
+ error: {
731
+ code: "PAGE_NOT_FOUND";
732
+ message: "Page not found";
733
+ };
734
+ };
735
+ outputFormat: "json";
736
+ status: 404;
737
+ } | {
738
+ input: {
739
+ json: {
740
+ page_id: string;
741
+ body: string;
742
+ revision_id?: string | undefined;
743
+ grant?: number | undefined;
744
+ };
745
+ };
746
+ output: {
747
+ error: {
748
+ code: "PAGE_REVISION_ERROR";
749
+ message: string;
750
+ };
751
+ };
752
+ outputFormat: "json";
753
+ status: 409;
754
+ };
755
+ };
756
+ } & {
757
+ "/pages/grant": {
758
+ $put: {
759
+ input: {
760
+ json: {
761
+ page_id: string;
762
+ grant: number;
763
+ };
764
+ };
765
+ output: {
766
+ page: {
767
+ _id: string;
768
+ path: string;
769
+ commentCount: number;
770
+ createdAt: string;
771
+ revision?: string | {
772
+ _id: string;
773
+ path: string;
774
+ body: string;
775
+ format: string;
776
+ createdAt: string;
777
+ author?: {
778
+ _id: string;
779
+ username: string;
780
+ name: string;
781
+ email: string;
782
+ createdAt: string;
783
+ id?: string | undefined;
784
+ image?: string | null | undefined;
785
+ } | null | undefined;
786
+ meta?: {
787
+ toc?: {
788
+ level: number;
789
+ text: string;
790
+ anchorId: string;
791
+ }[] | undefined;
792
+ wikiLinks?: {
793
+ raw: string;
794
+ target: string;
795
+ displayText?: string | undefined;
796
+ }[] | undefined;
797
+ mentions?: {
798
+ username: string;
799
+ }[] | undefined;
800
+ codeBlockLanguages?: string[] | undefined;
801
+ } | undefined;
802
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
803
+ rendererVersion?: string | undefined;
804
+ parentRevisionId?: string | null | undefined;
805
+ type?: "snapshot" | "incremental" | undefined;
806
+ savedBy?: string | {
807
+ _id: string;
808
+ username: string;
809
+ name: string;
810
+ email: string;
811
+ createdAt: string;
812
+ id?: string | undefined;
813
+ image?: string | null | undefined;
814
+ } | null | undefined;
815
+ contributors?: (string | {
816
+ _id: string;
817
+ username: string;
818
+ name: string;
819
+ email: string;
820
+ createdAt: string;
821
+ id?: string | undefined;
822
+ image?: string | null | undefined;
823
+ })[] | undefined;
824
+ message?: string | undefined;
825
+ editVia?: "web" | "oauth" | "pat" | undefined;
826
+ } | undefined;
827
+ redirectTo?: string | null | undefined;
828
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
829
+ grant?: number | undefined;
830
+ grantedUsers?: string[] | undefined;
831
+ creator?: string | {
832
+ _id: string;
833
+ username: string;
834
+ name: string;
835
+ email: string;
836
+ createdAt: string;
837
+ id?: string | undefined;
838
+ image?: string | null | undefined;
839
+ } | null | undefined;
840
+ lastUpdateUser?: string | {
841
+ _id: string;
842
+ username: string;
843
+ name: string;
844
+ email: string;
845
+ createdAt: string;
846
+ id?: string | undefined;
847
+ image?: string | null | undefined;
848
+ } | null | undefined;
849
+ liker?: string[] | undefined;
850
+ extended?: {
851
+ [x: string]: any;
852
+ } | undefined;
853
+ updatedAt?: string | undefined;
854
+ currentRevision?: string | null | undefined;
855
+ yjsCheckpointAt?: string | null | undefined;
856
+ latestRevision?: string | undefined;
857
+ likerCount?: number | undefined;
858
+ seenUsersCount?: number | undefined;
859
+ };
860
+ };
861
+ outputFormat: "json";
862
+ status: 200;
863
+ } | {
864
+ input: {
865
+ json: {
866
+ page_id: string;
867
+ grant: number;
868
+ };
869
+ };
870
+ output: {
871
+ error: {
872
+ code: string;
873
+ message: string;
874
+ };
875
+ };
876
+ outputFormat: "json";
877
+ status: 400;
878
+ } | {
879
+ input: {
880
+ json: {
881
+ page_id: string;
882
+ grant: number;
883
+ };
884
+ };
885
+ output: {
886
+ error: {
887
+ code: "AUTHENTICATION_REQUIRED";
888
+ message: "Authentication is required";
889
+ redirectTo?: string | undefined;
890
+ };
891
+ };
892
+ outputFormat: "json";
893
+ status: 401;
894
+ } | {
895
+ input: {
896
+ json: {
897
+ page_id: string;
898
+ grant: number;
899
+ };
900
+ };
901
+ output: {
902
+ error: {
903
+ code: "PAGE_NOT_FOUND";
904
+ message: "Page not found";
905
+ };
906
+ };
907
+ outputFormat: "json";
908
+ status: 404;
909
+ };
910
+ };
911
+ } & {
912
+ "/pages/seen": {
913
+ $post: {
914
+ input: {
915
+ json: {
916
+ page_id: string;
917
+ };
918
+ };
919
+ output: {
920
+ seenUsers: {
921
+ _id: string;
922
+ username: string;
923
+ name: string;
924
+ email: string;
925
+ createdAt: string;
926
+ id?: string | undefined;
927
+ image?: string | null | undefined;
928
+ introduction?: string | undefined;
929
+ admin?: boolean | undefined;
930
+ status?: 1 | 2 | 3 | 4 | 5 | undefined;
931
+ }[];
932
+ seenUsersCount: number;
933
+ };
934
+ outputFormat: "json";
935
+ status: 200;
936
+ } | {
937
+ input: {
938
+ json: {
939
+ page_id: string;
940
+ };
941
+ };
942
+ output: {
943
+ error: {
944
+ code: "INVALID_PAGE_ID";
945
+ message: string;
946
+ };
947
+ };
948
+ outputFormat: "json";
949
+ status: 400;
950
+ } | {
951
+ input: {
952
+ json: {
953
+ page_id: string;
954
+ };
955
+ };
956
+ output: {
957
+ error: {
958
+ code: "AUTHENTICATION_REQUIRED";
959
+ message: "Authentication is required";
960
+ redirectTo?: string | undefined;
961
+ };
962
+ };
963
+ outputFormat: "json";
964
+ status: 401;
965
+ } | {
966
+ input: {
967
+ json: {
968
+ page_id: string;
969
+ };
970
+ };
971
+ output: {
972
+ error: {
973
+ code: "PAGE_NOT_FOUND";
974
+ message: "Page not found";
975
+ };
976
+ };
977
+ outputFormat: "json";
978
+ status: 404;
979
+ };
980
+ };
981
+ } & {
982
+ "/pages/seen-users": {
983
+ $get: {
984
+ input: {
985
+ query: {
986
+ page_id: string;
987
+ limit?: unknown;
988
+ };
989
+ };
990
+ output: {
991
+ seenUsers: {
992
+ _id: string;
993
+ username: string;
994
+ name: string;
995
+ email: string;
996
+ createdAt: string;
997
+ id?: string | undefined;
998
+ image?: string | null | undefined;
999
+ introduction?: string | undefined;
1000
+ admin?: boolean | undefined;
1001
+ status?: 1 | 2 | 3 | 4 | 5 | undefined;
1002
+ }[];
1003
+ seenUsersCount: number;
1004
+ };
1005
+ outputFormat: "json";
1006
+ status: 200;
1007
+ } | {
1008
+ input: {
1009
+ query: {
1010
+ page_id: string;
1011
+ limit?: unknown;
1012
+ };
1013
+ };
1014
+ output: {
1015
+ error: {
1016
+ code: "INVALID_PAGE_ID";
1017
+ message: string;
1018
+ };
1019
+ };
1020
+ outputFormat: "json";
1021
+ status: 400;
1022
+ } | {
1023
+ input: {
1024
+ query: {
1025
+ page_id: string;
1026
+ limit?: unknown;
1027
+ };
1028
+ };
1029
+ output: {
1030
+ error: {
1031
+ code: "AUTHENTICATION_REQUIRED";
1032
+ message: "Authentication is required";
1033
+ redirectTo?: string | undefined;
1034
+ };
1035
+ };
1036
+ outputFormat: "json";
1037
+ status: 401;
1038
+ } | {
1039
+ input: {
1040
+ query: {
1041
+ page_id: string;
1042
+ limit?: unknown;
1043
+ };
1044
+ };
1045
+ output: {
1046
+ error: {
1047
+ code: "PAGE_NOT_FOUND";
1048
+ message: "Page not found";
1049
+ };
1050
+ };
1051
+ outputFormat: "json";
1052
+ status: 404;
1053
+ };
1054
+ };
1055
+ } & {
1056
+ "/pages/like": {
1057
+ $post: {
1058
+ input: {
1059
+ json: {
1060
+ page_id: string;
1061
+ };
1062
+ };
1063
+ output: {
1064
+ page: {
1065
+ _id: string;
1066
+ path: string;
1067
+ commentCount: number;
1068
+ createdAt: string;
1069
+ revision?: string | {
1070
+ _id: string;
1071
+ path: string;
1072
+ body: string;
1073
+ format: string;
1074
+ createdAt: string;
1075
+ author?: {
1076
+ _id: string;
1077
+ username: string;
1078
+ name: string;
1079
+ email: string;
1080
+ createdAt: string;
1081
+ id?: string | undefined;
1082
+ image?: string | null | undefined;
1083
+ } | null | undefined;
1084
+ meta?: {
1085
+ toc?: {
1086
+ level: number;
1087
+ text: string;
1088
+ anchorId: string;
1089
+ }[] | undefined;
1090
+ wikiLinks?: {
1091
+ raw: string;
1092
+ target: string;
1093
+ displayText?: string | undefined;
1094
+ }[] | undefined;
1095
+ mentions?: {
1096
+ username: string;
1097
+ }[] | undefined;
1098
+ codeBlockLanguages?: string[] | undefined;
1099
+ } | undefined;
1100
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
1101
+ rendererVersion?: string | undefined;
1102
+ parentRevisionId?: string | null | undefined;
1103
+ type?: "snapshot" | "incremental" | undefined;
1104
+ savedBy?: string | {
1105
+ _id: string;
1106
+ username: string;
1107
+ name: string;
1108
+ email: string;
1109
+ createdAt: string;
1110
+ id?: string | undefined;
1111
+ image?: string | null | undefined;
1112
+ } | null | undefined;
1113
+ contributors?: (string | {
1114
+ _id: string;
1115
+ username: string;
1116
+ name: string;
1117
+ email: string;
1118
+ createdAt: string;
1119
+ id?: string | undefined;
1120
+ image?: string | null | undefined;
1121
+ })[] | undefined;
1122
+ message?: string | undefined;
1123
+ editVia?: "web" | "oauth" | "pat" | undefined;
1124
+ } | undefined;
1125
+ redirectTo?: string | null | undefined;
1126
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
1127
+ grant?: number | undefined;
1128
+ grantedUsers?: string[] | undefined;
1129
+ creator?: string | {
1130
+ _id: string;
1131
+ username: string;
1132
+ name: string;
1133
+ email: string;
1134
+ createdAt: string;
1135
+ id?: string | undefined;
1136
+ image?: string | null | undefined;
1137
+ } | null | undefined;
1138
+ lastUpdateUser?: string | {
1139
+ _id: string;
1140
+ username: string;
1141
+ name: string;
1142
+ email: string;
1143
+ createdAt: string;
1144
+ id?: string | undefined;
1145
+ image?: string | null | undefined;
1146
+ } | null | undefined;
1147
+ liker?: string[] | undefined;
1148
+ extended?: {
1149
+ [x: string]: any;
1150
+ } | undefined;
1151
+ updatedAt?: string | undefined;
1152
+ currentRevision?: string | null | undefined;
1153
+ yjsCheckpointAt?: string | null | undefined;
1154
+ latestRevision?: string | undefined;
1155
+ likerCount?: number | undefined;
1156
+ seenUsersCount?: number | undefined;
1157
+ };
1158
+ };
1159
+ outputFormat: "json";
1160
+ status: 200;
1161
+ } | {
1162
+ input: {
1163
+ json: {
1164
+ page_id: string;
1165
+ };
1166
+ };
1167
+ output: {
1168
+ error: {
1169
+ code: "INVALID_PAGE_ID";
1170
+ message: string;
1171
+ };
1172
+ };
1173
+ outputFormat: "json";
1174
+ status: 400;
1175
+ } | {
1176
+ input: {
1177
+ json: {
1178
+ page_id: string;
1179
+ };
1180
+ };
1181
+ output: {
1182
+ error: {
1183
+ code: "AUTHENTICATION_REQUIRED";
1184
+ message: "Authentication is required";
1185
+ redirectTo?: string | undefined;
1186
+ };
1187
+ };
1188
+ outputFormat: "json";
1189
+ status: 401;
1190
+ } | {
1191
+ input: {
1192
+ json: {
1193
+ page_id: string;
1194
+ };
1195
+ };
1196
+ output: {
1197
+ error: {
1198
+ code: "PAGE_NOT_FOUND";
1199
+ message: "Page not found";
1200
+ };
1201
+ };
1202
+ outputFormat: "json";
1203
+ status: 404;
1204
+ };
1205
+ };
1206
+ } & {
1207
+ "/pages/unlike": {
1208
+ $post: {
1209
+ input: {
1210
+ json: {
1211
+ page_id: string;
1212
+ };
1213
+ };
1214
+ output: {
1215
+ page: {
1216
+ _id: string;
1217
+ path: string;
1218
+ commentCount: number;
1219
+ createdAt: string;
1220
+ revision?: string | {
1221
+ _id: string;
1222
+ path: string;
1223
+ body: string;
1224
+ format: string;
1225
+ createdAt: string;
1226
+ author?: {
1227
+ _id: string;
1228
+ username: string;
1229
+ name: string;
1230
+ email: string;
1231
+ createdAt: string;
1232
+ id?: string | undefined;
1233
+ image?: string | null | undefined;
1234
+ } | null | undefined;
1235
+ meta?: {
1236
+ toc?: {
1237
+ level: number;
1238
+ text: string;
1239
+ anchorId: string;
1240
+ }[] | undefined;
1241
+ wikiLinks?: {
1242
+ raw: string;
1243
+ target: string;
1244
+ displayText?: string | undefined;
1245
+ }[] | undefined;
1246
+ mentions?: {
1247
+ username: string;
1248
+ }[] | undefined;
1249
+ codeBlockLanguages?: string[] | undefined;
1250
+ } | undefined;
1251
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
1252
+ rendererVersion?: string | undefined;
1253
+ parentRevisionId?: string | null | undefined;
1254
+ type?: "snapshot" | "incremental" | undefined;
1255
+ savedBy?: string | {
1256
+ _id: string;
1257
+ username: string;
1258
+ name: string;
1259
+ email: string;
1260
+ createdAt: string;
1261
+ id?: string | undefined;
1262
+ image?: string | null | undefined;
1263
+ } | null | undefined;
1264
+ contributors?: (string | {
1265
+ _id: string;
1266
+ username: string;
1267
+ name: string;
1268
+ email: string;
1269
+ createdAt: string;
1270
+ id?: string | undefined;
1271
+ image?: string | null | undefined;
1272
+ })[] | undefined;
1273
+ message?: string | undefined;
1274
+ editVia?: "web" | "oauth" | "pat" | undefined;
1275
+ } | undefined;
1276
+ redirectTo?: string | null | undefined;
1277
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
1278
+ grant?: number | undefined;
1279
+ grantedUsers?: string[] | undefined;
1280
+ creator?: string | {
1281
+ _id: string;
1282
+ username: string;
1283
+ name: string;
1284
+ email: string;
1285
+ createdAt: string;
1286
+ id?: string | undefined;
1287
+ image?: string | null | undefined;
1288
+ } | null | undefined;
1289
+ lastUpdateUser?: string | {
1290
+ _id: string;
1291
+ username: string;
1292
+ name: string;
1293
+ email: string;
1294
+ createdAt: string;
1295
+ id?: string | undefined;
1296
+ image?: string | null | undefined;
1297
+ } | null | undefined;
1298
+ liker?: string[] | undefined;
1299
+ extended?: {
1300
+ [x: string]: any;
1301
+ } | undefined;
1302
+ updatedAt?: string | undefined;
1303
+ currentRevision?: string | null | undefined;
1304
+ yjsCheckpointAt?: string | null | undefined;
1305
+ latestRevision?: string | undefined;
1306
+ likerCount?: number | undefined;
1307
+ seenUsersCount?: number | undefined;
1308
+ };
1309
+ };
1310
+ outputFormat: "json";
1311
+ status: 200;
1312
+ } | {
1313
+ input: {
1314
+ json: {
1315
+ page_id: string;
1316
+ };
1317
+ };
1318
+ output: {
1319
+ error: {
1320
+ code: "INVALID_PAGE_ID";
1321
+ message: string;
1322
+ };
1323
+ };
1324
+ outputFormat: "json";
1325
+ status: 400;
1326
+ } | {
1327
+ input: {
1328
+ json: {
1329
+ page_id: string;
1330
+ };
1331
+ };
1332
+ output: {
1333
+ error: {
1334
+ code: "AUTHENTICATION_REQUIRED";
1335
+ message: "Authentication is required";
1336
+ redirectTo?: string | undefined;
1337
+ };
1338
+ };
1339
+ outputFormat: "json";
1340
+ status: 401;
1341
+ } | {
1342
+ input: {
1343
+ json: {
1344
+ page_id: string;
1345
+ };
1346
+ };
1347
+ output: {
1348
+ error: {
1349
+ code: "PAGE_NOT_FOUND";
1350
+ message: "Page not found";
1351
+ };
1352
+ };
1353
+ outputFormat: "json";
1354
+ status: 404;
1355
+ };
1356
+ };
1357
+ } & {
1358
+ "/pages/watch": {
1359
+ $get: {
1360
+ input: {
1361
+ query: {
1362
+ page_id: string;
1363
+ };
1364
+ };
1365
+ output: {
1366
+ watching: boolean;
1367
+ };
1368
+ outputFormat: "json";
1369
+ status: 200;
1370
+ } | {
1371
+ input: {
1372
+ query: {
1373
+ page_id: string;
1374
+ };
1375
+ };
1376
+ output: {
1377
+ error: {
1378
+ code: "INVALID_PAGE_ID";
1379
+ message: string;
1380
+ };
1381
+ };
1382
+ outputFormat: "json";
1383
+ status: 400;
1384
+ } | {
1385
+ input: {
1386
+ query: {
1387
+ page_id: string;
1388
+ };
1389
+ };
1390
+ output: {
1391
+ error: {
1392
+ code: "AUTHENTICATION_REQUIRED";
1393
+ message: "Authentication is required";
1394
+ redirectTo?: string | undefined;
1395
+ };
1396
+ };
1397
+ outputFormat: "json";
1398
+ status: 401;
1399
+ } | {
1400
+ input: {
1401
+ query: {
1402
+ page_id: string;
1403
+ };
1404
+ };
1405
+ output: {
1406
+ error: {
1407
+ code: "PAGE_NOT_FOUND";
1408
+ message: "Page not found";
1409
+ };
1410
+ };
1411
+ outputFormat: "json";
1412
+ status: 404;
1413
+ };
1414
+ };
1415
+ } & {
1416
+ "/pages/watch": {
1417
+ $put: {
1418
+ input: {
1419
+ json: {
1420
+ page_id: string;
1421
+ watching: boolean;
1422
+ };
1423
+ };
1424
+ output: {
1425
+ watching: boolean;
1426
+ };
1427
+ outputFormat: "json";
1428
+ status: 200;
1429
+ } | {
1430
+ input: {
1431
+ json: {
1432
+ page_id: string;
1433
+ watching: boolean;
1434
+ };
1435
+ };
1436
+ output: {
1437
+ error: {
1438
+ code: "INVALID_PAGE_ID";
1439
+ message: string;
1440
+ };
1441
+ };
1442
+ outputFormat: "json";
1443
+ status: 400;
1444
+ } | {
1445
+ input: {
1446
+ json: {
1447
+ page_id: string;
1448
+ watching: boolean;
1449
+ };
1450
+ };
1451
+ output: {
1452
+ error: {
1453
+ code: "AUTHENTICATION_REQUIRED";
1454
+ message: "Authentication is required";
1455
+ redirectTo?: string | undefined;
1456
+ };
1457
+ };
1458
+ outputFormat: "json";
1459
+ status: 401;
1460
+ } | {
1461
+ input: {
1462
+ json: {
1463
+ page_id: string;
1464
+ watching: boolean;
1465
+ };
1466
+ };
1467
+ output: {
1468
+ error: {
1469
+ code: "PAGE_NOT_FOUND";
1470
+ message: "Page not found";
1471
+ };
1472
+ };
1473
+ outputFormat: "json";
1474
+ status: 404;
1475
+ };
1476
+ };
1477
+ } & {
1478
+ "/pages": {
1479
+ $delete: {
1480
+ input: {
1481
+ json: {
1482
+ page_id: string;
1483
+ revision_id?: string | undefined;
1484
+ completely?: boolean | undefined;
1485
+ };
1486
+ };
1487
+ output: {
1488
+ page: {
1489
+ _id: string;
1490
+ path: string;
1491
+ commentCount: number;
1492
+ createdAt: string;
1493
+ revision?: string | {
1494
+ _id: string;
1495
+ path: string;
1496
+ body: string;
1497
+ format: string;
1498
+ createdAt: string;
1499
+ author?: {
1500
+ _id: string;
1501
+ username: string;
1502
+ name: string;
1503
+ email: string;
1504
+ createdAt: string;
1505
+ id?: string | undefined;
1506
+ image?: string | null | undefined;
1507
+ } | null | undefined;
1508
+ meta?: {
1509
+ toc?: {
1510
+ level: number;
1511
+ text: string;
1512
+ anchorId: string;
1513
+ }[] | undefined;
1514
+ wikiLinks?: {
1515
+ raw: string;
1516
+ target: string;
1517
+ displayText?: string | undefined;
1518
+ }[] | undefined;
1519
+ mentions?: {
1520
+ username: string;
1521
+ }[] | undefined;
1522
+ codeBlockLanguages?: string[] | undefined;
1523
+ } | undefined;
1524
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
1525
+ rendererVersion?: string | undefined;
1526
+ parentRevisionId?: string | null | undefined;
1527
+ type?: "snapshot" | "incremental" | undefined;
1528
+ savedBy?: string | {
1529
+ _id: string;
1530
+ username: string;
1531
+ name: string;
1532
+ email: string;
1533
+ createdAt: string;
1534
+ id?: string | undefined;
1535
+ image?: string | null | undefined;
1536
+ } | null | undefined;
1537
+ contributors?: (string | {
1538
+ _id: string;
1539
+ username: string;
1540
+ name: string;
1541
+ email: string;
1542
+ createdAt: string;
1543
+ id?: string | undefined;
1544
+ image?: string | null | undefined;
1545
+ })[] | undefined;
1546
+ message?: string | undefined;
1547
+ editVia?: "web" | "oauth" | "pat" | undefined;
1548
+ } | undefined;
1549
+ redirectTo?: string | null | undefined;
1550
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
1551
+ grant?: number | undefined;
1552
+ grantedUsers?: string[] | undefined;
1553
+ creator?: string | {
1554
+ _id: string;
1555
+ username: string;
1556
+ name: string;
1557
+ email: string;
1558
+ createdAt: string;
1559
+ id?: string | undefined;
1560
+ image?: string | null | undefined;
1561
+ } | null | undefined;
1562
+ lastUpdateUser?: string | {
1563
+ _id: string;
1564
+ username: string;
1565
+ name: string;
1566
+ email: string;
1567
+ createdAt: string;
1568
+ id?: string | undefined;
1569
+ image?: string | null | undefined;
1570
+ } | null | undefined;
1571
+ liker?: string[] | undefined;
1572
+ extended?: {
1573
+ [x: string]: any;
1574
+ } | undefined;
1575
+ updatedAt?: string | undefined;
1576
+ currentRevision?: string | null | undefined;
1577
+ yjsCheckpointAt?: string | null | undefined;
1578
+ latestRevision?: string | undefined;
1579
+ likerCount?: number | undefined;
1580
+ seenUsersCount?: number | undefined;
1581
+ };
1582
+ };
1583
+ outputFormat: "json";
1584
+ status: 200;
1585
+ } | {
1586
+ input: {
1587
+ json: {
1588
+ page_id: string;
1589
+ revision_id?: string | undefined;
1590
+ completely?: boolean | undefined;
1591
+ };
1592
+ };
1593
+ output: {
1594
+ error: {
1595
+ code: string;
1596
+ message: string;
1597
+ };
1598
+ };
1599
+ outputFormat: "json";
1600
+ status: 400;
1601
+ } | {
1602
+ input: {
1603
+ json: {
1604
+ page_id: string;
1605
+ revision_id?: string | undefined;
1606
+ completely?: boolean | undefined;
1607
+ };
1608
+ };
1609
+ output: {
1610
+ error: {
1611
+ code: "AUTHENTICATION_REQUIRED";
1612
+ message: "Authentication is required";
1613
+ redirectTo?: string | undefined;
1614
+ };
1615
+ };
1616
+ outputFormat: "json";
1617
+ status: 401;
1618
+ } | {
1619
+ input: {
1620
+ json: {
1621
+ page_id: string;
1622
+ revision_id?: string | undefined;
1623
+ completely?: boolean | undefined;
1624
+ };
1625
+ };
1626
+ output: {
1627
+ error: {
1628
+ code: "PAGE_NOT_FOUND";
1629
+ message: "Page not found";
1630
+ };
1631
+ };
1632
+ outputFormat: "json";
1633
+ status: 404;
1634
+ } | {
1635
+ input: {
1636
+ json: {
1637
+ page_id: string;
1638
+ revision_id?: string | undefined;
1639
+ completely?: boolean | undefined;
1640
+ };
1641
+ };
1642
+ output: {
1643
+ error: {
1644
+ code: "PAGE_REVISION_ERROR";
1645
+ message: string;
1646
+ };
1647
+ };
1648
+ outputFormat: "json";
1649
+ status: 409;
1650
+ };
1651
+ };
1652
+ } & {
1653
+ "/pages/revert": {
1654
+ $post: {
1655
+ input: {
1656
+ json: {
1657
+ page_id: string;
1658
+ };
1659
+ };
1660
+ output: {
1661
+ page: {
1662
+ _id: string;
1663
+ path: string;
1664
+ commentCount: number;
1665
+ createdAt: string;
1666
+ revision?: string | {
1667
+ _id: string;
1668
+ path: string;
1669
+ body: string;
1670
+ format: string;
1671
+ createdAt: string;
1672
+ author?: {
1673
+ _id: string;
1674
+ username: string;
1675
+ name: string;
1676
+ email: string;
1677
+ createdAt: string;
1678
+ id?: string | undefined;
1679
+ image?: string | null | undefined;
1680
+ } | null | undefined;
1681
+ meta?: {
1682
+ toc?: {
1683
+ level: number;
1684
+ text: string;
1685
+ anchorId: string;
1686
+ }[] | undefined;
1687
+ wikiLinks?: {
1688
+ raw: string;
1689
+ target: string;
1690
+ displayText?: string | undefined;
1691
+ }[] | undefined;
1692
+ mentions?: {
1693
+ username: string;
1694
+ }[] | undefined;
1695
+ codeBlockLanguages?: string[] | undefined;
1696
+ } | undefined;
1697
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
1698
+ rendererVersion?: string | undefined;
1699
+ parentRevisionId?: string | null | undefined;
1700
+ type?: "snapshot" | "incremental" | undefined;
1701
+ savedBy?: string | {
1702
+ _id: string;
1703
+ username: string;
1704
+ name: string;
1705
+ email: string;
1706
+ createdAt: string;
1707
+ id?: string | undefined;
1708
+ image?: string | null | undefined;
1709
+ } | null | undefined;
1710
+ contributors?: (string | {
1711
+ _id: string;
1712
+ username: string;
1713
+ name: string;
1714
+ email: string;
1715
+ createdAt: string;
1716
+ id?: string | undefined;
1717
+ image?: string | null | undefined;
1718
+ })[] | undefined;
1719
+ message?: string | undefined;
1720
+ editVia?: "web" | "oauth" | "pat" | undefined;
1721
+ } | undefined;
1722
+ redirectTo?: string | null | undefined;
1723
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
1724
+ grant?: number | undefined;
1725
+ grantedUsers?: string[] | undefined;
1726
+ creator?: string | {
1727
+ _id: string;
1728
+ username: string;
1729
+ name: string;
1730
+ email: string;
1731
+ createdAt: string;
1732
+ id?: string | undefined;
1733
+ image?: string | null | undefined;
1734
+ } | null | undefined;
1735
+ lastUpdateUser?: string | {
1736
+ _id: string;
1737
+ username: string;
1738
+ name: string;
1739
+ email: string;
1740
+ createdAt: string;
1741
+ id?: string | undefined;
1742
+ image?: string | null | undefined;
1743
+ } | null | undefined;
1744
+ liker?: string[] | undefined;
1745
+ extended?: {
1746
+ [x: string]: any;
1747
+ } | undefined;
1748
+ updatedAt?: string | undefined;
1749
+ currentRevision?: string | null | undefined;
1750
+ yjsCheckpointAt?: string | null | undefined;
1751
+ latestRevision?: string | undefined;
1752
+ likerCount?: number | undefined;
1753
+ seenUsersCount?: number | undefined;
1754
+ };
1755
+ };
1756
+ outputFormat: "json";
1757
+ status: 200;
1758
+ } | {
1759
+ input: {
1760
+ json: {
1761
+ page_id: string;
1762
+ };
1763
+ };
1764
+ output: {
1765
+ error: {
1766
+ code: string;
1767
+ message: string;
1768
+ };
1769
+ };
1770
+ outputFormat: "json";
1771
+ status: 400;
1772
+ } | {
1773
+ input: {
1774
+ json: {
1775
+ page_id: string;
1776
+ };
1777
+ };
1778
+ output: {
1779
+ error: {
1780
+ code: "AUTHENTICATION_REQUIRED";
1781
+ message: "Authentication is required";
1782
+ redirectTo?: string | undefined;
1783
+ };
1784
+ };
1785
+ outputFormat: "json";
1786
+ status: 401;
1787
+ } | {
1788
+ input: {
1789
+ json: {
1790
+ page_id: string;
1791
+ };
1792
+ };
1793
+ output: {
1794
+ error: {
1795
+ code: "PAGE_NOT_FOUND";
1796
+ message: "Page not found";
1797
+ };
1798
+ };
1799
+ outputFormat: "json";
1800
+ status: 404;
1801
+ };
1802
+ };
1803
+ } & {
1804
+ "/pages/rename": {
1805
+ $post: {
1806
+ input: {
1807
+ json: {
1808
+ page_id: string;
1809
+ new_path: string;
1810
+ revision_id?: string | undefined;
1811
+ create_redirect?: boolean | undefined;
1812
+ include_descendants?: boolean | undefined;
1813
+ };
1814
+ };
1815
+ output: {
1816
+ page: {
1817
+ _id: string;
1818
+ path: string;
1819
+ commentCount: number;
1820
+ createdAt: string;
1821
+ revision?: string | {
1822
+ _id: string;
1823
+ path: string;
1824
+ body: string;
1825
+ format: string;
1826
+ createdAt: string;
1827
+ author?: {
1828
+ _id: string;
1829
+ username: string;
1830
+ name: string;
1831
+ email: string;
1832
+ createdAt: string;
1833
+ id?: string | undefined;
1834
+ image?: string | null | undefined;
1835
+ } | null | undefined;
1836
+ meta?: {
1837
+ toc?: {
1838
+ level: number;
1839
+ text: string;
1840
+ anchorId: string;
1841
+ }[] | undefined;
1842
+ wikiLinks?: {
1843
+ raw: string;
1844
+ target: string;
1845
+ displayText?: string | undefined;
1846
+ }[] | undefined;
1847
+ mentions?: {
1848
+ username: string;
1849
+ }[] | undefined;
1850
+ codeBlockLanguages?: string[] | undefined;
1851
+ } | undefined;
1852
+ renderedAst?: import("hono/utils/types").JSONValue | undefined;
1853
+ rendererVersion?: string | undefined;
1854
+ parentRevisionId?: string | null | undefined;
1855
+ type?: "snapshot" | "incremental" | undefined;
1856
+ savedBy?: string | {
1857
+ _id: string;
1858
+ username: string;
1859
+ name: string;
1860
+ email: string;
1861
+ createdAt: string;
1862
+ id?: string | undefined;
1863
+ image?: string | null | undefined;
1864
+ } | null | undefined;
1865
+ contributors?: (string | {
1866
+ _id: string;
1867
+ username: string;
1868
+ name: string;
1869
+ email: string;
1870
+ createdAt: string;
1871
+ id?: string | undefined;
1872
+ image?: string | null | undefined;
1873
+ })[] | undefined;
1874
+ message?: string | undefined;
1875
+ editVia?: "web" | "oauth" | "pat" | undefined;
1876
+ } | undefined;
1877
+ redirectTo?: string | null | undefined;
1878
+ status?: "deleted" | "deprecated" | "published" | "wip" | "draft" | null | undefined;
1879
+ grant?: number | undefined;
1880
+ grantedUsers?: string[] | undefined;
1881
+ creator?: string | {
1882
+ _id: string;
1883
+ username: string;
1884
+ name: string;
1885
+ email: string;
1886
+ createdAt: string;
1887
+ id?: string | undefined;
1888
+ image?: string | null | undefined;
1889
+ } | null | undefined;
1890
+ lastUpdateUser?: string | {
1891
+ _id: string;
1892
+ username: string;
1893
+ name: string;
1894
+ email: string;
1895
+ createdAt: string;
1896
+ id?: string | undefined;
1897
+ image?: string | null | undefined;
1898
+ } | null | undefined;
1899
+ liker?: string[] | undefined;
1900
+ extended?: {
1901
+ [x: string]: any;
1902
+ } | undefined;
1903
+ updatedAt?: string | undefined;
1904
+ currentRevision?: string | null | undefined;
1905
+ yjsCheckpointAt?: string | null | undefined;
1906
+ latestRevision?: string | undefined;
1907
+ likerCount?: number | undefined;
1908
+ seenUsersCount?: number | undefined;
1909
+ };
1910
+ renamed_count: number;
1911
+ };
1912
+ outputFormat: "json";
1913
+ status: 200;
1914
+ } | {
1915
+ input: {
1916
+ json: {
1917
+ page_id: string;
1918
+ new_path: string;
1919
+ revision_id?: string | undefined;
1920
+ create_redirect?: boolean | undefined;
1921
+ include_descendants?: boolean | undefined;
1922
+ };
1923
+ };
1924
+ output: {
1925
+ error: {
1926
+ code: string;
1927
+ message: string;
1928
+ };
1929
+ } | {
1930
+ error: {
1931
+ code: "PAGE_RENAME_TREE_FAILED";
1932
+ message: string;
1933
+ conflicts: {
1934
+ path: string;
1935
+ reasons: string[];
1936
+ }[];
1937
+ partial?: boolean | undefined;
1938
+ };
1939
+ };
1940
+ outputFormat: "json";
1941
+ status: 400;
1942
+ } | {
1943
+ input: {
1944
+ json: {
1945
+ page_id: string;
1946
+ new_path: string;
1947
+ revision_id?: string | undefined;
1948
+ create_redirect?: boolean | undefined;
1949
+ include_descendants?: boolean | undefined;
1950
+ };
1951
+ };
1952
+ output: {
1953
+ error: {
1954
+ code: "AUTHENTICATION_REQUIRED";
1955
+ message: "Authentication is required";
1956
+ redirectTo?: string | undefined;
1957
+ };
1958
+ };
1959
+ outputFormat: "json";
1960
+ status: 401;
1961
+ } | {
1962
+ input: {
1963
+ json: {
1964
+ page_id: string;
1965
+ new_path: string;
1966
+ revision_id?: string | undefined;
1967
+ create_redirect?: boolean | undefined;
1968
+ include_descendants?: boolean | undefined;
1969
+ };
1970
+ };
1971
+ output: {
1972
+ error: {
1973
+ code: "PAGE_NOT_FOUND";
1974
+ message: "Page not found";
1975
+ };
1976
+ };
1977
+ outputFormat: "json";
1978
+ status: 404;
1979
+ } | {
1980
+ input: {
1981
+ json: {
1982
+ page_id: string;
1983
+ new_path: string;
1984
+ revision_id?: string | undefined;
1985
+ create_redirect?: boolean | undefined;
1986
+ include_descendants?: boolean | undefined;
1987
+ };
1988
+ };
1989
+ output: {
1990
+ error: {
1991
+ code: "PAGE_REVISION_ERROR";
1992
+ message: string;
1993
+ };
1994
+ };
1995
+ outputFormat: "json";
1996
+ status: 409;
1997
+ };
1998
+ };
1999
+ } & {
2000
+ "/pages/rename-subtree": {
2001
+ $post: {
2002
+ input: {
2003
+ json: {
2004
+ old_path: string;
2005
+ new_path: string;
2006
+ create_redirect?: boolean | undefined;
2007
+ };
2008
+ };
2009
+ output: {
2010
+ renamed_count: number;
2011
+ };
2012
+ outputFormat: "json";
2013
+ status: 200;
2014
+ } | {
2015
+ input: {
2016
+ json: {
2017
+ old_path: string;
2018
+ new_path: string;
2019
+ create_redirect?: boolean | undefined;
2020
+ };
2021
+ };
2022
+ output: {
2023
+ error: {
2024
+ code: string;
2025
+ message: string;
2026
+ };
2027
+ } | {
2028
+ error: {
2029
+ code: "PAGE_RENAME_TREE_FAILED";
2030
+ message: string;
2031
+ conflicts: {
2032
+ path: string;
2033
+ reasons: string[];
2034
+ }[];
2035
+ partial?: boolean | undefined;
2036
+ };
2037
+ };
2038
+ outputFormat: "json";
2039
+ status: 400;
2040
+ } | {
2041
+ input: {
2042
+ json: {
2043
+ old_path: string;
2044
+ new_path: string;
2045
+ create_redirect?: boolean | undefined;
2046
+ };
2047
+ };
2048
+ output: {
2049
+ error: {
2050
+ code: "AUTHENTICATION_REQUIRED";
2051
+ message: "Authentication is required";
2052
+ redirectTo?: string | undefined;
2053
+ };
2054
+ };
2055
+ outputFormat: "json";
2056
+ status: 401;
2057
+ };
2058
+ };
2059
+ }, "/">;