Contrast
< Back to Blog
Original link:

https://www.youtube.com/watch?v=gvq_tSqCY4w

2023-08-03 15:47:41

Create a Telegram Bot in 10 Minutes with ChatGPT! Make and deploy telegram bot with ChatGPT

video content Image generated by Wilowrid

In this video , I'm going to show you how you can create an awesome telegram board using Child GPT .

Here is the boat which I have created using the GP T and let me show you what it can do .

So if I enter the start command , it's going to introduce itself and it's going to send me this .

Welcome GIF .

And there are some more commands as well which is gonna respond to according to the code .

But it's just a simple both which respond to some particular commands .

But this is not it , you can create a way more advanced boat using shared GP T and it can help you to perform your task .

It can help you to save your time .

So let's just create a boat and let me show you how you can do this .

So I am with Patel and you are watching with the master channel .

So if you find this video helpful , please drop a like and let me know in the comment section .

So let me just open chat GP and let me show you how you can do it .

So we are creating this boat from the scratch .

video content Image generated by Wilowrid

So I opened my charity and I asked it to how can I create a telegram boat ?

And it showed me that I need to go to boat further and I have to create a boat there and I need to get my A P A ton off my boat , which I will be using in my Python code .

So it showed me whole process in detail .

It also showed me a sample code .

So after this , I asked it , how can I get the API token from the board father ?

So it also showed me a step by step process .

Then I followed the process and I went to the telegram and I created my boat into the boat further where I need to give a name to my boat .

And I also have to give a user name .

video content Image generated by Wilowrid

So you need to follow the same process because it's the similar process that everyone needs to do in order to create a telegram boat , no matter what your boat do , what your how advanced your boat .

First of all , you need to get disappeared .

After getting the A P A to I asked the GP to create a Python code for a telegram board to which you can reply to some predefined commands like start info health status .

And I also asked it to give some commands from your side as well .

So it gave me a pretty good code for the my telegram board and it used the Telegram library and it also used the classes called data and dispatcher .

And I , I had also used this code before and actually it didn't work for me .

So I asked it to use another library .

I don't want to use this particular Telegram library .

video content Image generated by Wilowrid

So it also gave me the same code using the different library called Tele Boat , which is actually Python Telegram Boat API library .

So it gave me a create a good code .

And after getting the code , I copied the code , I went to the VS code and I created a new file called TG dot P and I tested my whole code into that particular file .

So here you need to do one thing that the code is actually not using your API token .

So you need to replace your API token into that particular variable name .

So I went to Telegram and copied my uh that particular API and I requested right here .

So once this is done , I ran my code and once my code is running without any errors , how to check your boat is working or not .

video content Image generated by Wilowrid

You can go to telegram and open your boats user name and just give the command start and it will show you the response which was uh actually written in the code and you can modify it as well .

So I tested all the commands and all were working fine .

And here I have edited this uh command info and I added my name that uh the boat is created by Patel and I also added this print boat is running line so I can know that my boat is actually working without any error .

So then again , I run info code and it showed me my name .

After that , I asked the GT to add one more feature of the time command .

So if someone uses less time command , then it should show the current time as well .

So it modified my previously written code and it gave me new code which was also uh replying to slash time command and it was returning the current time .

video content Image generated by Wilowrid

So I made changes to my main TG dot G dot py file and I ran it and I checked it was working perfectly fine .

So then I copied my current working code and I went to the and pasted into the uh the textbooks .

And I also added details like that .

This is my current working code and I want to add a feature uh If someone start the boat , it should respond to them with a nice welcome image and it should also grade them with a nice welcome message .

So it took my that particular token , A P A token from the my code .

And in the response uh code , it also used that token into the uh new code .

So you said that it detected that this is the A P A token and it replaced it with a variable called API token .

And it , it gave me a fully functional code .

And it also gave me two approaches for this functionality .

video content Image generated by Wilowrid

One was using the image into that particular root folder of your code and also the image uh from the URL .

