API Reference#
The EEGDash API reference curates everything you need to integrate, extend, and automate EEGDash—from core dataset helpers to feature extraction and rich dataset metadata. The focus is interoperability, extensibility, and ease of use.
What's inside EEGDash
Everything you need to discover, prepare, and benchmark EEG and MEG data.
Search metadata, modalities, tasks, and cohorts with unified filters.
One-command pipelines with EEGPrep, MNE, and BIDS alignment.
Export model-ready features and compare baselines across datasets.
Keep metadata consistent and portable across teams and tools.
The API is organized into three main components:
Core API
Build, query, and manage EEGDash datasets and utilities.
Feature engineering
Extract statistical, spectral, and machine-learning-ready features.
Dataset catalog
Browse dynamically generated dataset classes with rich metadata.
REST API Endpoints#
The EEGDash metadata server exposes a FastAPI REST interface for discovery and querying. Base URL: https://data.eegdash.org. Below is a concise map of the main entrypoints and their purpose.
Meta Endpoints#
GET /Returns API name, version, and available databases.GET /healthReturns API health and MongoDB connection status.GET /metricsPrometheus metrics (if enabled).
Public Data Endpoints#
GET /api/{database}/recordsQuery records (files) with filter and pagination.GET /api/{database}/countCount records matching a filter.GET /api/{database}/datasets/namesList unique dataset names from records.GET /api/{database}/metadata/{dataset}Get metadata for a single dataset (from records).GET /api/{database}/datasets/summaryGet summary statistics and metadata for all datasets (with pagination, filtering). Query params:limit(1-1000),skip,modality(eeg/meg/ieeg),source(openneuro/nemar/zenodo/etc.). Response includes aggregate totals for datasets, subjects, files, and size.GET /api/{database}/datasets/summary/{dataset_id}Get detailed summary for a specific dataset.dataset_idmay be the dataset ID or dataset name.GET /api/{database}/datasets/{dataset_id}Get a specific dataset document by ID.GET /api/{database}/datasetsList dataset documents (with filtering and pagination).GET /api/{database}/datasets/stats/recordsGet aggregatednchansandsampling_frequencycounts for all datasets. Used to generate summary tables efficiently.
Admin Endpoints (require Bearer token)#
POST /admin/{database}/recordsInsert a single record (file document).POST /admin/{database}/records/bulkInsert multiple records (max 1000 per request).POST /admin/{database}/datasetsInsert or update a single dataset document (upsert bydataset_id).POST /admin/{database}/datasets/bulkInsert or update multiple dataset documents (max 500 per request).PATCH /admin/{database}/recordsUpdate records matching a filter (only$setallowed).GET /admin/security/blockedList blocked IPs and offense counts.POST /admin/security/unblockUnblock a specific IP.