• Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below
  • Forum
  • Website
  • GitHub
  • Status
  • Translation
  • Features
  • Team
  • Rules
  • Help
  • Feeds
User Links
  • Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below

    Useful Links Forum Website GitHub Status Translation Features Team Rules Help Feeds
    Jellyfin Forum Support Troubleshooting Help

     
    • 0 Vote(s) - 0 Average

    Help

    Unable to receive slack notifications via webhook
    Aaditya Joshi
    Offline

    Junior Member

    Posts: 2
    Threads: 2
    Joined: 2023 Sep
    Reputation: 0
    #1
    2023-09-11, 06:20 AM
    I am new to Jellyfin and want to set up Slack notifications using webhooks to get notifications when a user has started playing ANY content. However, I am getting the following error in the logs (I have redacted sensitive info):
    Code:
    [05:53:31] [WRN] [41] Jellyfin.Plugin.Webhook.Destinations.Slack.SlackClient: Notification failed with POST request to https://hooks.slack.com/services/<webhookidandmore>: { "token": "", "user": "", "device": "", "title": "", "url": "https://<servername.com>/web/index.html#!/details?id=<ig-goes-here>&serverId=<serveridgoeshere>", "url_title": "", "priority": , "sound": "", "message": "JohnDoe started watching Looney.Tunes.Cartoons.S05E04 ()" } [05:53:31] [WRN] [41] Jellyfin.Plugin.Webhook.Destinations.Slack.SlackClient: Notification failed with response status code BadRequest: invalid_payload
    I am using this template for my webhook setup which I found on a similar post on this Subreddit.
    Code:
    {
      "token": "{{Token}}",
      "user": "{{UserToken}}",
      "device": "{{Device}}",
      "title": "{{{Title}}}",
      "url": "{{ServerUrl}}/web/index.html#!/details?id={{ItemId}}&serverId={{ServerId}}",
      "url_title": "{{{MessageUrlTitle}}}",
      "priority": {{MessagePriority}},
      "sound": "{{NotificationSound}}",
      {{#if_equals NotificationType 'ItemAdded'}}
        {{#if_equals ItemType 'Season'}}
          "message": "{{{SeriesName}}} {{{Name}}} has been added to {{{ServerName}}}"
        {{else}}
          {{#if_equals ItemType 'Episode'}}
            "message": "{{{SeriesName}}} S{{SeasonNumber00}}E{{EpisodeNumber00}} {{{Name}}} has been added to {{{ServerName}}}"
          {{else}}
            "message": "{{{Name}}} ({{Year}}) has been added to {{{ServerName}}}"
          {{/if_equals}}
        {{/if_equals}}
      {{/if_equals}}
      {{#if_equals NotificationType 'PlaybackStart'}}
        {{#if_equals ItemType 'Season'}}
          "message": "{{{NotificationUsername}}} started watching {{{SeriesName}}} {{{Name}}}"
        {{else}}
          {{#if_equals ItemType 'Episode'}}
            "message": "{{{NotificationUsername}}} started watching {{{SeriesName}}} S{{SeasonNumber00}}E{{EpisodeNumber00}} {{{Name}}}"
          {{else}}
            "message": "{{{NotificationUsername}}} started watching {{{Name}}} ({{Year}})"
          {{/if_equals}}
        {{/if_equals}}
      {{/if_equals}}
      {{#if_equals NotificationType 'PlaybackStop'}}
        {{#if_equals ItemType 'Season'}}
          "message": "{{{NotificationUsername}}} stopped watching {{{SeriesName}}} {{{Name}}}"
        {{else}}
          {{#if_equals ItemType 'Episode'}}
            "message": "{{{NotificationUsername}}} stopped watching {{{SeriesName}}} S{{SeasonNumber00}}E{{EpisodeNumber00}} {{{Name}}}"
          {{else}}
            "message": "{{{NotificationUsername}}} stopped watching {{{Name}}} ({{Year}})"
          {{/if_equals}}
        {{/if_equals}}
      {{/if_equals}}
    }

    I am sure that I'm doing something wrong but not sure what. Any help will be appreciated.
    « Next Oldest | Next Newest »

    Users browsing this thread: 1 Guest(s)


    • View a Printable Version
    • Subscribe to this thread
    Forum Jump:

    Home · Team · Help · Contact
    © Designed by D&D - Powered by MyBB
    L


    Jellyfin

    The Free Software Media System

    Linear Mode
    Threaded Mode