'Invokes end point for resource on path.'

def _invoke(self, method, path, data=None, use_system=True, timeout=None, verify=False, **kwargs):

    url = self._get_resource_url(path, use_system, **kwargs)
    if (self._content_type == 'json'):
        headers = {'Accept': 'application/json', 'Content-Type': 'application/json'}
        if cinder_utils.TRACE_API:
            self._log_http_request(method, url, headers, data)
        data = (json.dumps(data) if data else None)
        res = self.invoke_service(method, url, data=data, headers=headers, timeout=timeout, verify=verify)
        try:
            res_dict = (res.json() if res.text else None)
        except scanner.JSONDecodeError:
            res_dict = None
        if cinder_utils.TRACE_API:
            self._log_http_response(res.status_code, dict(res.headers), res_dict)
        self._eval_response(res)
        return res_dict
    else:
        raise exception.NetAppDriverException(_('Content    type    not    supported.'))
