Skip to main content

addToBlocklist

Use this method to add one or more file hashes to the Blocklist.

Parameters

Parameter

Type

Optional

Description

hashType

Number

No

the algorithm used to obtain the hash. Possible values: 1 - SHA256, 2 - MD5

hashList

Array

No

An array containing several hashes. All hashes must be of the type specified by the hashType parameter.

companyId

String

Yes

The ID of the company to which the Blocklist item belongs.

sourceInfo

String

No

A description for the hashes.

Return value

This method returns a Boolean which is True if the operation was successful.

Example

Request:

  {
   "id": "0df7568c-59c1-48e0-a31b-18d83e6d9810",
   "jsonrpc": "2.0",
   "method": "addToBlocklist",
   "params": {
       "companyId": "5b680f6fb1a43d860a7b23c8",
       "hashType" : 2,
       "hashList": ["5b7ac19bb1a43dfb107b23c6",
                    "f696282aa4cd4f614aa995190cf442fe"],
       "sourceInfo": "Added from public API"
        }
  }  

Response:

   {
       "id": "0df7568c-59c1-48e0-a31b-18d83e6d9810",
       "jsonrpc": "2.0",
       "result": true
   }