emailengine-app 2.76.0 → 2.77.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 (102) hide show
  1. package/.github/workflows/release.yaml +24 -19
  2. package/.ncurc.js +14 -2
  3. package/.release-please-manifest.json +3 -0
  4. package/CHANGELOG.md +23 -0
  5. package/README.md +1 -1
  6. package/data/google-crawlers.json +1 -1
  7. package/encrypt.js +71 -4
  8. package/lib/address-strategies.js +18 -0
  9. package/lib/api-reference/code-samples.js +194 -0
  10. package/lib/api-reference/format.js +179 -0
  11. package/lib/api-reference/index.js +205 -0
  12. package/lib/api-reference/model.js +336 -0
  13. package/lib/api-reference/schema-tree.js +366 -0
  14. package/lib/api-routes/account-routes.js +117 -37
  15. package/lib/api-routes/behavior-notes.js +54 -0
  16. package/lib/api-routes/blocklist-routes.js +9 -9
  17. package/lib/api-routes/changes-routes.js +6 -4
  18. package/lib/api-routes/chat-routes.js +3 -3
  19. package/lib/api-routes/delivery-test-routes.js +24 -6
  20. package/lib/api-routes/export-routes.js +14 -12
  21. package/lib/api-routes/gateway-routes.js +11 -11
  22. package/lib/api-routes/license-routes.js +7 -7
  23. package/lib/api-routes/mailbox-routes.js +18 -9
  24. package/lib/api-routes/message-routes.js +55 -35
  25. package/lib/api-routes/oauth2-app-routes.js +22 -16
  26. package/lib/api-routes/outbox-routes.js +7 -7
  27. package/lib/api-routes/pubsub-routes.js +3 -3
  28. package/lib/api-routes/settings-routes.js +10 -9
  29. package/lib/api-routes/stats-routes.js +3 -3
  30. package/lib/api-routes/submit-routes.js +58 -8
  31. package/lib/api-routes/template-routes.js +13 -13
  32. package/lib/api-routes/token-routes.js +15 -10
  33. package/lib/api-routes/webhook-route-routes.js +5 -5
  34. package/lib/consts.js +7 -0
  35. package/lib/email-client/base-client.js +66 -12
  36. package/lib/enum-descriptions.js +130 -0
  37. package/lib/imapproxy/imap-server.js +30 -26
  38. package/lib/imapproxy/upstream-client.js +38 -0
  39. package/lib/oauth2-apps.js +9 -3
  40. package/lib/openapi/build-document.js +318 -0
  41. package/lib/openapi/index.js +95 -0
  42. package/lib/openapi/joi-schema.js +523 -0
  43. package/lib/routes-ui.js +5 -1
  44. package/lib/schemas.js +76 -17
  45. package/lib/swagger-options.js +173 -0
  46. package/lib/tokens.js +69 -5
  47. package/lib/ui-routes/admin-entities-routes.js +3 -0
  48. package/lib/ui-routes/dashboard-routes.js +2 -26
  49. package/lib/ui-routes/reference-routes.js +195 -0
  50. package/lib/ui-routes/route-helpers.js +11 -0
  51. package/package.json +9 -11
  52. package/prepare-bundle-deps.sh +28 -0
  53. package/release-please-config.json +11 -0
  54. package/sbom.json +0 -1
  55. package/server.js +10 -2
  56. package/static/css/flyonui.css +1 -1
  57. package/static/css/src/app.tailwind.css +90 -0
  58. package/static/js/ee-client.js +238 -8
  59. package/static/js/reference.js +736 -0
  60. package/static/js/ui.js +61 -33
  61. package/static/licenses.html +4 -4
  62. package/translations/messages.pot +27 -27
  63. package/views/config/ai.hbs +1 -1
  64. package/views/config/document-store/chat.hbs +5 -5
  65. package/views/config/document-store/index.hbs +2 -2
  66. package/views/config/document-store/pre-processing/index.hbs +1 -1
  67. package/views/config/email-processing.hbs +1 -1
  68. package/views/config/imap-proxy.hbs +1 -1
  69. package/views/config/license.hbs +1 -1
  70. package/views/config/oauth/index.hbs +3 -3
  71. package/views/config/security.hbs +1 -1
  72. package/views/config/smtp.hbs +2 -2
  73. package/views/dashboard.hbs +1 -1
  74. package/views/layout/app.hbs +18 -7
  75. package/views/partials/oauth_form.hbs +4 -4
  76. package/views/partials/reference/anchor-link.hbs +20 -0
  77. package/views/partials/reference/disclosure.hbs +37 -0
  78. package/views/partials/reference/nav.hbs +93 -0
  79. package/views/partials/reference/operation.hbs +127 -0
  80. package/views/partials/reference/params.hbs +20 -0
  81. package/views/partials/reference/schema-node.hbs +99 -0
  82. package/views/partials/reference/schema.hbs +19 -0
  83. package/views/partials/reference/section-heading.hbs +16 -0
  84. package/views/partials/reference/token-alert.hbs +24 -0
  85. package/views/partials/reference/try-field.hbs +31 -0
  86. package/views/partials/reference/try-it.hbs +78 -0
  87. package/views/partials/side_menu.hbs +1 -1
  88. package/views/partials/ui/badge.hbs +4 -2
  89. package/views/partials/ui/page-header.hbs +1 -1
  90. package/views/partials/ui/search-input.hbs +31 -0
  91. package/views/partials/ui/setting-ref.hbs +1 -1
  92. package/views/partials/ui/stat-card.hbs +4 -2
  93. package/views/partials/ui/tab.hbs +6 -1
  94. package/views/partials/ui/tabs.hbs +2 -2
  95. package/views/reference/index.hbs +76 -0
  96. package/views/reference/redirect.hbs +49 -0
  97. package/views/reference/tag.hbs +28 -0
  98. package/views/reference/token.hbs +49 -0
  99. package/views/tokens/index.hbs +9 -1
  100. package/views/webhooks/index.hbs +3 -3
  101. package/workers/api.js +37 -215
  102. package/views/swagger/index.hbs +0 -82
