mlab Hash Lookup API

Reputation of a file hash across known-good and known-bad reference sets.

GitHub OpenAPI

Operations 2

GET /api/v1/scan/hash Look up a file hash #
POST /api/v1/scan/hash Look up a batch of file hashes #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/mlab-sh:mlab-sh-hash-lookup-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

mlab-sh-hash-lookup-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: mlab.sh Hash Lookup API
  version: 1.0.0
  description: 'The **mlab.sh** REST API lets you launch domain security scans, look up IP, crypto, hash, URL, email, phone and MAC intelligence, extract IOCs from raw text, analyze files and scripts, triage indicator lists, run RedKit audits, schedule scans, work on cases and inspect SSL certificates programmatically.


    All endpoints are authenticated with an API key sent in the `Authorization` header. Generate a key from **Organization → Settings → API keys** on mlab.sh. A key belongs to the organization and carries permissions chosen when it is created (`scan.lookup`, `scan.domain`, `scan.file`, `scan.batch`, `redkit`, `watchdog.read`, `watchdog.write`, `cases.read`, `cases.write`, `tags.read`, `tags.write`, `webhooks.manage`, or full access). A call outside the key''s permissions returns **403** naming the missing permission; organization and account settings are never reachable with a key. `webhooks.manage` is the one exception and is **never part of full access**: it must be ticked by name (a full-access key can hold it too). It lets a key register signed webhook endpoints and list or delete only the ones it registered itself.


    **Working through an AI agent?** Prefer the Model Context Protocol server at `https://mlab.sh/mcp` (Streamable HTTP, OAuth 2.0 or an `mcp_` token). It exposes 48 tools covering most of what is below plus CVE search, threat-actor attribution, SBOM scanning, cases and workspace memory, cluster and Proxmox inspection and offline indicator lookups that consume no scan quota, so it is a wider surface than this REST API rather than a wrapper over it. See https://doc.mlab.sh/docs/mlab.sh/integrations/mcp and https://mlab.sh/llms.txt.


    **Permissions.** Each operation lists the API key permission it needs (`x-api-key-permission`). Keys created before 2026-10-01 were migrated to full access.


    **Expiry.** A key is created with a lifetime (90 days by default; 30, 180, 365 days or never). An expired key is answered **401**, like an unknown one. The expiry date shows in Organization → Settings → API keys.


    **Quota headers.** Every call that spends scan quota answers with `X-RateLimit-Limit` (the plan''s limit for that scan type), `X-RateLimit-Remaining` (what is left after this call), `X-RateLimit-Resource` (the scan type) and `X-RateLimit-Window` (86400: quotas count a rolling 24 hours, so there is no fixed reset time). Unlimited plans send none.'
  contact:
    name: mlab.sh support
    email: contact@cyberdream.io
    url: https://mlab.sh
  license:
    name: Proprietary
  x-source-of-truth: html/openapi.json in the mlab.sh app repository, served at https://mlab.sh/openapi.json. The docs repository generates openapi.yaml from it with scripts/sync-openapi.mjs.
servers:
- url: https://mlab.sh
  description: Production
security:
- ApiKeyAuth: []
tags:
- name: Hash Lookup
  description: Reputation of a file hash across known-good and known-bad reference sets.
paths:
  /api/v1/scan/hash:
    get:
      tags:
      - Hash Lookup
      summary: Look up a file hash
      operationId: lookupHash
      description: 'Checks an MD5, SHA-1 or SHA-256 digest against CIRCL hashlookup (NIST NSRL), which knows legitimate files and flags some known malware, plus any sample already analysed on mlab (`mlab_sample`). Answers are cached.


        `unknown` means the sources were reached and none knows the digest. `unavailable` means a source could not be reached; it is never cached, retry. `sources_answered` says how many feeds actually answered. A SHA-512 is accepted but answers `not_queryable`, since no feed indexes it.


        Offline analysis: no scan job and no scan quota.


        **API key permission:** `scan.lookup`.'
      parameters:
      - name: hash
        in: query
        required: true
        description: MD5, SHA-1, SHA-256 or SHA-512 hex digest.
        schema:
          type: string
          example: 44d88612fea8a8f36de82e1278abb02f
      responses:
        '200':
          description: Look up a file hash
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HashVerdict'
              example:
                hash: 44d88612fea8a8f36de82e1278abb02f
                algorithm: MD5
                verdict: known_malicious
                found: true
                known_malicious: true
                matched_on: md5
                enrichment_source: circl-hashlookup
                trust: 100
                cached: true
                sources_hit: 1
                sources_answered: 1
                sources_queried: 1
        '400':
          description: Missing or malformed input. The body carries the reason.
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
      x-api-key-permission: scan.lookup
    post:
      tags:
      - Hash Lookup
      summary: Look up a batch of file hashes
      operationId: lookupHashBulk
      description: 'The same lookup as the GET route, for up to 500 digests (an EDR export, say). Cached answers come from one query, the rest fan out to the feeds within a 35 s budget. Results come back in request order. Requires an authenticated caller. Offline analysis: no scan job and no scan quota.


        **API key permission:** `scan.lookup`.'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
              - hashes
              properties:
                hashes:
                  type: array
                  maxItems: 500
                  items:
                    type: string
      responses:
        '200':
          description: Verdicts in request order.
          content:
            application/json:
              schema:
                type: object
                properties:
                  count:
                    type: integer
                  cached:
                    type: integer
                    description: How many answers came from the cache.
                  summary:
                    type: object
                    additionalProperties:
                      type: integer
                    description: Count per verdict.
                  results:
                    type: array
                    items:
                      $ref: '#/components/schemas/HashVerdict'
                  invalid:
                    type: array
                    items:
                      type: object
                    description: Entries that are not a hex digest of a supported length.
        '400':
          description: Missing or malformed input. The body carries the reason.
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
      x-api-key-permission: scan.lookup
components:
  responses:
    Unauthorized:
      description: Invalid or missing API key.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            status: error
            message: Invalid or missing API key.
    Forbidden:
      description: The API key lacks the permission this endpoint needs, or the endpoint is not open to API keys (organization and account settings never are).
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: This API key does not have the 'cases.write' permission (Write cases). An owner or admin can add it in the organization settings.
  schemas:
    Error:
      type: object
      properties:
        status:
          type: string
          example: error
        message:
          type: string
          example: Description of what went wrong.
    HashVerdict:
      type: object
      properties:
        hash:
          type: string
        algorithm:
          type: string
          enum:
          - MD5
          - SHA-1
          - SHA-256
          - SHA-512
        verdict:
          type: string
          enum:
          - known_good
          - known_malicious
          - unknown
          - unavailable
          - not_queryable
          - disabled
        found:
          type: boolean
        known_malicious:
          type: boolean
        matched_on:
          type: string
        enrichment_source:
          type: string
          nullable: true
          description: Which feed answered.
        source:
          type: string
        product:
          type: string
        family:
          type: string
        file_name:
          type: string
        summary:
          type: string
        cached:
          type: boolean
        checked_at:
          type: string
          nullable: true
        sources_hit:
          type: integer
        sources_answered:
          type: integer
        sources_queried:
          type: integer
        sources:
          type: object
          description: Each feed's own answer.
        mlab_sample:
          type: object
          description: The mlab file analysis of this sample, when one exists.
        hint:
          type: string
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
      description: 'Your API key, prefixed with `token `. Example: `Authorization: token mlab_your_api_key_here`. Each key only reaches the endpoints its permissions allow.

        '