Skip to content

API Documentation

Nathanaël Khodl edited this page Jul 10, 2023 · 2 revisions

Disclaimer

The data returned by this API is provided on an "as is" basis, without any form of warranty, whether expressed or implied, including but not limited to warranties of accuracy, completeness, or reliability.

The authors of the API shall not be held liable for any claims, damages, or other liabilities arising from, connected with, or resulting from the use or misuse of the data.

This applies to any kind of claim, whether it be contractual, tortious, or otherwise.

Endpoints

GET /api/ratings

Displays the list of all ratings available.

{
   "ratings": [
      {
         "title": "Pay attention", // The title of the rating
         "description": "This source has content that may or may not be legit",
         "is_dangerous": false|true, // Whether the source is dangerous or not. Available if probability is high enough
         "level": 0.5 // A number between 0 (scam) and 1 (reliable)
      },
      ...
   ]
}

GET /api/check/{DOMAIN|EMAIL}

Returns the rating for an email address or a domain name (an url without path).

{
   "is_analysed": true, // Whether the domain has an analysis or not
   "domain": {
      "host": "unicef.org", // The extracted host
      "analysis": { // Analysis for that domain, if is_analysed is true
         "rating": { // The rating of the analysis
            "title": "Official source",
            "description": "This address is an official source that you can trust.",
            "is_dangerous": false,
            "level": 0.99
         },
         "title": "Official UN website" // A title for the analysis
      }
   }
}
Clone this wiki locally