def import_url(self, url, hostoverride=None, apikey=''):
"""
Import an Open API definition from a URL, hostOverride allows the host to be replaced
This component is optional and therefore the API will only work if it is installed
"""
params = {'url': url, 'apikey': apikey}
if hostoverride is not None:
params['hostOverride'] = hostoverride
return six.next(six.itervalues(self.zap._request(self.zap.base + 'openapi/action/importUrl/', params)))
评论列表
文章目录