title: Google Adword API + PHP
body: <p>Hai I am trying to integrate Google Adword API .. I am not having any devloper token for under MCC (My client center) account .</p>
  
  <p>I am using this code ... But its not working 
  If you have any answer for this problem then please help me ... thanks in advance</p>
  
  <pre><code>&lt;?php 
  require_once 'Google/Api/Ads/AdWords/Lib/AdWordsUser.php';
  
  $username = "abc@mail.com";
  $password = "abc";
  $currencyCode = "USD";
  $developerToken = "$username++$currencyCode";
  
  $user = new AdWordsUser(null, $username, $password, $developerToken);
  $user-&gt;SetDefaultServer("https://adwords-sandbox.google.com/");
  $user-&gt;LogAll();
  $user-&gt;SetClientId(null);
  
  try {
      $campaignService = $user-&gt;GetService("CampaignService", 'v201306');
      $page = $campaignService-&gt;get(new Selector());
  } catch (Exception $e) {
  
  }
  
  $managedCustomerService = $user-&gt;GetService('ManagedCustomerService', 'v201306');
  $selector = new Selector();
  $selector-&gt;fields = array('Login', 'CustomerId', 'Name');
  $page = $managedCustomerService-&gt;get($selector);
  
  $accounts = array();
  foreach ($page-&gt;entries as $account) {
      if ($account-&gt;customerId &gt; 0) {
          $accounts[] = $account;
      }
  }
  
  foreach ($accounts as $account) {
      print "Customer ID: {$account-&gt;customerId}\n";
  }
  
  $customerId = $accounts[0]-&gt;customerId;
  $user-&gt;SetClientId($customerId);
  
  $budgetService = $user-&gt;GetService('BudgetService', 'v201306');
  
  $budget = new Budget();
  $budget-&gt;name = 'Test Budget #' . time();
  $budget-&gt;period = 'DAILY';
  $budget-&gt;amount = new Money((float) 10000000);
  $budget-&gt;deliveryMethod = 'STANDARD';
  
  $operations = array();
  
  $operation = new BudgetOperation();
  $operation-&gt;operand = $budget;
  $operation-&gt;operator = 'ADD';
  $operations[] = $operation;
  
  $result = $budgetService-&gt;mutate($operations);
  $budget = $result-&gt;value[0];
  
  $campaignService = $user-&gt;GetService("CampaignService", 'v201306');
  
  $campaign = new Campaign();
  $campaign-&gt;name = "Test Sandbox Account #" + time();
  $campaign-&gt;status = "ACTIVE";
  $campaign-&gt;biddingStrategy = new ManualCPC();
  
  $campaign-&gt;budget = new Budget();
  $campaign-&gt;budget-&gt;budgetId = $budget-&gt;budgetId;
  
  $networkSetting = new NetworkSetting();
  $networkSetting-&gt;targetGoogleSearch = TRUE;
  $campaign-&gt;networkSetting = $networkSetting;
  
  $campaign-&gt;settings = array(new KeywordMatchSetting(false));
  
  $operation = new CampaignOperation();
  $operation-&gt;operand = $campaign;
  $operation-&gt;operator = 'ADD';
  
  $operations = array($operation);
  $result = $campaignService-&gt;mutate($operations);
  
  print_r($result);
  ?&gt;
  </code></pre>
  
  <p>I am getting this error ::</p>
  
  <pre><code>Fatal error: Uncaught SoapFault exception: [WSDL] SOAP-ERROR: Parsing WSDL: Couldn't load from 'https://adwords-sandbox.google.com//api/adwords/mcm/v201306/ManagedCustomerService?wsdl' : failed to load external entity "https://adwords-sandbox.google.com//api/adwords/mcm/v201306/ManagedCustomerService?wsdl" in /home/profiles/public_html/testing/seoteam/q/src/Google/Api/Ads/Common/Lib/AdsSoapClient.php:169 Stack trace: #0 /home/profiles/public_html/testing/seoteam/q/src/Google/Api/Ads/Common/Lib/AdsSoapClient.php(169): SoapClient-&gt;SoapClient('https://adwords...', Array) #1 /home/profiles/public_html/testing/seoteam/q/src/Google/Api/Ads/AdWords/Lib/AdWordsSoapClient.php(53): AdsSoapClient-&gt;__construct('https://adwords...', Array, Object(AdWordsUser), 'ManagedCustomer...', 'https://adwords...') #2 /home/profiles/public_html/testing/seoteam/q/src/Google/Api/Ads/AdWords/v201306/ManagedCustomerService.php(3660): AdWordsSoapClient-&gt;__construct('https://adwords...', Array, Object(AdWordsUser), 'ManagedCustomer...', 'https://adwor in /home/profiles/public_html/testing/seoteam/q/src/Google/Api/Ads/Common/Lib/AdsSoapClient.php on line 169
  </code></pre>