Skip to content
Tek Nepal edited this page Jul 1, 2016 · 3 revisions

$api = API::withUsernameAndPassword($server, $username, $password);

$start = new DateTime('8:00 AM'); $end = new DateTime('9:00 AM');

$request = array( 'Items' => array( 'CalendarItem' => array( 'Start' => $start->format('c'), 'End' => $end->format('c'), 'Body' => array( 'BodyType' => Enumeration\BodyTypeType::HTML, '_value' => 'This is <b>the</b> body' ), 'ItemClass' => Enumeration\ItemClassType::APPOINTMENT, 'Sensitivity' => Enumeration\SensitivityChoicesType::NORMAL, 'Categories' => array('Testing', 'php-ews'), 'Importance' => Enumeration\ImportanceChoicesType::NORMAL ) ), 'SendMeetingInvitations' => Enumeration\CalendarItemCreateOrDeleteOperationType::SEND_TO_NONE );

$request = Type::buildFromArray($request); $response = $api->getClient()->CreateItem($request);

Clone this wiki locally