A Simple Python Web Server to Echo Back HTTP Request Headers and Data

preview_player
Показать описание
This could come in handy for testing your web app's webhooks and more.

Hit the subscribe button to receive more videos like this!

---

Timestamps:

0:00 -- What we'll be covering in this video
0:21 -- Testing webhooks is one use case for using this tool
1:08 -- Taking a quick peek at the Python code to make it work
1:33 -- Sending a basic GET request with curl
2:41 -- Sending a POST request with a JSON payload using curl
3:35 -- A quick aside to send JSON data from a file with curl
4:30 -- Sending a POST request with form data using curl
5:22 -- Connecting to the web server from a Dockerized web app
8:39 -- It's up on GitHub along with documentation
9:01 -- Using ngrok to make the web server accessible on the internet

Reference links:

---

Follow along?

Рекомендации по теме
Комментарии
Автор

Great video, please do a video on ngrok. Thanks.

Supperconductor
Автор

Not sure if it would fit your format or if it's the work you do, but I'd like to see some Redis scenarios. How it can save you money (e.g. calling APIs less) and how it can bite you like it did me as you cannot really scale it when you cache everything... thanks!

johnanth
Автор

Hi Nick, Thank you so much for the tutorial. I am a newbie in computer networks and coding etc. I have a question. I am trying to create a jamming scenario for my project. For that purpose i want to create a web server and the send http requests to that webserver continuously and note the rssi values and packet density + packet retransmissions etc.
I came across your video and i have used your code to make webserver. The problem is when i use the terminal window of the same computer in which the server is running then i can use curt to get and post requests but when i use another computer on the same network to send the request, It does not work. I have no clue why. If you know can you please guide me...

In the end i would have to write a python code to send http requests to the server. Do you think that that would work but only the curl is not working. Sorry if you find my questions lame. I don't have much knowledge and understanding on the subject.

Fatimatuzahra
Автор

You are using windows terminal now, 😊. How are you liking it?

chris-ewwl
Автор

Can i get other information like protocol, service....etc

abiddhiya
welcome to shbcf.ru