@@ -2,6 +2,7 @@ import { Query } from '../models/query/query';
2
2
import { GenericResponse } from '../models/response/responses' ;
3
3
import { XYModel } from '../models/xy' ;
4
4
import { TimeGraphEntry , TimeGraphArrow , TimeGraphModel } from '../models/timegraph' ;
5
+ import { AnnotationCategoriesModel , AnnotationModel } from '../models/annotation' ;
5
6
import { TableModel , ColumnHeaderEntry } from '../models/table' ;
6
7
import { Trace } from '../models/trace' ;
7
8
import { RestClient } from './rest-client' ;
@@ -218,6 +219,29 @@ export class TspClient {
218
219
return await RestClient . post < GenericResponse < TimeGraphArrow > > ( url , parameters ) ;
219
220
}
220
221
222
+ /**
223
+ * Fetch annotations categories.
224
+ * @param expUUID Experiment UUID
225
+ * @param outputID Output ID
226
+ * @returns Generic response with the model
227
+ */
228
+ public async fetchAnnotationsCategories ( expUUID : string , outputID : string ) : Promise < TspClientResponse < GenericResponse < AnnotationCategoriesModel > > > {
229
+ const url = this . baseUrl + '/experiments/' + expUUID + '/outputs/' + outputID + '/annotations' ;
230
+ return await RestClient . get < GenericResponse < AnnotationCategoriesModel > > ( url ) ;
231
+ }
232
+
233
+ /**
234
+ * Fetch annotations.
235
+ * @param expUUID Experiment UUID
236
+ * @param outputID Output ID
237
+ * @param parameters Query object
238
+ * @returns Generic response with the model
239
+ */
240
+ public async fetchAnnotations ( expUUID : string , outputID : string , parameters : Query ) : Promise < TspClientResponse < GenericResponse < AnnotationModel > > > {
241
+ const url = this . baseUrl + '/experiments/' + expUUID + '/outputs/' + outputID + '/annotations' ;
242
+ return await RestClient . post < GenericResponse < AnnotationModel > > ( url , parameters ) ;
243
+ }
244
+
221
245
/**
222
246
* Fetch Time Graph tooltip for states and arrows
223
247
* @param expUUID Experiment UUID
0 commit comments