Skip to content

Commit 074d29a

Browse files
Adds an example share request as javadoc comment
Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
1 parent 515920d commit 074d29a

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

src/main/java/org/opensearch/timeseries/rest/RestShareConfigAction.java

+15-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,21 @@
2424
/**
2525
* Registers REST API to handle detector/forecaster sharing.
2626
* Here is an example request:
27-
*
27+
* POST /_plugins/_anomaly_detection/detectors
28+
* {
29+
* "config_id" : <document_id>,
30+
* "share_with" : {
31+
* "AD_FULL_ACCESS": {
32+
* "users": ["x"],
33+
* "roles": ["y"],
34+
* "backend_roles": ["z"]
35+
* }
36+
* }
37+
* }
38+
* example response:
39+
* {
40+
* "message": "Resource <document_id> shared successfully with <share_with>"
41+
* }
2842
*/
2943
public class RestShareConfigAction extends BaseRestHandler {
3044
public RestShareConfigAction() {}

0 commit comments

Comments
 (0)