Rebuild your site with webhooks

6 min read

When an editor publishes, your static site needs to rebuild and your integrations need to know. Webhooks are that signal: a signed POST to the endpoints you choose, the moment content goes live. Webhooks are available from the Pro plan.

Add a webhook

  1. 1 Open API keys and find the Webhooks section.
  2. 2 Give it a name and the URL to call — for example a Netlify or Vercel build hook.
  3. 3 Save it. Mojimoto shows a signing secret once; copy it somewhere safe.

What gets sent

On publish, Mojimoto POSTs a JSON payload describing the event and the affected document. Every request carries an X-Mojimoto-Signature header — an HMAC of the body using your signing secret — so your receiver can prove the request is genuine before acting on it.

Verify the signature

Compute the same HMAC over the raw request body and compare it, in constant time, to the header. Reject anything that does not match.

node — verify
import crypto from 'node:crypto';

function verify(rawBody, signature, secret) {
  const expected = crypto
    .createHmac('sha256', secret)
    .update(rawBody)
    .digest('hex');
  return crypto.timingSafeEqual(
    Buffer.from(signature),
    Buffer.from(expected),
  );
}

If you only need rebuilds, point the webhook straight at your host's build hook — no receiver code required.

Next

Build it for real

Spin up a project and try this in your own space — free for 14 days.

© 2026 Mojimoto, Inc. 文 · モジモト