SMS
Contacts
Appointments

Add Appointment

Below is a set the dataset and examples needed in order to send add appointments programmactically. 
https://www.titanly.net/api/appointments/addAppointment.php
Name Status Description
aId Optional Appointment Id (used when edits need to be made to an appointment)
ApiKey Required Your API key found in your account area.
ContactId Required ContactId assigned to the appointment.
aStart Required Unix timestamp of the start time for the appointment
aEnd Optional Appointment end time
Location Optional Location ID assigned to appointment (if any)
Creator Optional User ID that created the appointment
ProductList Optional List of products to be assigned to the appointment.
UserList Optional List of User Ids assigned to the appointment
Name Status Description
appointmentId Payload This is the ID of the Appointment that was just created or edited.
pl Payload The number of products assigned to this appointment.
Base Example
PHP
<?php	
	//Setup Variables
	$url = "https://www.titanly.net/api/appointments/addAppointment.php";
	$fields['ContactId'] = urlencode('Titanly Contact ID that the appointment is scheduled with');
	$fields['Creator'] = urlencode('Titanly User ID that created the appointment');
	$fields['aId'] = urlencode('Appointment ID can be passed when you want to update an appointment instead of add a new one');
	$fields['aStart'] = urlencode("Unix timestamp of when the appointment is scheduled to start");
	$fields['aEnd'] = urlencode("Unix timestamp of when the appointment is scheduled to end");
	$fields['ApiKey'] = urlencode('Your API Key');

	$fieldString = '';
	foreach($fields as $key=>$value)
	{ 
		$fieldString .= $key.'='.$value.'&'; 
	}
	rtrim($fieldString, '&');


	// Use Curl To send the reqeust
	$ch = curl_init();
	curl_setopt($ch, CURLOPT_URL, $url);
	curl_setopt($ch, CURLOPT_POST, count($fields));
	curl_setopt($ch, CURLOPT_POSTFIELDS, $fieldString);
	curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
	curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_ANY);
	$userData = curl_exec($ch);
	$info = curl_getinfo($ch);
	curl_close($ch);
?>
Example Payload
Payload
<Root>
	<response>success</response>
	<message>Appointment has been updated</message>
    <Data>
        <appointmentId>1234</appointmentId>
    </Data>
</Root>