Skip to content

Directory Structure and Scripts

Elsa Perelli edited this page Nov 20, 2025 · 4 revisions

src Directory Structure

The following sub-directories exist in the src directory:

  • resources - Sets up BeeQueue export queue to establish new Redis Connectathon.
  • scripts - Contains database setup scripts and data upload scripts.
  • server - Connects to server, established queue that pulls down the jobs on Redis to handle, and establishes server endpoints.
  • services - Contains the following services:
    • bulkstatus.service - checks bulk export status (in progress, completed, etc.)
    • bundle.service - handles transaction bundle uploads
    • export.service - handles export level and validates provided parameters
    • group.service - manages FHIR group creation, updates, etc.
    • ndjson.service - returnes exported ndjson
  • util - Contains a variety of helper functions, including:
    • ValueSet handling for _typeFilter
    • Mongo setup
    • exportToNDJson file - contains the bulk of the logic on query building from the provided bulk parameters

Available npm Scripts

  • upload-bundles - Pulls bundles from the ecqm-content-r4-2021 repository. Requires that the repository is cloned locally in order to upload bundles successfully.
  • post-synthea-patients - Takes in a directory of Synthea patients and performs transaction bundle upload via POST request. Requires a directory path to Synthea patient bundles and for the server to be running.

Clone this wiki locally