Skip to content
This repository has been archived by the owner on Jan 4, 2023. It is now read-only.

[tgBot] TG bot command to get client info by user #110

Merged
merged 2 commits into from
Nov 22, 2022
Merged

Conversation

hossinasaadi
Copy link
Owner

give bot to your customers and they can check some details :)

Screenshot from 2022-11-22 07-59-51
/usage uuid | id
https://github.com/hossinasaadi/x-ui/issues/89

@alirezax5
Copy link

👍❤️

@amihos
Copy link

amihos commented Nov 22, 2022

@hossinasaadi

I just tested it and it seems not working correctly. Here is what I did. On a test server, I uninstalled older version, and installed again the newest version.

Then I created a test inbound and used it a bit. Then I created a new bot and connected it to the server. I used the command /usage uuid and it turns back the following

💡 Active: true
📧 Email:
🔼 Upload↑: 0.00B
🔽 Download↓: 0.00B
🔄 Total: 0.00B / unlimited
📅 Expire in: unlimited

@amihos
Copy link

amihos commented Nov 22, 2022

@hossinasaadi

I just tested it and it seems not working correctly. Here is what I did. On a test server, I uninstalled older version, and installed again the newest version.

Then I created a test inbound and used it a bit. Then I created a new bot and connected it to the server. I used the command /usage uuid and it turns back the following

💡 Active: true 📧 Email: 🔼 Upload↑: 0.00B 🔽 Download↓: 0.00B 🔄 Total: 0.00B / unlimited 📅 Expire in: unlimited

Update: I you add a client (with email) to the inbound you created it starts working. So the bug is: If you create just a simple inbound (without adding any client) it does not work.

@hossinasaadi
Copy link
Owner Author

@amihos are u set email?

@hossinasaadi
Copy link
Owner Author

@amihos it's for client usage not inbound usage!

@hossinasaadi
I just tested it and it seems not working correctly. Here is what I did. On a test server, I uninstalled older version, and installed again the newest version.
Then I created a test inbound and used it a bit. Then I created a new bot and connected it to the server. I used the command /usage uuid and it turns back the following
💡 Active: true 📧 Email: 🔼 Upload↑: 0.00B 🔽 Download↓: 0.00B 🔄 Total: 0.00B / unlimited 📅 Expire in: unlimited

Update: I you add a client (with email) to the inbound you created it starts working. So the bug is: If you create just a simple inbound (without adding any client) it does not work.

@amihos
Copy link

amihos commented Nov 22, 2022 via email

@amihos
Copy link

amihos commented Nov 22, 2022

@amihos it's for client usage not inbound usage!

@hossinasaadi
I just tested it and it seems not working correctly. Here is what I did. On a test server, I uninstalled older version, and installed again the newest version.
Then I created a test inbound and used it a bit. Then I created a new bot and connected it to the server. I used the command /usage uuid and it turns back the following
💡 Active: true 📧 Email: 🔼 Upload↑: 0.00B 🔽 Download↓: 0.00B 🔄 Total: 0.00B / unlimited 📅 Expire in: unlimited

Update: I you add a client (with email) to the inbound you created it starts working. So, the bug is: If you create just a simple inbound (without adding any client) it does not work.

I got you. However, imagine you want to create multiple inbounds for different users and do not want to use client feature. Is it not possible to just provide inbound usage stats if there is no clients available on that particular inbound?

@hossinasaadi
Copy link
Owner Author

@amihos maybe in next version :)

@Saeed-Tavoosi
Copy link

نمیشه توی یه URL خاص، به علاوه ی آی دی شخص در انتهاش بشه حجم رو دید؟ بدون معلوم شدن پورت پنل.
اجراش سخته؟

@rasolebadat
Copy link

Hello Dear Asaadi, I'm demanding the source of TG Bot to make a Discord Bot to make it easier for me or if it's possible make a documentary for the public to use the API.
Sincerely MikasaSuCasa.

@hossinasaadi
Copy link
Owner Author

@rasolebadat @Saeed-Tavoosi

REST API


#51

@fk6989
Copy link

fk6989 commented Nov 24, 2022

