Back to Service

Method Details for GetContactsRaw.

Gets a list of contacts

Definition

TimeLog.TLP.WebAppCode.Service.GetContactsRaw(System.String,System.String,System.String,System.Int32,System.Int32)

Parameters

  • siteCode String Unique identification for your TimeLog account
  • apiID String The API ID
  • apiPassword String The API password
  • customerID Integer ID of specific customer. Set to 0 to get all contacts
  • contactID Integer ID of specific contact. Set to 0 to get all contacts

Returns

A list of contact objects in XML format

Result Example

<?xml version="1.0" encoding="utf-8"?>
<tlp:Contacts
  xmlns:tlp="http://www.timelog.com/XML/Schema/tlp/v4_4"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.timelog.com/XML/Schema/tlp/v4_4 http://www.timelog.com/api/xsd/ContactsRaw.xsd">
  <tlp:Contact ID="3353">
    <tlp:FirstName>John</tlp:FirstName>
    <tlp:LastName>Smith</tlp:LastName>
    <tlp:FullName>John Smith</tlp:FullName>
    <tlp:CustomerID>1</tlp:CustomerID>
    <tlp:CustomerName>Microsoft</tlp:CustomerName>
    <tlp:CustomerNo>02.0000</tlp:CustomerNo>
    <tlp:Title>Sales manager</tlp:Title>
    <tlp:Phone>+1 9999 9999</tlp:Phone>
    <tlp:Mobile>+1 9999 9999</tlp:Mobile>
    <tlp:PrivatePhone>+1 9999 9999</tlp:PrivatePhone>
    <tlp:Email>j.smith@micorsoft.com</tlp:Email>
    <tlp:Address1>One Microsoft Way</tlp:Address1>
    <tlp:ZipCode>WA 98052-6399</tlp:ZipCode>
    <tlp:City>Remond</tlp:City>
    <tlp:State>Washington</tlp:State>
    <tlp:Country>USA</tlp:Country>
    <tlp:AccountManagerID>14</tlp:AccountManagerID>
    <tlp:AccountManagerFullName>Anders Egede Brandstrup</tlp:AccountManagerFullName>
    <tlp:CreatedAt>2010-06-12T13:24:52</tlp:CreatedAt>
    <tlp:CreatedByEmployeeId>414</tlp:CreatedByEmployeeId>
    <tlp:CreatedBy>mhe</tlp:CreatedBy>
    <tlp:LastModifiedAt>2010-06-12T13:24:52</tlp:LastModifiedAt>
    <tlp:LastModifiedByEmployeeId>414</tlp:LastModifiedByEmployeeId>
    <tlp:LastModifiedBy>mhe</tlp:LastModifiedBy>
  </tlp:Contact>
</tlp:Contacts>

Result Schema

<?xml version="1.0" encoding="utf-8"?>
<xsd:schema
  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns:tlp="http://www.timelog.com/XML/Schema/tlp/v4_4" targetNamespace="http://www.timelog.com/XML/Schema/tlp/v4_4" elementFormDefault="qualified" attributeFormDefault="unqualified">
  <xsd:element name="Contacts">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element name="Contact" type="tlp:ContactRaw_Type" minOccurs="0" maxOccurs="unbounded" />
      </xsd:sequence>
    </xsd:complexType>
    <xsd:key name="Contact_Key">
      <xsd:selector xpath=".//tlp:Contact" />
      <xsd:field xpath="@ID" />
    </xsd:key>
  </xsd:element>
  <xsd:complexType name="ContactRaw_Type">
    <xsd:sequence>
      <xsd:element name="FirstName" type="xsd:string" />
      <xsd:element name="LastName" type="xsd:string" />
      <xsd:element name="FullName" type="xsd:string" />
      <xsd:element name="CustomerID" type="xsd:positiveInteger" />
      <xsd:element name="CustomerName" type="xsd:string" />
      <xsd:element name="CustomerNo" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="Title" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="Phone" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="Mobile" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="PrivatePhone" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="Email" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="Address1" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="Address2" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="ZipCode" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="City" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="State" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="Country" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="AccountManagerID" type="xsd:positiveInteger" minOccurs="0" maxOccurs="1" />
      <xsd:element name="AccountManagerFullName" type="xsd:string" minOccurs="0" maxOccurs="1" />
      <xsd:element name="CreatedAt" type="xsd:dateTime" />
      <xsd:element name="CreatedByEmployeeId" type="xsd:positiveInteger" />
      <xsd:element name="CreatedBy" type="xsd:string" />
      <xsd:element name="LastModifiedAt" type="xsd:dateTime" />
      <xsd:element name="LastModifiedByEmployeeId" type="xsd:positiveInteger" />
      <xsd:element name="LastModifiedBy" type="xsd:string" />
    </xsd:sequence>
    <xsd:attribute name="ID" type="xsd:positiveInteger" use="required"></xsd:attribute>
  </xsd:complexType>
</xsd:schema>

Download the XSD