Webhook determine notification type

When you receive a webhook it doesn’t tell you what type the channel is. I’m saving this data in my database and I’d like a column for notification type, e.g “email” “sms” “push-notification” etc.

Looking at the payload “providers” section, it can tell me the channel “mailgun” but not the type (it shows the type in the Courier Web UI so it’s stored somewhere in Courier…)


    channel: { name: '', template: '953a5ab2-9b46-4210-a105-76c3dcecc632' },
    provider: 'mailgun',
    providerResponse: {
      id: '<20220716190654.76885fd2914df840@mg.xx.xx>',
      message: 'Queued. Thank you.'
    reference: {
      id: '<20220716190654.76885fd2914df840@mg.xx.xx>'
    sent: 1657998414438,
    status: 'SENT'

Thanks for the question, I think this is a bug, I would expect to see the default channel name of Email to show up here, but it looks like the name field is empty for some reason.

I was able to reproduce this behavior and will file a bug report. In the meantime, if you go to the channel settings in a given template and rename the channel to something like email then you should see this start to appear in the webhook response.