Sessions are a sequence of request and response transactions associated with a single user. The sessions are usually maintained on the server level by authenticating the user and keeping track of his/her activity over the web page.
Session with each client is assigned a session ID. Sessions are generally stored on top of cookies and the server signs them cryptographically--they are decrypted by the Flask application using the secret key for a temporary duration.
Currently, we haven't set up authentication--we will be defining it in Chapter 8, Securing the Web Application. So, at this point in time, we will create the session by asking about the username accessing the web page and making sure that the user is identified using the sessions.
Now let's create a web page, say, main.html, which will have a URL to create the session if it is needed to be...