What's Changed
- Service URLs are now validated when they are read, so a URL that would fail on every send now fails when the service is initialized or a sender is created. Applications that check user-supplied URLs with
CreateSenderor the router may reject URLs they accepted before. - A URL without a host is rejected by the generic, Gotify, Mattermost, Rocket.Chat, and SMTP services, and a Notifiarr URL without an API key is rejected. ntfy, MQTT, and Signal use their default host instead:
ntfy.sh,localhost, andlocalhost. - IPv6 addresses in a URL must be enclosed in brackets, such as
mqtt://[2001:db8::1]/topic. - Gotify requires a valid application token, Google Chat requires both
keyandtoken, and ntfy topic names must follow ntfy's naming rule of up to 64 letters, digits, underscores, and dashes. - Several services also reject values they cannot send with, such as an empty token or API key, port 0, or an invalid recipient.
- Some failures that were reported as successful sends now return an error: an MQTT QoS 1 publish rejected by the broker, and a Signal send that the REST API could not deliver to some recipients.
- Discord sends every rich item, splitting them across messages as needed, and MQTT sends a password even when the URL has no username.
Deprecations
- PagerDuty:
EventPayload.DetailsandEventPayload.Contexts. UsePayload.CustomDetails,EventPayload.Links, andEventPayload.Imagesinstead. - Gotify: the
dateURL setting, which is ignored because Gotify sets each message's date itself. - MQTT:
Config.ValidateCredentialsandErrPasswordWithoutUsername, since MQTT v5 accepts a password without a username.
Fixes
- fix(services): redact service urls from request building errors by @nicholas-fedor in #1571
- fix(mattermost): accept username and channel send params by @nicholas-fedor in #1577
- fix(homeassistant): omit empty notify targets by @nicholas-fedor in #1586
- fix(ifttt): send the title in the titlevalue field by @nicholas-fedor in #1588
- fix(pagerduty): apply the default host and port from the url by @nicholas-fedor in #1599
- fix(pagerduty): send details and contexts in the events api v2 format by @nicholas-fedor in #1601
- fix(opsgenie): accept named escalation and schedule responders by @nicholas-fedor in #1603
- fix(signal): read send results and report failed recipients by @nicholas-fedor in #1619
- fix(zulip): send direct message user ids as numbers and count characters by @nicholas-fedor in #1627
- fix(gotify): send priority only when set and stop sending the date by @nicholas-fedor in #1632
- fix(format): leave defaults out of service URLs however their tags are spelled by @nicholas-fedor in #1638
- fix(ntfy): apply the tls send params to the send by @nicholas-fedor in #1640
- fix(smtp): trim spaces around each address before restoring plus tags by @nicholas-fedor in #1648
- fix(smtp): fold header lines at whitespace within rfc line limits by @nicholas-fedor in #1650
- fix(standard): correct the failure messages for details and test setup by @nicholas-fedor in #1656
- fix(format): read hex prefixes, colons in map values, and enum aliases in any case by @nicholas-fedor in #1667
- fix(format): stop adding a slash after the path in markdown url examples by @nicholas-fedor in #1668
- fix(discord): send every rich item and stop waiting after the last retry by @nicholas-fedor in #1679
- fix(mqtt): report rejected qos 1 publishes as PublishError by @nicholas-fedor in #1681
- fix(discord): keep rich sends within discord's embed limits by @nicholas-fedor in #1683
- fix(mqtt): accept a password without a username by @nicholas-fedor in #1690
- fix(mqtt): keep a topic's leading slash in the config url by @nicholas-fedor in #1692
- fix(wecom): validate the webhook key from every source by @nicholas-fedor in #1694
- fix(wecom): send each mention as its own list entry by @nicholas-fedor in #1697
- fix(generic): keep acronyms and digits in custom header keys by @nicholas-fedor in #1699
- fix(googlechat): require the key and token and default the host by @nicholas-fedor in #1701
- fix(opsgenie): reject entities without an identifier by @nicholas-fedor in #1703
- fix(opsgenie): validate the api key and port and default the host by @nicholas-fedor in #1705
- fix(pagerduty): skip validation only for the docs dummy url by @nicholas-fedor in #1707
- fix(services): support ipv6 hosts in services that connect to their host by @nicholas-fedor in #1709
- fix(ntfy): validate topic names and reject empty path segments by @nicholas-fedor in #1711
- fix(services): default or reject a missing host in service urls by @nicholas-fedor in #1713
- fix(rocketchat): reject empty webhook tokens in the service url by @nicholas-fedor in #1715
- fix(gotify): validate the token when reading the service url by @nicholas-fedor in #1717
- fix(signal): validate source and recipients from the url query by @nicholas-fedor in #1723
- fix(rocketchat): keep the username and channel in the config url by @nicholas-fedor in #1727
- fix(redact): keep host escapes in redacted request urls by @nicholas-fedor in #1729
- fix(services): match the docs dummy url exactly in xmpp and mqtt by @nicholas-fedor in #1731
Dependency Updates
- chore(deps): update go toolchain directive to v1.27.3 by @renovate[bot] in #1688
- chore(deps): update module github.com/stretchr/objx to v0.8.0 by @renovate[bot] in #1574
- chore(deps): update github.com/google/pprof digest to 1facf8f by @renovate[bot] in #1624
Full Changelog: v0.22.0...v0.22.1