I'm using the php library https://github.com/vgrem/phpSPO to connect my symfony application to our sharepoint online. This is working fine with normal username and password authentication. But I would like to use oauth to login.

I have tried another library but this one is outdated. https://github.com/golincode/sharepoint-oauth-app-client

In the example code from vrgrem/phpspo I keep seeing username and password to make connection. But I can't seem to find the way to make connection with oauth.

$authCtx = new AuthenticationContext($Url);
$authCtx->acquireTokenForUser($UserName,$Password); //authenticate

Is it possible to connect with oauth and vrgem/phpSPO? Has anyone done this before?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.