Forums

Http Server To Receive Simple Request Not Working

I made a http server to receive this simple request. Yet, it never sends back 'valid'

Requester:

Http Request

This is my server I have on pythonanywhere: Http Server

What do you see if you print token.text in your client-side code? Also, what is token.status_code? It looks like your view is set up to serve responses on http://tixr.pythonanywhere.com/, but not on http://tixr.pythonanywhere.com/something, so I'd expect a "not found" text with a 404 status code. If that's the case, you'll need to modify the app.route so that your view accepts a cookie parameter at the end of the URL.

Hey, @giles. How do I modify the app.route so that it accepts a cookie parameter at the end of the url? Thank you.

Here you go: https://flask.palletsprojects.com/en/2.3.x/quickstart/#routing