diff --git a/docs/api/notification_channels.md b/docs/api/notification_channels.md index afbed9052a..e7828dde6c 100644 --- a/docs/api/notification_channels.md +++ b/docs/api/notification_channels.md @@ -33,17 +33,27 @@ Some events generate notifications that you can deliver to the users through one ### Available notification types -- [`Ibexa\Contracts\FormBuilder\Notifications\FormSubmitted`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-FormBuilder-Notifications-FormSubmitted.html) -- [`Ibexa\Contracts\Notifications\SystemNotification\SystemNotification`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Notifications-SystemNotification-SystemNotification.html) -- [`Ibexa\Contracts\OrderManagement\Notification\OrderStatusChange`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-OrderManagement-Notification-OrderStatusChange.html) -- [`Ibexa\Contracts\Payment\Notification\PaymentStatusChange`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Payment-Notification-PaymentStatusChange.html) -- [`Ibexa\Contracts\Shipping\Notification\ShipmentStatusChange`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Shipping-Notification-ShipmentStatusChange.html) -- [`Ibexa\Contracts\User\Notification\UserInvitation`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-User-Notification-UserInvitation.html) -- [`Ibexa\Contracts\User\Notification\UserPasswordReset`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-User-Notification-UserPasswordReset.html) -- [`Ibexa\Contracts\User\Notification\UserRegister`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-User-Notification-UserRegister.html) -- `Ibexa\Share\Notification\ContentEditInvitationNotification` -- `Ibexa\Share\Notification\ContentViewInvitationNotification` -- `Ibexa\Share\Notification\ExternalParticipantContentViewInvitationNotification` +Several built-in notification types are available. +TODO: Some/All are sent by various notifiers like event subscribers. + +| Notification type | Default recipients | +|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------| +| `Ibexa\AdminUi\Notifier\Notification\UserInvitation` | TODO: Given email address | +| `Ibexa\AdminUi\Notifier\Notification\UserPasswordReset` | TODO: Given email address | +| [`Ibexa\Contracts\FormBuilder\Notifications\FormSubmitted`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-FormBuilder-Notifications-FormSubmitted.html) | [Form submit email notification field](customize_email_notifications.md) | +| [`Ibexa\Contracts\Notifications\SystemNotification\SystemNotification`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Notifications-SystemNotification-SystemNotification.html) | TODO | +| [`Ibexa\Contracts\OrderManagement\Notification\OrderStatusChange`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-OrderManagement-Notification-OrderStatusChange.html) | Order owner | +| [`Ibexa\Contracts\Payment\Notification\PaymentStatusChange`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Payment-Notification-PaymentStatusChange.html) | Order owner | +| [`Ibexa\Contracts\Shipping\Notification\ShipmentStatusChange`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Shipping-Notification-ShipmentStatusChange.html) | Order owner | +| [`Ibexa\Contracts\User\Notification\UserInvitation`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-User-Notification-UserInvitation.html) | TODO: Given email address | +| [`Ibexa\Contracts\User\Notification\UserPasswordReset`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-User-Notification-UserPasswordReset.html) | TODO: Given email address | +| [`Ibexa\Contracts\User\Notification\UserRegister`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-User-Notification-UserRegister.html) | TODO | +| `Ibexa\Share\Notification\ContentEditInvitationNotification`
(alias `ibexa_content_edit_invitation`) | TODO: Given users | +| `Ibexa\Share\Notification\ContentViewInvitationNotification`
(alias `ibexa_content_view_invitation`) | TODO: Given users | +| `Ibexa\Share\Notification\ExternalParticipantContentViewInvitationNotification`
(alias `ibexa_external_participant_content_view_invitation`) | TODO: Given email addresses | + +Notice that `Ibexa\AdminUi\Notifier\Notification\UserInvitation` are sent by the back office and don't implement `Ibexa\Contracts\User\Notification\UserInvitation` which is made for front end users and other more generic usages. +Same for the two `UserPasswordReset` in distinct namespaces. ### Available notification channels @@ -79,6 +89,49 @@ This page contains several examples of subscriptions configuration. php bin/console ibexa:debug:config notifications.subscriptions --siteaccess= ``` + For example, the following command returns the subscription for the `admin` siteaccess. + You should see subscriptions to handle back office password reset and user invitation, and the share invitations through, at least, `email`. + + ```bash + php bin/console ibexa:debug:config notifications.subscriptions --siteaccess=admin --json | jq + ``` + ```json + { + "ibexa_content_edit_invitation": { + "channels": [ + "ibexa", + "email" + ] + }, + "ibexa_content_view_invitation": { + "channels": [ + "ibexa", + "email" + ] + }, + "ibexa_external_participant_content_view_invitation": { + "channels": [ + "email" + ] + }, + "Ibexa\\AdminUi\\Notifier\\Notification\\UserPasswordReset": { + "channels": [ + "email" + ] + }, + "Ibexa\\AdminUi\\Notifier\\Notification\\UserInvitation": { + "channels": [ + "email" + ] + }, + "Ibexa\\Contracts\\FormBuilder\\Notifications\\FormSubmitted": { + "channels": [ + "email" + ] + } + } + ``` + #### Subscription example The following example shows how you can deliver notifications about Commerce-related activities through Slack: