Skip to content

Latest commit

 

History

History
28 lines (19 loc) · 656 Bytes

File metadata and controls

28 lines (19 loc) · 656 Bytes

MongoDB Export Example

Export study records to MongoDB while preserving nested record_data payloads.

Prerequisites

  • imednet[mongodb] installed:

    pip install 'imednet[mongodb]'

Environment variables

export IMEDNET_API_KEY=...
export IMEDNET_SECURITY_KEY=...      # if required by your environment
export MONGODB_URI=mongodb://localhost:27017
export MONGODB_DATABASE=imednet
export MONGODB_COLLECTION=records
export IMEDNET_STUDY_KEY=MY_STUDY
.. literalinclude:: /../examples/mongodb_export.py
   :language: python