# telegram-logger

> An npm package for logging to telegram bot

Latest version **1.0.0** (published 2017-02-20) · MIT license · 0 weekly downloads

## Install

```sh
npm install telegram-logger
pnpm add telegram-logger
yarn add telegram-logger
bun add telegram-logger
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2017-02-20 |
| First published | 2017-02-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Piotrovskyi |
| Maintainers | piotrovskyi |
| Keywords | telegram, bot, logger |

## Links

- npm: https://www.npmjs.com/package/telegram-logger
- Repository: https://github.com/Piotrovskyi/telegram-logger
- Homepage: https://github.com/Piotrovskyi/telegram-logger#readme
- Issues: https://github.com/Piotrovskyi/telegram-logger/issues
- npm.io page: https://npm.io/package/telegram-logger

## Dependencies (1)

- [telegram-bot-api](https://npm.io/package/telegram-bot-api.md) ^1.2.0

## Alternatives

- [cli-color](https://npm.io/package/cli-color.md) — 3.4M weekly downloads
- [log](https://npm.io/package/log.md) — 1.3M weekly downloads
- [logstash-client](https://npm.io/package/logstash-client.md) — 4.5K weekly downloads
- [@nocobase/plugin-logger](https://npm.io/package/@nocobase/plugin-logger.md) — 2.0K weekly downloads
- [child-process-debug](https://npm.io/package/child-process-debug.md) — 695 weekly downloads

## Recent versions

- 1.0.0 (latest) — 2017-02-20

## README

logger library for node.js and telegram

## API

```js
const telegramLogger = require('telegram-logger')
```
Create a new logger function using the given telegram bot `token` and `chat_id`.
The `format` argument you can get after [create bot](https://core.telegram.org/bots#3-how-do-i-create-a-bot)

The `chat_id` argument you can get [here](http://stackoverflow.com/questions/32423837/telegram-bot-how-to-get-a-group-chat-id-ruby-gem-telegram-bot)

#### Using

```js
const logger = telegramLogger({
  token: '<PUT YOUR TOKEN HERE>',
  chat_id: '<PUT YOUR CHAT ID HERE>',
})

logger('message')
  .then(data => console.log(data))
  .catch(err => console.error(err))
```

---
_Source: https://npm.io/package/telegram-logger · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
