landing.html 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272
  1. <!doctype html>
  2. <html lang="zh-CN">
  3. <head>
  4. <meta charset="UTF-8" />
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  6. <meta name="description" content="MailHub — self-hosted transactional email with API, SMTP, DNS and webhooks." />
  7. <title>MailHub</title>
  8. <script type="module" crossorigin src="/assets/landing-OL30yro5.js"></script>
  9. <link rel="modulepreload" crossorigin href="/assets/modulepreload-polyfill-Dezn_h7o.js">
  10. <link rel="stylesheet" crossorigin href="/assets/landing-C6XYaH1w.css">
  11. </head>
  12. <body>
  13. <div class="page">
  14. <header class="site-header">
  15. <a class="brand" href="#top">
  16. <span class="brand-mark">MH</span>
  17. <span class="brand-name">MailHub</span>
  18. </a>
  19. <nav class="nav-links" aria-label="Primary">
  20. <a href="#features" data-i18n="nav.features">Features</a>
  21. <a href="#quickstart" data-i18n="nav.quickstart">Quick start</a>
  22. <a href="#api" data-i18n="nav.api">API</a>
  23. <a href="#mailboxes" data-i18n="nav.mailboxes">Mailboxes</a>
  24. <a href="#domains" data-i18n="nav.domains">Domain setup</a>
  25. <a href="#smtp" data-i18n="nav.smtp">SMTP</a>
  26. <a href="#webhooks" data-i18n="nav.webhooks">Webhooks</a>
  27. </nav>
  28. <div class="header-actions">
  29. <div class="lang-switch" role="group" aria-label="Language">
  30. <button type="button" data-locale="zh-CN" class="lang-btn">中文</button>
  31. <button type="button" data-locale="en-US" class="lang-btn">EN</button>
  32. </div>
  33. <a
  34. class="btn btn-ghost"
  35. href="https://github.com/chendeben/MailHub"
  36. target="_blank"
  37. rel="noopener noreferrer"
  38. data-i18n="cta.github"
  39. >GitHub</a>
  40. <a class="btn btn-ghost" href="/login" data-i18n="cta.login">Log in</a>
  41. <a class="btn btn-primary" href="/register" data-i18n="cta.signup">Get started</a>
  42. </div>
  43. </header>
  44. <main id="top">
  45. <section class="hero">
  46. <div class="hero-copy">
  47. <p class="eyebrow" data-i18n="hero.eyebrow">Transactional email platform</p>
  48. <h1 data-i18n="hero.title">Send reliable email via API &amp; SMTP</h1>
  49. <p class="lede" data-i18n="hero.lede">
  50. Self-hosted MailHub gives you domain DNS guidance, DKIM signing, delivery logs, and signed webhooks — without locking you into a black-box SaaS.
  51. </p>
  52. <div class="hero-cta">
  53. <a class="btn btn-primary btn-lg" href="/register" data-i18n="cta.signup">Get started</a>
  54. <a class="btn btn-ghost btn-lg" href="#api" data-i18n="cta.viewApi">View API sample</a>
  55. </div>
  56. <ul class="trust-strip">
  57. <li data-i18n="trust.selfHosted">Self-hosted</li>
  58. <li>DKIM</li>
  59. <li>SPF</li>
  60. <li>DMARC</li>
  61. <li data-i18n="trust.webhooks">Delivery webhooks</li>
  62. </ul>
  63. </div>
  64. <div class="hero-code" aria-hidden="false">
  65. <div class="code-card">
  66. <div class="code-card-bar">
  67. <span>curl</span>
  68. <button type="button" class="copy-btn" data-copy-target="hero-curl" data-i18n="common.copy">Copy</button>
  69. </div>
  70. <pre id="hero-curl"><code data-i18n-html="hero.curl"></code></pre>
  71. </div>
  72. </div>
  73. </section>
  74. <section id="features" class="section">
  75. <div class="section-head">
  76. <h2 data-i18n="features.title">Built for production senders</h2>
  77. <p data-i18n="features.sub">Everything you need to authenticate domains and observe delivery.</p>
  78. </div>
  79. <div class="feature-grid">
  80. <article class="card"><h3 data-i18n="features.dns.title">Domains &amp; DNS</h3><p data-i18n="features.dns.body">Guided SPF, DKIM, DMARC, and one-click DNS provider writes.</p></article>
  81. <article class="card"><h3 data-i18n="features.smtp.title">SMTP Submission</h3><p data-i18n="features.smtp.body">App-friendly SMTP listeners with credentials you control.</p></article>
  82. <article class="card"><h3 data-i18n="features.api.title">HTTP Send API</h3><p data-i18n="features.api.body">Bearer tokens and a simple JSON send endpoint for apps and services.</p></article>
  83. <article class="card"><h3 data-i18n="features.mailboxes.title">Mailboxes &amp; receiving</h3><p data-i18n="features.mailboxes.body">Create persistent or expiring inboxes with IMAP, POP3, forwarding, and catch-all routing.</p></article>
  84. <article class="card"><h3 data-i18n="features.logs.title">Delivery logs</h3><p data-i18n="features.logs.body">Track queue and MTA outcomes with searchable send history.</p></article>
  85. <article class="card"><h3 data-i18n="features.hooks.title">Webhooks</h3><p data-i18n="features.hooks.body">Signed callbacks for sent, bounced, and failed terminal events.</p></article>
  86. <article class="card"><h3 data-i18n="features.multi.title">Multi-user isolation</h3><p data-i18n="features.multi.body">Domains, tokens, and logs stay scoped to each account.</p></article>
  87. </div>
  88. </section>
  89. <section id="quickstart" class="section section-alt">
  90. <div class="section-head">
  91. <h2 data-i18n="quickstart.title">Start in four steps</h2>
  92. <p data-i18n="quickstart.sub">The console keeps domain, token, mailbox, and delivery configuration in one place.</p>
  93. </div>
  94. <div class="steps-grid">
  95. <article class="card">
  96. <span class="step-number">1</span>
  97. <h3 data-i18n="quickstart.domain.title">Add a domain</h3>
  98. <p data-i18n="quickstart.domain.body">Add your sending domain and publish the DNS records shown by MailHub.</p>
  99. <a class="text-link" href="#domains" data-i18n="quickstart.domain.link">Review domain setup →</a>
  100. </article>
  101. <article class="card">
  102. <span class="step-number">2</span>
  103. <h3 data-i18n="quickstart.token.title">Create a scoped token</h3>
  104. <p data-i18n="quickstart.token.body">Give each integration only the send or mailbox permissions it needs.</p>
  105. <a class="text-link" href="#api" data-i18n="quickstart.token.link">Review API access →</a>
  106. </article>
  107. <article class="card">
  108. <span class="step-number">3</span>
  109. <h3 data-i18n="quickstart.mailbox.title">Provision mailboxes</h3>
  110. <p data-i18n="quickstart.mailbox.body">Create persistent mailboxes in the console or create persistent and temporary mailboxes by API.</p>
  111. <a class="text-link" href="#mailboxes" data-i18n="quickstart.mailbox.link">Review mailbox API →</a>
  112. </article>
  113. <article class="card">
  114. <span class="step-number">4</span>
  115. <h3 data-i18n="quickstart.client.title">Connect your client</h3>
  116. <p data-i18n="quickstart.client.body">Use SMTP to send and IMAP or POP3 to receive with the mailbox's full address and password.</p>
  117. <a class="text-link" href="#smtp" data-i18n="quickstart.client.link">Review protocol settings →</a>
  118. </article>
  119. </div>
  120. </section>
  121. <section id="api" class="section">
  122. <div class="section-head">
  123. <h2 data-i18n="api.title">Send API</h2>
  124. <p data-i18n="api.sub">Minimal JSON contract. Hostnames below are placeholders — replace with your MailHub host.</p>
  125. </div>
  126. <div class="code-card">
  127. <div class="code-card-bar">
  128. <span>POST /api/send</span>
  129. <button type="button" class="copy-btn" data-copy-target="api-curl" data-i18n="common.copy">Copy</button>
  130. </div>
  131. <pre id="api-curl"><code data-i18n-html="api.curl"></code></pre>
  132. </div>
  133. <ul class="field-list">
  134. <li><code>from</code> — <span data-i18n="api.field.from">sender address on a verified domain</span></li>
  135. <li><code>to</code> — <span data-i18n="api.field.to">recipient string or array</span></li>
  136. <li><code>subject</code> — <span data-i18n="api.field.subject">message subject</span></li>
  137. <li><code>text</code> / <code>html</code> — <span data-i18n="api.field.body">message body</span></li>
  138. </ul>
  139. </section>
  140. <section id="mailboxes" class="section section-alt">
  141. <div class="section-head">
  142. <h2 data-i18n="mailboxes.title">Mailbox API and clients</h2>
  143. <p data-i18n="mailboxes.sub">Create a persistent address for ongoing work, or an expiring address for a short-lived workflow.</p>
  144. </div>
  145. <div class="doc-grid">
  146. <article class="card">
  147. <h3 data-i18n="mailboxes.api.title">Create a mailbox</h3>
  148. <p data-i18n="mailboxes.api.body">POST to /api/mailboxes with a token holding mailboxes:write. The target domain must belong to that account.</p>
  149. <ul class="field-list compact-list">
  150. <li><code>mode</code> — <span data-i18n="mailboxes.api.mode">permanent or temporary</span></li>
  151. <li><code>address</code> / <code>domain</code> — <span data-i18n="mailboxes.api.address">use a full address, or let a temporary mailbox generate one from domain</span></li>
  152. <li><code>expiresInMinutes</code> — <span data-i18n="mailboxes.api.expires">required for temporary mailboxes; 5 minutes to 30 days</span></li>
  153. <li><code>password</code> — <span data-i18n="mailboxes.api.password">optional; a secure password is returned once when omitted</span></li>
  154. </ul>
  155. </article>
  156. <article class="card">
  157. <h3 data-i18n="mailboxes.client.title">Use the returned configuration</h3>
  158. <p data-i18n="mailboxes.client.body">Creation returns the address, password, expiration, and ready-to-use IMAP, POP3, and SMTP settings.</p>
  159. <ul class="field-list compact-list">
  160. <li><strong>IMAP</strong> — <span data-i18n="mailboxes.client.imap">recommended for synchronized folders and sent mail</span></li>
  161. <li><strong>POP3</strong> — <span data-i18n="mailboxes.client.pop3">for download-oriented clients</span></li>
  162. <li><strong>SMTP</strong> — <span data-i18n="mailboxes.client.smtp">use the same full mailbox address and password to send</span></li>
  163. </ul>
  164. </article>
  165. </div>
  166. <div class="code-card doc-code-card">
  167. <div class="code-card-bar">
  168. <span>POST /api/mailboxes</span>
  169. <button type="button" class="copy-btn" data-copy-target="mailbox-curl" data-i18n="common.copy">Copy</button>
  170. </div>
  171. <pre id="mailbox-curl"><code data-i18n-html="mailboxes.curl"></code></pre>
  172. </div>
  173. <p class="note" data-i18n="mailboxes.note">Use GET /api/mailboxes with mailboxes:read to list the account's mailboxes. A temporary mailbox stops accepting mail and authenticating at its expiration time.</p>
  174. </section>
  175. <section id="domains" class="section">
  176. <div class="section-head">
  177. <h2 data-i18n="domainsDoc.title">Domain configuration</h2>
  178. <p data-i18n="domainsDoc.sub">Create the domain in MailHub first. Its DNS panel is the source of truth for your exact verification, DKIM, SPF, DMARC, and sender-host values.</p>
  179. </div>
  180. <div class="table-wrap">
  181. <table>
  182. <thead>
  183. <tr>
  184. <th data-i18n="domainsDoc.col.purpose">Purpose</th>
  185. <th data-i18n="domainsDoc.col.record">Record</th>
  186. <th data-i18n="domainsDoc.col.requirement">Requirement</th>
  187. </tr>
  188. </thead>
  189. <tbody>
  190. <tr><td data-i18n="domainsDoc.row.verify">Domain ownership</td><td><code>TXT _mailhub.&lt;domain&gt;</code></td><td data-i18n="domainsDoc.row.verifyValue">Publish the verification value generated in the console.</td></tr>
  191. <tr><td>DKIM</td><td><code>TXT &lt;selector&gt;._domainkey.&lt;domain&gt;</code></td><td data-i18n="domainsDoc.row.dkim">Publish the public key generated for this domain.</td></tr>
  192. <tr><td>SPF</td><td><code>TXT &lt;domain&gt;</code></td><td data-i18n="domainsDoc.row.spf">Keep one SPF record and include the sender IP/host required by MailHub.</td></tr>
  193. <tr><td>DMARC</td><td><code>TXT _dmarc.&lt;domain&gt;</code></td><td data-i18n="domainsDoc.row.dmarc">Start with monitoring, then strengthen the policy after alignment is verified.</td></tr>
  194. <tr><td data-i18n="domainsDoc.row.mx">Inbound mail</td><td><code>MX &lt;domain&gt;</code></td><td data-i18n="domainsDoc.row.mxValue">Point MX to the MailHub receiving host and ensure that host has an A/AAAA record.</td></tr>
  195. </tbody>
  196. </table>
  197. </div>
  198. <p class="note" data-i18n="domainsDoc.note">For reliable delivery, also configure the sending IP's PTR to match the MailHub sending hostname and allow the documented SMTP, IMAP, and POP3 ports through your firewall.</p>
  199. </section>
  200. <section id="smtp" class="section section-alt">
  201. <div class="section-head">
  202. <h2 data-i18n="smtp.title">SMTP submission</h2>
  203. <p data-i18n="smtp.sub">Default listener ports (override in your deployment):</p>
  204. </div>
  205. <div class="port-grid">
  206. <div class="card mono"><strong>25</strong><span>smtp</span></div>
  207. <div class="card mono"><strong>587</strong><span>smtp / STARTTLS</span></div>
  208. <div class="card mono"><strong>465</strong><span>smtps</span></div>
  209. <div class="card mono"><strong>2525</strong><span>smtp</span></div>
  210. </div>
  211. <p class="note" data-i18n="smtp.note">Use a mailbox's full address and password for SMTP, IMAP, and POP3. Prefer TLS ports 465, 993, and 995; use STARTTLS/STLS on the plain ports when needed.</p>
  212. </section>
  213. <section id="webhooks" class="section">
  214. <div class="section-head">
  215. <h2 data-i18n="webhooks.title">Delivery webhooks</h2>
  216. <p data-i18n="webhooks.sub">Terminal events only — signed HTTPS callbacks to your systems.</p>
  217. </div>
  218. <div class="table-wrap">
  219. <table>
  220. <thead>
  221. <tr>
  222. <th data-i18n="webhooks.col.status">Status</th>
  223. <th data-i18n="webhooks.col.type">type</th>
  224. </tr>
  225. </thead>
  226. <tbody>
  227. <tr><td><code>sent</code></td><td><code>email.sent</code></td></tr>
  228. <tr><td><code>bounced</code></td><td><code>email.bounced</code></td></tr>
  229. <tr><td><code>failed</code></td><td><code>email.failed</code></td></tr>
  230. </tbody>
  231. </table>
  232. </div>
  233. <p class="note"><span data-i18n="webhooks.sig">Signature header:</span> <code>X-MailHub-Signature: t=&lt;unix&gt;,v1=&lt;hmac&gt;</code></p>
  234. </section>
  235. <section class="section cta-band">
  236. <h2 data-i18n="ctaBand.title">Ready to send?</h2>
  237. <p data-i18n="ctaBand.sub">Create an account, add a domain, and ship your first message in minutes.</p>
  238. <div class="hero-cta">
  239. <a class="btn btn-primary btn-lg" href="/register" data-i18n="cta.signup">Get started</a>
  240. <a class="btn btn-ghost btn-lg" href="/login" data-i18n="cta.login">Log in</a>
  241. </div>
  242. </section>
  243. </main>
  244. <footer class="site-footer">
  245. <div>
  246. <strong>MailHub</strong>
  247. <span data-i18n="footer.tag">Self-hosted email delivery control plane</span>
  248. </div>
  249. <div class="footer-links">
  250. <a
  251. href="https://github.com/chendeben/MailHub"
  252. target="_blank"
  253. rel="noopener noreferrer"
  254. data-i18n="cta.github"
  255. >GitHub</a>
  256. <a href="/login" data-i18n="cta.login">Log in</a>
  257. <a href="/register" data-i18n="cta.signup">Get started</a>
  258. </div>
  259. </footer>
  260. </div>
  261. </body>
  262. </html>