Retrieving lists of groups with the Conversation Web Service

To retrieve a list of groups, use a request with AttributeGroupListConfig which, as an extension of the ContentElementConfig complex type, provides information about attribute groups.

To retrieve a list of groups:
Use a request similar to the following example:
<Request xmlns="http://www.endeca.com/MDEX/conversation/2/0">
   <State/>
   <ContentElementConfig xsi:type="AttributeGroupListConfig"
     Id="AttributeGroupList"
     HandlerFunction="AttributeGroupListHandler" 
     HandlerNamespace="http://www.endeca.com/MDEX/conversation/2/0" 
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   </ContentElementConfig>
</Request>

The Conversation Web Service request contains a list of groups that are currently defined, specifying each group's display name and the number of attributes in each group. Information about each group is returned inside the GroupSummary element of the ContentElement response.

In this example, two groups are returned — Sale-Geography and Sales-Transaction. The attribute Cardinality specifies the number of attributes in each of these groups. The attributes for each group are also listed.

The first half of the response repeats the request:
<cs:Results xmlns:cs="http://www.endeca.com/MDEX/conversation/2/0" 
  xmlns:mdex="http://www.endeca.com/MDEX/XQuery/2009/09">
   <cs:Request>
     <ns3:State xmlns:ns2="http://www.endeca.com/MDEX/lql_parser/types" 
        xmlns:ns3="http://www.endeca.com/MDEX/conversation/2/0" 
        xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"/>
     <ns3:ContentElementConfig 
        xsi:type="ns3:AttributeGroupListConfig" Id="AttributeGroupList" 
        HandlerNamespace="http://www.endeca.com/MDEX/conversation/2/0" 
        HandlerFunction="AttributeGroupListHandler" 
        xmlns:ns3="http://www.endeca.com/MDEX/conversation/1/0" 
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
   </cs:Request>
The second half of the response includes information about groups and their contents:
<cs:ContentElement 
     xsi:type="cs:AttributeGroupList" 
     Id="AttributeGroupList" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <cs:GroupSummary Key="Sale-Geography" Cardinality="7">
       <cs:Record>
         <system-group_DisplayName type="mdex:string">
            Sale Geography
         </system-group_DisplayName>
         <system-group_Key type="mdex:string">
            Sale-Geography
         </system-group_Key>
       </cs:Record>
       <cs:GroupMembers>
         <mdex-property_Key>DimGeography_CountryRegionName</mdex-property_Key>
         <mdex-property_Key>DimGeography_StateProvinceName</mdex-property_Key>
         <mdex-property_Key>DimGeography_City</mdex-property_Key>
         <mdex-property_Key>DimGeography_PostalCode</mdex-property_Key>
         <mdex-property_Key>DimSalesTerritory_SalesTerritoryCountry</mdex-property_Key>
         <mdex-property_Key>DimSalesTerritory_SalesTerritoryGroup</mdex-property_Key>
         <mdex-property_Key>DimSalesTerritory_SalesTerritoryRegion</mdex-property_Key>
       </cs:GroupMembers>
    </cs:GroupSummary>
    <cs:GroupSummary Key="Sales-Transaction" Cardinality="15">
       <cs:Record>
         <system-group_DisplayName type="mdex:string">Sales Transaction</system-group_DisplayName>
         <system-group_Key type="mdex:string">Sales-Transaction</system-group_Key>
       </cs:Record>
       <cs:GroupMembers>
         ...
         <mdex-property_Key>FactSales_CarrierTrackingNumber</mdex-property_Key>
         <mdex-property_Key>FactSales_CustomerPONumer</mdex-property_Key>
       </cs:GroupMembers>
    </cs:GroupSummary>
  </cs:ContentElement>
</cs:Results>
Note: In a response, you may also notice a group system-navigation_InternalGroup (not shown in this example), which contains all of the attributes that are not members of any other user-created groups. This group is used by the Oracle Endeca Server and Studio and is not intended to be used in your application.