FETCHES a filtered list of vouchers log entries.
        
        :type vid_encoded: ``alphanumeric(64)``
        :param vid_encoded:
            Voucher ID, as a string with CRC.
        :type vid: ``bigint``
        :param vid:
            Voucher ID.
        :type action: ``string`` (add | use | revoke | expire)
        :param action:
            Filter only these actions on vouchers.
        :type uid_from: ``bigint``
        :param uid_from:
            Filter by source account UID.
        :type uid_to: ``bigint``
        :param uid_to:
            Filter by destination account UID.
        :type gid: ``alphanumeric(32)``
        :param gid:
            Filter by voucher Group ID. GID is localized to `uid_from`.
        :type valid_after: ``datetime``/``dict``
        :param valid_after:
            Voucher has to be valid after this timestamp. Absolute
            (``datetime``) or relative (``dict``) timestamps are accepted. Valid
            keys for relative timestamp dictionary are same as keyword arguments
            for `datetime.timedelta` (``days``, ``seconds``, ``minutes``,
            ``hours``, ``weeks``).
        :type valid_before: ``datetime``/``dict``
        :param valid_before:
            Voucher was valid until this timestamp (for format, see the
            `valid_after` above).
        :type create_after: ``datetime``/``dict``
        :param create_after:
            Voucher has to be created after this timestamp (for format, see the
            `valid_after` above).
        :type create_before: ``datetime``/``dict``
        :param create_before:
            Voucher was created until this timestamp (for format, see the
            `valid_after` above).
        :type last: ``bigint``
        :param last:
            The number of newest voucher entries (that satisfy all other
            criteria) to return.
        :type first: ``bigint``
        :param first:
            The number of oldest voucher entries (that satisfy all other
            criteria) to return.
        
        :note:
            If `first` or `last` are used, the vouchers list is sorted by time
            created, otherwise it is sorted alphabetically by `id`.
        
        :rtype: ``list``/``dict``
        :returns:
            A list of voucher log description dictionaries.
        :raises GeneralException:
        
        :resource:
            ``vouchers/history[/<vid_encoded>][/from=<uid_from>][/to=<uid_to>]``
            ``[/vid=<vid>][/action=<action>][/last=<last>][/first=<first>]``
            ``[/valid_after=<valid_after>][/valid_before=<valid_before>]``
            ``[/create_after=<create_after>][/create_before=<create_before>]``
            ``[/gid=<group_id>]``
        :access: authorized users (ACL flag: ``voucher.history``)

def get_vouchers_history(self, vid_encoded=None, vid=None, action=None,
                             uid_from=None, uid_to=None, gid=None,
                             valid_after=None, valid_before=None,
                             create_after=None, create_before=None,
                             last=None, first=None):
        """
        FETCHES a filtered list of vouchers log entries.
        
        :type vid_encoded: ``alphanumeric(64)``
        :param vid_encoded:
            Voucher ID, as a string with CRC.
        :type vid: ``bigint``
        :param vid:
            Voucher ID.
        :type action: ``string`` (add | use | revoke | expire)
        :param action:
            Filter only these actions on vouchers.
        :type uid_from: ``bigint``
        :param uid_from:
            Filter by source account UID.
        :type uid_to: ``bigint``
        :param uid_to:
            Filter by destination account UID.
        :type gid: ``alphanumeric(32)``
        :param gid:
            Filter by voucher Group ID. GID is localized to `uid_from`.
        :type valid_after: ``datetime``/``dict``
        :param valid_after:
            Voucher has to be valid after this timestamp. Absolute
            (``datetime``) or relative (``dict``) timestamps are accepted. Valid
            keys for relative timestamp dictionary are same as keyword arguments
            for `datetime.timedelta` (``days``, ``seconds``, ``minutes``,
            ``hours``, ``weeks``).
        :type valid_before: ``datetime``/``dict``
        :param valid_before:
            Voucher was valid until this timestamp (for format, see the
            `valid_after` above).
        :type create_after: ``datetime``/``dict``
        :param create_after:
            Voucher has to be created after this timestamp (for format, see the
            `valid_after` above).
        :type create_before: ``datetime``/``dict``
        :param create_before:
            Voucher was created until this timestamp (for format, see the
            `valid_after` above).
        :type last: ``bigint``
        :param last:
            The number of newest voucher entries (that satisfy all other
            criteria) to return.
        :type first: ``bigint``
        :param first:
            The number of oldest voucher entries (that satisfy all other
            criteria) to return.
        
        :note:
            If `first` or `last` are used, the vouchers list is sorted by time
            created, otherwise it is sorted alphabetically by `id`.
        
        :rtype: ``list``/``dict``
        :returns:
            A list of voucher log description dictionaries.
        :raises GeneralException:
        
        :resource:
            ``vouchers/history[/<vid_encoded>][/from=<uid_from>][/to=<uid_to>]``
            ``[/vid=<vid>][/action=<action>][/last=<last>][/first=<first>]``
            ``[/valid_after=<valid_after>][/valid_before=<valid_before>]``
            ``[/create_after=<create_after>][/create_before=<create_before>]``
            ``[/gid=<group_id>]``
        :access: authorized users (ACL flag: ``voucher.history``)
        """
        resource = self.kvpath(
            'vouchers/history',
            ('ident', vid_encoded),
            **{
                'vid': ('int', vid),
                'action': ('ident', action),
                'from': ('int', uid_from),
                'to': ('int', uid_to),
                'gid': ('ident', gid),
                'valid_after': ('isobasic', absdatetime(valid_after)),
                'valid_before': ('isobasic', absdatetime(valid_before)),
                'create_after': ('isobasic', absdatetime(create_after)),
                'create_before': ('isobasic', absdatetime(create_before)),
                'first': ('int', first),
                'last': ('int', last)
            }
        )
        return self.request('get', resource)