Last updated: 2024-06-07
Get Operation
In this topic:
Overview
The get operation retrieves an object and its child objects' information by ID. The main object's ID is required. The child object's ID is not required.
A get request must also specify the properties to be returned in the response. If no properties are specified, the response will contain the default properties. The object ID is always returned in the response.
The following example request retrieves a contact's last name, first name and preferred phone number (area code and number):
<request version="1.0">
<header>...</header>
<get>
<Contact id="Contact.123.456">
<LastName/>
<FirstName/>
<PreferredPhone>
<AreaCode/>
<Number/>
</PreferredPhone>
</Contact>
</get>
</request>The response containing the requested data looks like this:
<response version="1.0">
<header>...</header>
<get>
<Contact id="Contact.123.456">
<LastName>Ackerman</LastName>
<FirstName>Joe</FirstName>
<PreferredPhone id="Phone.123.789">
<AreaCode>626</AreaCode>
<Number>5553505</Number>
</PreferredPhone>
</Contact>
</get>
</response>Get Lookup
SmartOffice drop-down lists are represented as lookups in SmartIntegrator. The get lookup operation retrieves the index and description of each choice that exists for a particular lookup, based on the lookup ID.
This example requests the indexes and descriptions for two lookups:
<request version="1.0">
<header>...</header>
<get>
<lookup id="3"/>
<lookup id="4"/>
</get>
</request>The response returns the index and description (if available) for each lookups:
<response version="1.0">
<header>...</header>
<get>
<lookup name="YesNoUnknown" id="3">
<value index="0"/>
<value index="1">Yes</value>
<value index="2">No</value>
</lookup>
<lookup name="Record Type" id="4">
<value index="1">Individual</value>
<value index="2">Business</value>
<value index="10">Archived</value>
</lookup>
</get>
</response>