printf("%d keywords were added successfully: %s\n", sizeof($succeeded), implode(', ', $succeeded));
        printf("%d keywords were skipped and should be retried: %s\n", sizeof($skipped), implode(', ', $skipped));
        printf("%d keywords were not added due to errors:\n", sizeof($failed));
        foreach ($failed as $keywordText) {
            $errorStrings = array();
            foreach ($errors[$keywordText] as $error) {
                $errorStrings[] = $error->errorString;
            }
            printf("- %s: %s\n", $keywordText, implode(', ', $errorStrings));
        }
        printf("%d generic errors were encountered:\n", sizeof($genericErrors));
        foreach ($genericErrors as $error) {
            printf("- %s\n", $error->errorString);
        }
    }
}
// Don't run the example if the file is being included.
if (__FILE__ != realpath($_SERVER['PHP_SELF'])) {
    return;
}
try {
    // Get AdWordsUser from credentials in "../auth.ini"
    // relative to the AdWordsUser.php file's directory.
    $user = new AdWordsUser();
    // Log every SOAP XML request and response.
    $user->LogAll();
    // Run the example.
    AddKeywordsInBulkExample($user, $adGroupId);
} catch (Exception $e) {
    printf("An error has occurred: %s\n", $e->getMessage());
}
 public function testAddKeywordsInBulkExample()
 {
     AddKeywordsInBulkExample($this->user, $this->adGroupId);
 }