Tofu
Start here

Get from install to replay in one terminal session

Tofu gives every provider a stable URL, forwards requests to your local app, and keeps events ready to inspect. Once the payload expires, the event remains visible but can no longer be replayed.

Terminal
$ curl -fsSL https://trytofu.dev/install | sh$ tofu login$ tofu hooks create stripe --name "Stripe"$ tofu hooks url stripe$ tofu targets set local "http://127.0.0.1:3000/api/webhooks/stripe" --hook stripe$ tofu watch stripe$ tofu replay latest --hook stripe

Run the commands from the project that receives webhooks. The provider URL stays the same across restarts, branches, and ports. The CLI is open source on GitHub, including the installer and release artifacts.

Step by step

  1. 1
    tofu login

    Open browser approval and connect the CLI to your account.

  2. 2
    tofu hooks create stripe --name "Stripe"

    Create a named provider URL for Stripe webhooks.

  3. 3
    tofu hooks url stripe

    Print the provider URL to paste into Stripe.

  4. 4
    tofu targets set local "http://127.0.0.1:3000/api/webhooks/stripe" --hook stripe

    Forward events to the webhook route in your local app.

What should happen

The CLI is connected

tofu login opens browser approval and saves your account token locally. After that, commands use your active workspace.

The provider has one URL

Paste the URL from tofu hooks url stripe into the provider dashboard. Keep your local target URL separate from the provider URL.

Events appear in watch

Trigger a provider test event while tofu watch stripeis running. You should see the event arrive, then delivery results after Tofu forwards it.

Next steps

Once events are arriving, the rest of the docs cover the same flow in depth.