a method to retrieve a list of events member attended or will attend

        :param upcoming: [optional] boolean to filter list to only future events
        :return: dictionary with list of event details inside [json] key

        event_details = self._reconstruct_event({})

def list_member_events(self, upcoming=True):

        ''' a method to retrieve a list of events member attended or will attend

        :param upcoming: [optional] boolean to filter list to only future events
        :return: dictionary with list of event details inside [json] key

        event_details = self._reconstruct_event({})
        '''

    # https://www.meetup.com/meetup_api/docs/self/events/

    # construct request fields
        url = '%s/self/events' % self.endpoint
        params = {
            'status': 'past',
            'fields': 'comment_count,event_hosts,rsvp_rules,short_link,survey_questions,rsvpable'
        }
        if upcoming:
            params['status'] = 'upcoming'

    # send requests
        response_details = self._get_request(url, params=params)

    # construct method output
        member_events = {
            'json': []
        }
        for key, value in response_details.items():
            if key != 'json':
                member_events[key] = value
        for event in response_details['json']:
            member_events['json'].append(self._reconstruct_event(event))

        return member_events