# `Mailcast.Swoosh.Adapter`
[🔗](https://github.com/mailcastio/mailcast-elixir/blob/0.0.8/lib/swoosh/adapter.ex#L2)

Adapter module to configure Swoosh to send emails via Mailcast.

To configure your Mailer, specify the adapter and a Mailcast API key:

```ex
config :my_app, MyApp.Mailer,
  adapter: Mailcast.Swoosh.Adapter,
  api_key: "mailcast_prod_5nn4ohz3lg2yrz4tk5wdaqwvtxpylxrduresdbd2xkoqm"
```

If you're configuring your app for production, configure your adapter in `prod.exs`, and
your API key from the environment in `runtime.exs`:

```ex
# prod.exs
config :my_app, MyApp.Mailer, adapter: Mailcast.Swoosh.Adapter
```

```ex
# runtime.exs
config :my_app, MyApp.Mailer, api_key: "mailcast_prod_5nn4ohz3lg2yrz4tk5wdaqwvtxpylxrduresdbd2xkoqm"
```

## Provider Options

  * `:tags` ([%{"name" => string, "value" => string}, ...]) - tags to add to the email

  * `:data` (map) - data to be used in the template language

  * `:transactional` (boolean) - indicates if the email is transactional

  * `:template_id` (string) - id of the template to use

# `deliver`

# `deliver_many`

# `validate_config`

# `validate_dependency`

---

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