Skip to content

mxhook route ​

Manage routing rules that connect recipient patterns to webhook endpoints.

Subcommands ​

route add ​

Create a new routing rule.

bash
mxhook route add --recipient <pattern> --webhook <url> [flags]

Flags

FlagDefaultRequiredDescription
--recipient—YesRecipient pattern (e.g., *@yourdomain.com)
--webhook—YesWebhook URL
--api-urlhttp://localhost:8080NoMXHook API URL
--api-key—NoAPI authentication key

Examples ​

Create a catch-all route:

bash
mxhook route add \
  --recipient "*@yourdomain.com" \
  --webhook "https://yourapp.com/webhook"

Create a route for a specific address:

bash
mxhook route add \
  --recipient "support@yourdomain.com" \
  --webhook "https://yourapp.com/support" \
  --api-key your-secret-key

Released under the Apache 2.0 License.