Health Gateway provides secure and convenient access to your B.C. health records all in one place. Keep track of what's important to you and your health.
- Health records Access your blood test and other lab results, medication history, immunization records, health visits and more.
- Poof of vaccination Save proof of vaccination documents for you and your family. Have them ready for travel or to access events and services that require it.
- Health resources Connect with HealthLink BC for health advice and get the latest information about COVID-19.
graph LR
A((Clone project)) --> B((Open Terminal))
B --> C((Navigate project directory))
C --> D{execute Pod instsall}
D --> E((open BCVaccineCard.xcworkspace))
- IQKeyboardManagerSwift: keyboard manager
- AlamofireRSSParser: used for processing data
- SnowplowTracker: used for tracking anonymous app analytics
- SwiftyJSON: used for processing data
- SwipeCellKit: siwpable cells
- SwiftQRCodeGenerator: used for generating QR svgs
- PocketSVG: Used for converting SVG into ios friendly formats
- BCVaccineValidator: validation library for BC vaccine cards
- EncryptedCoreData: storage encryption.
QueueITLibrary: used with some health gateway endpoints
Switch between different environments by selecting the appropriate target:
- HealthGateway (PROD)
- HealthGatewayDev
- HealthGatewayTest
Github Actions have been setup for this project for handling the archive and upload of builds:
- Pushes to the dev branch will trigger a workflow to create and upload a build to TestFlight
- Pushes to the main branch will trigger a workflow to create and upload a build to TestFlight
You can upload builds manually through Xcode, after obtaining the certificates from an admin of Government of British Columbia Apple account. The certificates included in the repository are encrypted for use by the automated pipeline.
This application uses UIKit as its UI framework, and Core Data with encryption as its storage option.
The diagram below shows the high level architecture:
graph LR
A[View Controller]
C(View Model)
D(Storage Service)
E(Core Data)
G(Record Services)
F(Health Gateway API)
A --> C
C --> A
C --> D
D --> C
D --> E
E --> D
C --> G
G ---> C
G --> F
F --> G
G ---> D
Each health record type has its it own record service that handles the network calls, and storage of data through the Storage Service Storage Service handles reads and writes from the core data database.
The data for this application is completely wiped and re-fetched with each synchronization and the app is not required to hold onto data that hasn't been uploaded to the back end. Because of this, the database doesn't require manual migrations.
If there is a change in the Database structure, update the app version. If the app was updated, or if there was any error with accessing the database, MigrationService will delete the sqlite file and generate a new one on application launch.
The documentation for the backend api is available through Swagger. There are services for various sets of APIs: