File: getme.js

package info (click to toggle)
node-telegram-bot-api 2.0.1-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 2,964 kB
  • sloc: javascript: 1,333; makefile: 2
file content (14 lines) | stat: -rw-r--r-- 267 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
const TG = require('../lib/index')

const BOT_TOKEN = process.env.BOT_TOKEN
if (!BOT_TOKEN) {
    console.log('Opps, you need to define your BOT_TOKEN')
}

const api = new TG({
    token: BOT_TOKEN
})

api.getMe()
.then(console.log)
.catch(console.err)