Skip to content

SESClient#

Index > SES > SESClient

Auto-generated documentation for SES type annotations stubs module mypy-boto3-ses.

SESClient#

Type annotations and code completion for boto3.client("ses"). boto3 documentation

# SESClient usage example

from boto3.session import Session
from mypy_boto3_ses.client import SESClient

def get_ses_client() -> SESClient:
    return Session().client("ses")

Exceptions#

boto3 client exceptions are generated in runtime. This class provides code completion for boto3.client("ses").exceptions structure.

# Exceptions.exceptions usage example

client = boto3.client("ses")

try:
    do_something(client)
except (
    client.exceptions.AccountSendingPausedException,
    client.exceptions.AlreadyExistsException,
    client.exceptions.CannotDeleteException,
    client.exceptions.ClientError,
    client.exceptions.ConfigurationSetAlreadyExistsException,
    client.exceptions.ConfigurationSetDoesNotExistException,
    client.exceptions.ConfigurationSetSendingPausedException,
    client.exceptions.CustomVerificationEmailInvalidContentException,
    client.exceptions.CustomVerificationEmailTemplateAlreadyExistsException,
    client.exceptions.CustomVerificationEmailTemplateDoesNotExistException,
    client.exceptions.EventDestinationAlreadyExistsException,
    client.exceptions.EventDestinationDoesNotExistException,
    client.exceptions.FromEmailAddressNotVerifiedException,
    client.exceptions.InvalidCloudWatchDestinationException,
    client.exceptions.InvalidConfigurationSetException,
    client.exceptions.InvalidDeliveryOptionsException,
    client.exceptions.InvalidFirehoseDestinationException,
    client.exceptions.InvalidLambdaFunctionException,
    client.exceptions.InvalidPolicyException,
    client.exceptions.InvalidRenderingParameterException,
    client.exceptions.InvalidS3ConfigurationException,
    client.exceptions.InvalidSNSDestinationException,
    client.exceptions.InvalidSnsTopicException,
    client.exceptions.InvalidTemplateException,
    client.exceptions.InvalidTrackingOptionsException,
    client.exceptions.LimitExceededException,
    client.exceptions.MailFromDomainNotVerifiedException,
    client.exceptions.MessageRejected,
    client.exceptions.MissingRenderingAttributeException,
    client.exceptions.ProductionAccessNotGrantedException,
    client.exceptions.RuleDoesNotExistException,
    client.exceptions.RuleSetDoesNotExistException,
    client.exceptions.TemplateDoesNotExistException,
    client.exceptions.TrackingOptionsAlreadyExistsException,
    client.exceptions.TrackingOptionsDoesNotExistException,
) as e:
    print(e)
# Exceptions.exceptions type checking example

from mypy_boto3_ses.client import Exceptions

def handle_error(exc: Exceptions.AccountSendingPausedException) -> None:
    ...

Methods#

can_paginate#

Check if an operation can be paginated.

Type annotations and code completion for boto3.client("ses").can_paginate method. boto3 documentation

# can_paginate method definition

def can_paginate(
    self,
    operation_name: str,
) -> bool:
    ...

clone_receipt_rule_set#

Creates a receipt rule set by cloning an existing one.

Type annotations and code completion for boto3.client("ses").clone_receipt_rule_set method. boto3 documentation

# clone_receipt_rule_set method definition

def clone_receipt_rule_set(
    self,
    *,
    RuleSetName: str,
    OriginalRuleSetName: str,
) -> Dict[str, Any]:
    ...
# clone_receipt_rule_set method usage example with argument unpacking

kwargs: CloneReceiptRuleSetRequestRequestTypeDef = {  # (1)
    "RuleSetName": ...,
    "OriginalRuleSetName": ...,
}

parent.clone_receipt_rule_set(**kwargs)
  1. See CloneReceiptRuleSetRequestRequestTypeDef

close#

Closes underlying endpoint connections.

Type annotations and code completion for boto3.client("ses").close method. boto3 documentation

# close method definition

def close(
    self,
) -> None:
    ...

create_configuration_set#

Creates a configuration set.

Type annotations and code completion for boto3.client("ses").create_configuration_set method. boto3 documentation

# create_configuration_set method definition

def create_configuration_set(
    self,
    *,
    ConfigurationSet: ConfigurationSetTypeDef,  # (1)
) -> Dict[str, Any]:
    ...
  1. See ConfigurationSetTypeDef
# create_configuration_set method usage example with argument unpacking

kwargs: CreateConfigurationSetRequestRequestTypeDef = {  # (1)
    "ConfigurationSet": ...,
}

parent.create_configuration_set(**kwargs)
  1. See CreateConfigurationSetRequestRequestTypeDef

create_configuration_set_event_destination#

Creates a configuration set event destination.

Type annotations and code completion for boto3.client("ses").create_configuration_set_event_destination method. boto3 documentation

# create_configuration_set_event_destination method definition

def create_configuration_set_event_destination(
    self,
    *,
    ConfigurationSetName: str,
    EventDestination: EventDestinationTypeDef,  # (1)
) -> Dict[str, Any]:
    ...
  1. See EventDestinationTypeDef
