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: docs/useCases.md
+35Lines changed: 35 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -20,6 +20,7 @@ The different use cases currently available in the package are classified below,
20
20
-[List All Datasets](#list-all-datasets)
21
21
-[Datasets write use cases](#datasets-write-use-cases)
22
22
-[Create a Dataset](#create-a-dataset)
23
+
-[Publish a Dataset](#publish-a-dataset)
23
24
-[Files](#Files)
24
25
-[Files read use cases](#files-read-use-cases)
25
26
-[Get a File](#get-a-file)
@@ -305,6 +306,40 @@ The above example creates the new dataset in the `root` collection since no coll
305
306
306
307
The use case returns a [CreatedDatasetIdentifiers](../src/datasets/domain/models/CreatedDatasetIdentifiers.ts) object, which includes the persistent and numeric identifiers of the created dataset.
307
308
309
+
#### Publish a Dataset
310
+
311
+
Publishes a Dataset, given its identifier and the type of version update to perform.
The above example publishes the dataset with the specified identifier and performs a minor version update. If the response
333
+
is successful, the use case does not return the dataset object, but the HTTP status code `200`. Otherwise, it throws an error.
334
+
If you want to perform a major version update, you must set the `versionUpdateType` parameter to `VersionUpdateType.MAJOR`.
335
+
336
+
The `datasetId` parameter can be a string, for persistent identifiers, or a number, for numeric identifiers.
337
+
338
+
The `versionUpdateType` parameter can be a [VersionUpdateType](../src/datasets/domain/models/VersionUpdateType.ts) enum value, which can be one of the following:
0 commit comments