From 9e9bad731d7247557796f4e317db4508c23f4e7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20Vinot?= Date: Thu, 21 Dec 2017 17:25:12 +0100 Subject: [PATCH] new: Add last field to get_csv --- pymisp/api.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pymisp/api.py b/pymisp/api.py index a4d91fc..9bbb7ae 100644 --- a/pymisp/api.py +++ b/pymisp/api.py @@ -1606,7 +1606,7 @@ class PyMISP(object): def get_stix(self, **kwargs): return self.get_stix_event(**kwargs) - def get_csv(self, eventid=None, attributes=[], object_attributes=[], misp_types=[], context=False, ignore=False): + def get_csv(self, eventid=None, attributes=[], object_attributes=[], misp_types=[], context=False, ignore=False, last=None): """Get MISP values in CSV format :param eventid: The event ID to query :param attributes: The column names to export from normal attributes (i.e. uuid, value, type, ...) @@ -1632,6 +1632,8 @@ class PyMISP(object): to_post['includeContext'] = True if ignore: to_post['ignore'] = True + if last: + to_post['last'] = last if to_post: response = self.__prepare_request('POST', url, json.dumps(to_post), output_type='json') else: