Before you begin using Purlem's API you will need to do two things:
1) Request an API Token from Purlem.
2) Inform Purlem of the website where the form will be hosted.
Both of these steps are required for security purposes. Once you have registered with Purlem's API, you will simply need to create a form on your website. The form must include a field for the First Name, Last Name, Purlem User ID, API Token, and Campaign ID. The form's action will need to be set to "http://purlem.com/api/import/contact/index.php". Use the form code below as a starting point.
<form id="form1" name="form1" method="get" action="http://purlapi.com/import/contact/index.php">
<table width="400" border="0" cellspacing="0" cellpadding="3">
<tr>
<td>First Name:</td>
<td><input type="text" name="firstName" id="firstName" /></td>
</tr>
<tr>
<td>Last Name:</td>
<td><input type="text" name="lastName" id="lastName" /></td>
</tr>
<tr>
<td>Organization:</td>
<td><input type="text" name="organization" id="organization" /></td>
</tr>
<tr>
<td>Position:</td>
<td><input type="text" name="position" id="position" /></td>
</tr>
<tr>
<td>Email:</td>
<td><input type="text" name="email" id="email" /></td>
</tr>
<tr>
<td>Phone:</td>
<td><input type="text" name="phone" id="phone" /></td>
</tr>
<tr>
<td>Fax:</td>
<td><input type="text" name="fax" id="fax" /></td>
</tr>
<tr>
<td>Address 1:</td>
<td><input type="text" name="address1" id="address1" /></td>
</tr>
<tr>
<td>Address 2:</td>
<td><input type="text" name="address2" id="address2" /></td>
</tr>
<tr>
<td>City:</td>
<td><input type="text" name="city" id="city" /></td>
</tr>
<tr>
<td>State:</td>
<td><input type="text" name="state" id="state" /></td>
</tr>
<tr>
<td>Zip:</td>
<td><input type="text" name="zip" id="zip" /></td>
</tr>
<tr>
<td> </td>
<td><input type="submit" name="button" id="button" value="Submit" />
<input name="ID" type="hidden" id="ID" value="<insert your Purlem ID here>" />
<input name="campaignID" type="hidden" id="campaignID" value="<insert your campaignID here>" />
<input name="token" type="hidden" id="token" value="<insert your token here>" />
<input name="return" type="hidden" id="return" value="<insert the return ULR here>" />
<input name="adminEmail" type="hidden" id="adminEmail" value="<insert your email here (if you want to be notified of added contacts)>" /></td>
</tr>
</table>
</form>
