Stat API Documentation

Overview


The "stats" API is used to retrieve information relating to the current API key, this includes information such as the current request limits, daily request limits etc.

Requirements


API Key

The leak-lookup API requires an API key to perform queries, to find your API key please click here.

Endpoint


All "stats" API requests should be sent as a POST request to the following endpoint:

https://leak-lookup.com/api/stats

Parameters


API requests require the following parameters:

  • key - This is the clients API key, which can found here.

Fields


API responses contain the following fields:

  • status - active/inactive, current status of API key.
  • type - public/private/inactive, current API key type.
  • added - Y-m-d, date API key was added.
  • updated - Y-m-d H:i:s, date API key was last updated (allowance reset).
  • expiry - Y-m-d H:i:s, API key expiry date.
  • requests - API key current request count.
  • limit - API key current rate-limit count.

Responses


Standard Response

The following response format is returned regardless of the status of the provided API key.

{
    "error": "false",
    "message": {
        "status":   "active",
        "type":     "public",
        "added":    "2020-06-11",
        "updated":  "2022-01-04 18:26:16",
        "expiry":   "2024-01-04 17:32:53",
        "requests": 2,
        "limit":    10
    }
}

Error Response

Should an error occur, the follow response will be returned.

Please see below for an expanded explanation of all provided error messages.

{
    "error": "true",
    "message": ""
}

Error Messages

  • MISSING API KEY - Invalid search API request, the search key parameter is missing.
  • MISSING REQUIRED PARAMETERS - Invalid search API request, please refer to the search API documentation.
  • EMPTY VALUE DETECTED - Invalid search API request, empty parameter detected. Please refer to the search API documentation.
  • INVALID API KEY - API key provided is invalid, please contact support.

Examples


Curl

Here are some command line examples using CURL, please replace {API_KEY} with the provided API key.

Standard example:

curl 'https://leak-lookup.com/api/stats' -d 'key={API_KEY}'