PHP code example of nholdren / marketing-cloud-php-soap

1. Go to this page and download the library: Download nholdren/marketing-cloud-php-soap library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

nholdren / marketing-cloud-php-soap example snippets



$wsdl = 'https:/YOUR-TENANT-ID.soap.marketingcloudapis.com/etframework.wsdl';

$client = new MarketingCloudSoapClient($wsdl, array('trace'=>1));

//Set username and password if still using this auth
$client->username = 'YOUR_USERNAME';
$client->password = 'YOUR_PASSWORD';

//Or pass your auth token instead
$client->username = '*';
$client->password = '*';
$client->authtoken = 'YOUR-AUTH-TOKEN';        

$ php composer.phar update nholdren/marketing-cloud-php-soap

$ composer update nholdren/marketing-cloud-php-soap