Enforced TLS

The Enforced TLS settings specify whether or not the recipient is required to support TLS or have a valid certificate. The Enforced TLS endpoint supports retrieving and updating TLS settings.

If either require_tls or require_valid_cert is set to true, the recipient must support TLS 1.1 or higher or have a valid certificate. If these conditions are not met, we drop the message and send a block event with “TLS required but not supported” as the description.

GET

Get the current Enforced TLS settings.

Request URL

GET https://api.sendgrid.com/v3/user/settings/enforced_tls HTTP/1.1

Response

HTTP/1.1 200
{
    "require_tls": true,
    "require_valid_cert": false,
    "version": 1.1
}

PATCH

Change the Enforced TLS settings

URI Parameter Required Requirements Description
require_tls False true or false Require recipient TLS support
require_valid_cert False true or false Require certificates to be valid
version False 1.1, 1.2, 1.3 The minimum required TLS certificate version.

Request URL

PATCH https://api.sendgrid.com/v3/user/settings/enforced_tls HTTP/1.1

Request Body

{
  "require_tls": true
}

Response

HTTP/1.1 200
{
    "require_tls": true,
    "require_valid_cert": false,
    "version": 1.1
}
Rate this page:

Need some help?

We all do sometimes. Get help now from the Twilio SendGrid Support Team.

Running into a coding hurdle? Lean on the wisdom of the crowd by browsing the SendGrid tag on Stack Overflow or visiting Twilio's Stack Overflow Collective.

Thank you for your feedback!

Please select the reason(s) for your feedback. The additional information you provide helps us improve our documentation:

Sending your feedback...
🎉 Thank you for your feedback!
Something went wrong. Please try again.

Thanks for your feedback!

Refer us and get $10 in 3 simple steps!

Step 1

Get link

Get a free personal referral link here

Step 2

Give $10

Your user signs up and upgrade using link

Step 3

Get $10

1,250 free SMSes
OR 1,000 free voice mins
OR 12,000 chats
OR more