Integrate a Live Chat on your website with Telegram
867
Docker Image for integrating self hosted Live Chat on your website with Telegram. Credits go to https://github.com/idoco/intergram
/newbot and run through the bot setup process. You will get an HTTP API Token. Save that for later.docker run -d -p 80:3000 -e TELEGRAM_TOKEN="YOUR_TOKEN" mainmethod/intergram. Alternatively you can use docker-compose (see below) or any other container orchestration, which supports Docker.<YOUR_TOKEN> with the HTTP API Token you got from @BotFather and <YOUR_SERVER_URL> with the URL under which you will run this Docker Image. Run curl "https://api.telegram.org/bot<YOUR_TOKEN>/setWebhook?url=<YOUR_SERVER_URL>/hook"/start. You will get a chat id.<body> of your website. Replace <CHAT_ID> with the chat id you got from your bot. Replace <YOUR_SERVER_URL> with the URL under which you will run this Docker Image.<script>
window.intergramId = "<CHAT_ID>";
window.intergramServer = "<YOUR_SERVER_URL>";
</script>
<script id="intergram" type="text/javascript" src="<YOUR_SERVER_URL>/js/widget.js"></script>
If you want to use docker-compose instead of a simple docker run, you can use it this way. Replace <YOUR_TOKEN> with the HTTP API Token you got from @BotFather:
version: "3.1"
services:
intergram:
image: mainmethod/intergram
ports:
- "80:3000"
environment:
- TELEGRAM_TOKEN=<YOUR_TOKEN>
restart: unless-stopped
Content type
Image
Digest
Size
83.5 MB
Last updated
about 6 years ago
docker pull mainmethod/intergram