Python
import os
from dataframer import Dataframer
client = Dataframer(
api_key=os.environ.get("DATAFRAMER_API_KEY"), # This is the default and can be omitted
)
response = client.dataframer.seed_datasets.create_from_zip(
name="name",
zip_file=b"Example data",
)
print(response.id)curl https://df-api.dataframer.ai/api/dataframer/seed-datasets/create-from-zip/ \
-H 'Content-Type: multipart/form-data' \
-H "Authorization: Bearer $DATAFRAMER_API_KEY" \
-F name=name \
-F 'zip_file=@/path/to/zip_file'{
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "Support Ticket Conversations",
"description": "Customer support chat logs organized by ticket",
"dataset_type": "MULTI_FOLDER",
"file_count": 10,
"folder_count": 2,
"created_at": "2025-01-15T10:30:00Z",
"created_by_email": "sarah.chen@acme.com"
}{
"error": "<string>",
"code": "not_supported_hybrid"
}Seed Datasets
Create seed dataset from ZIP
Create a seed dataset by uploading a ZIP file
POST
/
api
/
dataframer
/
seed-datasets
/
create-from-zip
/
Python
import os
from dataframer import Dataframer
client = Dataframer(
api_key=os.environ.get("DATAFRAMER_API_KEY"), # This is the default and can be omitted
)
response = client.dataframer.seed_datasets.create_from_zip(
name="name",
zip_file=b"Example data",
)
print(response.id)curl https://df-api.dataframer.ai/api/dataframer/seed-datasets/create-from-zip/ \
-H 'Content-Type: multipart/form-data' \
-H "Authorization: Bearer $DATAFRAMER_API_KEY" \
-F name=name \
-F 'zip_file=@/path/to/zip_file'{
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "Support Ticket Conversations",
"description": "Customer support chat logs organized by ticket",
"dataset_type": "MULTI_FOLDER",
"file_count": 10,
"folder_count": 2,
"created_at": "2025-01-15T10:30:00Z",
"created_by_email": "sarah.chen@acme.com"
}{
"error": "<string>",
"code": "not_supported_hybrid"
}The system automatically detects the dataset type based on ZIP structure:
- SINGLE_FILE: ZIP contains exactly one file containing all the samples
- MULTI_FILE: ZIP contains multiple files at root level, where each file is a separate sample
- MULTI_FOLDER: ZIP contains multiple folders, where each folder is a separate sample and only contains files with no nested folders
File constraints by dataset type
| Type | Allowed formats | Size limit | Count limit |
|---|---|---|---|
| SINGLE_FILE | CSV, JSON, JSONL | 50MB | 1 file, min 2 rows |
| MULTI_FILE | TXT, MD, JSON, CSV, JSONL, PDF | 1MB/file, 50MB total | 2-1000 files |
| MULTI_FOLDER | TXT, MD, JSON, CSV, JSONL, PDF | 1MB/file, 50MB total | 2-1000 files, 20/folder, min 2 folders |
Authorizations
Body
multipart/form-data
Response
Seed dataset created successfully

