Validate records in a container
Validates records in the specified container. The records will be provided in the request content as XML.
You can also validate MDM data records through the REST API using a Job. For more information, see How to validate MDM data records against the master storage through the REST API.
Request |
The body is an XML representation of one or more records to be validated, which are enclosed by a root tag with an arbitrary name, records for an example. |
Parameters |
|
Headers |
|
Response | The list of the validation result for each record in JSON format, including the validity status, a message from the validation rule or the Before Saving process or empty, and optionally the input record as an echo. |
Status |
|
Limitation | This REST API does not support validating records for the following entity:
|
Sample request
<records>
<ProductFamily>
<Name>Literature</Name>
<Status>Approved</Status>
</ProductFamily>
<ProductFamily>
<Name>Comics</Name>
<Status>Unknown</Status>
</ProductFamily>
</records>
Sample response in XML format
<results>
<result>
<isValid>false</isValid>
<message><msg>[EN:Validation faild]</msg></message>
<sourceXml>
<ProductFamily>
<Name>Literature</Name>
<Status>Approved</Status>
</ProductFamily>
</sourceXml>
</result>
<result>
<isValid>false</isValid>
<message></message>
<sourceXml>
<ProductFamily>
<Name>Comics</Name>
<Status>Unknown</Status>
</ProductFamily>
</sourceXml>
</result>
</results>
Sample response in JSON format
[
{
"isValid": false,
"message": "<msg>[EN:Validation faild]</msg>\n",
"sourceXml": "<ProductFamily><Name>Literature</Name><Status>Approved</Status></ProductFamily>"
},
{
"isValid": true,
"message": "",
"sourceXml": "<ProductFamily><Name>Comics</Name><Status>Unknown</Status></ProductFamily>"
}
]