# `Ash.Notifier`
[🔗](https://github.com/ash-project/ash/blob/v3.17.1/lib/ash/notifier/notifier.ex#L5)

A notifier is an extension that receives various events

# `load`
*optional* 

```elixir
@callback load(Ash.Resource.t(), Ash.Resource.Actions.action()) ::
  atom() | [atom()] | Keyword.t()
```

A load statement to be applied before this notifier receives the notification.

The loaded fields are merged onto `notification.data` before `notify/1` is called.
If multiple notifiers request the same fields with the same arguments, the
calculation dependency resolver ensures they are only loaded once.

The return value can be anything accepted by `Ash.Query.load/2`, including
`%Ash.Query.Calculation{}` structs for multi-level dependency resolution
(e.g. a PubSub notifier building one inner load per publication).

# `notify`

```elixir
@callback notify(Ash.Notifier.Notification.t()) :: :ok
```

# `requires_original_data?`

```elixir
@callback requires_original_data?(Ash.Resource.t(), Ash.Resource.Actions.action()) ::
  boolean()
```

# `notify`

```elixir
@spec notify([Ash.Notifier.Notification.t()] | Ash.Notifier.Notification.t()) :: [
  Ash.Notifier.Notification.t()
]
```

Sends any notifications that can be sent, and returns the rest.

A notification can only be sent if you are not currently in a transaction
for the resource in question.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
