The GetContactDOB method returns all contacts whose birth dates fall within a specified date range and who are assigned to a particular SmartOffice user. The response includes each contact's first name, last name, contact ID and birth date.
The GetContactDOB method is invoked as part of the MethodOperation.
Name | Type |
---|---|
UserID | String |
FromDate | String |
ToDate | String |
Request XML
This example retrieves contacts whose birthdays fall on or between January 1, 1950, and December 31, 1955, and who are assigned to the SmartOffice user whose ID is User.1.2.
<request version='1.0'> <header> <office>myoffice</office> <user>jdoe</user> <password>password</password> </header> <method> <GetContactDOB> <UserID>User.1.2</UserID> <FromDate>1950-01-01</FromDate> <ToDate>1955-12-31</ToDate> </GetContactDOB> </method> </request>
Response XML
<response version="1.0"> <header> <sessionClosed/> </header> <method> <GetContactDOB> <Contact id="Contact.1.12" _type="obj"> <FirstName>Paulette</FirstName> <LastName>Garner</LastName> <Person id="Person.1.12" _type="obj"> <Dob>1952-07-03</Dob> </Person> </Contact> <Contact id="Contact.1.14" _type="obj"> <FirstName>Genevieve</FirstName> <LastName>Bates</LastName> <Person id="Person.1.14" _type="obj"> <Dob>1954-10-16</Dob> </Person> </Contact> </GetContactDOB> </method> <_status>OK</_status> <_systime>2015-06-04T22:38:49</_systime> <!--Cost 36 mill seconds.--> </response>
-- Main.DinosLambropoulos - 04 Jun 2015