JSON (JavaScript Object Notation) is a lightweight data interchange format. Easy for people to read and write. It is also easy for machine parsing and generation.  
First, JSON is a string. A string is used to pass information. A JSON string is actually a format-defined string,
In this format, we can pass information to each other in different programming languages, for example, we can convert JavaScript objects to JSON to Java, so that Java can parse out the objects that the Java language itself represents, so we can turn Java objects into JSON, By parsing the Json,python language, the JSON can be converted into its own dict or List,json Unified Communication format, so that information can be transferred smoothly between different languages.
Official website: https://docs.python.org/2/library/json.html#json.dumps
The Python2.6 version supports JSON encoding and decoding, supporting most of Python's built-in types and JSON conversions. A simple example is as follows:
>>>ImportJSON>>> data = {"spam":"Foo","Parrot": 42}>>> In_json = json.dumps (data)#Encode the Data>>>In_json'{"Parrot": "Spam": "foo"}'>>> json.loads (In_json)#Decode into a Python object{"spam":"Foo","Parrot": 42}
The encode process is a process of converting a Python object into a JSON object, and the two commonly used functions are the dumps and dump functions. The only difference between the two functions is that dump converts the Python object into a JSON object to generate an FP file stream, and dumps generates a string:
Dumps is converting dict to str format, loads is converting str to dict format.
JSON of Python