feat(webhook): add Apprise webhook support and rename bot-webhook to discord-webhook
- Rename the Discord webhook endpoint from `/bot-webhook/` to `/discord-webhook/` for better clarity. - Add new routes and controller methods (`receiveApprise`, `receiveAppriseNotify`) to support Apprise integrations. - Implement `mapApprisePayload` in TalkService to map Apprise JSON format (title, body, type, attachments) to Talk message format. - Update the settings UI to generate and display URLs for both Discord and Apprise webhooks. - Update `INSTALL.md` and `README.md` documentation to reflect the new webhook paths and Apprise support. - Refactor token revocation logic to revoke all tokens for a room at once.
This commit is contained in:
+11
-1
@@ -4,7 +4,7 @@ return [
|
||||
'routes' => [
|
||||
[
|
||||
'name' => 'webhook#receive',
|
||||
'url' => '/bot-webhook/{roomToken}/{token}',
|
||||
'url' => '/discord-webhook/{roomToken}/{token}',
|
||||
'verb' => 'POST',
|
||||
],
|
||||
[
|
||||
@@ -28,5 +28,15 @@ return [
|
||||
'verb' => 'GET',
|
||||
'type' => 'noCsrf',
|
||||
],
|
||||
[
|
||||
'name' => 'webhook#receiveApprise',
|
||||
'url' => '/apprise-webhook/{roomToken}/{token}',
|
||||
'verb' => 'POST',
|
||||
],
|
||||
[
|
||||
'name' => 'webhook#receiveAppriseNotify',
|
||||
'url' => '/apprise-webhook/{roomToken}/notify/{token}',
|
||||
'verb' => 'POST',
|
||||
],
|
||||
],
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user