Skip to main content

How to Fix an AWS SES Connection Error

When you connect Amazon SES to LetterPress with an AWS access key, the connection test can fail with this message:

AWS rejected the credentials. Check the access key,
secret key and that the key has ses:SendEmail
and ses:GetAccount permissions.

The message points at the credentials, but the keys are often fine. A missing IAM permission is the most common cause. LetterPress asks SES for account details when it tests the connection, and that request needs ses:GetAccount.

This guide shows you how to check the common causes and add the missing permission without creating a new access key.

Common causes​

  • The access key ID or secret access key is wrong.
  • The key belongs to a different AWS account than the one that owns your SES identity.
  • The IAM user is missing ses:SendEmail or ses:GetAccount.
  • The AWS region in LetterPress does not match the region where your SES identity is verified.
  • SES is still in the sandbox and the recipient address is not verified.

The steps below fix the permission case. If you recently created the key, start there.

Before you start​

You need:

  • Access to the AWS account that owns your SES identity.
  • The IAM user that matches the access key in LetterPress.
  • Permission to create and attach IAM policies.

Step 1: Find the IAM user behind your access key​

  1. Sign in to the AWS Management Console.
  2. Open IAM > Users.
  3. Select the user whose access key you entered in LetterPress.
  4. Open the Permissions tab.

Add the policy to this user. Adding it to a different user or the root account will not fix the connection.

The letterpress-sender IAM user with the Permissions tab open and Add permissions highlighted Open the user's Permissions tab, then choose Add permissions.

Step 2: Create the SES policy​

  1. Open IAM > Policies.
  2. Click Create policy.
  3. Open the JSON editor.
  4. Replace the existing JSON with this policy:
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"ses:SendEmail",
"ses:GetAccount",
"ses:GetEmailIdentity"
],
"Resource": "*"
}
]
}
  1. Click Next.
  2. Name the policy LetterPressSESPermissions.
  3. Create the policy.

Here is what each permission does:

  • ses:SendEmail lets LetterPress send email through the SES API.
  • ses:GetAccount lets LetterPress read account details and sending quota during the connection test.
  • ses:GetEmailIdentity lets LetterPress check whether your sender identity is verified and whether DKIM is active. The connection test can pass without it, but the identity status will be blank.

The IAM JSON policy editor with the LetterPress SES permissions policy Paste the policy into the JSON editor, then continue to review.

Step 3: Attach the policy to your IAM user​

Creating a policy does not grant access on its own. You still need to attach it.

  1. Go back to IAM > Users.
  2. Select the same user.
  3. Open the Permissions tab.
  4. Click Add permissions.
  5. Choose Attach policies directly.
  6. Search for LetterPressSESPermissions.
  7. Select the policy and click Next.
  8. On the review screen, click Add permissions.

IAM usually applies the policy within a few seconds. You do not need to create a new access key.

The Attach policies directly screen with the LetterPressSESPermissions policy selected Choose Attach policies directly, select the policy, and continue.

Step 4: Test the connection in LetterPress​

  1. Open LetterPress > Settings > Email providers.
  2. Choose Amazon SES.
  3. Enter your AWS Access Key ID and Secret Access Key.
  4. Select the AWS region where your SES identity is verified.
  5. Save your changes and run Test connection.

SES is regional. A domain verified in one region is not automatically available in another. If your identity is in US East (N. Virginia), choose us-east-1 in LetterPress.

The test should now pass and show your SES sending quota.

Why does ses:GetAccount matter?​

LetterPress validates the SES connection by calling the account endpoint (GET /v2/email/account). That call returns your sending quota and requires ses:GetAccount.

Permission to send email does not include permission to read account details. Without ses:GetAccount, AWS returns a 403 response. LetterPress sees the failed account check and shows the credential error, even when the key can send email.

LetterPress also looks up your sender identity for verification and DKIM status. That lookup uses ses:GetEmailIdentity. If the permission is missing, the connection test can still pass, but the identity details will not appear.

Security notes​

  • Use a dedicated IAM user for LetterPress. Do not use your AWS root account.
  • Scope the policy to your verified SES identity when you can. For production, replace Resource: "*" on the send and identity actions with the ARN of your identity. ses:GetAccount still needs *.
  • Rotate access keys on a schedule and delete keys you no longer use.
  • Keep SES API keys separate from SES SMTP credentials.
  • Never paste access keys into a support ticket, screenshot, or public issue.

Conclusion​

If the access key and secret key are correct, check IAM before you regenerate them. Adding ses:GetAccount to the user's policy is often the missing step.