An example of the UANodeSetcan be found below.

This example defines the Nodesfor an InformationModelwith the URI of “”. This example references Nodesdefined in the base OPC UA InformationModeland an InformationModelwith the URI “”.

The XML namespaces declared at the top include the URIs for the Namespacesreferenced in the document because the document includes Complex Data. Documents without Complex Datawould not have these declarations.




xmlns:uax="" xmlns:xsi="" xmlns="">

The NamespaceUristable includes all Namespacesreferenced in the document except for the base OPC UA InformationModel. A NamespaceIndexof 1 refers to the URI “”.





The Aliasestable is provided to enhance readability. There are no rules for what is included. A useful guideline would include standard ReferenceTypesand DataTypesif they are referenced in the document. An Aliasmay be used for any NodeIdvalue in the document except for NodeIdsthat appear in Valuesof Variablesor VariableTypes.


<Alias Alias="HasComponent">i=47</Alias>

<Alias Alias="HasProperty">i=46</Alias>

<Alias Alias="HasSubtype">i=45</Alias>

<Alias Alias="HasTypeDefinition">i=40</Alias>


The BicycleTypeis a DataType Nodethat inherits from a DataTypedefined in another InformationModel(ns=2;i=314). It is assumed that any application importing this file will already know about the referenced InformationModel. A Servercould map the references onto another OPC UA Serverby adding a ServerIndexto TargetNode NodeIds. The structure of the DataTypeis defined by the Definitionelement. This information can be used by code generators to automatically create serializers for the DataType.

<UADataType NodeId="ns=1;i=365" BrowseName="1:BicycleType">



<Reference ReferenceType="HasSubtype" IsForward="false">ns=2;i=314</Reference>


<Definition Name="BicycleType">

<Field Name="NoOfGears" DataType="UInt32" />

<Field Name="ManufacturerName" DataType="String" />



This Nodeis an instance of an Object TypeDefinition Nodedefined in another InformationModel(ns=2;i=341). It has a single Propertywhich is declared later in the document.

<UAObject NodeId="ns=1;i=375" BrowseName="1:DriverOfTheMonth" ParentNodeId="ns=1;i=281">



<Reference ReferenceType="HasProperty">ns=1;i=376</Reference>

<Reference ReferenceType="HasTypeDefinition">ns=2;i=341</Reference>

<Reference ReferenceType="HasComponent" IsForward="false">ns=1;i=281</Reference>



This Nodeis an instance of a Variable TypeDefinition Nodedefined in base OPC UA InformationModel(i=68). The DataTypeis the base type for the BicycleType DataType.The AccessLevelsdeclare the Variableas Readableand Writeable. The ParentNodeId indicates that this Node is tightly coupled with the Parent (DriverOfTheMonth) and will be deleted if the Parent is deleted.

<UAVariable NodeId="ns=1;i=376" BrowseName="2:PrimaryVehicle"

ParentNodeId="ns=1;i=375" DataType="ns=2;i=314" AccessLevel="3">



<Reference ReferenceType="HasTypeDefinition">i=68</Reference>

<Reference ReferenceType="HasProperty" IsForward="false">ns=1;i=375</Reference>


This Valueis an instance of a BicycleType DataType. It is wrapped in an ExtensionObjectwhich declares that the value is serialized using the Default XML DataTypeEncodingfor the DataType. The Valuecould be serialized using the Default Binary DataTypeEncodingbut that would result in a document that cannot be edited by hand. No matter which DataTypeEncodingis used, the NamespaceIndexused in the ManufactureNamefield refers to the NamespaceUristable in this document. The application is responsible for changing whatever value it needs to be when the document is loaded by an application.


<ExtensionObject xmlns="">


















These are the DataTypeEncoding Nodesfor the BicycleType DataType.

<UAObject NodeId="ns=1;i=366" BrowseName="Default XML">

<DisplayName>Default XML</DisplayName>


<Reference ReferenceType="HasEncoding" IsForward="false">ns=1;i=365</Reference>

<Reference ReferenceType="HasTypeDefinition">i=76</Reference>



<UAObject NodeId="ns=1;i=370" BrowseName="Default Binary">

<DisplayName>Default Binary</DisplayName>


<Reference ReferenceType="HasEncoding" IsForward="false">ns=1;i=365</Reference>

<Reference ReferenceType="HasTypeDefinition">i=76</Reference>