import Dataframer from 'dataframer';
const client = new Dataframer({
apiKey: 'My API Key',
});
const dataset = await client.dataframer.datasets.update('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');
console.log(dataset.id);{
"name": "<string>",
"dataset_type": "SINGLE_FILE",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"description": "<string>",
"dataset_type_display": "<string>",
"config_json": {},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"created_by": 123,
"created_by_name": "<string>",
"company": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"company_name": "<string>",
"folders": [
{
"name": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"description": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"files": [
{
"file_name": "<string>",
"file_type": "JSON",
"storage_uri": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"file_type_display": "<string>",
"bytes_size": 0,
"sha256": "<string>",
"folder_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"datasets_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2023-11-07T05:31:56Z"
}
],
"file_count": 123
}
],
"folder_count": 123,
"file_count": 123,
"short_sample_compatibility": {
"is_short_samples_compatible": true,
"is_long_samples_compatible": true,
"reason": "<string>"
}
}Update dataset name and description.
Note: Only metadata can be updated. Dataset type and structure cannot be changed after creation.
import Dataframer from 'dataframer';
const client = new Dataframer({
apiKey: 'My API Key',
});
const dataset = await client.dataframer.datasets.update('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');
console.log(dataset.id);{
"name": "<string>",
"dataset_type": "SINGLE_FILE",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"description": "<string>",
"dataset_type_display": "<string>",
"config_json": {},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"created_by": 123,
"created_by_name": "<string>",
"company": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"company_name": "<string>",
"folders": [
{
"name": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"description": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"files": [
{
"file_name": "<string>",
"file_type": "JSON",
"storage_uri": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"file_type_display": "<string>",
"bytes_size": 0,
"sha256": "<string>",
"folder_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"datasets_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2023-11-07T05:31:56Z"
}
],
"file_count": 123
}
],
"folder_count": 123,
"file_count": 123,
"short_sample_compatibility": {
"is_short_samples_compatible": true,
"is_long_samples_compatible": true,
"reason": "<string>"
}
}API Key authentication. Format: "Bearer YOUR_API_KEY"
Dataset updated successfully
1SINGLE_FILE, MULTI_FILE, MULTI_FOLDER 111Show child attributes
1Show child attributes
1JSON, JSONL, CSV, MD, TXT, PDF 11-9223372036854776000 <= x <= 9223372036854776000Show child attributes
Whether the dataset is compatible with short sample generation
Whether the dataset is compatible with long sample generation
Reason for incompatibility if applicable