telegram-bot-activitystreams

1.0.2 • Public • Published

Telegram Bot Messages to ActivityStreams 2.0

ActivityStreams 2.0

Activity Available
summary
instrument
actor
origin
target
origin
startTime
endTime
Objects Available
Person
Profile
Note
Audio
Video
Document
Event
Place

Example

Example use node-telegram-bot-api

const activitystreams = require('telegram-bot-activitystreams');
const TelegramBot = require('node-telegram-bot-api');

const token = 'YOUR_TELEGRAM_BOT_TOKEN';
const bot = new TelegramBot(token, {polling: true});

bot.on('message', (msg) => {
  const activity = activitystreams(msg);
  bot.sendMessage(msg.chat.id, 'Hello ' + activity.actor.name);
});

Package Sidebar

Install

npm i telegram-bot-activitystreams

Weekly Downloads

4

Version

1.0.2

License

MIT

Unpacked Size

9.73 kB

Total Files

9

Last publish

Collaborators

  • qertis