Message Element Detail Tables
Requirement Designation
Element Attributes
Code | Description |
|---|---|
mandatory | The element must be used per the specification (e.g., XML schema validation). Note: The term mandatory applies to mandatory and required fields in the different standards. For example, NCPDP uses the term mandatory, while FHIR uses the term required. |
conditional | The element must be used per the conditions specified. Note: The term conditional applies to conditional and situational fields in the different standards. For example, NCPDP uses the term conditional, while X12 uses the term situational. |
business rule | If sent, the element must be used per the Surescripts business rule. |
Note: This guide includes data elements only where Surescripts has specific requirements or further explains the field usage. Refer to the schema for a complete list of fields.
Message Header Elements
Element | Code | Comments |
|---|---|---|
To | mandatory | This field contains the identification of the receiver. This field is used in conjunction with To/@Qualifier, which qualifies which ID was used. Response messages will contain the Panel user Participant or customer ID assigned by Surescripts. |
@Qualifier | conditional | business rule If the To field is sent, then the Qualifier must also be sent. Value: ZZZ = Mutually Defined |
From | mandatory | This field is used in conjunction with From/@Qualifier, which qualifies which ID was used. Response messages will contain S00000000000003. |
@Qualifier | conditional | business rule If the From field is sent, then the Qualifier must also be sent. Value: ZZZ = Mutually defined |
MessageID | mandatory | Unique MessageID, reference for support to lookup medication history transaction. |
RelatesToMessageID | conditional | References for support to lookup for medication history transaction. |
SentTime | mandatory | Date and time the medication history message was sent. Please see UTC Time FormatUTC Time Format section. |
TestMessage | conditional | Staging or Production platform Indicator Values:
|
RxHistoryResponse Message Body Elements
Element | Code | Comments |
|---|---|---|
Response | mandatory | |
Approved | mandatory | |
ApprovalReasonCode | conditional | When AQ (More History Available) is present in the ApprovalReasonCode, a second Panel RxHistoryResponse will be sent from Surescripts to the customer for the same patient. |
Note | conditional | Refer to the RxHistoryResponse Note DescriptionsRxHistoryResponse Note Descriptions table for details. |
Prescriber | conditional | |
Identification | conditional | |
NPI | mandatory | The NPI for organization or individual prescriber provided in the file load from Panel user. NPI provided will be validated against the National Provider Identification file and mapped to the outgoing medication history request to Panel data supplier. https://nppes.cms.hhs.gov/#/ |
Name | conditional | |
LastName | conditional | LastName (organization name or prescriber last name) |
Patient | mandatory | |
Identification | conditional | |
MutuallyDefined | mandatory | business rule The Patient ID provided in the Patient Load File will be populated in the MutuallyDefined identification field. |
Name | conditional | Includes the patient demographics provided in File load by Panel user. |
LastName | conditional | Patient last name |
FirstName | conditional | Patient first name |
Gender | conditional | Patient Gender |
DateOfBirth | conditional | Patient DOB |
Address | conditional | |
Zipcode | conditional | Patient zip code |
BenefitsCoordination | mandatory | |
EffectiveDate | mandatory | EffectiveDate is the beginning date for the desired history (up to one year ago from requested date). Example: Effective Date 2019-02-06 |
ExpirationDate | mandatory | ExpirationDate is the end date for the desired history. This is set to the date the medication history was initiated for the initial request. If the "AQ" indicator was in the ApprovalReasonCode of the first response message, this would be set to the last drug's LastFillDate. Examples: Message 1 with 300 medication dispensed records and AQ indicator. ExpirationDate set to requested date 2019-02-06 LastFillDate of the last drug in Message 1 is 2019-04-03 Message 2 with remaining medication dispensed records. Expiration Date of second response is 2019-04-03, set to LastFillDate of last drug of Message 1. |
Consent | conditional | Patient Consent Indicator Values: Y |
MedicationDispensed | mandatory | See section below for details. |
MedicationDispensed Elements
Zero to 300 loops of the drugs in the patient’s history. If there are more than 300 drugs in the patient’s history, a second RxHistoryResponse will be included in the Panel History File. The most recent drug according to date filled is shown first.
Element | Code | Comments |
|---|---|---|
MedicationDispensed | mandatory | Dispensed Medication within the RxHistoryResponse message. |
DrugDescription | mandatory | Drug name. The item or drug description field should include the standardized drug name including strength and form from a Surescripts approved drug compendia. Example: fentanyl 25 mcg/hr transdermal patch |
DrugCoded | conditional | |
ProductCode | conditional | ProductCode is the 11 digit NDC Note: When this is all 9s for the NDC and this is for fill data, this means that the prescription is a compound. |
ProductCodeQualifier | conditional | ProductCodeQualifier value is ND, indicating it is NDC11 |
Strength | conditional | Strength indicates the measurement value |
DEASchedule | conditional | DEASchedule is populated by the system generating the message, and would utilize the Federal DEA Schedule classification code list, based on federal classification of the medication or the state reclassification of the medication. For a complete list of values, see the NCPDP External Code List (7996). Example: C48675 |
Quantity | conditional | Use the NCPDP QuantityUnitOfMeasure Terminology rows from the downloaded data. For a list of codes, go to: |
Value | mandatory | Example: 10 |
CodeListQualifier | mandatory | Values: 87 = Quantity Received |
UnitSourceCode | mandatory | AC = Potency Unit |
PotencyUnitCode | mandatory | Use the NCPDP QuantityUnitOfMeasure Terminology rows from the downloaded data. For a list of codes, go to: Example: C48524 |
DaysSupply | conditional | Example: 30 |
Directions | conditional | SIG instructions |
Refills | conditional | |
Qualifier | mandatory | Qualifier REM = Remaining number of Refills |
Value | conditional | Example: 0 |
Substitutions | conditional | Example: 0 |
WrittenDate | conditional | |
Date | mandatory | Example: 2019-04-14 |
LastFillDate | mandatory | |
Date | mandatory | Example: 2020-02-05 |
SoldDate | conditional | |
Date | mandatory | Example: 2020-01-30 |
Pharmacy | conditional | Dispensing pharmacy segment including the details of identification, name, address and communication numbers. Refer to the File ExamplesFile Examples to view how element values could appear. |
Identification | conditional |
|
NCPDPID | mandatory |
|
StoreName | conditional |
|
Address | conditional |
|
AddressLine1 | conditional |
|
City | conditional |
|
State | conditional |
|
Zipcode | conditional |
|
CommunicationNumbers | conditional |
|
Communication | mandatory |
|
Number | mandatory |
|
Qualifier | mandatory | |
Prescriber | conditional | Prescribing physician segment including the details of identification, name, address and communication numbers. Refer to the File ExamplesFile Examples to view how element values could appear. |
Identification | conditional |
|
NPI | mandatory |
|
DEANumber | mandatory |
|
Name | conditional |
|
LastName | conditional |
|
FirstName | conditional |
|
MiddleName | conditional |
|
Address | conditional |
|
AddressLine1 | conditional |
|
City | conditional |
|
State | conditional |
|
ZipCode | conditional |
|
CommunicationNumbers | conditional |
|
Communication | mandatory |
|
Number | mandatory |
|
Qualifier | mandatory |
|
HistorySource | conditional | This is the source and fill number information for the medication listed. |
Source | conditional | |
SourceQualifier | mandatory | SourceQualifier Qualifies the Source Description.
|
SourceDescription | conditional | SourceDescription is the name of medication history source. Pharmacy or Payer/PBM Name. |
Reference | conditional | |
IDValue | mandatory | |
IDQualifier | mandatory |
|
SourceReference | conditional | Prescription Number associated to medication history record. If the submitter chooses to send this field and SourceQualifier is “P2”, then it should be populated with the pharmacy prescription number. If the submitter chooses to send this field and SourceQualifier is “PY”, then it should be populated with prescription number from PBM/payer system from claims processing. |
FillNumber | conditional | Defines the dispensing episode as an initial fill or an authorized refill. If this field is sent for fill data, it will contain the fill number from the pharmacy. If this field is sent for claim data, it will contain pharmacy’s fill number from the PBM/payer system from claims processing. Values:
|