In case of time constraints in implementing the MVVM architecture , as default solution the body widget can be simply be rawly implemented in the statefull widget of the appbar . This will save us from handling initialisation state and communication between widget .
The main error in the code is the fetch fetched method is be called in the initstate method which itself only runs once at with construction making it not path of the widget tree .
With the MVVM architecture . In the first widget ie. appBar class , submit the input and default value to the fetch method . Go in the controller , create an object of the Body widget which will the initialise with the api fetch parameters