QualifiedName values shall be encoded as a JSON string using the format defined in 5.1.12.

The form with the NamespaceIndex is not allowed unless there is an encoding error. This can occur when the encoder cannot map a NamespaceIndex to a NamespaceUri. In this case, the encoder shall encode the NamespaceIndex using the <namespace-index> form. The decoder shall pass this NamespaceIndex to the application.

A second abnormal state occurs when the decoder cannot convert a NamespaceUri to a NamespaceIndex. If this occurs the decoder shall set the NamespaceIndex to 0 and the Name to the raw JSON string that includes the NamespaceUri that cannot be decoded.