I want to confirm automation perform status.
How do I confirm this by PHP via SOAP-API?
PHP sample code is here.
require('../ET_Client.php');
const OBJ_TYPE = "Automation";
const ACTION_TYPE = "start";
const AUTOMATION_NAME = "[Automation name]";
try {
$authStub = new ET_Client();
// Get ObjectID
$props = array(
'ProgramID',
'Name'
);
$filter = array(
'Property' => 'Name',
'SimpleOperator' => 'equals',
'Value' => AUTOMATION_NAME
);
$automationInfo = new ET_Get($authStub, OBJ_TYPE, $props, $filter);
var_dump($automationInfo);
$objectID = $automationInfo->results[0]->ObjectID;
// Perform automation immediately
$props = array(
'ObjectID' => $objectID
);
$response = new ET_Perform($authStub, OBJ_TYPE, ACTION_TYPE, $props);
var_dump($response);
} catch (Exception $ex) {
echo 'Caught exception: ', $ex->getMessage(), "\n";
}