Action: GetDescendantNodes

Purpose: Returns pointers to all the nodes that exist in the sub-tree under a specified node. The sequence in which the nodes are listed is not significant.

Action-specific name/value pairs:

Parameter Name Description
NodeOID The Node whose sub-tree Nodes (child nodes, grandchild nodes, etc) are to be retrieved.

Alternatively, the parameters above can be incorporated into a single JSON string and specified using the parameter name JSON, eg:

{NodeOID:"1-4"}

Example Request

Action=GetDescendantNodes
&MDBAccessKeyId=[your access key id]
&NodeOID=1-4
&Signature=[computed signature]
&SignatureMethod=HmacSHA256
&SignatureVersion=2
&Timestamp=2009-06-14T13%3A19%3A41
&Version=2009-04-15
&db=mdbx

or:

Action=GetDescendantNodes
&JSON=%7BNodeOID%3A%221-4%22%7D
&MDBAccessKeyId=[your access key id]
&OutputFormat=JSON
&Signature=[computed signature]
&SignatureMethod=HmacSHA256
&SignatureVersion=2
&Timestamp=2009-06-14T13%3A19%3A41
&Version=2009-04-15
&db=mdbx

Example Response

XML

<?xml version='1.0'?>
<GetDescendantNodesResponse xmlns="http://mdbx.mgateway.com/doc/2009-06-05/">
   <GetDescendantNodesResult>
      <DescendantNode>
         <NodeOID>
            1-14
         </NodeOID>
         <NodeType>
            8
         </NodeType>
      </DescendantNode>
      <DescendantNode>
         <NodeOID>
            1-17
         </NodeOID>
         <NodeType>
            1
         </NodeType>
         <TagName>
            ewd:test
         </TagName>
      </DescendantNode>
      <DescendantNode>
         <NodeOID>
            1-7
         </NodeOID>
         <NodeType>
            3
         </NodeType>
      </DescendantNode>
      <DescendantNode>
         <NodeOID>
            1-8
         </NodeOID>
         <NodeType>
            3
         </NodeType>
      </DescendantNode>
   </GetDescendantNodesResult>
</GetDescendantNodesResponse>

The GetDescendantNodes Action returns the NodeOID and NodeType of all relevant Nodes.

JSON (ie if OutputFormat=JSON specified in the Request)

["1-14","1-17","1-7","1-8"]

The JSON output is much less verbose, simply being an array of descendant Node OIDs.