Read this in other languages: English | 简体中文
Archive webpages from Telegram channel and etc.
Using npm:
npm install @wabarc/archiver
Using yarn:
yarn add @wabarc/archiver
import { Archiver } from '@wabarc/archiver';
// const archiver = require('@wabarc/archiver');
const archived = await new Archiver().telegram({ channel: 'channel_name', msgid: 1 }).start();
console.log(archived)
The available instance methods are listed below.
- archiver#telegram({ channel: string, msgid: number })
- archiver#start()
- archiver#do()
- archiver#stage()
These are the available options for archival webpage from Telegram channel. channel
and msgid
is required.
{
// `channel` is the Telegram channel name
channel: 'wabarc_testing',
// `msgid` is the message id published on the Telegram channel.
msgid: 1
}
[
{
id: 1,
url: 'https://example.org/',
title: 'Example ORG',
content: '<html><head></head><body>body content</body></html>',
success: true
}
]
This software is released under the terms of the GNU General Public License v3.0. See the LICENSE file for details.