Skip to main content

QueryInfectionScanStatusByID

Will retrieve the result of a given scanning session

Syntax​

Method ID​

#define WAAPI_MID_QUERY_INFECTION_SCAN_STATUS_BY_ID 80005

JSON Input Structure​

{
"input": {
"method": 80005,
"infection_scan_id": string
}
}

Input Properties​

ParameterTypeDescription
infection_scan_idstringA session id key representing the scanning session

JSON Output Structure​

{
"result": {
"method": 80005,
"code": number,
"timing": number,
"timestamp": string,
"scan_complete": boolean,
"malware_found": boolean,
"scanning_type": boolean,
"details": [
{
"status": string,
"total_source": number,
"hash": string,
"scan_time": string,
"mso_data_id": string,
"network_address": string,
"domain_name": string,
"mac_address": string,
"explanation": [
string,
...
],
"threats": [
{
"threat_name": string,
"av_name": string,
"scan_time": string,
"av_def_time": string,
"assessment": string,
"source_name": string,
"confident": string
},
...
],
"geo_info": {
"country_name": string,
"country_code": string,
"region_name": string,
"region_code": string,
"city": string
}
},
...
],
"files_in_archive": [
{},
...
]
}
}

Output Properties​

PropertyTypeDescription
result.methodnumberThe method ID that generated this result.
result.codenumberThe result code. See Result Codes.
result.timingnumberThe measured time for the method call in milliseconds.
result.timestampstringThe timestamp in seconds of when the call was made.
result.scan_completebooleanTrue if the given scanning session was completed
result.malware_foundbooleanTrue if there was any malware found
result.scanning_typebooleanShows the type of the queried scan
result.detailsarray<object>Will contain a key for each type of scanning object, include process_id, file_path or network_address type. The value varies depending on the type of scanning object
result.details.statusstringIndicates the scanning object is clear, dirty or in-progress
result.details.total_sourcenumberIndicates the total number or engines used to scan the object
result.details.hashstringIndicates the hash code of the scanning object if the object is a file or process
result.details.scan_timestringIndicates the scan time of this particular file.
result.details.mso_data_idstringIndicates the data_id on Metadefender of the scanning object if the object is a file or process
result.details.network_addressstringNetwork address of the detected threat
result.details.domain_namestringDomain name of the connection (only for external IP addresses)
result.details.mac_addressstringMAC address of the connection (only for internal IP addresses)
result.details.explanationarray<string>An array of reasons which explain the scanning status
result.details.threatsarray<object>An array of threats found with details information
result.details.threats.threat_namestringName of threat found
result.details.threats.av_namestringName of antivirus engine which found the threat
result.details.threats.scan_timestringScan time of specific antivirus engine over the threat
result.details.threats.av_def_timestringThe definition time of a specific antivirus engine
result.details.threats.assessmentstringType of threat detected
result.details.threats.source_namestringSource of the feed, usually the domain where the feed is from (e.g., example.com)
result.details.threats.confidentstringRepresents the reliability of the detection based on several factors. The higher the score, the more reliable the result.
result.details.geo_infoobjectAn object represents the geolocation of address
result.details.geo_info.country_namestringCountry name of the network address (e.g., Brazil)
result.details.geo_info.country_codestringCountry name of the network address (e.g., BR)
result.details.geo_info.region_namestringRegion name of the network address (e.g., Rio de Janeiro)
result.details.geo_info.region_codestringRegion code of the network address (e.g., 27)
result.details.geo_info.citystringCity name of the network address (e.g., Rio de Janeiro)
result.files_in_archivearray<object>(optional) List all file inside an archive file along with its detail information if the archive file is dirty

Result Codes​

CodeNameDescription
0WAAPI_OKThe operation completed successfully.
note

Other codes may be returned. See the full Result Codes reference for the complete list.

Remarks​

Error Handling​

The results of this function are determined by the error code returned by the call. If successful, WAAPI_OK or a special success code will be returned. Always check both the function return value and the result.code field in the output JSON.

Examples​

Examples will be added here demonstrating the usage of this method.

See Also​


Last updated: 2026-10-01