New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More

airgram-api

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

airgram-api

This repository contains strict typed wrappers for all [TDLib](https://core.telegram.org/tdlib) (1.4.0) methods and classes.


Version published
Weekly downloads
2
decreased by-50%
Maintainers
1
Weekly downloads
 
Created

Wrappers for TDLib API

This repository contains strict typed wrappers for all TDLib (1.4.0) methods and classes.

Differences from the original API:

  • All parameter names are represent in "camelCase".
  • Parameter @type renamed to _.

Installation

# npm
npm install airgram-api

Basic usage

import { apiFactory } from 'airgram-api'

function callApi (method, params) {
    // some function which sends request to TDLib
    return requestToTDLib({
      _: method,
      ...params
    }) 
}

const api = apiFactory(callApi)

// Now you can invoke all TDLib methods
api.getMe().then((response) => {
  console.info(response)
})

License

The source code is licensed under GPL v3. License is available here.

FAQs

Package last updated on 29 Jun 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts