This project has been archived by its maintainers, and is no longer receiving any updates.
Telegram Interface
A quick tool for listing the Telegram Messenger groups that a user-account is invited into and listing the users within groups.
Project
Install
via PyPi
pip3 install telegram-interface-cli
via Source
git clone https://github.com:ndejong/telegram-interface
cd telegram-interface
python3 -m venv venv
source venv/bin/activate
pip3 install -r requirements.txt
python3 setup.py clean
python3 setup.py test
python3 setup.py install
Prerequisites
- A Telegram Messenger account invited into one or more group chat channels.
- Setup API credentials on the Telegram Messenger account core.telegram.org/api/obtaining_api_id
Configuration
Configuration is via a YAML format as per the following example
---
telegram_interface_cli:
#
# api_id: env:telegram_api_id
# api_hash: env:telegram_api_hash
# api_phone: env:telegram_api_phone
#
api_id: '123456'
api_hash: '0123456789abcdef0123456789abcdef'
api_phone: '12125551234'
session_filename: '~/.telegram.session'
Loading environment variables into the configuration file is possible using the env name with an
env: prefix, for example
api_id: env:telegram_api_id
In this case the api_id value is loaded loaded from the telegram_api_id env value.
Environment Variables
TELEGRAMINTERFACECLI_CONFIG_FILENAME- configuration file override.
Outputs
By default output is in JSON data-structures making it easier to chain with other tools such as jq for further parsing
and filtering if required.
Additionally, CSV outputs are possible using the --csv argument.
Log status messages are sent to stderr and do not get in the way of pipe style tool chaining.
Usage
usage: telegram-interface [-h] [-c <filename>] [-f <filename>] [-o <filename>]
[-g] [-u] [--csv] [-d]
Telegram Interface v0.1.4
optional arguments:
-h, --help show this help message and exit
-c <filename> Configuration file to use (required)
-f <filename> Data filename to use. If the data-file already exists it will
be loaded as input without connecting to Telegram thus
allowing a reload of a previous run. By default a filename is
auto-generated in the current-working-directory.
-o <filename> Output filename, by default output is sent to <stdout>.
-g, --group Output names of groups that the Telegram user is a member of,
combine with -u to obtain the users within these groups.
-u, --user Output names of the users that the Telegram user has
visibility on.
--csv Output in flattened CSV format.
-d, --debug Debug level logging output.
A quick tool for listing the Telegram Messenger groups that a user-account is
invited into and listing the users within groups.
Authors
License
BSD-2-Clause - see LICENSE file for full details.
Metadata
Release files for telegram-interface-cli 0.1.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| telegram-interface-cli-0.1.7.tar.gz | 8.4 kB | Without provenance | Details for telegram-interface-cli-0.1.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| telegram_interface_cli-0.1.7-py3-none-any.whl | Python 3 | none | any | Details for telegram_interface_cli-0.1.7-py3-none-any.whl |
Total release size: 20.1 kB
Release files / telegram-interface-cli-0.1.7.tar.gz
| Download URL | telegram-interface-cli-0.1.7.tar.gz |
|---|---|
| Size | 8.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
db047d76a6fc09f5da7151caa846fe6a8d96743473841c8557c90fd69bccb542
|
|
BLAKE2b-256 checksum How to use checksums |
1a429629093526fe98e88c21dcb65f5d312087e73130cc6448049fef337d861a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.6.9
|
Release files / telegram_interface_cli-0.1.7-py3-none-any.whl
| Download URL | telegram_interface_cli-0.1.7-py3-none-any.whl |
|---|---|
| Size | 11.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1de44ddc5cdc51600b7594c0896e31f6a9f3957a31fdba30c214a7fa329c1d77
|
|
BLAKE2b-256 checksum How to use checksums |
f0183c3c2234ef8ec2c799a1e0efc88ff86c22d3bc693c08f3738e9bab90b853
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.6.9
|
Security for telegram-interface-cli 0.1.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.