def get(self, user_id, return_request_id=None):
"""Get the details for a specific user.
:param user_id: ID of the user
:param return_request_id: If an empty list is provided, populate this
list with the request ID value from the header
x-openstack-request-id
"""
resp, body = self.client.get('/users/%s' % parse.quote(str(user_id)))
if return_request_id is not None:
return_request_id.append(resp.headers.get(OS_REQ_ID_HDR, None))
data = body.get('user')
return self.resource_class(self, data, loaded=True)
评论列表
文章目录