|
31 | 31 | "post": { |
32 | 32 | "summary": "Detect anomalies for the entire series in batch.", |
33 | 33 | "description": "This operation generates a model using an entire series, each point is detected with the same model. With this method, points before and after a certain point are used to determine whether it is an anomaly. The entire detection can give user an overall status of the time series.", |
34 | | - "operationId": "EntireDetect", |
| 34 | + "operationId": "DetectEntireSeries", |
35 | 35 | "parameters": [ |
36 | 36 | { |
37 | 37 | "name": "body", |
38 | 38 | "in": "body", |
39 | 39 | "description": "Time series points and period if needed. Advanced model parameters can also be set in the request.", |
40 | 40 | "required": true, |
41 | 41 | "schema": { |
42 | | - "$ref": "#/definitions/Request" |
| 42 | + "$ref": "#/definitions/DetectRequest" |
43 | 43 | } |
44 | 44 | } |
45 | 45 | ], |
|
59 | 59 | "default": { |
60 | 60 | "description": "Error response.", |
61 | 61 | "schema": { |
62 | | - "$ref": "#/definitions/APIError" |
| 62 | + "$ref": "#/definitions/AnomalyDetectorError" |
63 | 63 | } |
64 | 64 | } |
65 | 65 | }, |
|
74 | 74 | "post": { |
75 | 75 | "summary": "Detect anomaly status of the latest point in time series.", |
76 | 76 | "description": "This operation generates a model using points before the latest one. With this method, only historical points are used to determine whether the target point is an anomaly. The latest point detecting operation matches the scenario of real-time monitoring of business metrics.", |
77 | | - "operationId": "LastDetect", |
| 77 | + "operationId": "DetectLastPoint", |
78 | 78 | "parameters": [ |
79 | 79 | { |
80 | 80 | "name": "body", |
81 | 81 | "in": "body", |
82 | 82 | "description": "Time series points and period if needed. Advanced model parameters can also be set in the request.", |
83 | 83 | "required": true, |
84 | 84 | "schema": { |
85 | | - "$ref": "#/definitions/Request" |
| 85 | + "$ref": "#/definitions/DetectRequest" |
86 | 86 | } |
87 | 87 | } |
88 | 88 | ], |
|
102 | 102 | "default": { |
103 | 103 | "description": "Error response.", |
104 | 104 | "schema": { |
105 | | - "$ref": "#/definitions/APIError" |
| 105 | + "$ref": "#/definitions/AnomalyDetectorError" |
106 | 106 | } |
107 | 107 | } |
108 | 108 | }, |
|
113 | 113 | } |
114 | 114 | } |
115 | 115 | }, |
116 | | - "/timeseries/changePoint/detect": { |
| 116 | + "/timeseries/changepoint/detect": { |
117 | 117 | "post": { |
118 | 118 | "summary": "Detect change point for the entire series", |
119 | 119 | "description": "Evaluate change point score of every series point", |
120 | | - "operationId": "ChangePointDetect", |
| 120 | + "operationId": "DetectChangePoint", |
121 | 121 | "parameters": [ |
122 | 122 | { |
123 | 123 | "name": "body", |
|
145 | 145 | "default": { |
146 | 146 | "description": "Error response.", |
147 | 147 | "schema": { |
148 | | - "$ref": "#/definitions/APIError" |
| 148 | + "$ref": "#/definitions/AnomalyDetectorError" |
149 | 149 | } |
150 | 150 | } |
151 | 151 | }, |
|
158 | 158 | } |
159 | 159 | }, |
160 | 160 | "definitions": { |
161 | | - "APIError": { |
| 161 | + "AnomalyDetectorError": { |
162 | 162 | "type": "object", |
163 | 163 | "description": "Error information returned by the API.", |
164 | 164 | "properties": { |
|
186 | 186 | } |
187 | 187 | } |
188 | 188 | }, |
189 | | - "Granularity": { |
| 189 | + "TimeGranularity": { |
190 | 190 | "type": "string", |
191 | 191 | "description": "Can only be one of yearly, monthly, weekly, daily, hourly, minutely or secondly. Granularity is used for verify whether input series is valid.", |
192 | 192 | "x-nullable": false, |
193 | 193 | "x-ms-enum": { |
194 | | - "name": "Granularity", |
195 | | - "modelAsString": false |
| 194 | + "name": "TimeGranularity", |
| 195 | + "modelAsString": false, |
| 196 | + "values": [ |
| 197 | + { |
| 198 | + "value": "yearly" |
| 199 | + }, |
| 200 | + { |
| 201 | + "value": "monthly" |
| 202 | + }, |
| 203 | + { |
| 204 | + "value": "weekly" |
| 205 | + }, |
| 206 | + { |
| 207 | + "value": "daily" |
| 208 | + }, |
| 209 | + { |
| 210 | + "value": "hourly" |
| 211 | + }, |
| 212 | + { |
| 213 | + "name": "perMinute", |
| 214 | + "value": "minutely" |
| 215 | + }, |
| 216 | + { |
| 217 | + "name": "perSecond", |
| 218 | + "value": "secondly" |
| 219 | + } |
| 220 | + ] |
196 | 221 | }, |
197 | 222 | "enum": [ |
198 | 223 | "yearly", |
|
210 | 235 | "x-nullable": false, |
211 | 236 | "description": "Custom Interval is used to set non-standard time interval, for example, if the series is 5 minutes, request can be set as {\"granularity\":\"minutely\", \"customInterval\":5}." |
212 | 237 | }, |
213 | | - "Request": { |
| 238 | + "DetectRequest": { |
214 | 239 | "type": "object", |
215 | 240 | "required": [ |
216 | 241 | "granularity", |
|
221 | 246 | "type": "array", |
222 | 247 | "description": "Time series data points. Points should be sorted by timestamp in ascending order to match the anomaly detection result. If the data is not sorted correctly or there is duplicated timestamp, the API will not work. In such case, an error message will be returned.", |
223 | 248 | "items": { |
224 | | - "$ref": "#/definitions/Point" |
| 249 | + "$ref": "#/definitions/TimeSeriesPoint" |
225 | 250 | } |
226 | 251 | }, |
227 | 252 | "granularity": { |
228 | | - "$ref": "#/definitions/Granularity" |
| 253 | + "$ref": "#/definitions/TimeGranularity" |
229 | 254 | }, |
230 | 255 | "customInterval": { |
231 | 256 | "description": "Custom Interval is used to set non-standard time interval, for example, if the series is 5 minutes, request can be set as {\"granularity\":\"minutely\", \"customInterval\":5}.", |
|
248 | 273 | } |
249 | 274 | } |
250 | 275 | }, |
251 | | - "Point": { |
| 276 | + "TimeSeriesPoint": { |
252 | 277 | "type": "object", |
253 | 278 | "required": [ |
254 | 279 | "timestamp", |
|
400 | 425 | "type": "array", |
401 | 426 | "description": "Time series data points. Points should be sorted by timestamp in ascending order to match the change point detection result.", |
402 | 427 | "items": { |
403 | | - "$ref": "#/definitions/Point" |
| 428 | + "$ref": "#/definitions/TimeSeriesPoint" |
404 | 429 | } |
405 | 430 | }, |
406 | 431 | "granularity": { |
407 | | - "$ref": "#/definitions/Granularity", |
| 432 | + "$ref": "#/definitions/TimeGranularity", |
408 | 433 | "description": "Can only be one of yearly, monthly, weekly, daily, hourly, minutely or secondly. Granularity is used for verify whether input series is valid." |
409 | 434 | }, |
410 | 435 | "customInterval": { |
|
0 commit comments