import itertools


def flatten_list_of_pairs(list_of_pairs):
    """
    given a list of items containing key-value pairs, flatten into a sorted list of unique key-value pairs
    :param list_of_pairs:
    :return:
    """
    return sorted(list(set(itertools.chain.from_iterable([elem.keys() for elem in list_of_pairs]))))