Skip to main content

TriggerInfectionScanRunningProcesses

Will scan given running processes and dlls for a given computer

Syntax​

Method ID​

#define WAAPI_MID_TRIGGER_INFECTION_SCAN_RUNNING_PROCESSES 80001

JSON Input Structure​

{
"input": {
"method": 80001,
"target_process_ids": [
number,
...
],
"scan_all_running_processes": boolean,
"scan_level": string,
"force_rescan": boolean,
"no_file_upload": boolean,
"no_sample_sharing": boolean,
"no_hash_lookup": boolean
}
}

Input Properties​

ParameterTypeDescription
target_process_idsarray<number>An array of process_id which are running need to be scanned. This input need to be specified if scan_all_running_processes is false.
scan_all_running_processesbooleanIf true, will scan all running processes of all users on given computer.
scan_levelstring(optional) Indicates whether function should scan the given process and all the loaded dll and exe by each process by using value 'deep' or the given processes only by using value 'quick'. The default scan_level value is 'quick'
force_rescanboolean(optional) If true, will do a force rescan even we have cached result.
no_file_uploadboolean(optional) If true, the scanned file will only be scanned using the hash lookup, and will not be uploaded to Metadefender or target Metadefender server for scanning. Default value is 'false'
no_sample_sharingboolean(optional) If no_file_upload is set to true, then this value is ignored. Otherwise, if this value is set to true - the file will be saved on Metadefender Server, with intention of sharing samples with antimalware vendors for research. Default value is 'false'
no_hash_lookupboolean(optional) If true, file will not be scanned at all and will not be uploaded to Metadefender or target Metadefender server for scanning. If true, 'no_file_upload' is not used anymore. Default value is 'false'

JSON Output Structure​

{
"result": {
"method": 80001,
"code": number,
"timing": number,
"timestamp": string,
"infection_scan_id": string
}
}

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.infection_scan_idstringA session id key representing the created scanning session

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