0
After post, I get an object load_response
, in Dict format, with the following structure:
{'_content': b'{"params":{},"_id":"5a566f175ff52e02704de1aa","variables":"/dataset/5a566f175ff52e02704de1aa/variables","scenarios":"/dataset/5a566f175ff52e02704de1aa/scenarios","client_code":"test","tags":["test"]}',
'_content_consumed': True,
'connection': <requests.adapters.HTTPAdapter at 0x111103d30>,
'cookies': <RequestsCookieJar[]>,
'elapsed': datetime.timedelta(0, 25, 923809),
'encoding': 'UTF-8',
'headers': {'Server': 'waitress', 'Content-Length': '215', 'Content-Type': 'text/html; charset=UTF-8', 'Date': 'Wed, 10 Jan 2018 19:52:29 GMT'},
'history': [],
'raw': <requests.packages.urllib3.response.HTTPResponse at 0x113bd1240>,
'reason': 'Created',
'request': <PreparedRequest [POST]>,
'status_code': 201,
'url': 'http://localhost:8080/xfg/v2.0/dataset'}
I wonder how I can extract the value of the "_id" field from this dictionary.