how to sort a list of dictionary based on a key code example
Example: sort list of dictionaries by key python
newlist = sorted(list_to_be_sorted, key=lambda k: k['name'])
newlist = sorted(list_to_be_sorted, key=lambda k: k['name'])