package/static/js/ui.js CHANGED
@@ -250,41 +250,34 @@ window.paintCertData = certData => {
250
250
  }
251
251
  };
252
252
 
253
- // Copy-to-clipboard buttons: a .copy-btn with data-copy-target="#selector"
254
- // copies the target's value (inputs), ACE editor content (a mounted
255
- // ui/code-editor div) or text content. Delegated, so buttons inside
256
- // dynamically injected markup work without re-binding. Uses the async
257
- // Clipboard API where available; self-hosted installs served over plain HTTP
258
- // are not a secure context, so those fall back to execCommand on a throwaway
259
- // textarea (a selection on the target itself would not work for password
260
- // inputs or ACE editors, which only render the visible lines).
261
- document.addEventListener('click', e => {
262
- let btn = e.target.closest('.copy-btn');
263
- if (!btn) {
253
+ // Keyboard hints that spell a modifier differently on macOS (ui/search-input
254
+ // renders `shortcut` with an optional `shortcutMac`). The server cannot know
255
+ // the platform, so it emits the Ctrl form and the Mac spelling rides along in
256
+ // data-mac; this swaps it in. Generic on purpose - the next page that binds a
257
+ // hotkey gets the right label without reaching into the partial's markup.
258
+ document.addEventListener('DOMContentLoaded', () => {
259
+ if (!/mac/i.test((navigator.userAgentData && navigator.userAgentData.platform) || navigator.platform || '')) {
264
260
  return;
265
261
  }
266
- // toolbar copy controls are <a href="#"> links
267
- e.preventDefault();
268
-
269
- let value;
270
- if ('copyValue' in btn.dataset) {
271
- // literal value carried on the button itself (e.g. the per-row ids in
272
- // ui/entity-id) - no target element needed
273
- value = btn.dataset.copyValue;
274
- } else {
275
- let target = btn.dataset.copyTarget ? document.querySelector(btn.dataset.copyTarget) : null;
276
- if (!target) {
277
- return;
278
- }
279
262
 
280
- let aceEntry = uiAceInstances.get(target);
281
- if (aceEntry) {
282
- value = aceEntry.editor.getValue();
283
- } else {
284
- value = 'value' in target ? target.value : target.textContent;
285
- }
263
+ for (let elm of document.querySelectorAll('kbd[data-mac]')) {
264
+ elm.textContent = elm.dataset.mac;
286
265
  }
266
+ });
287
267
 
268
+ // Writes a string to the clipboard and confirms it on the button that asked
269
+ // for it (the copy icon flips to a checkmark, a failure raises a toast).
270
+ // Uses the async Clipboard API where available; self-hosted installs served
271
+ // over plain HTTP are not a secure context, so those fall back to execCommand
272
+ // on a throwaway textarea (a selection on the source element itself would not
273
+ // work for password inputs or ACE editors, which only render the visible
274
+ // lines).
275
+ //
276
+ // Exposed rather than kept inside the delegated handler below because not
277
+ // every copyable value can be pointed at: the API reference's copy-as-curl
278
+ // serializes its try-it form at click time, so there is no element holding the
279
+ // text and no data attribute it could have been rendered into.
280
+ window.uiCopyText = (value, btn) => {
288
281
  let copied;
289
282
  if (navigator.clipboard && window.isSecureContext) {
290
283
  copied = navigator.clipboard.writeText(value).then(
@@ -309,16 +302,51 @@ document.addEventListener('click', e => {
309
302
  copied = Promise.resolve(ok);
310
303
  }
311
304
 
312
- copied.then(ok => {
305
+ return copied.then(ok => {
313
306
  if (!ok) {
314
307
  window.showToast('Failed to copy to clipboard', 'alert-triangle');
315
- return;
308
+ return false;
316
309
  }
317
- let icon = btn.querySelector('[class*="icon-"]');
310
+ let icon = btn && btn.querySelector('[class*="icon-"]');
318
311
  if (icon && icon.classList.replace('icon-[tabler--copy]', 'icon-[tabler--check]')) {
319
312
  window.setTimeout(() => icon.classList.replace('icon-[tabler--check]', 'icon-[tabler--copy]'), 1500);
320
313
  }
314
+ return true;
321
315
  });
316
+ };
317
+
318
+ // Copy-to-clipboard buttons: a .copy-btn with data-copy-target="#selector"
319
+ // copies the target's value (inputs), ACE editor content (a mounted
320
+ // ui/code-editor div) or text content. Delegated, so buttons inside
321
+ // dynamically injected markup work without re-binding.
322
+ document.addEventListener('click', e => {
323
+ let btn = e.target.closest('.copy-btn');
324
+ if (!btn) {
325
+ return;
326
+ }
327
+ // toolbar copy controls are <a href="#"> links
328
+ e.preventDefault();
329
+
330
+ let value;
331
+ if ('copyValue' in btn.dataset) {
332
+ // literal value carried on the button itself (e.g. the per-row ids in
333
+ // ui/entity-id) - no target element needed
334
+ value = btn.dataset.copyValue;
335
+ } else {
336
+ let target = btn.dataset.copyTarget ? document.querySelector(btn.dataset.copyTarget) : null;
337
+ if (!target) {
338
+ return;
339
+ }
340
+
341
+ let aceEntry = uiAceInstances.get(target);
342
+ if (aceEntry) {
343
+ value = aceEntry.editor.getValue();
344
+ } else {
345
+ value = 'value' in target ? target.value : target.textContent;
346
+ }
347
+ }
348
+
349
+ window.uiCopyText(value, btn);
322
350
  });
323
351
 
324
352
  // Resource-list row delete: a .list-delete-btn (rendered by ui/row-actions in
@@ -29,7 +29,7 @@ pre { background: var(--bg); border-radius: 0.5rem; padding: 1rem; overflow-x: a
29
29
  </head>
30
30
  <body>
31
31
  <main>
32
- <h1>EmailEngine v2.75.0</h1>
32
+ <h1>EmailEngine v2.76.0</h1>
33
33
  <p class="intro">EmailEngine includes code from the following open source packages. Entries marked <em>asset</em> are build-time packages whose output is embedded in the UI assets, or bundled fonts and scripts.</p>
34
34
  <ul>
35
35
  <li class="package">
@@ -2420,7 +2420,7 @@ SOFTWARE.</pre></details>
2420
2420
  <li class="package">
2421
2421
  <div class="head">
2422
2422
  <span class="name">@postalsys/ee-client</span>
2423
- <span class="version">1.6.0</span>
2423
+ <span class="version">1.7.0</span>
2424
2424
  <span class="badge">MIT</span>
2425
2425
  <span class="badge badge-runtime">runtime</span>
2426
2426
  <span class="links"><a href="https://npmjs.com/package/@postalsys/ee-client" rel="noopener noreferrer">npm</a> <a href="https://github.com/postalsys/ee-client#readme" rel="noopener noreferrer">website</a></span>
@@ -4923,7 +4923,7 @@ THE SOFTWARE.</pre></details>
4923
4923
  <li class="package">
4924
4924
  <div class="head">
4925
4925
  <span class="name">bullmq</span>
4926
- <span class="version">5.81.2</span>
4926
+ <span class="version">5.81.3</span>
4927
4927
  <span class="badge">MIT</span>
4928
4928
  <span class="badge badge-runtime">runtime</span>
4929
4929
  <span class="links"><a href="https://npmjs.com/package/bullmq" rel="noopener noreferrer">npm</a> <a href="https://bullmq.io/" rel="noopener noreferrer">website</a></span>
@@ -8953,7 +8953,7 @@ SOFTWARE.</pre></details>
8953
8953
  <li class="package">
8954
8954
  <div class="head">
8955
8955
  <span class="name">msgpackr</span>
8956
- <span class="version">2.0.4</span>
8956
+ <span class="version">2.0.5</span>
8957
8957
  <span class="badge">MIT</span>
8958
8958
  <span class="badge badge-runtime">runtime</span>
8959
8959
  <span class="links"><a href="https://npmjs.com/package/msgpackr" rel="noopener noreferrer">npm</a> <a href="http://github.com/kriszyp/msgpackr" rel="noopener noreferrer">website</a></span>
@@ -1,7 +1,7 @@
1
1
  msgid ""
2
2
  msgstr ""
3
3
  "Content-Type: text/plain; charset=ascii\n"
4
- "POT-Creation-Date: 2026-07-29 19:18+0000\n"
4
+ "POT-Creation-Date: 2026-07-30 07:33+0000\n"
5
5
 
6
6
  #: views/error.hbs:6
7
7
  #: workers/api.js:3019
@@ -99,12 +99,30 @@ msgstr ""
99
99
  msgid "Email address"
100
100
  msgstr ""
101
101
 
102
- #: views/accounts/register/index.hbs:6
103
- msgid "Choose your email account provider"
102
+ #: views/accounts/register/imap.hbs:13
103
+ msgid "Your name"
104
104
  msgstr ""
105
105
 
106
- #: views/accounts/register/index.hbs:19
107
- msgid "Standard IMAP"
106
+ #: views/accounts/register/imap.hbs:19
107
+ msgid "Enter your full name"
108
+ msgstr ""
109
+
110
+ #: views/accounts/register/imap.hbs:29
111
+ msgid "Enter your email address"
112
+ msgstr ""
113
+
114
+ #: views/accounts/register/imap.hbs:33
115
+ #: views/accounts/register/imap-server.hbs:39
116
+ #: views/accounts/register/imap-server.hbs:146
117
+ msgid "Password"
118
+ msgstr ""
119
+
120
+ #: views/accounts/register/imap.hbs:39
121
+ msgid "Enter your account password"
122
+ msgstr ""
123
+
124
+ #: views/accounts/register/imap.hbs:45
125
+ msgid "Continue"
108
126
  msgstr ""
109
127
 
110
128
  #: views/accounts/register/imap-server.hbs:22
@@ -116,12 +134,6 @@ msgstr ""
116
134
  msgid "Username"
117
135
  msgstr ""
118
136
 
119
- #: views/accounts/register/imap-server.hbs:39
120
- #: views/accounts/register/imap-server.hbs:146
121
- #: views/accounts/register/imap.hbs:33
122
- msgid "Password"
123
- msgstr ""
124
-
125
137
  #: views/accounts/register/imap-server.hbs:51
126
138
  #: views/accounts/register/imap-server.hbs:158
127
139
  msgid "Important"
@@ -226,24 +238,12 @@ msgstr ""
226
238
  msgid "Request failed."
227
239
  msgstr ""
228
240
 
229
- #: views/accounts/register/imap.hbs:13
230
- msgid "Your name"
231
- msgstr ""
232
-
233
- #: views/accounts/register/imap.hbs:19
234
- msgid "Enter your full name"
235
- msgstr ""
236
-
237
- #: views/accounts/register/imap.hbs:29
238
- msgid "Enter your email address"
239
- msgstr ""
240
-
241
- #: views/accounts/register/imap.hbs:39
242
- msgid "Enter your account password"
241
+ #: views/accounts/register/index.hbs:6
242
+ msgid "Choose your email account provider"
243
243
  msgstr ""
244
244
 
245
- #: views/accounts/register/imap.hbs:45
246
- msgid "Continue"
245
+ #: views/accounts/register/index.hbs:19
246
+ msgid "Standard IMAP"
247
247
  msgstr ""
248
248
 
249
249
  #: lib/autodetect-imap-settings.js:90
@@ -117,7 +117,7 @@
117
117
  rel="noopener noreferrer" referrerpolicy="no-referrer"
118
118
  class="link link-animated">documentation</a>]
119
119
 
120
- [<a href="/admin/swagger#/Settings/postV1Settings" target="_blank" rel="noopener noreferrer"
120
+ [<a href="/admin/reference/settings#postV1Settings" target="_blank" rel="noopener noreferrer"
121
121
  referrerpolicy="no-referrer" class="link link-animated">openAiPreProcessingFn</a>]
122
122
  </div>
123
123
  <label class="label-text" for="editor-fn">Filter Function</label>
@@ -33,11 +33,11 @@
33
33
  <span class="helper-text">If enabled, then EmailEngine uses the OpenAI API to produce text embeddings
34
34
  for emails in the document store. For this feature to work, ensure document store syncing is active
35
35
  and that the OpenAI API key is configured. You can run chat requests with the <a
36
- href="/admin/swagger#/Chat/postV1ChatAccount" target="_blank" rel="noopener noreferrer"
36
+ href="/admin/reference/deprecated-endpoints-document-store#postV1ChatAccount" target="_blank" rel="noopener noreferrer"
37
37
  class="link link-animated">Chat API method</a>.</span>
38
38
  <div class="mt-2"><small><strong>Important:</strong> EmailEngine will only create embeddings for emails
39
39
  processed when the feature is active. To generate embeddings for previously stored emails,
40
- utilize the <a href="/admin/swagger#/Account/putV1AccountAccountFlush" target="_blank"
40
+ utilize the <a href="/admin/reference/account#putV1AccountAccountFlush" target="_blank"
41
41
  rel="noopener noreferrer" class="link link-animated">Flush API method</a>. This will force
42
42
  EmailEngine to re-process all emails in the Document Store.</small>
43
43
  </div>
@@ -51,10 +51,10 @@
51
51
  <div class="space-y-1">
52
52
  {{> ui/setting-ref name="documentStoreGenerateEmbeddings" class="whitespace-nowrap"}}
53
53
 
54
- {{> ui/setting-ref name="Chat with emails" href="/admin/swagger#/Chat/postV1ChatAccount"
54
+ {{> ui/setting-ref name="Chat with emails" href="/admin/reference/deprecated-endpoints-document-store#postV1ChatAccount"
55
55
  nofloat=true class="whitespace-nowrap"}}
56
56
 
57
- {{> ui/setting-ref name="Request account flush" href="/admin/swagger#/Account/putV1AccountAccountFlush"
57
+ {{> ui/setting-ref name="Request account flush" href="/admin/reference/account#putV1AccountAccountFlush"
58
58
  nofloat=true class="whitespace-nowrap"}}
59
59
 
60
60
  <div>
@@ -125,7 +125,7 @@
125
125
  <form id="chatPayloadForm" method="post" action=".">
126
126
  <div class="modal-body space-y-4">
127
127
  <div>
128
- {{> ui/setting-ref prefix="API Reference: " name="/v1/chat/{account}" href="/admin/swagger#/Chat/postV1ChatAccount"}}
128
+ {{> ui/setting-ref prefix="API Reference: " name="/v1/chat/{account}" href="/admin/reference/deprecated-endpoints-document-store#postV1ChatAccount"}}
129
129
  {{#> ui/form-field id="inputAccount" label="Account ID"}}
130
130
  <input type="text" class="input" name="account" id="inputAccount" aria-describedby="inputAccountHelp"
131
131
  value="" required>
@@ -39,7 +39,7 @@
39
39
 
40
40
  <div class="mt-2"><small><strong>Important:</strong> EmailEngine only saves emails to the Document
41
41
  Store if processed while the feature is active. To add existing emails, use the <a
42
- href="/admin/swagger#/Account/putV1AccountAccountFlush" target="_blank"
42
+ href="/admin/reference/account#putV1AccountAccountFlush" target="_blank"
43
43
  rel="noopener noreferrer" class="link link-animated">Flush API method</a>. This makes
44
44
  EmailEngine re-process all emails for a specific account.</small>
45
45
  </div>
@@ -49,7 +49,7 @@
49
49
  {{> ui/setting-ref name="documentStoreEnabled" class="whitespace-nowrap"}}
50
50
 
51
51
  <div class="text-base-content/60 code-link whitespace-nowrap">[<a
52
- href="/admin/swagger#/Account/putV1AccountAccountFlush" target="_blank"
52
+ href="/admin/reference/account#putV1AccountAccountFlush" target="_blank"
53
53
  rel="noopener noreferrer" class="link link-animated">Request&nbsp;account&nbsp;flush</a>]</div>
54
54
 
55
55
  {{#if values.documentStoreEnabled}}
@@ -35,7 +35,7 @@
35
35
  rel="noopener noreferrer" referrerpolicy="no-referrer"
36
36
  class="link link-animated">documentation</a>]
37
37
 
38
- [<a href="/admin/swagger#/Settings/postV1Settings" target="_blank" rel="noopener noreferrer"
38
+ [<a href="/admin/reference/settings#postV1Settings" target="_blank" rel="noopener noreferrer"
39
39
  referrerpolicy="no-referrer" class="link link-animated">documentStorePreProcessingFn</a>]
40
40
  </div>
41
41
  <label class="label-text" for="editor-fn">Filter function</label>
@@ -31,7 +31,7 @@
31
31
  </select>
32
32
  <span class="helper-text"><strong>Full:</strong> Track all changes (new, deleted, updated emails).
33
33
  <strong>Fast:</strong> Track only new emails. Applies to new accounts only. To change existing
34
- accounts, perform an <a href="/admin/swagger#/Account/putV1AccountAccountFlush"
34
+ accounts, perform an <a href="/admin/reference/account#putV1AccountAccountFlush"
35
35
  class="link link-animated">account flush</a>.</span>
36
36
  {{/ui/form-field}}
37
37
  </div>
@@ -103,7 +103,7 @@
103
103
 
104
104
  <p class="mb-4">Connect to the proxy using the account ID as your IMAP username.</p>
105
105
 
106
- {{#> ui/tabs label="Client configuration examples" id="code-examples"}}
106
+ {{#> ui/tabs label="Client configuration examples" elId="code-examples"}}
107
107
  {{> ui/tab target="example-node-imap" label="Node.js (node-imap)" active=true}}
108
108
  {{> ui/tab target="example-php-imap" label="PHP (php-imap)"}}
109
109
  {{/ui/tabs}}
@@ -101,7 +101,7 @@ class="mb-1"}}
101
101
  </div>
102
102
 
103
103
  <div class="mb-6">
104
- {{> ui/setting-ref name="license" href="/admin/swagger#/license/postV1License"}}
104
+ {{> ui/setting-ref name="license" href="/admin/reference/license#postV1License"}}
105
105
  {{#> ui/form-field id="licenseTextElement" label="Or paste license key here" error=errors.license}}
106
106
  <textarea class="textarea w-full droptxt autoselect{{#if errors.license}} is-invalid{{/if}}"
107
107
  id="licenseTextElement" name="license" rows="9" data-enable-grammarly="false" spellcheck="false"
@@ -59,12 +59,12 @@
59
59
  {{#if enabled}}
60
60
 
61
61
  {{#if meta.authFlag}}
62
- {{> ui/badge label="Failing" variant="error"}}
62
+ {{> ui/badge label="Failing" variant="error" class="" icon="" soft=""}}
63
63
  {{else}}
64
- {{> ui/badge label="Enabled" variant="success"}}
64
+ {{> ui/badge label="Enabled" variant="success" class="" icon="" soft=""}}
65
65
  {{/if}}
66
66
  {{else}}
67
- {{> ui/badge label="Disabled" variant="warning"}}
67
+ {{> ui/badge label="Disabled" variant="warning" class="" icon="" soft=""}}
68
68
  {{/if}}
69
69
  </td>
70
70
 
@@ -36,7 +36,7 @@
36
36
  {{> ui/checkbox id="enableOAuthTokensApi" name="enableOAuthTokensApi"
37
37
  label="Allow OAuth2 Token Access via API" checked=values.enableOAuthTokensApi
38
38
  error=errors.enableOAuthTokensApi}}
39
- <span class="helper-text">Enable <a href="/admin/swagger#/Account/getV1AccountAccountOauthtoken"
39
+ <span class="helper-text">Enable <a href="/admin/reference/account#getV1AccountAccountOauthtoken"
40
40
  target="_blank" rel="noopener noreferrer" class="link link-animated">API endpoint</a> to
41
41
  retrieve OAuth2 tokens. Set <code>EENGINE_ENABLE_OAUTH_TOKENS_API=true</code> at startup to enable
42
42
  by default.</span>
@@ -3,7 +3,7 @@
3
3
  {{> ui/page-header title="SMTP Server" icon="icon-[tabler--server]" stateLabel=serverState.label stateType="smtp" class="mb-1"}}
4
4
 
5
5
  <p>Send emails through EmailEngine using SMTP protocol. While the <a
6
- href="/admin/swagger#/Submit/postV1AccountAccountSubmit" target="_blank" rel="noopener noreferrer"
6
+ href="/admin/reference/submit#postV1AccountAccountSubmit" target="_blank" rel="noopener noreferrer"
7
7
  referrerpolicy="no-referrer" class="link link-animated">submission API</a> is recommended for modern
8
8
  applications, the SMTP
9
9
  interface supports legacy systems that require traditional email sending.</p>
@@ -107,7 +107,7 @@
107
107
  <p class="mb-4"><strong>With authentication disabled:</strong> Include the <code>X-EE-Account</code> header
108
108
  with the account ID in your messages.</p>
109
109
 
110
- {{#> ui/tabs label="Integration examples" id="code-examples"}}
110
+ {{#> ui/tabs label="Integration examples" elId="code-examples"}}
111
111
  {{> ui/tab target="example-nodemailer" label="Node.js (Nodemailer)" active=true}}
112
112
  {{> ui/tab target="example-phpmailer" label="PHP (PHPMailer)"}}
113
113
  {{/ui/tabs}}
@@ -69,7 +69,7 @@
69
69
  {{#unless hasAccounts}}
70
70
  {{#> ui/stat-card variant="success" title="Welcome to EmailEngine!" icon="icon-[tabler--info-circle]" class="mt-6"}}
71
71
  <p class="mb-2">Get started by connecting your first email account. Once connected, you can send
72
- and receive emails through the <a href="/admin/swagger" class="link link-animated">API</a>.
72
+ and receive emails through the <a href="/admin/reference" class="link link-animated">API</a>.
73
73
  </p>
74
74
  <p class="mb-4 text-sm text-base-content/60">You can also add accounts programmatically via the <a
75
75
  href="https://learn.emailengine.app/docs/api/post-v-1-account" target="_blank" rel="noopener noreferrer"
@@ -18,10 +18,6 @@
18
18
 
19
19
  <link href="/static/css/flyonui.css" rel="stylesheet">
20
20
 
21
- {{#if injectHtmlHead}}
22
- {{{injectHtmlHead}}}
23
- {{/if}}
24
-
25
21
  </head>
26
22
 
27
23
  <body class="bg-base-200 min-h-screen" data-sse-changes="true">
@@ -204,8 +200,23 @@
204
200
  <!-- End of Topbar -->
205
201
 
206
202
  <!-- Page content -->
207
- <div id="content" class="grow">
208
- <div class="w-full px-6 py-6">
203
+ <div id="content" class="grow lg:flex lg:items-start">
204
+
205
+ {{#if secondaryNav}}
206
+ <!-- Secondary navigation column. Rendered flush against the main sidebar
207
+ (no card, no gap, matching surface and border) so it reads as a second
208
+ level of the same menu rather than a panel floating in the page. A page
209
+ opts in by setting `secondaryNav` to a partial name in its view context;
210
+ every other page renders exactly as before.
211
+ On small screens it becomes a bounded scroll strip above the content,
212
+ because the sidebar drawer has no room for a second column. -->
213
+ <aside class="bg-base-100 border-base-content/20 max-h-48 shrink-0 overflow-y-auto border-b lg:sticky lg:top-topbar lg:h-[calc(100vh-var(--spacing-topbar))] lg:max-h-none lg:w-64 lg:self-start lg:border-e lg:border-b-0"
214
+ aria-label="Section navigation">
215
+ {{> (lookup . "secondaryNav")}}
216
+ </aside>
217
+ {{/if}}
218
+
219
+ <div class="w-full min-w-0 px-6 py-6">
209
220
 
210
221
  <div id="toastContainer" class="fixed top-16 right-6 z-[10000] w-80 max-w-[90vw]"></div>
211
222
 
@@ -221,7 +232,7 @@
221
232
 
222
233
  {{#unless licenseInfo.active}}
223
234
  {{#unless hideLicenseWarning}}
224
- {{#> ui/stat-card id="license-warning" variant="error" title="License key missing" icon="icon-[tabler--key]" class="mb-6"}}
235
+ {{#> ui/stat-card elId="license-warning" variant="error" title="License key missing" icon="icon-[tabler--key]" class="mb-6"}}
225
236
 
226
237
  {{#if licenseInfo.suspended}}
227
238
  <div class="alert alert-soft alert-error mb-6" role="alert">
@@ -23,7 +23,7 @@ interactive logins.
23
23
  </p>
24
24
  <p class="mt-2 mb-0">
25
25
  Accounts using service access can only be added via the
26
- <a href="/admin/swagger#/Account/postV1Account" class="link link-animated">REST API</a>, not through the hosted
26
+ <a href="/admin/reference/account#postV1Account" class="link link-animated">REST API</a>, not through the hosted
27
27
  authentication form.{{#if providerData.tutorialUrl}} Read the
28
28
  <a href="{{providerData.tutorialUrl}}" target="_blank" rel="noopener noreferrer" referrerpolicy="no-referrer"
29
29
  class="link link-animated">setup guide</a> for both methods.{{/if}}
@@ -38,7 +38,7 @@ client credentials, with no interactive user login required. The Entra app regis
38
38
  <strong>application permissions</strong> (not delegated) with admin consent. Use this for
39
39
  service integrations, shared mailboxes, or when you cannot perform interactive logins.
40
40
  Accounts using application access can only be added via the
41
- <a href="/admin/swagger#/Account/postV1Account" class="link link-animated">REST API</a>,
41
+ <a href="/admin/reference/account#postV1Account" class="link link-animated">REST API</a>,
42
42
  not through the hosted authentication form.
43
43
  {{#if providerData.tutorialUrl}}
44
44
  Read about setting up {{providerData.comment}} from <a href="{{providerData.tutorialUrl}}" target="_blank"
@@ -780,7 +780,7 @@ Read about setting up {{providerData.comment}} from <a href="{{providerData.tuto
780
780
  <p>
781
781
  If your EmailEngine instance cannot be exposed directly, configure a public
782
782
  proxy domain in <span class="text-base-content/60 code-link"><a
783
- href="/admin/swagger#/Settings/postV1Settings" target="_blank" rel="noopener noreferrer"
783
+ href="/admin/reference/settings#postV1Settings" target="_blank" rel="noopener noreferrer"
784
784
  class="link link-animated">notificationBaseUrl</a></span>. Microsoft Graph will then
785
785
  post to <code>https://&lt;proxy-domain&gt;/oauth/msg/...</code> instead of
786
786
  <code>{{mainServiceUrl}}</code>.
@@ -823,7 +823,7 @@ Read about setting up {{providerData.comment}} from <a href="{{providerData.tuto
823
823
  <p>
824
824
  If your EmailEngine instance cannot be exposed directly, configure a public
825
825
  proxy domain in <span class="text-base-content/60 code-link"><a
826
- href="/admin/swagger#/Settings/postV1Settings" target="_blank" rel="noopener noreferrer"
826
+ href="/admin/reference/settings#postV1Settings" target="_blank" rel="noopener noreferrer"
827
827
  class="link link-animated">notificationBaseUrl</a></span>. Microsoft Graph will then
828
828
  post to <code>https://&lt;proxy-domain&gt;/oauth/msg/...</code> instead of
829
829
  <code>{{mainServiceUrl}}</code>.
@@ -0,0 +1,20 @@
1
+ {{!--
2
+ reference/anchor-link - the link icon that makes something on a reference page
3
+ addressable. Used once per operation (reference/operation) and once per property row
4
+ (reference/schema-node), so the two stay identical rather than being kept in step by
5
+ hand.
6
+
7
+ A single element, with the icon mask on the anchor itself and the color and hover in
8
+ the .ee-ref-anchor rule rather than a utility string: a tag page renders this up to 434
9
+ times, where a wrapper span and a repeated 68-character class list cost real DOM nodes
10
+ and parse time. The accessible name comes from aria-label, since there is no text.
11
+
12
+ Params:
13
+ target - the id to link to, without the "#" (required)
14
+ label - the full accessible name, e.g. "Link to this operation" (required)
15
+ small - true for the smaller icon used on property rows (optional)
16
+ class - extra classes on the anchor: the ms-auto that pushes the operation link to
17
+ the end of its row, or the ee-ref-prop-anchor that keeps a property link
18
+ hidden until its row is hovered (optional)
19
+ --}}
20
+ <a href="#{{target}}" class="ee-ref-anchor icon-[tabler--link] {{#if small}}size-3.5{{else}}size-4{{/if}}{{#if class}} {{class}}{{/if}}" aria-label="{{label}}"></a>
@@ -0,0 +1,37 @@
1
+ {{!--
2
+ reference/disclosure - inline collapsible section used throughout the API reference:
3
+ example payloads, nested property groups, and the try-it panel. Block form; the block
4
+ is the body:
5
+ {{#> reference/disclosure label="Example response"}} ...body... {{/reference/disclosure}}
6
+
7
+ Params:
8
+ label - summary text (required)
9
+ elId - element id on the <details> (optional). Deliberately NOT named `id`:
10
+ Handlebars merges a partial's hash params into the caller's context,
11
+ so a partial that reads `id` also picks up an `id` that merely
12
+ happens to be on the surrounding context - and every call site here
13
+ sits inside an operation whose model has one. That silently emitted
14
+ the operation id on four elements per operation.
15
+ open - true to render expanded (optional)
16
+ primary - true for the larger primary-colored summary (the try-it panel);
17
+ default is the muted text-xs look used by the example blocks
18
+ class - extra classes on the <details> (optional; the caller owns spacing)
19
+
20
+ The chevron rotation is driven by .ee-ref-disclosure in app.tailwind.css rather than
21
+ Tailwind's group-open variant: these disclosures nest (a property group inside a
22
+ property group), and a named group matches ANY open ancestor, so an inner collapsed
23
+ group's chevron would rotate whenever an outer one was open. The stylesheet uses a
24
+ child combinator, which is exact at every depth.
25
+
26
+ Not ui/details: that one hardcodes a card shell plus font-bold text-primary on the
27
+ summary, which is the wrong weight for an inline disclosure inside a card body.
28
+ --}}
29
+ <details class="ee-ref-disclosure{{#if class}} {{class}}{{/if}}" {{#if elId}}id="{{elId}}" {{/if}}{{#if open}}open{{/if}}>
30
+ <summary
31
+ class="flex cursor-pointer list-none items-center gap-1 [&::-webkit-details-marker]:hidden {{#if primary}}text-primary hover:text-primary/80 text-sm font-semibold{{else}}text-base-content/60 hover:text-base-content text-xs{{/if}}">
32
+ <span class="ee-ref-chevron icon-[tabler--chevron-right] shrink-0 {{#if primary}}size-4{{else}}size-3.5{{/if}}"></span>
33
+ {{label}}
34
+ </summary>
35
+ {{!-- own hash params are neutralized so they cannot fall through into nested ui/* calls inside the block --}}
36
+ {{> @partial-block label="" elId="" open="" primary="" class=""}}
37
+ </details>