@narrative.io/data-collaboration-sdk-ts 2.41.0 → 2.42.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/models/index.d.ts +7 -0
- package/build/models/index.js +9 -0
- package/package.json +1 -1
package/build/models/index.d.ts
CHANGED
|
@@ -20,5 +20,12 @@ declare class ModelsApi extends BaseApi {
|
|
|
20
20
|
* @returns {Promise<Model>} A promise that resolves with the updated model.
|
|
21
21
|
*/
|
|
22
22
|
updateModel(modelId: string, data: UpdateModelRequest): Promise<Model>;
|
|
23
|
+
/**
|
|
24
|
+
* Deletes a model from the API.
|
|
25
|
+
*
|
|
26
|
+
* @param {string} modelId - The ID of the model to delete.
|
|
27
|
+
* @returns {Promise<void>} A promise that resolves when the model is deleted.
|
|
28
|
+
*/
|
|
29
|
+
deleteModel(modelId: string): Promise<void>;
|
|
23
30
|
}
|
|
24
31
|
export { ModelsApi, type ModelCollaborators, type Model, type CreateModelRequest, type UpdateModelRequest, };
|
package/build/models/index.js
CHANGED
|
@@ -29,5 +29,14 @@ class ModelsApi extends BaseApi {
|
|
|
29
29
|
async updateModel(modelId, data) {
|
|
30
30
|
return await this.put(`${resourceName}/${modelId}`, data);
|
|
31
31
|
}
|
|
32
|
+
/**
|
|
33
|
+
* Deletes a model from the API.
|
|
34
|
+
*
|
|
35
|
+
* @param {string} modelId - The ID of the model to delete.
|
|
36
|
+
* @returns {Promise<void>} A promise that resolves when the model is deleted.
|
|
37
|
+
*/
|
|
38
|
+
async deleteModel(modelId) {
|
|
39
|
+
return await this.delete(`${resourceName}/${modelId}`);
|
|
40
|
+
}
|
|
32
41
|
}
|
|
33
42
|
export { ModelsApi, };
|