> ## Documentation Index
> Fetch the complete documentation index at: https://docs.automate.ax/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Automate.ax automations are TypeScript programs.
> Use Bun for installation and command examples.
> Use Automate.ax for the product name and automate.ax for the package, CLI, and domain.
> Treat documented public APIs as current; do not invent transitional or deprecated names.

# On marketing email marked as spam

> Run an automation when a recipient reports a marketing email as spam.

`brevo.onMarketingEmailMarkedAsSpam` runs when a recipient reports a marketing email as spam.

## Example

```ts theme={null}
import { automation, log, t } from "automate.ax"
import { brevo } from "automate.ax/brevo"

export default automation("Handle Brevo marketing email marked as spam", () => {
  const event = brevo.onMarketingEmailMarkedAsSpam()
  log(t`Brevo marketing email marked as spam: ${event.messageId}`)
})
```

## Options

`account?: string | IntegrationAccountReference<"brevo">` selects a static Brevo API-key binding and defaults to the project binding. Runtime signals cannot select the watched account.

## Trigger data

Returns a normalized event with `family: "marketingEmail"`, `type: "markedAsSpam"`, `webhookId`, and the complete provider callback in `event`. Provider-dependent fields can include `email`, `phone`, `messageId`, `campaignId`, `occurredAt`, `status`, `reason`, `link`, `reply`, and `listIds`.

Suppress future marketing sends where required. Automate.ax authenticates the managed webhook and deduplicates exact callback retries.
