MCP Broker takes care of PRODA authentications for multiple medical practices, involving multiple PRODA devices, software instance keys and multiple instances of CloudPos.
The activation of the devices and the refresh of the software instance keys could be handled by DeviceHouseKeeping.exe through MCP Broker.
Prerequisites
1. The device is registered as per "PRODA B2B High Level.pdf", "Guide for creating PRODA Vendor Individual Account and Linking your Organisation.pdf" and "PRODA Step by Step guide.pdf" had described.
2. The key pair has been newly with kid=DeviceName, as described in "readme.md" of ActivateDevice.exe.
DeviceHouseKeeping.exe
This is a CLI program utlizing the Web API of MCP Broker which can handle PRODA devices of multiple organizations, in order to:
- Activate a PRODA device.
- Refresh software instance key.
- Refresh software instance keys due to expired.
- Query a device's expiry date.
- Query a key's expiry date.
- Query expiry info of all devices of organizations.
Activate Device
Run:
DeviceHouseKeeping.exe activate orgId deviceName activationCode
The endpoint of MCP Broker is defined in appsettings.json.
Remarks:
- During development and testing, DeviceHouseKeeping.csproj and Tests/McpBasic.csproj and McpBroker.csproj are sharing the same copy of
8992260705.MLK00000.json
through symbolic link. And make sure to update the key pair in the source repository after updating the device.
Refresh Software Instance Key
Run
DeviceHouseKeeping.exe refresh orgId clientId
.
Query Expiry Info of All Devices of Organizations
This will return the device and key info of all devices handled by MCP Broker. And an Email message will be sent to the admin of MCP Broker.
Run
DeviceHouseKeeping.exe queryAll
.
Refresh Software Instance Keys
This will refresh keys which are due to expire in 7 days. And after the refresh, an Email message is sent by MCP Broker to the system admin about all devices.
Run
DeviceHouseKeeping.exe refreshKeys
This Email message may also contain a section about devices to be expired within 30 days.
Query a Device's Expiry Date
This will return how many days left before the expiry of a device. And an Email message will be sent to the admin of MCP Broker.
Run
DeviceHouseKeeping.exe queryDeviceExpiry orgId deviceName
.
Hints
- This may be used as a casual check to see the supporting architecture of house keeping is working.
Query a Key's Expiry Date
This will return how many days left before the expiry of a key. And an Email message will be sent to the admin of MCP Broker.
Run
DeviceHouseKeeping.exe queryKeyExpiry orgId clientId
Hints
- This may be used as a casual check to see the supporting architecture of house keeping is working.
Automation of House Keeping
Email is the primary channel of notification about the expiry of PRODA devices and software instance keys. Since the house keeping is mostly done through MCP Broker which provides Web API returning respect info, other channles of notification may be implemented in the future.
In a workstation/PC/server that runs 24x7, run a daily task of scheduler which calls DeviceHouseKeeping.exe refreshKeys
. Therefore, generally the key refresh should be automatic without user interaction, and not needing notification to system admin.
During the startup of MCP Broker, the broker will check:
- Whether any key is due to expire in 7 days, an Email message is sent by MCP Broker to the system admin about all keys due to expire. The admin should then run
DeviceHouseKeeping.exe refreshKeys
and investigate why the scheduled task of key refresh is not running successfully. - Whether any device is due to expire in 30 days, an Email message is sent by MCP Broker to the system admin about all devices due to expire in 30 days.
For further assurance, the system admin should set a weekly task in the scheduler which runs DeviceHouseKeeping.exe queryAll
. If the system admin is not getting respective Email message weekly, the admin should investigate if somewhere in the house keeping automation is going wrong.
To decide the schedule of auto refresh of software instance keys, please consider the following factors:
- The scheduled outages of PRODA.
- The common schedules of bulkbill operations run by all CloudPos instances associated with this MCP Broker instance.