Google Appengine sending emails: [Error] unauthorized sender

后端 未结 4 1869
孤独总比滥情好
孤独总比滥情好 2020-12-18 22:42

I\'m trying to use google app engine\'s mail service on my site. It\'s showing some error whenever I visit the page that sends the email. The error says that I am using an

相关标签:
4条回答
  • 2020-12-18 23:01

    First follow these steps

    https://cloud.google.com/appengine/docs/python/mail/#who_can_send_mail

    Then you need to manually add the sender email in cloud console

    How to add an authorized sender

    0 讨论(0)
  • 2020-12-18 23:01

    Add the unauthorized email address as an administrator here: https://console.developers.google.com/project/_/permissions/projectpermissions

    0 讨论(0)
  • 2020-12-18 23:03

    You may also have to add the email address you which to send the email from to the App Engine application settings Email API authorized senders.

    See https://cloud.google.com/appengine/docs/python/mail/#Python_Sending_mail

    0 讨论(0)
  • 2020-12-18 23:13

    What is myapp@appspot.gserviceaccount.com? You might not be able to send mail from that address.

    App Engine applications can send email messages on behalf of the app's administrators, and on behalf of users with Google Accounts.

    The email address of the sender, the From address. The sender address must be one of the following types:

    • The address of a registered administrator for the application. You can add administrators to an application using the Administration Console.

    • The address of the user for the current request signed in with a Google Account. You can determine the current user's email address with the Users API. The user's account must be a Gmail account, or be on a domain managed by Google Apps.

    • Any valid email receiving address for the app (such as xxx@APP-ID.appspotmail.com).

    • Any valid email receiving address of a domain account, such as support@example.com. Domain accounts are accounts outside of the Google domain with email addresses that do not end in @gmail.com or @APP-ID.appspotmail.com.

    https://developers.google.com/appengine/docs/python/mail/sendingmail

    0 讨论(0)
提交回复
热议问题