# create_configuration_set_event_destination method usage example with argument unpacking

kwargs: CreateConfigurationSetEventDestinationRequestRequestTypeDef = {  # (1)
    "ConfigurationSetName": ...,
    "EventDestination": ...,
}

parent.create_configuration_set_event_destination(**kwargs)
  1. See CreateConfigurationSetEventDestinationRequestRequestTypeDef

create_configuration_set_tracking_options#

Creates an association between a configuration set and a custom domain for open and click event tracking.

Type annotations and code completion for boto3.client("ses").create_configuration_set_tracking_options method. boto3 documentation

# create_configuration_set_tracking_options method definition

def create_configuration_set_tracking_options(
    self,
    *,
    ConfigurationSetName: str,
    TrackingOptions: TrackingOptionsTypeDef,  # (1)
) -> Dict[str, Any]:
    ...
  1. See TrackingOptionsTypeDef
# create_configuration_set_tracking_options method usage example with argument unpacking

kwargs: CreateConfigurationSetTrackingOptionsRequestRequestTypeDef = {  # (1)
    "ConfigurationSetName": ...,
    "TrackingOptions": ...,
}

parent.create_configuration_set_tracking_options(**kwargs)
  1. See CreateConfigurationSetTrackingOptionsRequestRequestTypeDef

create_custom_verification_email_template#

Creates a new custom verification email template.

Type annotations and code completion for boto3.client("ses").create_custom_verification_email_template method. boto3 documentation

# create_custom_verification_email_template method definition

def create_custom_verification_email_template(
    self,
    *,
    TemplateName: str,
    FromEmailAddress: str,
    TemplateSubject: str,
    TemplateContent: str,
    SuccessRedirectionURL: str,
    FailureRedirectionURL: str,
) -> EmptyResponseMetadataTypeDef:  # (1)
    ...
  1. See EmptyResponseMetadataTypeDef
# create_custom_verification_email_template method usage example with argument unpacking

kwargs: CreateCustomVerificationEmailTemplateRequestRequestTypeDef = {  # (1)
    "TemplateName": ...,
    "FromEmailAddress": ...,
    "TemplateSubject": ...,
    "TemplateContent": ...,
    "SuccessRedirectionURL": ...,
    "FailureRedirectionURL": ...,
}

parent.create_custom_verification_email_template(**kwargs)
  1. See CreateCustomVerificationEmailTemplateRequestRequestTypeDef

create_receipt_filter#

Creates a new IP address filter.

Type annotations and code completion for boto3.client("ses").create_receipt_filter method. boto3 documentation

# create_receipt_filter method definition

def create_receipt_filter(
    self,
    *,
    Filter: ReceiptFilterTypeDef,  # (1)
) -> Dict[str, Any]:
    ...
  1. See ReceiptFilterTypeDef
# create_receipt_filter method usage example with argument unpacking

kwargs: CreateReceiptFilterRequestRequestTypeDef = {  # (1)
    "Filter": ...,
}

parent.create_receipt_filter(**kwargs)
  1. See CreateReceiptFilterRequestRequestTypeDef

create_receipt_rule#

Creates a receipt rule.

Type annotations and code completion for boto3.client("ses").create_receipt_rule method. boto3 documentation

# create_receipt_rule method definition

def create_receipt_rule(
    self,
    *,
    RuleSetName: str,
    Rule: ReceiptRuleTypeDef,  # (1)
    After: str = ...,
) -> Dict[str, Any]:
    ...
  1. See ReceiptRuleTypeDef
# create_receipt_rule method usage example with argument unpacking

kwargs: CreateReceiptRuleRequestRequestTypeDef = {  # (1)
    "RuleSetName": ...,
    "Rule": ...,
}

parent.create_receipt_rule(**kwargs)
  1. See CreateReceiptRuleRequestRequestTypeDef

create_receipt_rule_set#

Creates an empty receipt rule set.

Type annotations and code completion for boto3.client("ses").create_receipt_rule_set method. boto3 documentation

# create_receipt_rule_set method definition

def create_receipt_rule_set(
    self,
    *,
    RuleSetName: str,
) -> Dict[str, Any]:
    ...
# create_receipt_rule_set method usage example with argument unpacking

kwargs: CreateReceiptRuleSetRequestRequestTypeDef = {  # (1)
    "RuleSetName": ...,
}

parent.create_receipt_rule_set(**kwargs)
  1. See CreateReceiptRuleSetRequestRequestTypeDef

create_template#

Creates an email template.

Type annotations and code completion for boto3.client("ses").create_template method. boto3 documentation

# create_template method definition

def create_template(
    self,
    *,
    Template: TemplateTypeDef,  # (1)
) -> Dict[str, Any]:
    ...
  1. See TemplateTypeDef
# create_template method usage example with argument unpacking

kwargs: CreateTemplateRequestRequestTypeDef = {  # (1)
    "Template": ...,
}

parent.create_template(**kwargs)
  1. See CreateTemplateRequestRequestTypeDef

delete_configuration_set#

Deletes a configuration set.

Type annotations and code completion for boto3.client("ses").delete_configuration_set method.