We can get the argument’s value using the request object in Flask.
An example is shown below.
from flask import Flask from flask import request app = Flask(__name__) @app .route( "/" ) def index(): val = request.args.get( "var" ) return "Hello, World! {}" . format (val) if __name__ = = "__main__" : app.run(host = "0.0.0.0" , port = 8080 ) |