Dataset API
api_delete_dataset(ds_id)
Deletes a dataset identified by its unique dataset ID.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
ds_id |
str
|
The unique identifier for the dataset to be deleted. |
required |
Returns:
Name | Type | Description |
---|---|---|
bool |
bool
|
True if the dataset was successfully deleted. |
Raises:
Type | Description |
---|---|
Exception
|
If the deletion process encounters an error. |
Source code in moonshot/src/api/api_dataset.py
api_get_all_datasets()
This function retrieves all available datasets and returns them as a list of dictionaries. Each dictionary represents a result and contains its information.
Returns:
Type | Description |
---|---|
list[dict]
|
list[dict]: A list of dictionaries, each representing a result. |
Source code in moonshot/src/api/api_dataset.py
api_get_all_datasets_name()
This function retrieves all available datasets names and returns them as a list.
Returns:
Type | Description |
---|---|
list[str]
|
list[str]: A list of datasets names. |