Skip to main content
POST
/
api
/
scan
Scan a file for malware
curl --request POST \
  --url https://6465762e76312e7363616e.slayers.tech/api/scan \
  --header 'Content-Type: multipart/form-data' \
  --form file='@example-file'
{
  "detections": [
    [
      "Avast",
      "Malware"
    ],
    [
      "Kaspersky",
      "Trojan"
    ]
  ],
  "file_hash": {
    "md5_hash": "5d41402abc4b2a76b9719d911017c592",
    "sha256_hash": "2c26b46b68ffc68ff99b453c1d30413413422d706483bfa0f98a5e886266e7ae"
  },
  "has_detections": true,
  "metadata": {
    "FileSize": "1024 bytes",
    "FileType": "PDF"
  },
  "num_detections": 2
}

Scan file

Uploads a file to be scanned. The request is multipart/form-data.

Form fields

  • file (required): the file to scan
  • apikey (optional): alternative to the X-API-Key header
  • devicename (optional): alternative to the X-Device-Name header

Headers

X-API-Key
string

User API key for authentication

X-Device-Name
string

Name of the device making the request

Body

multipart/form-data
file
file
required

The file to scan

apikey
string

User API key (alternative to X-API-Key header)

devicename
string

Device name (alternative to X-Device-Name header)

Response

Scan completed successfully

detections
string[][]

List of detections found

Tuple of (antivirus_name, detection_name)

file_hash
object
has_detections
boolean

Whether any detections were found

metadata
object

File metadata extracted using exiftool and python-magic

num_detections
integer

Number of malware detections