telegram客户端for golang,本程序用于使用自己账号定时发送tg消息给指定用户/组/channe

使用说明

此项目主要用于tg自己账号登录 定时发送消息给某人

当前容器支持 amd64、i386、arm64、armhf

特别说明!!! tg的验证码不是发的手机短信,是发送到了tg客户端上!!!!国内手机号需要加上+86!!

首次使用需要进行登录

需要使用docker run进行登录处理

docker run -it --rm --name tg_cli \
-v `pwd`:/home \
-e AppID="1807909" \
-e AppHash="4b1594bcfab16b370686b14d85c60559" \
-e ProxyStatus="true" \
-e ProxyType="Socks5" \
-e ProxyAddr="192.168.0.111" \
-e ProxyPort="7890" \
-e ProxyUser="" \
-e ProxyPasswd="" \
scjtqs/go-tg:latest

AppID 可不填

AppHash 可不填

ProxyStatus 是否开启 网络代理,默认为 "false"

ProxyType 支持Socks5HTTPHTTPSMtProto

ProxyPasswd 如果是MtProto 这里填secret

ProxyAddr 这个别填 localhost和 127.0.0.1。否则会识别成docker容器内部,而非宿主机

国内阿里云镜像 registry.cn-hangzhou.aliyuncs.com/scjtqs/go-tg:latest

其他 环境变量,请查看 Dockerfile.go-td 里面的 ENV部分

WebApiStatus 是否开启api,默认为 "false"。要开启请填 "true"

WebApiPort api监听端口,默认"9001"

WebApiToken api鉴权token,默认 "abcde"

定时任务配置

首次运行后,当前目录会生成一个cron.json目录

{
	"cron_config": [
		{
			"cron": "* * * * *",
			"to_user_name": "@LvanLamCommitCodeBot",
			"text_msg": "/start"
		},
		{
			"cron": "* * * * *",
			"to_user_name": "@TuringLabbot",
			"text_msg": "/start"
		}
	]
}

cron 是定时配置,参考linux的crontab,5个参数为分钟即,6个参数为秒级

to_user_name 是对方的username

text_msg 是要发送的消息类容

请自行修改

cron薅羊毛参考 1,2,3,4,5 0 1,8,16,24 * ?

docker后台运行

docker run  -D --restart=always --name tg_bot \
-v /yourdir:/home \
-e ProxyStatus="true" \
-e ProxyType="Socks5" \
-e ProxyAddr="192.168.0.111" \
-e ProxyPort="7890" \
-e ProxyUser="" \
-e ProxyPasswd="" \
scjtqs/go-tg:latest

api 功能

点击查看

使用docker-compose 方式运行

点击查看

for develop

如果我想自己修改代码,要如何编译当前代码

Owner
scjtqs
前世今生,再聚首。
scjtqs
Similar Resources

A bot based on Telegram Bot API written in Golang allows users to download public Instagram photos, videos, and albums without receiving the user's credentials.

InstagramRobot InstagramRobot is a bot based on Telegram Bot API written in Golang that allows users to download public Instagram photos, videos, and

Dec 16, 2021

Bot para o discord escrito em Golang durante o workshop ministrado na Codecon 2021

Codecon Bot Bot para o discord escrito em Golang durante o workshop ministrado na Codecon 2021 Primeiramente no arquivo main.go coloque o TOKEN do bot

Oct 4, 2021

企业微信群机器人接口 Golang 封装

wxwork-bot-go 企业微信群机器人接口 Golang 封装 Usage package main import ( "fmt" "log" "github.com/vimsucks/wxwork-bot-go" ) func main() { bot :

Jan 3, 2023

Golang bot that connects to slack using Socketclient to read and write messages.

Golang bot that connects to slack using Socketclient to read and write messages.

🚀 (not)simple go project 🚀 Golang bot that connects to slack using Socketclient to read and write messages. 🏆 Use 🏆 @SquidBot : Mentions your name

Aug 23, 2022

telegram 的 golang 客户端。可api,可定时发送消息。

使用说明 此项目主要用于tg自己账号登录 定时发送消息给某人 当前容器支持 amd64、i386、arm64、armhf 特别说明!!! tg的验证码不是发的手机短信,是发送到了tg客户端上!!!!国内手机号需要加上+86!! 首次使用需要进行登录 需要使用docker run进行登录处理 dock

Nov 25, 2022

An easy-to-use discord bot template written in golang using discordgo

Discord Bot An easy-to-use discord bot template written in golang using discordgo. This template was written for learning golang. It will be updated a

Oct 30, 2021

Discord Bot written in Go. Created for 'Intro to Golang', Fall 21

goDiscordBot Discord Bot written in Go. Created for 'Intro to Golang', Fall 21 Session where we coded the bot (goes over setup steps): https://gdsc.co

Nov 3, 2021

Paraguas Bot Reloaded With Golang

Paraguas Bot Reloaded Usage You need an env file ("env.env") on the root directory which contains a "TOKEN" key/value pair. Example: TOKEN=YOURSECRETK

Nov 10, 2022

Discord Bot in Golang

Discord Bot in Golang

Discord Bot in Golang. In this we will be creating a simple discord bot which retur **pong** when we type **ping** . For this you have to be admin of

Dec 19, 2022
Golang telegram bot API wrapper, session-based router and middleware

go-tgbot Pure Golang telegram bot API wrapper generated from swagger definition, session-based routing and middlewares. Usage benefits No need to lear

Nov 16, 2022
A golang implementation of a console-based trading bot for cryptocurrency exchanges
A golang implementation of a console-based trading bot for cryptocurrency exchanges

Golang Crypto Trading Bot A golang implementation of a console-based trading bot for cryptocurrency exchanges. Usage Download a release or directly bu

Dec 30, 2022
Golang Framework for writing Slack bots

hanu - Go for Slack Bots! The Go framework hanu is your best friend to create Slack bots! hanu uses allot for easy command and request parsing (e.g. w

Oct 24, 2022
Golang bindings for the Telegram Bot API

Golang bindings for the Telegram Bot API All methods are fairly self explanatory, and reading the godoc page should explain everything. If something i

Jan 6, 2023
Golang Based Account Generator Telegram Bot

Account Generator Bot Account Generator Bot, written in GoLang via gotgbot library. Variables Env Vars - BOT_TOKEN - Get it from @BotFather CHANNEL_ID

Nov 21, 2022
its the same idea as bruh-bot, but with golang, and add more bots
its the same idea as bruh-bot, but with golang, and add more bots

bruh-bot but more powerful! requirements python go you can used on mac and linux the idea its really simple, can make a lot of bots with the same task

Jul 7, 2021
Golang Implementation of RLBot

RLBotGo This repository holds a library for making Rocket League bots in Go! It provides: An easy to use interface for writing bots An example bot usi

Jan 1, 2023
Library for working with golang telegram client + bot based on tdlib. This library was taken from the user Arman92 and changed for the current version of tdlib.

go-tdlib Golang Telegram TdLib JSON bindings Install To install, you need to run inside a docker container (it is given below) go get -u github.com/ka

Dec 2, 2022
discord exploit tools written in golang

The ultimate CLI tool for TiKV

Aug 19, 2021
Check for new github releases of your Golang application 🎊

whatsnew Check for new github releases of your Golang application ?? whatsnew provides a simple way to check GitHub for new releases of your Go applic

Dec 1, 2021