aws / aws-sdk-net

The official AWS SDK for .NET. For more information on the AWS SDK for .NET, see our web site:
http://aws.amazon.com/sdkfornet/
Apache License 2.0
2.05k stars 852 forks source link

simpleemailv2 not exposing Source #1711

Closed rogerfar closed 4 years ago

rogerfar commented 4 years ago

Currently in the simpleemailv2 the Source property on SendEmailRequest is not available.

Original: https://docs.aws.amazon.com/sdkfornet/v3/apidocs/items/SimpleEmailV2/TSendEmailRequest.html

v2: https://docs.aws.amazon.com/sdkfornet/v3/apidocs/items/SimpleEmailV2/TSendEmailRequest.html

Currently there is no way to specify the from name in an email request with v2.

ashishdhingra commented 4 years ago

Hi @rogerfar,

Good morning.

Please refer the SES V2 API documentation for SendEmail, FromEmailAddress is one of the new parameters. There is no Source parameter in the new service API. The .NET SDK SendEmailRequest (V2) class is generated as per the new Service API, hence, this is per design.

Hope this provides guidance to your concern. Please let me know if we could close this issue.

Thanks, Ashish

rogerfar commented 4 years ago

Hello Ashish,

That is correct, but where do I specify the name? Before you could set the source property to: My Name <name@domain.com>, in v2 there is no option to specify the name.

ashishdhingra commented 4 years ago

@rogerfar Could you please confirm if using the same format in FromEmailAddress property works? If not, we might need to seek inputs from SES V2 support to provide guidance since this property is limited by the Service API.

Thanks, Ashish

rogerfar commented 4 years ago

Yes this seems to be the case.

When I set the same format in the FromEmailAddress field it will accept the My Name <name@domain.com> format.

This is not clear from documentation though.

The v2 docs state for FromEmailAddress:

Gets and sets the property FromEmailAddress.The email address that you want to use as the "From" address for the email. The address that you specify has to be verified.

The v1 docs state for Source:

The email address that is sending the email. This email address must be either individually verified with Amazon SES, or from a domain that has been verified with Amazon SES. For information about verifying identities, see the Amazon SES Developer Guide.If you are sending on behalf of another user and have been permitted to do so by a sending authorization policy, then you must also specify the SourceArn parameter. For more information about sending authorization, see the Amazon SES Developer Guide.Amazon SES does not support the SMTPUTF8 extension, as described in RFC6531. For this reason, the local part of a source email address (the part of the email address that precedes the @ sign) may only contain 7-bit ASCII characters. If the domain part of an address (the part after the @ sign) contains non-ASCII characters, they must be encoded using Punycode, as described in RFC3492. The sender name (also known as the friendly name) may contain non-ASCII characters. These characters must be encoded using MIME encoded-word syntax, as described in RFC 2047. MIME encoded-word syntax uses the following form: =?charset?encoding?encoded-text?=.

The latter explicitly mentions the "friend name" part of the email can be added, but does it not present in the v2 documentation.

ashishdhingra commented 4 years ago

@rogerfar Thanks for confirming the issue. I will close this issue. Please use the "Provide Feedback" link on the bottom of the documentation page to submit your feedback to add such a note in the new documentation.