Skip to content

OUTLOOK update MFA #1150

Answered by dividduang
dividduang asked this question in Q&A
Dec 7, 2022 · 5 comments · 7 replies
Discussion options

You must be logged in to vote
def Email(to,cc_mail,subject, body, attachmentspath=None):

    creds = Credentials(
        username='xxxxx@xxxxxxcom',  # 账号
        password='xxxxxxxxxxx'  # 密码
    )
    account = Account(
        primary_smtp_address='*******@*********.com',  
        credentials=creds,
        autodiscover=True,
        access_type=DELEGATE
    )
    m = Message(
        account=account,
        cc_recipients=cc_mail,
        subject=subject,
        body=HTMLBody(body),
        to_recipients=[Mailbox(email_address=to)]
    )

im successful!!!!!!!!!!!
thx!!!love u 

Replies: 5 comments 7 replies

Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
4 replies
@ecederstrand
Comment options

@dividduang
Comment options

@ecederstrand
Comment options

@dividduang
Comment options

Comment options

You must be logged in to vote
3 replies
@ecederstrand
Comment options

@dividduang
Comment options

@dividduang
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by dividduang
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants