{"id":18222592,"url":"https://github.com/wl0ckk/circle_tg","last_synced_at":"2026-04-29T21:32:31.136Z","repository":{"id":260907239,"uuid":"881136325","full_name":"Wl0cKk/circle_tg","owner":"Wl0cKk","description":"Bot for converting video into a circle note, scheduling feeds to channels, and merging video files together","archived":false,"fork":false,"pushed_at":"2024-11-05T12:50:05.000Z","size":66,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-14T01:45:04.811Z","etag":null,"topics":["bot","converter","docker","docker-compose","ffmpeg","ffmpeg-wrapper","parser","ruby","schedule","scheduler","send-video","telegram","telegram-bot","telegram-bot-api","telegram-channel","timetable","video-bot","video-processing","video-tools"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Wl0cKk.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-10-31T01:06:19.000Z","updated_at":"2024-11-28T08:56:04.000Z","dependencies_parsed_at":"2024-11-03T14:31:58.279Z","dependency_job_id":"9ba421b7-1b1c-4da4-828e-22976597018d","html_url":"https://github.com/Wl0cKk/circle_tg","commit_stats":null,"previous_names":["wl0ckk/circle_tg"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wl0cKk%2Fcircle_tg","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wl0cKk%2Fcircle_tg/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wl0cKk%2Fcircle_tg/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wl0cKk%2Fcircle_tg/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Wl0cKk","download_url":"https://codeload.github.com/Wl0cKk/circle_tg/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247761051,"owners_count":20991533,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bot","converter","docker","docker-compose","ffmpeg","ffmpeg-wrapper","parser","ruby","schedule","scheduler","send-video","telegram","telegram-bot","telegram-bot-api","telegram-channel","timetable","video-bot","video-processing","video-tools"],"created_at":"2024-11-04T00:00:29.446Z","updated_at":"2026-04-29T21:32:31.098Z","avatar_url":"https://github.com/Wl0cKk.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\r\n  \u003cimg src=\"https://github.com/user-attachments/assets/5d7aac49-2d8e-4b61-aacd-54469d89aee4\" alt=\"project-image\"\u003e\r\n\u003c/p\u003e\r\n\r\n---\r\n# What can this bot do?\r\n|  |                                                                                                                                                                    |\r\n|--|--------------------------------------------------------------------------------------------------------------------------------------------------------------------|\r\n|✅| \u003cdetails closed\u003e\u003csummary\u003eConvert sent video into circles\u003c/summary\u003e\u003cimg src=\"https://i.imgur.com/BtSEUKD.png\" alt=\"convert-video\"\u003e\u003c/details\u003e                        |\r\n|✅| \u003cdetails closed\u003e\u003csummary\u003eCombine multiple files into one mp4 and send it to you\u003c/summary\u003e\u003cimg src=\"https://i.imgur.com/AVOc6jX.png\" alt=\"combine-files\"\u003e\u003c/details\u003e |\r\n|✅| \u003ca href=\"#syntax-for-caption\"\u003eCan send a circle to channels, at a given time\u003c/a\u003e                                                                                                                   |\r\n\r\n### This bot avoid of some annoying limitations because it uses the [Local Bot API Server](https://core.telegram.org/bots/api#using-a-local-bot-api-server)\r\n\r\n### although this bot is [long polling](https://www.geeksforgeeks.org/what-is-long-polling-and-short-polling/), kill feature here is the size of files we can work with.\r\n\r\n\u003e [!IMPORTANT]\r\n\u003e ### But the circle video limit is still 60sec, so if the video is long it will be trimmed from the beginning to one minute \r\n---\r\n## How to run\r\n  ```bash\r\n    git clone https://github.com/Wl0cKk/circle_tg.git\r\n    cd circle_tg\r\n  ```\r\n  #### Then create or rename [config_example.json](https://github.com/Wl0cKk/circle_tg/blob/main/config_example.json) to config.json\r\n  `touch config.json` or `mv config_example.json config.json`\r\n  #### Open it in any editor and replace TOKEN with obtained token from [@BotFather](https://t.me/botfather)\r\n  \u003e #### channels can be empty if you don't need broadcast feature.\r\n  \r\n  \u003e [!IMPORTANT]  \r\n  \u003e #### Get *API_ID* and *API_HASH* here - https://core.telegram.org/api/obtaining_api_id\r\n- ### Docker compose\r\n\u003e [!TIP]\r\n  \u003e - *In [Dockerfile.bot](https://github.com/Wl0cKk/circle_tg/blob/main/Dockerfile.bot) you can specify \u003ca href=\"#options\"\u003earguments\u003c/a\u003e separated by commas*\r\n  \u003e - `CMD [\"ruby\", \"--mjit\", \"./bot\", \"--server=http://telegram-bot-api:8081\", \"--keep_files\", \"--silent\"]`\r\n\r\n  \u003e Have you already installed docker and docker-compose?\r\n  #### Create or rename *[.env_example](https://github.com/Wl0cKk/circle_tg/blob/main/.env_example)* to *.env*\r\n  `touch .env` or `mv .env_example .env`\r\n  #### Open it in any editor and replace *API_ID* and *API_HASH* with yours\r\n  ### *You are free to change the folder name, but do the same in [docker-compose.yml](https://github.com/Wl0cKk/circle_tg/blob/main/docker-compose.yml).*:\r\n  ```bash\r\n    mkdir videos\r\n  ```\r\n  ### *this will install what's needed and run*:\r\n  ```bash\r\n    docker-compose up --build\r\n  ```\r\n  \u003e Installing telegram-bot-api takes a while.\r\n- ### Locally\r\n  \u003e #### You need [ruby](https://www.ruby-lang.org/en/documentation/installation/) and [bundle](https://www.jetbrains.com/help/ruby/using-the-bundler.html#install_bundler) installed.\r\n  ```bash\r\n  ruby -v\r\n  bundle -v\r\n  ```\r\n  \r\n  #### install all \u003ca href=\"https://github.com/tdlib/telegram-bot-api?tab=readme-ov-file#dependencies\"\u003edependencies\u003c/a\u003e and follow the \u003ca href=\"https://github.com/tdlib/telegram-bot-api?tab=readme-ov-file#installation\"\u003einstallation\u003c/a\u003e proccess\r\n  #### Once installed you can run it with \r\n  ```bash\r\n    telegram-bot-api --api-id=API_ID --api-hash=API_HASH --local\r\n  ``` \r\n  #### Then open a new tab in terminal and do the following\r\n  ```bash\r\n  bundle install\r\n  ```\r\n  ```bash\r\n  ruby --mjit bot\r\n  ```\r\n  Specify the \u003ca href=\"#options\"\u003earguments\u003c/a\u003e if you wish\r\n---\r\n## Options\r\n\u003e You can start bot using 3 arguments: --keep_files, --verbose, --silent.\r\n- **--keep_files** — *all files including submitted and edited files will not be deleted*\r\n- **--verbose** — *Log output from [FFMPEG](https://www.ffmpeg.org/) will \u003cins\u003enot\u003c/ins\u003e be muted*\r\n- **--silent** — *Everything will be muted, including logo output and telegram bot logs*\r\n\u003e [!WARNING]  \r\n\u003e *You can't run* **--verbose** *and* **--silent** *at the same time*\r\n---\r\n## Syntax for caption\r\n\u003e [!NOTE]  \r\n\u003e - By sending caption along with the video, the bot will not send the video personally, but to the channels specified in [config.json](https://github.com/Wl0cKk/circle_tg/blob/main/config_example.json)\r\n\u003e - Don't forget to add [channel ID](https://gist.github.com/mraaroncruz/e76d19f7d61d59419002db54030ebe35) to [config.json](https://github.com/Wl0cKk/circle_tg/blob/main/config_example.json)\r\n\u003e - Make the bot an administrator\r\n\r\n- **'.'** — Just a dot, will immediately send circle to channels.\r\n- **'at 2024/11/8 23:05:09'** - specifies a timestamp for an action, `YYYY/MM/DD HH:MM:SS`.\r\n\u003e [!TIP]\r\n\u003e Trailing zero is not important: `at 2024/11/08 23:05:09` or `at 2024/11/08 23:5:9`\r\n### dhms\r\n\u003e This syntax is summarized with the current time.\r\nGiven the current time is 2024/11/03 14:25:\r\n- **'at 5d 23:05:09'** — Scheduled for 2024/11/08 23:05:09.\r\n- **'at 5d 10h25m55s'** — Scheduled for 2024/11/09 00:50:55.\r\n- **'in 10d5h'** — Will happen in 10 days and 5 hours.\r\n---\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwl0ckk%2Fcircle_tg","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwl0ckk%2Fcircle_tg","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwl0ckk%2Fcircle_tg/lists"}