patient_api
In-process FastAPI service serving patient-eligibility data to the Trials Web App.
The package is laid out as:
app.py— the factory: what the app is and how it is wired.openapi.py— the published contract: its version, and how the document is built and rendered.routes.py— the API's routes, assembled from the domains.domains/— one directory per subject the API serves, holding that subject's routes, models, repository methods and examples.core/— what the domains share: the routing plumbing, the cross-domain models, and the published-partition lookup.models.py,protocol.py,repository.py,examples.py— façades that keep the names those modules have always exported importable, now that the definitions live with the domains.auth.py,server.py,service.py— how the pod runs it.
tests/bitfount/patient_api/test_openapi.py pins the published document, so a
change to the API's surface fails there rather than reaching a client.
Module
Submodules
- bitfount.patient_api.app - FastAPI application factory for the patient-data API.
- bitfount.patient_api.auth - Authentication for the patient-data API.
- bitfount.patient_api.core - What the patient-data API's domains share.
- bitfount.patient_api.dependencies - FastAPI dependency providers for the patient-data API.
- bitfount.patient_api.domains - The patient-data API's domains.
- bitfount.patient_api.examples - Where a caller imports the served examples from.
- bitfount.patient_api.models - Where a caller imports the patient-data API's models from.
- bitfount.patient_api.openapi - The published contract: how the API's surface becomes its OpenAPI document.
- bitfount.patient_api.protocol - Data-access seam for the patient-data API.
- bitfount.patient_api.repository - Cache-backed implementation of the patient-data API's data-access seam.
- bitfount.patient_api.routes - The patient-data API's routes, assembled from its domains.
- bitfount.patient_api.server - Runs the patient-data API via uvicorn in a dedicated daemon thread.
- bitfount.patient_api.service - Builds and serves the patient-data API, with no
Podinvolved.