Read office365 e-mails etc in PHP

Job ID: 36838786

Budget: $70 – $71 USD

Before Gabohost (Godaddy) partnered up with Microsoft office365, I was able to access my email via PHP by connecting with:

$mbox = imap_open( "{outlook.office365.com:993/imap/ssl}INBOX" , $username, $password)

Now this code gives me error: "Can not authenticate to IMAP server: AUTHENTICATE failed."
This is because office365 no longer allows "Basic Authentication".

GOAL:
=====
What I am trying to accomplish, is a code that is VERY similar to the PHP file I included in this project.
I want to be able to:

* Search for emails (loop through)
* Copy/Move emails from one folder to another
* Mark emails as "Answered" etc
It does not need to send e-mails.

I prefer not using 3rd party tools and just use pure PHP code. If however this TRULY is not possible, please put all these files in to a folder and the main PHP file in the root (outside this folder). Please do not put the main php file (where I enter my credentials) inside that folder. This project should work without me having to install a composer or anything myself.


PRIVACY:
=========
Each time you send me files to review, all of them will be checked to see if there's ANY attempts to steal my login and password and if so you will be reported.


PAYMENT:
========
Each time you think your code is ready, you can send it to me and I'll enter my cred. and test it. If all features work, I'll release payment. No exception please


Kindly view the test.php attached here and only contact me if you are VERY familiar with emails in PHP and oauth with Microsoft.
This should NOT be an experiment where you figure it out.
Also I don't need to migrate. I can access my email fine on browser and phone etc.
Thank you very much :)
Related categories: PHP OAuth Office 365 IMAP