# Email DSN configuring Amazon SES-API error

**URL:** https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923
**Category:** Product Support
**Created:** [May 1, 2024, 9:16am UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923 "2024-05-01T09:16:00Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![feelwacom](https://avatars.discourse-cdn.com/v4/letter/f/c37758/32.png) [@feelwacom](https://forum.mautic.org/u/feelwacom)
#### Post date: [May 1, 2024, 9:16am UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/1 "2024-05-01T09:16:00Z")

</div>

**Your software**  
My Mautic version is: 5.0.4  
My PHP version is: 8.1.27  
My Database type and version is: mysql Ver 15.1 Distrib 10.5.23-MariaDB, for Linux (x86\_64) using EditLine wrapper

**Your problem**  
My problem is: Is that after installing Mautic in AWS EC2 with AWS Linux I got error in configuring the email settings with AWS SES

These errors are showing in the log:

Here are the errors I got:

![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/5/51b6372950985fe2707759f532f2e92d2a78a573.png)

after installing the amazon-mailer:

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/3/31334fe27119003aff6f8666d1726f40765592f5.png)

Steps I have tried to fix the problem:

work on which is the next thing to proceed in this error I have installed everything and I need some steps further I even created another policy on Amazon SES.

---

<div class="post-metadata">

### Author: ![feelwacom](https://avatars.discourse-cdn.com/v4/letter/f/c37758/32.png) [@feelwacom](https://forum.mautic.org/u/feelwacom)
#### Post date: [May 1, 2024, 3:20pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/2 "2024-05-01T15:20:09Z")

</div>

![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/7/7b845c9b001aba72066d8830063074dde2fd8343.png)

error when I installit

---

<div class="post-metadata">

### Author: ![feelwacom](https://avatars.discourse-cdn.com/v4/letter/f/c37758/32.png) [@feelwacom](https://forum.mautic.org/u/feelwacom)
#### Post date: [May 1, 2024, 4:23pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/3 "2024-05-01T16:23:20Z")

</div>

Got this error:

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/8/803242f9ac20e23107b2c58a9f1303e554c72b43.png)

---

<div class="post-metadata">

### Author: ![expert](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/expert/32/1865_2.png) [@expert](https://forum.mautic.org/u/expert)
#### Post date: [July 4, 2024, 9:59am UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/4 "2024-07-04T09:59:54Z")

</div>

After migration from Mautic 4.1.11 to 5.1 our AWS SES email configuration was not working anymore. As a result campaigns got paused and all test mails resulted in errors.

After some investigation we found out that the DSN field in the email settings contained ‘mautic.transport.amazon’. After only changing this field to ‘smtp’ the email configuration started to work again. Only had to start the paused campaigns again.

Hope this helps.

---

<div class="post-metadata">

### Author: ![marketing.fibra](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/marketing.fibra/32/13025_2.png) [@marketing.fibra](https://forum.mautic.org/u/marketing.fibra)
#### Post date: [November 6, 2024, 8:55pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/5 "2024-11-06T20:55:59Z")

</div>

![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/9/9a6fea86db8f7fda6ddeeb6534b98c95231726b7.png)

I need help, I tested all configurations and even tried updating Symfony, but I couldn’t solve the problem. Thank you in advance."

---

<div class="post-metadata">

### Author: ![matbcvo](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/matbcvo/32/6285_2.png) [@matbcvo](https://forum.mautic.org/u/matbcvo)
#### Post date: [November 8, 2024, 2:19pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/6 "2024-11-08T14:19:05Z")

</div>

If you want to use SES API, then set **Host** to “default” and add option for region like below image.

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/d/dacf5d2244f83cfba40ff2d522d05e97c3d0ec08.png)

Make sure you have installed mailer that supports SES API like `symfony/amazon-mailer`.  
It can be installed with `composer require symfony/amazon-mailer` and then clear cache with `php bin/console cache:clear`.

---

<div class="post-metadata">

### Author: ![marketing.fibra](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/marketing.fibra/32/13025_2.png) [@marketing.fibra](https://forum.mautic.org/u/marketing.fibra)
#### Post date: [November 8, 2024, 4:47pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/7 "2024-11-08T16:47:17Z")

</div>

> [@matbcvo](#):
>
> composer require symfony/amazon-mailer

I’m trying to run the command composer require symfony where my project is, which is on a shared server."

Problem 1  
- symfony/redis-messenger v6.0.19 requires ext-redis \* → it is missing from your system. Install or enable PHP’s re dis extension.  
- mautic/core-lib 5.0.0-dev requires symfony/messenger ~5.4 → satisfiable by symfony/messenger[v5.4.35].  
- symfony/messenger v5.4.35 requires symfony/redis-messenger ^5.1|^6.0 → satisfiable by symfony/redis-messenger[v6. 0.19].  
- Root composer.json requires mautic/core-lib ^5.0 → satisfiable by mautic/core-lib[5.0.0-dev].

To enable extensions, verify that they are enabled in your .ini files:  
- /opt/cpanel/ea-php82/root/etc/php.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/10-opcache.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-bcmath.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-bz2.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-calendar.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-ctype.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-curl.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-dom.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-exif.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-fileinfo.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-ftp.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-gd.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-gettext.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-gmp.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-iconv.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-imap.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-intl.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-mbstring.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-mysqlnd.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-odbc.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-pdo.ini  
- /opt/cpanel/ea-php82/root/etc/php.d/20-pgsql.ini

You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.  
Alternatively, you can run Composer with `--ignore-platform-req=ext-redis` to temporarily ignore these required extensio ns.  
You can also try re-running composer require with an explicit version constraint, e.g. “composer require symfony/amazon- mailer:\*” to figure out if any version is installable, or “composer require symfony/amazon-mailer:^2.1” if you know whic h you need.

Installation failed, reverting ./composer.json and ./composer.lock to their original content.

---

<div class="post-metadata">

### Author: ![matbcvo](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/matbcvo/32/6285_2.png) [@matbcvo](https://forum.mautic.org/u/matbcvo)
#### Post date: [November 8, 2024, 5:27pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/8 "2024-11-08T17:27:56Z")

</div>

Can you try with `--ignore-platform-reqs`?  
eg `composer require symfony/amazon-mailer --ignore-platform-reqs`

---

<div class="post-metadata">

### Author: ![marketing.fibra](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/marketing.fibra/32/13025_2.png) [@marketing.fibra](https://forum.mautic.org/u/marketing.fibra)
#### Post date: [November 8, 2024, 5:53pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/9 "2024-11-08T17:53:30Z")

</div>

different error

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/4/4e8bd73c6989c41f7f2498c723a0f2ad7a80455a.png)

---

<div class="post-metadata">

### Author: ![matbcvo](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/matbcvo/32/6285_2.png) [@matbcvo](https://forum.mautic.org/u/matbcvo)
#### Post date: [November 8, 2024, 6:06pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/10 "2024-11-08T18:06:17Z")

</div>

At this point just use `pm-pmaas/etailors_amazon_ses` which can be installed without composer.

Steps:

1. Go to `plugins` folder with `cd plugins`
2. Clone `pm-pmaas/etailors_amazon_ses` repository into plugins folder with `git clone https://github.com/pm-pmaas/etailors_amazon_ses.git AmazonSesBundle`  
There should be now new folder named `AmazonSesBundle` in `plugins` folder.
3. Go back to Mautic root folder with `cd ..`
4. Clear Mautic cache with `php bin/console cache:clear`
5. Set scheme to `mautic+ses+api` instead of `ses+api`

---

<div class="post-metadata">

### Author: ![matbcvo](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/matbcvo/32/6285_2.png) [@matbcvo](https://forum.mautic.org/u/matbcvo)
#### Post date: [November 8, 2024, 6:14pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/11 "2024-11-08T18:14:37Z")

</div>

