Get Study Data Availability
get_study_data_availabilityRetrieve record-count inventories for every ImmPort data category in one or more studies to assess which parsed datasets are available before fetching assay or study data.
Instructions
Get a record-count inventory for every ImmPort data category in a study — how many rows have been parsed out of the raw data and stored in the ImmPort database.
⚡ CALL THIS FIRST when assessing what data a study contains. It reads the study's ~5 KB release file listing every ImmPort data category alongside its record count for this specific study.
MULTIPLE STUDIES: study_accession may list up to 20 studies separated by commas (e.g. 'SDY180,SDY212') — one call instead of one per study; the result is then a list with one entry per study, in the order given.
USE THIS TO AVOID WASTED API CALLS: • elisa_result=0 → skip get_assay_results(assay_type='elisa') • hai_result=240 → study has HAI titer data worth fetching • lab_test=0 → no clinical lab data, don't call get_study_data(resource='lab_tests') • assessment_component=98893 → very large dataset, use Tab.zip instead of the API • immune_exposure=0 → no vaccination/challenge records • fcs_analyzed_result=0 but expsample=500 → raw FCS files exist but no gated data
⚠️ IMPORTANT LIMITATION — PARSED DATA ONLY: These counts reflect only data that ImmPort has parsed and loaded into its relational database. Many studies — especially older studies, recently submitted data, and studies with non-standard formats — contain data exclusively inside their study files that has not been parsed into the database. A count of 0 does NOT mean the data doesn't exist; it means it hasn't been extracted into the ImmPort data model yet.
When counts are low or zero for a study you expect to have data:
Call get_study_files(action='manifest', study_accession=...) with no file_type filter to see all available files.
Stream individual study_file or protocol_file documents (action='stream') — protocols, case report forms, and data dictionaries often describe data that was submitted but not parsed.
Get a signed URL for the Tab.zip (file_type='release_file' → find '_Tab.zip' → action='download') — it contains the complete set of parsed TSV files and is often more complete than the API responses.
Returns (one study): {'studyAccession': 'SDY####', 'dataRelease': 'DR##', 'tables': {category_name: record_count, ...}}; a study without the release file gets {'studyAccession', 'error'} instead. Several studies: a list of these.
Zero-count categories ARE included — 0 means not parsed into the database, not necessarily absent from the study. Requires authentication.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| study_accession | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |