MCPcopy Index your code
hub / github.com/StackStorm/st2 / delete

Method delete

st2client/st2client/models/core.py:388–400  ·  view source on GitHub ↗
(self, instance, **kwargs)

Source from the content-addressed store, hash-verified

386
387 @add_auth_token_to_kwargs_from_env
388 def delete(self, instance, **kwargs):
389 url = "/%s/%s" % (self.resource.get_url_path_name(), instance.id)
390 response = self.client.delete(url, **kwargs)
391
392 if response.status_code not in [
393 http_client.OK,
394 http_client.NO_CONTENT,
395 http_client.NOT_FOUND,
396 ]:
397 self.handle_error(response)
398 return False
399
400 return True
401
402 @add_auth_token_to_kwargs_from_env
403 def delete_action(self, instance, remove_files, **kwargs):

Callers 4

test_resource_deleteMethod · 0.95
delete_actionMethod · 0.45
delete_by_idMethod · 0.45

Calls 2

handle_errorMethod · 0.95
get_url_path_nameMethod · 0.80

Tested by 2

test_resource_deleteMethod · 0.76