After clearing Mautic cache, go **Settings** → **Integrations** → **Plugins** → Click on **Install/Upgrade Plugins** button, it should list **Amazon SES** after that

---

<div class="post-metadata">

### Author: ![marketing.fibra](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/marketing.fibra/32/13025_2.png) [@marketing.fibra](https://forum.mautic.org/u/marketing.fibra)
#### Post date: [November 8, 2024, 6:25pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/12 "2024-11-08T18:25:11Z")

</div>

![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/3/36dc0d21c16ed8630dc43db1a6f11b2a28b2256b.png)

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/8/848e9aea7ba9d97fe93a0c383fdd48f5a2dc81de.png)

Now, when I set it to mautic+ses+api an error occurs, and when I set it to ses+api the page breaks.

---

<div class="post-metadata">

### Author: ![matbcvo](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/matbcvo/32/6285_2.png) [@matbcvo](https://forum.mautic.org/u/matbcvo)
#### Post date: [November 8, 2024, 6:27pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/13 "2024-11-08T18:27:56Z")

</div>

Looks like you already have different mailer installed.  
Please delete `AmazonSESBundle`/`AmazonSesBundle` from `plugins` folder and try again these steps I provided earlier.  
Make sure there is only `AmazonSesBundle` (not `AmazonSESBundle` or anything else).

---

<div class="post-metadata">

### Author: ![matbcvo](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/matbcvo/32/6285_2.png) [@matbcvo](https://forum.mautic.org/u/matbcvo)
#### Post date: [November 8, 2024, 6:34pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/14 "2024-11-08T18:34:20Z")

</div>

This is what `pm-pmaas/etailors_amazon_ses` looks like

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/b/b738de27dbf0b2ad3d056e68b144214c10530680.png)

---

<div class="post-metadata">

### Author: ![marketing.fibra](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/marketing.fibra/32/13025_2.png) [@marketing.fibra](https://forum.mautic.org/u/marketing.fibra)
#### Post date: [November 8, 2024, 7:17pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/15 "2024-11-08T19:17:12Z")

</div>

The plugin doesn’t appear, but it seems to be active because the error now was different.

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/8/89109a8fb4122472a444b2ad75103dfedfe73246.png)

---

<div class="post-metadata">

### Author: ![matbcvo](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/matbcvo/32/6285_2.png) [@matbcvo](https://forum.mautic.org/u/matbcvo)
#### Post date: [November 8, 2024, 7:23pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/16 "2024-11-08T19:23:31Z")

</div>

Set **Host** to “default”  
Set **Port** to empty

DSN should look like `mautic+ses+api://<AWS_ACCESS_KEY>:<AWS_SECRET_KEY>@default?region=<AWS_REGION>`

---

<div class="post-metadata">

### Author: ![marketing.fibra](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/marketing.fibra/32/13025_2.png) [@marketing.fibra](https://forum.mautic.org/u/marketing.fibra)
#### Post date: [November 8, 2024, 7:57pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/17 "2024-11-08T19:57:10Z")

</div>

![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/6/6d0cae9e95909ed201f1be255c2a2965976dfe78.png)  
Where can I check the log?

---

<div class="post-metadata">

### Author: ![matbcvo](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/matbcvo/32/6285_2.png) [@matbcvo](https://forum.mautic.org/u/matbcvo)
#### Post date: [November 8, 2024, 8:07pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/18 "2024-11-08T20:07:03Z")

</div>

You can check logs under `<Mautic root>/var/logs`

Do you have production access enabled in Amazon SES? Not in sandbox.

If credentials are for SMTP, then you need create IAM user and attach SES policy to this user, then create API credentials for this IAM user.

