Purpose: Appends a previously unattached Node (and its sub-tree of child Nodes if present) as the new Last Child of a specified parent Node in a DOM.
The OID of the Node that was appended will be returned in the response. Note that this NodeOID will be the same as before it was attached.
Note that when nodes are created using the primitive Createtype Actions, they are associated with a Document but are not actually attached to the DOM tree. Until attached, such new Nodes will not appear if the OutputDOM Action is invoked, since this recursively lists all nodes attached under the DOM's DocumentNode.
Attempts to append a Node that already has a ParentNode will return an error
A Node cannot be attached to a Node that belongs to a different Document. See the ImportNode and CopyNodes Actions if you are working between DOMs.
Action-specific name/value pairs:
|NodeOID||The OID of the currently unattached node that is to be appended into the DOM|
|ParentOID||The OID of the Node to which the unattached node will be appended as a Last Child.|
Alternatively, the parameters above can be incorporated into a single JSON string and specified using the parameter name JSON, eg:
Action=AppendChild &MDBAccessKeyId=[your access key id] &NodeOID=1-10 &ParentOID=1-3 &Signature=[computed signature] &SignatureMethod=HmacSHA256 &SignatureVersion=2 &Timestamp=2009-06-14T13%3A19%3A41 &Version=2009-04-15 &db=mdbx
Action=AppendChild &JSON=%7BNodeOID%3A%221-10%22%2CParentOID%3A%221-3%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
This request will append Node 1-10 as the new Last Child of the Node whose OID is 1-3. Any child nodes that are attached to node 1-10 will also now be present in the DOM as a result of this Action.
<?xml version='1.0'?> <AppendChildResponse xmlns="http://mdbx.mgateway.com/doc/2009-06-05/"> <AppendChildResult> <NodeOID> 1-10 </NodeOID> </AppendChildResult> </AppendChildResponse>