+
+
+
+
+
+
+ deleteAlertRule
+ ++
/api/v1/alerts/rule/{id}
+ +
Usage and SDK Samples
+ + + +
+
+
+
+
+ curl -X DELETE \
+-H "api-key: [[apiKey]]" \
+ -H "Accept: application/json" \
+ "https://app.sentio.xyz/api/v1/alerts/rule/{id}"
+
+
+
+
+ import org.openapitools.client.*;
+import org.openapitools.client.auth.*;
+import org.openapitools.client.model.*;
+import org.openapitools.client.api.DefaultApi;
+
+import java.io.File;
+import java.util.*;
+
+public class DefaultApiExample {
+ public static void main(String[] args) {
+ ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+ // Configure API key authorization: ApiKeyAuth
+ ApiKeyAuth ApiKeyAuth = (ApiKeyAuth) defaultClient.getAuthentication("ApiKeyAuth");
+ ApiKeyAuth.setApiKey("YOUR API KEY");
+ // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+ //ApiKeyAuth.setApiKeyPrefix("Token");
+
+ // Create an instance of the API class
+ DefaultApi apiInstance = new DefaultApi();
+ String id = id_example; // String |
+
+ try {
+ Object result = apiInstance.deleteAlertRule(id);
+ System.out.println(result);
+ } catch (ApiException e) {
+ System.err.println("Exception when calling DefaultApi#deleteAlertRule");
+ e.printStackTrace();
+ }
+ }
+}
+
+
+
+
+ import 'package:openapi/api.dart';
+
+final api_instance = DefaultApi();
+
+final String id = new String(); // String |
+
+try {
+ final result = await api_instance.deleteAlertRule(id);
+ print(result);
+} catch (e) {
+ print('Exception when calling DefaultApi->deleteAlertRule: $e\n');
+}
+
+
+
+
+
+ import org.openapitools.client.api.DefaultApi;
+
+public class DefaultApiExample {
+ public static void main(String[] args) {
+ DefaultApi apiInstance = new DefaultApi();
+ String id = id_example; // String |
+
+ try {
+ Object result = apiInstance.deleteAlertRule(id);
+ System.out.println(result);
+ } catch (ApiException e) {
+ System.err.println("Exception when calling DefaultApi#deleteAlertRule");
+ e.printStackTrace();
+ }
+ }
+}
+
+
+
+ Configuration *apiConfig = [Configuration sharedConfig];
+
+// Configure API key authorization: (authentication scheme: ApiKeyAuth)
+[apiConfig setApiKey:@"YOUR_API_KEY" forApiKeyIdentifier:@"api-key"];
+// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
+//[apiConfig setApiKeyPrefix:@"Bearer" forApiKeyIdentifier:@"api-key"];
+
+
+// Create an instance of the API class
+DefaultApi *apiInstance = [[DefaultApi alloc] init];
+String *id = id_example; // (default to null)
+
+[apiInstance deleteAlertRuleWith:id
+ completionHandler: ^(Object output, NSError* error) {
+ if (output) {
+ NSLog(@"%@", output);
+ }
+ if (error) {
+ NSLog(@"Error: %@", error);
+ }
+}];
+
+
+
+
+
+ var SentioApi = require('sentio_api');
+var defaultClient = SentioApi.ApiClient.instance;
+
+// Configure API key authorization: ApiKeyAuth
+var ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
+ApiKeyAuth.apiKey = "YOUR API KEY";
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//ApiKeyAuth.apiKeyPrefix['api-key'] = "Token";
+
+// Create an instance of the API class
+var api = new SentioApi.DefaultApi()
+var id = id_example; // {String}
+
+var callback = function(error, data, response) {
+ if (error) {
+ console.error(error);
+ } else {
+ console.log('API called successfully. Returned data: ' + data);
+ }
+};
+api.deleteAlertRule(id, callback);
+
+
+
+
+ using System;
+using System.Diagnostics;
+using Org.OpenAPITools.Api;
+using Org.OpenAPITools.Client;
+using Org.OpenAPITools.Model;
+
+namespace Example
+{
+ public class deleteAlertRuleExample
+ {
+ public void main()
+ {
+ // Configure API key authorization: ApiKeyAuth
+ Configuration.Default.ApiKey.Add("api-key", "YOUR_API_KEY");
+ // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
+ // Configuration.Default.ApiKeyPrefix.Add("api-key", "Bearer");
+
+ // Create an instance of the API class
+ var apiInstance = new DefaultApi();
+ var id = id_example; // String | (default to null)
+
+ try {
+ Object result = apiInstance.deleteAlertRule(id);
+ Debug.WriteLine(result);
+ } catch (Exception e) {
+ Debug.Print("Exception when calling DefaultApi.deleteAlertRule: " + e.Message );
+ }
+ }
+ }
+}
+
+
+
+
+ <?php
+require_once(__DIR__ . '/vendor/autoload.php');
+
+// Configure API key authorization: ApiKeyAuth
+OpenAPITools\Client\Configuration::getDefaultConfiguration()->setApiKey('api-key', 'YOUR_API_KEY');
+// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
+// OpenAPITools\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('api-key', 'Bearer');
+
+// Create an instance of the API class
+$api_instance = new OpenAPITools\Client\Api\DefaultApi();
+$id = id_example; // String |
+
+try {
+ $result = $api_instance->deleteAlertRule($id);
+ print_r($result);
+} catch (Exception $e) {
+ echo 'Exception when calling DefaultApi->deleteAlertRule: ', $e->getMessage(), PHP_EOL;
+}
+?>
+
+
+
+ use Data::Dumper;
+use WWW::OPenAPIClient::Configuration;
+use WWW::OPenAPIClient::DefaultApi;
+
+# Configure API key authorization: ApiKeyAuth
+$WWW::OPenAPIClient::Configuration::api_key->{'api-key'} = 'YOUR_API_KEY';
+# uncomment below to setup prefix (e.g. Bearer) for API key, if needed
+#$WWW::OPenAPIClient::Configuration::api_key_prefix->{'api-key'} = "Bearer";
+
+# Create an instance of the API class
+my $api_instance = WWW::OPenAPIClient::DefaultApi->new();
+my $id = id_example; # String |
+
+eval {
+ my $result = $api_instance->deleteAlertRule(id => $id);
+ print Dumper($result);
+};
+if ($@) {
+ warn "Exception when calling DefaultApi->deleteAlertRule: $@\n";
+}
+
+
+
+ from __future__ import print_statement
+import time
+import openapi_client
+from openapi_client.rest import ApiException
+from pprint import pprint
+
+# Configure API key authorization: ApiKeyAuth
+openapi_client.configuration.api_key['api-key'] = 'YOUR_API_KEY'
+# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
+# openapi_client.configuration.api_key_prefix['api-key'] = 'Bearer'
+
+# Create an instance of the API class
+api_instance = openapi_client.DefaultApi()
+id = id_example # String | (default to null)
+
+try:
+ api_response = api_instance.delete_alert_rule(id)
+ pprint(api_response)
+except ApiException as e:
+ print("Exception when calling DefaultApi->deleteAlertRule: %s\n" % e)
+
+
+ extern crate DefaultApi;
+
+pub fn main() {
+ let id = id_example; // String
+
+ let mut context = DefaultApi::Context::default();
+ let result = client.deleteAlertRule(id, &context).wait();
+
+ println!("{:?}", result);
+}
+
+ Scopes
+Parameters
+ +Path parameters
+ Name | +Description | +
---|---|
id* | +
+
+
+
+
+
+
+
+
+ String
+
+
+
+
+ Required
+
+ |
+
Responses
+ + + + + + + + +
+
+
+
+
+
+
+
+