[![](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/8/83dcb23eeece531d0f3152f4a8dfad8c36a7a982.jpeg "Create SES API credentials for Mautic") ](https://www.youtube.com/watch?v=3FUJGFtX0Lw)

---

<div class="post-metadata">

### Author: ![marketing.fibra](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/marketing.fibra/32/13025_2.png) [@marketing.fibra](https://forum.mautic.org/u/marketing.fibra)
#### Post date: [November 12, 2024, 12:13pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/19 "2024-11-12T12:13:21Z")

</div>

[2024-11-08T18:22:57.833325+00:00] mautic.CRITICAL: Uncaught PHP Exception AsyncAws\Core\Exception\Http\NetworkException: “Could not contact remote server.” at /home2/bmdlco83/marketing.fibradobrasil.com.br/vendor/async-aws/core/src/Response.php line 161 {“exception”:“[object] (AsyncAws\Core\Exception\Http\NetworkException(code: 0): Could not contact remote server. at /home2/bmdlco83/marketing.fibradobrasil.com.br/vendor/async-aws/core/src/Response.php:161)\n[previous exception] [object] (Symfony\Component\HttpClient\Exception\TransportException(code: 0): Received HTTP/0.9 when not allowed for "[https://email-smtp.sa-east-1.amazonaws.com:465/v2/email/outbound-emails\](https://email-smtp.sa-east-1.amazonaws.com:465/v2/email/outbound-emails%5C)”. at /home2/bmdlco83/marketing.fibradobrasil.com.br/vendor/symfony/http-client/Chunk/ErrorChunk.php:65)\n[previous exception] [object] (Symfony\Component\HttpClient\Exception\TransportException(code: 0): Received HTTP/0.9 when not allowed for "[https://email-smtp.sa-east-1.amazonaws.com:465/v2/email/outbound-emails\](https://email-smtp.sa-east-1.amazonaws.com:465/v2/email/outbound-emails%5C)“. at /home2/bmdlco83/marketing.fibradobrasil.com.br/vendor/symfony/http-client/Response/CurlResponse.php:323)”} {“hostname”:“sh-pro14.hostgator.com.br”,“pid”:82227}  
[2024-11-08T18:23:35.219936+00:00] mautic.CRITICAL: Uncaught PHP Exception AsyncAws\Core\Exception\Http\NetworkException: “Could not contact remote server.” at /home2/bmdlco83/marketing.fibradobrasil.com.br/vendor/async-aws/core/src/Response.php line 161 {“exception”:“[object] (AsyncAws\Core\Exception\Http\NetworkException(code: 0): Could not contact remote server. at /home2/bmdlco83/marketing.fibradobrasil.com.br/vendor/async-aws/core/src/Response.php:161)\n[previous exception] [object] (Symfony\Component\HttpClient\Exception\TransportException(code: 0): Received HTTP/0.9 when not allowed for "[https://email-smtp.sa-east-1.amazonaws.com:465/v2/email/outbound-emails\](https://email-smtp.sa-east-1.amazonaws.com:465/v2/email/outbound-emails%5C)”. at /home2/bmdlco83/marketing.fibradobrasil.com.br/vendor/symfony/http-client/Chunk/ErrorChunk.php:65)\n[previous exception] [object] (Symfony\Component\HttpClient\Exception\TransportException(code: 0): Received HTTP/0.9 when not allowed for "[https://email-smtp.sa-east-1.amazonaws.com:465/v2/email/outbound-emails\](https://email-smtp.sa-east-1.amazonaws.com:465/v2/email/outbound-emails%5C)“. at /home2/bmdlco83/marketing.fibradobrasil.com.br/vendor/symfony/http-client/Response/CurlResponse.php:323)”} {“hostname”:“sh-pro14.hostgator.com.br”,“pid”:85327}

---

<div class="post-metadata">

### Author: ![marketing.fibra](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/marketing.fibra/32/13025_2.png) [@marketing.fibra](https://forum.mautic.org/u/marketing.fibra)
#### Post date: [November 12, 2024, 12:19pm UTC](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923/20 "2024-11-12T12:19:25Z")

</div>

I checked my AMAZONSES configuration, and everything is correct.

Attached is the log from my Mautic. Can you help?

[Next page](https://forum.mautic.org/t/email-dsn-configuring-amazon-ses-api-error/31923.md?page=2)
