SF - Enrollments Flat File - Incoming
The SF - Enrollments Flat File - Incoming is a standard flow that provides the baseline functionality for ingestion of an enrollment file to our database, and also provides the ability to customize values for integration-specific settings. The flow should be both customer and file-type agnostic, and be used by integration builders as a starting point for any integration that is built. It should also standardize the way a flow behaves, as well as log messages and status setting, to help with standardizing the way we build integrations for our customers.

Configuration of the Flow Widgets
While configuring the widgets composing this standard flow, only the following parameters should be set by the user:
Widget(s) | Parameter |
---|---|
ExternalSourceFhir | UNIQUE_ID_1 |
ExternalSourceFhir StageForExternalSink | SFTP_CONNECTION_ID |
ExternalSourceFhir StageForExternalSink | ENV |
ExternalSourceFhir StageForExternalSink | FLAT_FILENAME_REGEX |
StageForExternalSink | PAYER |
ValidateAndParseFile | UNIQUE_FILE_DEF_ID_1 |
MergeAndTranslatToFile | UNIQUE_ACK_FILE_DEF_ID_1 |
ValidateAndParseFile MergeAndTranslateToFile | PAYERID |
Create Enrollment Inbound Flat File Schema
Once the integration has been created and you have either imported or promoted a standard flow as inbound enrollment flat file, you must post the file schema created for “Enrollment Delimited Inbound Flat File“.
Curl the command in order to upload the schema attached in the previous step for a specific integration.
curl -X POST https://platform.prod.macrohealth.com/api/integration/INTEGRATON_ID/file/mhEnrollmentInboundDelimitedSchema \ -H 'Content-Type: application/json' \ -d 'BODY'
Tip
Replace BODY and INTEGRATION_ID with the content of the file attached in previous step.
Save the UUID generated in the previous step, which should be set as UNIQUE_FILE_DEF_ID_1 in the “Validate Inbound Delimited File“ widget.
Create Enrollment Acknowledgment File Schema for Inbound content
Repeat the previous steps by changing the filename in the endpoint.
Save the UUID generated in the previous step, which should be set as UNIQUE_ACK_FILE_DEF_ID_1 in the “Merge - Delimited Ack Generation“ widget.
External Source for FHIR Backed Flows
Defines the connection to an external SFTP.

id: UNIQUE_ID_1
connectionId: The ID of the SFTP configured in Connections.
directory: /PAYER/ENV/in
filenameConvention: FLAT_FILENAME_REGEX. Where:
UNIQUE_ID_1: Arbitrary UUID assigned by the user
FLAT_FILENAME_REGEX: Regex or literal name of the file defined by the Customer
For more information on how to configure this shovel operation, view External Source FHIR.
Validate Inbound Delimited File
This widget allows validating delimited files in this flow, data type, max lengths, and others.

fileDefinitionEntityType: PAYERIDEnrollmentInboundAckDelimitedSchema
fileDefinitionId: UNIQUE_ACK_FILE_DEF_ID_1
Where:
PAYERID: the name of the Payer is included as such payerEnrollmentInboundAckDelimitedSchema
UNIQUE_ACK_FILE_DEF_ID_1: the UUID set in the Create Enrollement Ack Fiel Schema step
For more information on how to configure this shovel operation, view Parse with File Definition.
Errors Branch

Route Errors

For more information on how to configure this shovel operation, view Route on Expression.
Commit Errors

For more information on how to configure this shovel operation, view Commit Transaction.
Commit (Errors Branch)

For more information on how to configure this shovel operation, view Commit Transaction.
Propagate Branch

Propagate Enrollments

For more information on how to configure this shovel operation, view Broadcast.
Filter Out Invalid Enrollments Branch

Filter Out Invalid Enrollments

For more information on how to configure this shovel operation, view Route on Expression.
Transaction Set to FHIR

For more information on how to configure this shovel operation, view Transaction Set to FHIR.
Stage for Store FHIR Bundle

For more information on how to configure this shovel operation, view Stage For Store FHIR Bundle.
Commit FHIR

For more information on how to configure this shovel operation, view Commit Transaction.
Commit Invalid Enrollments

For more information on how to configure this shovel operation, view Commit Transaction.
Ack Branch

Remap - Prepare Ack Content

For more information on how to configure this shovel operation, view Remap Document.
Merge - Delimited Ack Generation
This shovel operation is used to merge enrollment records already validated and generate the ack delimited file in the output.

fileDefinitionEntityType: PAYERIDEnrollmentInboundAckDelimitedSchema
fileDefinitionId: UNIQUE_ACK_FILE_DEF_ID_1
For more information on how to configure this shovel operation, view Merge and Translate to File.
Send Ack File
This shovel operation defines the connection to an external SFTP.

id: UNIQUE_ID_2
connectionId: the ID of the SFTP which was configured in Connections
directory: /PAYER/ENV/out
filenameConvention: FLAT_FILENAME_ACK_REGEX
Where:
UNIQUE_ID_1: Arbitrary UUID assigned by the user (Arbitrary ID assigned by the user and must be unique across all integrations)
FLAT_FILENAME_ACK_REGEX: shovel expression used to generate the file to the Customer. i.e.: concat("Eligibility_CUSTOMER_MH_", concat(formatDateTime(currentTime(),"YYYYMMddHHmmss","NETWORK"), "_ack.txt"))
For more information on how to configure this shovel operation, view Stage for External Sink.
Commit (Ack)

For more information on how to configure this shovel operation, view Commit Transaction.
Commit Unmerged

For more information on how to configure this shovel operation, view Commit Transaction.