Get Available Fields for a Simple Entity
Simple entities are projects, programs, resources, tasks, assets, and accounts
Use getEntityFields to retrieve the available fields for an entity. This example uses a Resource entity (entityTypeId=11), and gets all the fields that are available when a creating a resource (the mode for creating an entity is 1). The partial response shows four fields: Alternate Resource (ID), Alternatate Resource (title), Billing Rate. The full response lists all fields available when creating a resource.
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ser="http://services">
<soapenv:Header/>
<soapenv:Body>
<ser:getEntityFields>
<ser:sessionId>F0C6EDD44B270B1F3DD0F1492A2A1585</ser:sessionId>
<!--The entity Type for Resource is 11 -->
<ser:entityTypeId>11</ser:entityTypeId>
<!--Use 0 to get all fields, 1 = insert and 2 = update -->
<ser:mode>1</ser:mode>
</ser:getEntityFields>
</soapenv:Body>
</soapenv:Envelope>
Response (partial)
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<ns:getEntityFieldsResponse xmlns:ns="http://services" xmlns:ax21="http://objects.services/xsd">
<ns:return xsi:type="ax21:ObjectMethod" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ax21:defaultValue xsi:nil="true"/>
<ax21:fieldLength>0</ax21:fieldLength>
<ax21:fieldSubTypeId>0</ax21:fieldSubTypeId>
<ax21:fieldTypeId>1</ax21:fieldTypeId>
<ax21:isRequired>false</ax21:isRequired>
<ax21:label>Alternate Resource</ax21:label>
<ax21:method>alternateResourceId</ax21:method>
<ax21:methodId>1131</ax21:methodId>
<ax21:onInsert>true</ax21:onInsert>
<ax21:onSelect>true</ax21:onSelect>
<ax21:onUpdate>true</ax21:onUpdate>
<ax21:sequence>0</ax21:sequence>
</ns:return>
<ns:return xsi:type="ax21:ObjectMethod" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ax21:defaultValue xsi:nil="true"/>
<ax21:fieldLength>0</ax21:fieldLength>
<ax21:fieldSubTypeId>0</ax21:fieldSubTypeId>
<ax21:fieldTypeId>1</ax21:fieldTypeId>
<ax21:isRequired>false</ax21:isRequired>
<ax21:label>Alternate Resource</ax21:label>
<ax21:method>alternateResourceByTitle</ax21:method>
<ax21:methodId>1160</ax21:methodId>
<ax21:onInsert>true</ax21:onInsert>
<ax21:onSelect>false</ax21:onSelect>
<ax21:onUpdate>true</ax21:onUpdate>
<ax21:sequence>9999</ax21:sequence>
</ns:return>
<ns:return xsi:type="ax21:ObjectMethod" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ax21:defaultValue xsi:nil="true"/>
<ax21:fieldLength>64</ax21:fieldLength>
<ax21:fieldSubTypeId>0</ax21:fieldSubTypeId>
<ax21:fieldTypeId>1</ax21:fieldTypeId>
<ax21:isRequired>false</ax21:isRequired>
<ax21:label>Base Calendar</ax21:label>
<ax21:method>initialBaseCalendarTitle</ax21:method>
<ax21:methodId>101101</ax21:methodId>
<ax21:onInsert>true</ax21:onInsert>
<ax21:onSelect>false</ax21:onSelect>
<ax21:onUpdate>true</ax21:onUpdate>
<ax21:sequence>0</ax21:sequence>
</ns:return>
<ns:return xsi:type="ax21:ObjectMethod" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ax21:defaultValue xsi:nil="true"/>
<ax21:fieldLength>6</ax21:fieldLength>
<ax21:fieldSubTypeId>0</ax21:fieldSubTypeId>
<ax21:fieldTypeId>6</ax21:fieldTypeId>
<ax21:isRequired>false</ax21:isRequired>
<ax21:label>Billable Rate</ax21:label>
<ax21:method>targetBillingRate</ax21:method>
<ax21:methodId>1116</ax21:methodId>
<ax21:onInsert>true</ax21:onInsert>
<ax21:onSelect>true</ax21:onSelect>
<ax21:onUpdate>true</ax21:onUpdate>
<ax21:sequence>0</ax21:sequence>
</ns:return>
...