How to “GET” request from JSON objects passed through HTML form

from dataclasses import dataclass
from flask import request 

# As an exception, since I cannot explain the use of a database to you in this 
# example, I use a global variable. You shouldn't actually do this, but it is 
# helpful in this case for the reason described above.
botlist = []

# For the same reason, I use a dataclass to map a model, which is later saved 
# within the defined list.
class Bot:
    username: str
    channel: str
    name: str
    status: str

@app.route('/bots', methods=['GET', 'POST'])
def bots():
    global botlist
    if request.method == 'POST':
        # If it is a POST request, create a bot object and append it to the list.
        bot = Bot(

    # Re-render the page with the bots in the list.
    return render_template('bots.html', botlist=botlist)


{% for bot in botlist -%} {% endfor -%}
Username Channel Name Status
{{ bot.username }} {{ }} {{ }} {{ bot.status }}