Deletes a conversion action identified by its unique action key. The action is marked deleted, as the console does: it disappears from listings, its key answers 404 afterwards, and conversion tracking that references it stops recording conversions. Built-in (shared-by-default) actions cannot be deleted. The deletion is logged to the action log.
Path Params
keystringrequired
The unique action key string identifying the action to delete.
a1b2c3d4e5
Responses
200
Action deleted successfully (empty 200 response)
400
Bad request — wrong parameter types
401
Authentication error
403
Not enough permissions, or the action is a built-in one
404
No action found with the given action key, or it is already deleted
using var client = new HttpClient();
var request = new HttpRequestMessage(new HttpMethod("DELETE"), "https://YOUR-NETWORK-DOMAIN/rest-api/action/a1b2c3d4e5/delete.do");
request.Headers.Add("X-Api-Key", "YOUR_API_KEY");
var response = await client.SendAsync(request);
Console.WriteLine(await response.Content.ReadAsStringAsync());