Submission File and Field Details
9 min
this section details the shared requirements for all targeted messaging file formats field schema requirement designation throughout this guide, fields are designated as either mandatory, conditional, optional, or not used this provides a uniform way to distinguish which fields the system requires, expects, or simply recommends for most workflows code description mandatory the element must always be populated if missing in the header or trailer the file will fail if missing in a record, the record will fail if 10% or more of the records in a file fail, the file will stop processing conditional this element must be populated when the given conditions are met optional for the best outcome of messages surescripts recommends populating the element, but does not place any conditional or mandatory validation on it not used not used in this product but is included since it’s used in other similar surescripts products (often indicates a mandatory blank space ) character types and formats see the american standard code for information interchange (ascii) http //www asciitable com/ for a list of valid code representations for accepted character types use of characters outside these types will be rejected, which may cause records or entire files to fail alphanumeric data must only contain ascii characters with decimal values of 32 through 126, excluding the delimiter characters listed in the delimiter characters section numeric data must be composed of the integers 0 9 the field schemas use the following character type notations character type notation alphanumeric an date dt numeric n time tm date formats notation meaning cc two digit century, such as 19 in the year 1999 yy two digit year, such as 99 in the year 1999 mm two digit month (01=january, etc ) dd day of the month (01 31) time formats notation meaning hh two digits of hour (00 23) mm two digits of minute (00 59) ss two digits of second (00 59) dd two digits of decimal seconds (00 99) delimiter characters the following table contains delimiter characters used in inbound and outbound files unique fields must be separated using the pipe (|) character only unique records (rows) within the file must be separated by using either the line feed (lf) or both carriage return (cr) and lf characters together character description ascii hexadecimal value | pipe 0x7c lf line feed 0x0a cr carriage return 0x0d although the following characters are considered delimiter characters, they must not be used within submitted files inclusion of any of these characters will be read as field delimiters and cause records containing these characters to be flagged as an error character description ascii hexadecimal value asterisk 0x2a \ backslash 0x5c colon 0x3a tilde 0x7e file naming and formats to ensure proper file processing, as well as our ability to properly support customers with processed files, there are a few key rules that must be followed review the table below for more information rules instructions file naming convention the naming convention for targeted messaging batch files is pnlcustomername ccyymmddxx where ccyymmdd is the file transmission date and xx is a unique sequence for that day surescripts provides the customername portion, which will consist of 3 14 letters unique to the customer notice that standard files begin with pnl , while immunization files begin with imm standard targeted messaging file name example pnlacme2025120101 txt immunization notification file name example immacme2025120101 txt file compression methods (optional) prior to transmitting them to surescripts, we recommend using standard file compression methods the supported compression protocols are gzip , bzip2 , and zip each compressed file must contain only one targeted messaging file and the compressed archive file must have the same name as the targeted messaging file it contains, appended with the corresponding compression method file extension for example, a file named pnlacme2025120101 txt , compressed using gzip would be transmitted in a file named pnlacme2025120101 txt gz transmitting files to surescripts deliver the file to surescripts using ftp and place in the /to surescripts folder or other appropriate location per the customer’s ftp setup assigning authority id usage an assigning authority id, commonly known as an oid or home community id, is a globally unique id that systems use to represent themselves as well as to recognize each other in the secure exchange of clinical information the assigning authority id is a critical component to allowing ehr systems to accurately match patients if an ehr is unable to match a message to a patient in their system, the message is most likely to be rejected for targeted messaging messages to be processed successfully into ehr systems, each customer will need to use a unique assigning authority id in the file schemas in section 6 and 7, the assigning authority id is denoted as source system id (for standard files) patient issuer id (for immunization files) surescripts strongly encourages customers to use their sending organizations’ existing oid when populating these fields if sending on behalf of downstream customers, the oid should be that of the organization who assigned the associated unique patient id if the sender does not have an oid, surescripts recommends registering for one through hl7 https //www hl7 org/oid/index cfm or another available oid registry if for some reason one cannot be obtained, work with your implementation specialist to proceed context codes in messaging this section describes context codes that are supported for standard targeted messaging files use of context codes is considered best practice to enable ehrs to more accurately route messages within their systems note in addition to the codes listed below, the codes from the hl7 fhir r4 document type codes value set http //hl7 org/fhir/r4/valueset c80 doc typecodes html may also be used context code explanation 61357 0 medication pharmaceutical (advice brief document) default for meds 52034 6 payer letter 95411 5 sars coronavirus 2 ab neut 34133 9 general communication 75468 9 medication adherence