How to get only one Json value using request.get_data () Flask Python

1

I'm a beginner in Python and would like a tip to get only one value from the following Json.

{
  "test1":"valortest1",
  "test2":"valortest2",
  "test3":"valortest3",
  "test1":"valortest1"
}

Use to get json as follows in flask. given = request.get_data ()

I get the complete file as a return when starting the given variable, but I would like to handle it better, by doing the print only of valortest2.

What would be the best way to do this?

    
asked by anonymous 16.06.2017 / 22:42

0 answers