def get_documents(cls, ids):
    """Returns a list of ES documents with specified ids and doctype

    :arg cls: the class with a ``.search()`` to use
    :arg ids: the list of ids to retrieve documents for
    """
    ret = cls.search().filter(id__in=ids).values_dict()[:len(ids)]
    return list(ret)