Skip to content

Settings

Settings live under Webhook Notifier → Settings (admins only), or in a config/webhook-notifier.php file. When both exist, the config file wins, which makes it handy for per-environment values and for keeping settings in version control.

Settings reference

SettingConfig keyDefaultWhat it does
EnabledenabledtrueGlobal on/off switch for all notifications. A kill switch - turn it off and nothing is sent, whatever your rules say.
Default connectiondefaultConnectionIdnullThe connection used by any rule that doesn't choose its own. See Connections.
Default card versiondefaultCardVersion'1.5'The Adaptive Card schema version new Teams cards target.
Log retention (days)logRetentionDays30How many days of delivery log history to keep before pruning.
HTTP timeout (seconds)httpTimeout10How long to wait for a webhook to respond before treating the send as failed.
Max retriesmaxRetries5How many times a failed send is retried before it settles on Failed.

The config file

Copy the plugin's src/config.php to your project's config/ directory as webhook-notifier.php, then uncomment and change the values you want to override. A minimal example:

php
<?php

use craft\helpers\App;

return [
    // Keep two months of delivery history.
    'logRetentionDays' => 60,

    // Give slow endpoints a little longer to answer.
    'httpTimeout' => 20,
];

The config file always wins

A value set in config/webhook-notifier.php overrides whatever the control panel shows. If a setting won't stick no matter how often you save it, check the config file first.

Turning notifications off per environment

The Enabled switch reads a WEBHOOK_NOTIFIER_ENABLED environment variable if you set one, so you can silence notifications on staging without touching production:

php
<?php

use craft\helpers\App;

return [
    'enabled' => App::env('WEBHOOK_NOTIFIER_ENABLED') !== null
        ? (bool)App::env('WEBHOOK_NOTIFIER_ENABLED')
        : true,
];
bash
# .env on staging
WEBHOOK_NOTIFIER_ENABLED=false

Multi-environment values

Because it's a normal Craft config file, you can also vary settings by environment using Craft's multi-environment config style:

php
<?php

return [
    '*' => [
        'httpTimeout' => 10,
    ],
    'dev' => [
        // Don't send anything while developing locally.
        'enabled' => false,
    ],
];

A note on read-only settings

Plugin settings are stored in Craft's project config. On environments where admin changes are disabled (allowAdminChanges is off, as it usually is in production), the Settings screen is read-only and settings deploy in from project config instead. Edit them where admin changes are allowed - typically your local environment - or in the config/webhook-notifier.php file, and let them deploy from there.

Digital help you can trust.