# `MailglassAdmin.Inbound.DestructiveAction`
[🔗](https://github.com/szTheory/mailglass/blob/v1.2.0/lib/mailglass_admin/inbound/destructive_action.ex#L1)

Action-time authorization helper for destructive inbound work (replay).

Sibling of `MailglassAdmin.Operator.DestructiveAction` (D-48-10 / D-48-13). Rides
the existing `MailglassAdmin.Auth.authorize/3` `atom()` action type — NO new auth
surface — with action `:replay_inbound`, and passes the record under the
`:inbound_record` context key, NEVER `:delivery`. An adopter `Auth` implementation
may pattern-match `%Mailglass.Outbound.Delivery{}` on the `:delivery` key, so an
inbound record under that key would silently misclassify.

# `authorize`

```elixir
@spec authorize(Phoenix.LiveView.Socket.t(), module() | nil, map()) ::
  {:ok, Phoenix.LiveView.Socket.t()} | {:error, {:auth, String.t()}}
```

---

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