Hi Isaac.
Check this out. Hope it helps.
// Create task
//Create an entity representing the new task
$newTask = new stdClass();
$newTask->Id = new stdClass();
$newTask->Id->TypeName = 'Task';
$newTask->Id->Value = null;
//Set Task name
$nameField = new stdClass();
$nameField->FieldName = "Name";
$nameField->Value = new SoapVar("My Task", XSD_STRING, "string",
"http://www.w3.org/2001/XMLSchema");
//Set task start date
$startDateField = new stdClass();
$startDateField->FieldName = "DueDate";
$date = '2012-05-01';
$startDateField->Value = new SoapVar($date, XSD_DATETIME, "dateTime",
"http://www.w3.org/2001/XMLSchema");
//Assign the fields to the task
$newTask->Values = array($nameField, $startDateField);
$createMeesage = new stdClass();
$createMeesage->Entity = new SoapVar($newTask, SOAP_ENC_OBJECT,
"GenericEntity", 'http://clarizen.com/api');
$request[] = new SoapVar($createMeesage, SOAP_ENC_OBJECT, 'CreateMessage','http://clarizen.com/api');
$result = $client->Execute(array("request"=>$request));
$responseJSON = json_encode($result);
echo $responseJSON . "<br/><br/>";
$new_id = $result -> ExecuteResult -> Result -> Id;
$responseJSON = json_encode($new_id);
echo $responseJSON . "<br/><br/>";
// Link
$link = new stdClass();
$link->Id = new stdClass();
$link->Id->TypeName = 'WorkItemHierarchyLink';
$parent_project = array ("TypeName"=>"Project", "Value" => "803c569a-786e-401f-92bb-8bcbe07776bd");
$parent = new stdClass();
$parent->FieldName = 'Parent';
$parent->Value = new SoapVar($parent_project, SOAP_ENC_OBJECT, "EntityId","http://clarizen.com/api");
$child = new stdClass();
$child->FieldName = 'Child';
$child->Value = new SoapVar($new_id, SOAP_ENC_OBJECT, "EntityId","http://clarizen.com/api");
$link->Values = array($parent, $child);
$createMeesage = new stdClass();
$createMeesage->Entity = new SoapVar($link, SOAP_ENC_OBJECT, "GenericEntity", 'http://clarizen.com/api');
$request = array();
$request[] = new SoapVar($createMeesage, SOAP_ENC_OBJECT, 'CreateMessage', 'http://clarizen.com/api');
$result = $client->Execute(array("request"=>$request));
$responseJSON = json_encode($result);
echo $responseJSON . "<br/><br/>";