دوستان کسی توضیح میده اسکریپت رو چجوری با مشخصات خودمون جاگذاری کنیم؟ {} اینا رو بعد از وارد کردن توکن و آیدی باید حذف کنیم؟
و اینکه تو آموزشی که گذاشته بودن گفته این اسکریپت رو ببرین به /etc/profile.d/ و بهش دسترسی 555 بدین نه 777.
منظ.رم این آموزشه: https://coderfan.net/how-to-use-telegram-bot-to-alarm-you-when-someone-login-into-your-vps.html

کسی میتونه وارد کردن اسکریپت روی سرور رو ساده تر توضیح بده؟

@Jolge100
Copy link

Jolge100 commented Nov 24, 2022

دوستان کسی توضیح میده اسکریپت رو چجوری با مشخصات خودمون جاگذاری کنیم؟ {} اینا رو بعد از وارد کردن توکن و آیدی باید حذف کنیم؟ و اینکه تو آموزشی که گذاشته بودن گفته این اسکریپت رو ببرین به /etc/profile.d/ و بهش دسترسی 555 بدین نه 777. منظ.رم این آموزشه: https://coderfan.net/how-to-use-telegram-bot-to-alarm-you-when-someone-login-into-your-vps.html

کسی میتونه وارد کردن اسکریپت روی سرور رو ساده تر توضیح بده؟

اصلا این دردسرا رو نداره شما یه توکن از تلگرام می گیری و بعد با ایدی خودت یه chatid می گیری تو کادرهای پنلت می ذاری یه بار پنل رو ریستارت می کنی و همه چی راه می افته به همین سادگی

@fk6989
Copy link

fk6989 commented Nov 24, 2022

یبار اپگرید کردم ربات کار میکنه منتها تایم انقضا رو ۲ ساعت و نیم کمتر نشون میده. مثلا اکانتی که ساعت ۹:۳۰ شب تموم میشه رو ۷ نشون میده. روزش درسته. چجوری باید تایمش زو با پنل ست کنم که اونم درست نشون بده؟

@moslem2013
Copy link

یبار اپگرید کردم ربات کار میکنه منتها تایم انقضا رو ۲ ساعت و نیم کمتر نشون میده. مثلا اکانتی که ساعت ۹:۳۰ شب تموم میشه رو ۷ نشون میده. روزش درسته. چجوری باید تایمش زو با پنل ست کنم که اونم درست نشون بده؟

سلام لازمه توی بخش تنظیمات تب آخر ساعت سیستم رو بزاری Asia/tehran تا مشکل حل بشه

@moslem2013
Copy link

دوستان کسی توضیح میده اسکریپت رو چجوری با مشخصات خودمون جاگذاری کنیم؟ {} اینا رو بعد از وارد کردن توکن و آیدی باید حذف کنیم؟ و اینکه تو آموزشی که گذاشته بودن گفته این اسکریپت رو ببرین به /etc/profile.d/ و بهش دسترسی 555 بدین نه 777. منظ.رم این آموزشه: https://coderfan.net/how-to-use-telegram-bot-to-alarm-you-when-someone-login-into-your-vps.html
کسی میتونه وارد کردن اسکریپت روی سرور رو ساده تر توضیح بده؟

اصلا این دردسرا رو نداره شما یه توکن از تلگرام می گیری و بعد با ایدی خودت یه chatid می گیری تو کادرهای پنلت می ذاری یه بار پنل رو ریستارت می کنی و همه چی راه می افته به همین سادگی

من توکن و ایدی رو زدم منتها بات کار نمیکنه. قسمت telegram bot notification time رو چی باید بزنم؟ اونجا خالیه

30 * * * * * //Notify at the 30s of each point

@hourly // hourly notification

@daily // Daily notification (00:00 in the morning)

@every 8h // notify every 8 hours

از اینا باید استفاده کنی
مثلا
@every 8h
جای 8 عدد دیگه وارد کن مثلا 1 اینجوری هر 1 ساعت ربات مصرف کاربرا رو برات میفرسته
بقیه اشونم که واضحه

@moslem2013
Copy link

