'List all rejected entries'

@etag
@api.response(NotFoundError)
@api.response(200, model=rejected_entries_list_schema)
@api.doc(parser=rejected_parser)
def get(self, session=None):

    args = rejected_parser.parse_args()
    page = args[u'page']
    per_page = args[u'per_page']
    sort_by = args[u'sort_by']
    sort_order = args[u'order']
    if (per_page > 100):
        per_page = 100
    descending = (sort_order == u'desc')
    if (per_page > 100):
        per_page = 100
    start = (per_page * (page - 1))
    stop = (start + per_page)
    kwargs = {u'start': start, u'stop': stop, u'descending': descending, u'sort_by': sort_by, u'session': session}
    total_items = get_rejected(session, count=True)
    if (not total_items):
        return jsonify([])
    failed_entries = [rejected_entry_to_dict(reject) for reject in get_rejected(**kwargs)]
    total_pages = int(ceil((total_items / float(per_page))))
    if (page > total_pages):
        raise NotFoundError((u'page    %s    does    not    exist' % page))
    actual_size = min(per_page, len(failed_entries))
    pagination = pagination_headers(total_pages, total_items, actual_size, request)
    rsp = jsonify(failed_entries)
    rsp.headers.extend(pagination)
    return rsp
