Used to enable or disable DKIM authentication for an email identity.
Parameters:
-
email_identity
(Identity)
–
The email identity that you want to change the DKIM settings for.
-
signing_enabled
(Optional[Enabled], default:
None
)
–
Sets the DKIM signing configuration for the identity.
When you set this value true, then the messages that Amazon Pinpoint sends from the identity are DKIM-signed. When you set this value to false, then the messages that Amazon Pinpoint sends from the identity aren't DKIM-signed.
Raises:
Source code in docs_src/capo_pinpoint_email/_services/async_pinpoint_email.py
| async def put_email_identity_dkim_attributes(
self,
email_identity: "capo_pinpoint_email.types.identity.Identity",
*,
config_overrides: Optional[AsyncPinpointEmailClientConfig] = None,
signing_enabled: Optional["capo_pinpoint_email.types.enabled.Enabled"] = None,
) -> "capo_pinpoint_email.types.put_email_identity_dkim_attributes_response.PutEmailIdentityDkimAttributesResponse":
"""<p>Used to enable or disable DKIM authentication for an email identity.</p>
Args:
email_identity: <p>The email identity that you want to change the DKIM settings for.</p>
signing_enabled: <p>Sets the DKIM signing configuration for the identity.</p> <p>When you set this value <code>true</code>, then the messages that Amazon Pinpoint sends from the identity are DKIM-signed. When you set this value to <code>false</code>, then the messages that Amazon Pinpoint sends from the identity aren't DKIM-signed.</p>
Raises:
capo_pinpoint_email.errors.bad_request_exception.BadRequestException: <p>The input you provided is invalid.</p>
capo_pinpoint_email.errors.not_found_exception.NotFoundException: <p>The resource you attempted to access doesn't exist.</p>
capo_pinpoint_email.errors.too_many_requests_exception.TooManyRequestsException: <p>Too many requests have been made to the operation.</p>
capo_pinpoint_email.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_pinpoint_email.types.put_email_identity_dkim_attributes_request.PutEmailIdentityDkimAttributesRequest]",
) -> AsyncOperationResponse[
"capo_pinpoint_email.types.put_email_identity_dkim_attributes_response.PutEmailIdentityDkimAttributesResponse"
]:
import capo_pinpoint_email._operations.amazon_pinpoint_email_service.put_email_identity_dkim_attributes
(
output,
http_response,
) = await capo_pinpoint_email._operations.amazon_pinpoint_email_service.put_email_identity_dkim_attributes.async_put_email_identity_dkim_attributes(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("PutEmailIdentityDkimAttributes")
)
input_: capo_pinpoint_email.types.put_email_identity_dkim_attributes_request.PutEmailIdentityDkimAttributesRequest = {
"email_identity": email_identity
}
if signing_enabled is not None:
input_["signing_enabled"] = signing_enabled
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|