You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: _tuning-your-cluster/availability-and-recovery/workload-management/create-workload-group-rules-api.md
+26-3Lines changed: 26 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -62,7 +62,7 @@ You can retrieve rules created using the Create Workload Group Rules API by rule
62
62
The following request retrieves a rule by ID for the `workload_group` feature type:
63
63
64
64
```json
65
-
GET /_rules/workload_group/{_id}
65
+
GET /_rules/workload_group/{id}
66
66
```
67
67
{% include copy-curl.html %}
68
68
@@ -90,6 +90,15 @@ The following request provides the next page of rules from the same workload gro
90
90
```
91
91
{% include copy-curl.html %}
92
92
93
+
### Delete a rule
94
+
95
+
The following request deletes a rule using the rule's ID:
96
+
97
+
```json
98
+
DELETE /_rules/workload_group/{id}
99
+
```
100
+
{% include copy-curl.html %}
101
+
93
102
## Example responses
94
103
95
104
<detailsopenmarkdown="block">
@@ -100,7 +109,7 @@ The following request provides the next page of rules from the same workload gro
100
109
101
110
```json
102
111
{
103
-
"_id": "wi6VApYBoX5wstmtU_8l",
112
+
"id": "wi6VApYBoX5wstmtU_8l",
104
113
"description": "description for rule",
105
114
"index_pattern": ["log*", "event*"],
106
115
"workload_group": "EITBzjFkQ6CA-semNWGtRQ",
@@ -121,7 +130,7 @@ The following request provides the next page of rules from the same workload gro
121
130
{
122
131
"rules": [
123
132
{
124
-
"_id": "z1MJApUB0zgMcDmz-UQq",
133
+
"id": "z1MJApUB0zgMcDmz-UQq",
125
134
"description": "Rule for tagging workload_group_id to index123",
126
135
"index_pattern": ["index123"],
127
136
"workload_group": "workload_group_id",
@@ -137,3 +146,17 @@ If the `search_after` field is present in the response, more results are availab
137
146
To retrieve the next page, include the `search_after` value in the next `GET` request as a query parameter, such as `GET /_rules/{feature_type}?search_after=z1MJApUB0zgMcDmz-UQq`.
0 commit comments