So whatever you want to use , you can use it .

So while it was turned the code , I went to the Google and downloaded a nice welcome image and I copied , pasted it to the my root folder .

So once the code is TED , I went to the and grabbed , I grabbed the code and updated my code and I changed the name of that particular image and then I tested the code and holy moly , it worked .

But it was just a simple thing .

You can give a more detailed information to chat and create a more advanced board which can do some advanced task also like you can convert the file type , you can remove the image background , you need to do some research in order to accomplish that particular thing .

video content Image generated by Wilowrid

So I asked the GB to do , give me some ideas on how how I can upgrade my boat and make it useful for some groups channel and person personal use as well .

So it gave me some pretty good damn ideas .

You can just pause the video and you can read it out .

So it gave me around 6 to 7 .

I don't remember .

You can just read it right from here .

So yeah , it gave me some awesome ideas .

So you can take any of this idea and create your own boat .

And if you , if you do create the boat , please comment in the comment section .

I will check out your boat .

So currently the boat was running on my local machine and I don't want to run my laptop 24 by seven .

So I asked Mr GP how I can host my this boat on any server So it can run 24 by seven and I can use any time whenever I want .

So it gave me some pretty uh names for the servers which I can use .

video content Image generated by Wilowrid

And it gave me whole process from setting up the server and deploying my board there and installing my dependencies and getting logs .

All of the things I asked you to give me some free servers name , which I can use for hosting my boat .

And it gave me some names like Hero co , Python anywhere G five aws , lambda and Google like that .

And I asked it to how I can use a Python anywhere for my boat .

So it gave me detailed information from creating account to creating a web app .

So I used to the Python anywhere for this particular boat .

And you can also use it if you just want to taste your boat .

So it's very simple .

You can go to Python anywhere and create your account .

So I did the same thing and so you can use any of the service providers .

video content Image generated by Wilowrid

And uh if you need help chat G it is right there , you can ask it and it will show you how to deploy on that particular server .

So I used to Python anywhere because it was very fast and convenient for me to create this video and also taste my board .

So just go to there and create account and it's not like that you need uh any such kind of payment information for creating your account .

Once you create the account , you will find a similar interface like this and you have to go to web apps and create a new web app .

And here you have to select the flask for your uh the framework and the Python version , which is installed in your machine .

So the Python which I was using was 3.7 .

So I selected 3.7 and then once your web will be created , you have to go to the source file and you will find one file called flash dot py .

Here , I have two files , but there will be only one file .

video content Image generated by Wilowrid

You can delete that one file because we are going to upload our own files here .

So once the files are deleted , you can open your bash console and we need to install the libraries which we used in our boat .

So I used the Tele Boat .

So the command for installing Tele Boat is pre installed by Telegram Api and it is already installed because I already hosted a one boat here .

So once the all the libraries are installed , you can upload both files .

One is that Python file and another is that photo , photo file , PNG file .

So once your code is uploaded , you can open that file and you can make changes if you want to make any changes .

So I edit both is running command .

So once the you can see that my console limit was reached .

So you get a free two consoles on your free account .

So if you reach out the limit , you need to delete those previous two consoles and you can open your file again and you can run it again .

video content Image generated by Wilowrid

And once you see that your boat is running , boom , you hosted your first boat and it is live and you can access it from anywhere so you can perform all the commands and I hope this video helped you and I am really like to see your boats as well .

So please let me know in the comment section .

I will must check out your boat .

So that's all for today's video .

I will see you in the next time .

Peace out .

Partnership

Attention YouTube vloggers and media companies!
Are you looking for a way to reach a wider audience and get more views on your videos?
Our innovative video to text transcribing service can help you do just that.
We provide accurate transcriptions of your videos along with visual content that will help you attract new viewers and keep them engaged. Plus, our data analytics and ad campaign tools can help you monetize your content and maximize your revenue.
Let's partner up and take your video content to the next level!
Contact us today to learn more.