Radio server for Telegram groups.
-
Create
.env
in root:SESSION_NAME=<Name of .session file | Default: TgRadio> TG_API_ID=<token_id> TG_API_HASH=<token_hash> TG_PHONE_NUMBER=<you phone number> AVAILABLE_GROUPS=<Group IDs separated by commas | Default: without available filter> CMD_PREFIX=<Prefix for commands | Default: !>
For get
id
andhash
see this -
Create
default.raw
audio for loop playing if channel not have tracks. use ffmpeg to convert and move output file to root directory.$ ffmpeg -i path/to.mp3 -f s16le -ac 2 -ar 48000 -acodec pcm_s16le default.raw
-
Run server
$ pip install -r requirements.txt $ python TgRadio.py
-
Add you radio account in group.
-
Send
!help
in group for get help.
- License: © 2021 M.Price.
See the LICENSE file for license rights and limitations (MIT).