Validate Item Updatesession File
DescriptionValidates the files in the update session with the referenced identifier and ensures all necessary files are received. In the case where a file is missing, this operation will return its name in the File.ValidationResult.missing-files set. The user can add the missing files and try re-validating. For other type of errors, File.ValidationResult.invalid-files will contain the list of invalid files. if you do not have all of the privileges described as follows: - Operation execution requires System.Anonymous.
Request
URLURL
https://{api_host}/rest/com/vmware/content/library/item/updatesession/file/id:{update_session_id}?~action=validate
Parameters
Parameters
string
update_session_id
Required
Identifier of the update session to validate.
The parameter must be an identifier for the resource type: com.vmware.content.library.item.UpdateSession.
Header Parameters
Header Parameters
string
vmware-api-session-id
Required
Required session ID, acquired from Create Session API under CIS product
vmware-api-session-id Example
b00db39f948d13ea1e59b4d6fce56389
Response
Response
Response BodyResponse Body
200 OK returns
LibraryItemUpdatesessionFileValidateResponseBody
of type application/json
A validation result containing missing files or invalid files and the reason why they are invalid.
{
"value": {
"has_errors": false,
"invalid_files": [
{
"error_message": {
"args": [
"string"
],
"default_message": "string",
"id": "string",
"localized": "string",
"params": [
{
"key": "key1",
"value": {
"d": 0,
"dt": "string",
"format": "enum",
"i": 0,
"l": {
"id": "string",
"params": "StdLocalizationParam Object"
},
"precision": 0,
"s": "string"
}
}
]
},
"name": "string"
}
],
"missing_files": [
"string"
]
}
}
value
Optional
A validation result containing missing files or invalid files and the reason why they are invalid.
cURL Command
curl -X POST -H "vmware-api-session-id: b00db39f948d13ea1e59b4d6fce56389" https://{api_host}/rest/com/vmware/content/library/item/updatesession/file/id:{update_session_id}?~action=validate
Errors
404
com.vmware.vapi.std.errors.not_found : if no update session with the given identifier exists.
409
com.vmware.vapi.std.errors.not_allowed_in_current_state : if the update session is not in the ACTIVE state, or if some of the files that will be uploaded by the client aren't received correctly.
default
'Default' means this response is used for all HTTP codes that are not covered individually for this operation.