Skip to content
This repository has been archived by the owner on Jul 20, 2023. It is now read-only.

Latest commit

 

History

History
41 lines (29 loc) · 1.05 KB

README.md

File metadata and controls

41 lines (29 loc) · 1.05 KB

SpamProtection API Wrapper for Node.js

Installation and Basic Usage

Install it with your favorite package manager.

## as usual, with npm
npm i spamprotection

## using yarn?
yarn install spamprotection

Once installed, call the Client class as needed.

// Adopted from https://github.com/spamwatch/spamwatch-js#basic-usage
const SPB = require("spamprotection");
const lookupApi = new SPB.Client

(async () => {
    // Telegram username
    const netkaspam = lookupApi.queryUser("Netkas")
    console.log(netkaspam)

     // Telegram UID
    const isThisServiceNotifs = lookupApi.queryUser(777000)
    console.log(isThisServiceNotifs)

    // Private Telegram ID, copied from the public logs (https://t.me/SpamProtectionLogs/65181)
    const someRandomSpammer = lookup.queryUser("TEL-37f7eb286e1702732205949a15c75609625bf5a95655b8023a9d2c8900816eeb-e6f99ecb")
    console.log(someRandomSpammer)
})

Roadmap

  • Authenication for Operator/Agent/sub-operator API (through ?access_token=<stuff> parameter)
  • GitLab CI for tests and prettier