دوستان کسی توضیح میده اسکریپت رو چجوری با مشخصات خودمون جاگذاری کنیم؟ {} اینا رو بعد از وارد کردن توکن و آیدی باید حذف کنیم؟ و اینکه تو آموزشی که گذاشته بودن گفته این اسکریپت رو ببرین به /etc/profile.d/ و بهش دسترسی 555 بدین نه 777. منظ.رم این آموزشه: https://coderfan.net/how-to-use-telegram-bot-to-alarm-you-when-someone-login-into-your-vps.html
کسی میتونه وارد کردن اسکریپت روی سرور رو ساده تر توضیح بده؟

اصلا این دردسرا رو نداره شما یه توکن از تلگرام می گیری و بعد با ایدی خودت یه chatid می گیری تو کادرهای پنلت می ذاری یه بار پنل رو ریستارت می کنی و همه چی راه می افته به همین سادگی

ممنون. یبار من اسکریپت رو زدم اوکی نشد. لازمه چیزی حذف بشه یا کامندی زده بشه که undo کنه؟

بعد از اینکه چت ایدی ، توکن ربات و ساعت ارسال نوتیفکشن رو وارد کردی ذخیره کن بعد گزینه restat قرمز رنگه بزن تا پنل ریستارت بشه تنظیماتت کامل اعمال بشه

@ITheEqualizer
Copy link

Where can I get this bot?

@hhamed1989
Copy link

Hi, I created a bot and got an id from @getidsbot, then added both to the panel and set the notification time to */5 * * * *. restart the panel.
But only entering and exiting the panel is sent to Telegram. There is no switch or option to view user traffic inside the bot.?
I updated to the latest version with this command.
bash <(curl -Ls https://raw.githubusercontent.com/hossinasaadi/x-ui/master/install.sh)
Do I need to do something else to see user traffic?

@zoobin65
Copy link

zoobin65 commented Dec 2, 2022

چطوری می تونم این فایل و در سرور ویرایش کنم؟
داخل پوشه x-ui می شم‌فقط یه فایل بک آپ وجود داره.
چطوری مثلا وارد پوشه web/job بشم؟

@jafari404
Copy link

for me too

Hi, I created a bot and got an id from @getidsbot, then added both to the panel and set the notification time to */5 * * * *. restart the panel. But only entering and exiting the panel is sent to Telegram. There is no switch or option to view user traffic inside the bot.? I updated to the latest version with this command. bash <(curl -Ls https://raw.githubusercontent.com/hossinasaadi/x-ui/master/install.sh) Do I need to do something else to see user traffic?

for me too.

@realartin
Copy link

درود
ممنون بابت این حرکت زیبای شما
درخواست داشتم اگر امکانش باشه ورژن xray رو بروز نگاه دارید تا بازدهی پلتفرمی که دارید روش کار میکنید بالا باشه برای مثال پنل کافکا الان ورژن 1.6.6.2 رو ساپورت میکنه ولی این پنل شما 1.6.4 رو و روی 1.6.5 میخواهیم بزاریم ست نمیشه و رو همون ورژن میمونه ممنون از لطف شما

@fk6989
Copy link

fk6989 commented Dec 22, 2022

سلام دوستان. من چند جا دیدم اپ اختصاصی ساختن برای یوزراشون. و لیمیت هم میکنن به یه نفر. تک کاربره از داخل اپشون و به چند سرور وصل میشه. سورسی هست توی گیت هاب برای اپ اختصاصی؟ و اینکه اینا چجوری تک کاربره میکنن که فشار روی سی پی یو نمیاد؟

@realartin
Copy link

image
چرا وقتی هیج یوزری نساختم رو پنلم منابع پنلم داره استفاده میشه و ترافیکم هی داره بهش اضافه میشه ؟ اخرین اپدیت هم نصبه

@realartin
Copy link

درود ورژن ۱.۷ xray برای x-ui منتشر شد لطفا بروز رسانی کنید

@realartin
Copy link

xray version 1.7
منتشر شده لطفا در صورت امکان بروزرسانی نمایید

@Crackmaster2022
Copy link

یلام من ۳ پنل دارم روی یک ایدی ۳ روبات جدا گونه دارم روی ۲ سرور لاگ بات میاد روی یکی نمیاد تنطیمات و همه کارم درست انجام دادم لطفن راهنماییم کنین

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet