LogoLogo
  • Introduction
  • What's New?
  • Upgrade Guide
  • Getting Started
    • Requirements
    • Installation
  • Defining Channels
    • Configuration
    • Retrieving Channels
  • Creating and Sending Notifications
    • Defining Notifications
    • Notifiables
    • Sending Notifications
  • Providers
    • DatabaseProvider
    • EmailProvider
    • SlackProvider
      • Slack BlockKit
    • Creating Custom Providers
  • Testing
    • Coming Soon
  • Reference
    • NotificationService
    • BaseNotification
    • SendsNotifications
    • INotifiable
    • BaseProvider
      • DatabaseProvider
        • DatabaseNotificationService
        • HasDatabaseNotifications
        • DatabaseNotificationCursor
        • DatabaseNotification
      • EmailProvider
      • SlackProvider
        • SlackMessage
          • EventMetadata
          • ActionsBlock
          • ContextBlock
          • DividerBlock
          • HeaderBlock
          • ImageBlock
          • SectionBlock
          • ButtonElement
          • ConfirmObject
          • ImageElement
          • TextObject
          • PlainTextOnlyTextObject
  • ForgeBox
  • GitHub
Powered by GitBook
On this page
  • via
  • populate
  • routeForType
  • getNotificationType
  1. Reference

BaseNotification

via

Returns an array of channel names to send this notification on.

Name
Type
Required
Default
Description

notifiable

true

The notifiable instance being sent this notification instance.

Return: An array of string channel names.

populate

Populates the passed in struct of properties onto the variables scope of the Notification.

Name
Type
Required
Default
Description

properties

struct

false

{}

The properties to populate.

Return: The Notification instance.

routeForType

Routes the notification to the correct to{ChannelType} method.

Name
Type
Required
Default
Description

type

string

true

The type of channel to route to.

notifiable

true

The notifiable instance the notification is being sent to.

channelName

string

true

The name of the channel to route to.

additionalArgs

struct

false

{}

Any additional arguments to pass to the routing method (to{ChannelType} method).

Return: The result of the routing method. The variable type depends on the Provider.

getNotificationType

Returns the WireBox ID of the Notification.

Name
Type
Required
Default
Description

No arguments

Return: (string) The WireBox ID of the Notification.

PreviousNotificationServiceNextSendsNotifications

Last updated 1 year ago

INotifiable
INotifiable