I am using the library https://github.com/thybag/PHP-SharePoint-Lists-API for accessing the whole lists in SharePoint using php.

I am able to get a connection with SharePoint.I am giving the code below used by me


$sp = new SharePointAPI('[email protected]', 'Sample@nt1', 'https://sample-public.sharepoint.com/_vti_bin/Lists.asmx?WSDL',TRUE);


$data = $sp->getLists();


Here I am not able to get connection also .

It may be maintained or configured incorrectly.

I will be thankful if I solve the problem using the same above library.


1 Answer 1


Just to say, if you are using SharePoint online, it uses a different authentication method to standard SharePoint. I've now added support for it in the latest version of the library so it may be worth having a try with something like:

use Thybag\SharePointAPI;
$sp = new SharePointAPI('<username>', '<password>', '<path_to_WSDL>', 'SPONLINE');

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.