This MedicationStatement profile is part of the set of resource profiles supported by the API Server used with the athenaPractice 12.3 and athenaFlow 9.12 products. It further describes read, search, create and update capabilities of these products.
This resource contains a record of a medication associated with a patient. This may be a medication that was once consumed, is currently consumed, or will be consumed in future. The source of this information can be a patient, a significant other, a clinician. Prior medications are often recorded during an encounter when the patient’s medical history is taken. Because this information relies on patient memory or the clinical data available for a patient, it is less precise than medication administration recordings (see MedicationAdministration).
This profile is used to define the content that will be returned by the API Server in response to requests to access MedicationStatement resources. All elements listed in the differential profile view are Supported, which means that the API Server is capable of supplying these fields from the product database when they have been populated via the product or its APIs.
The profile also defines the content that must be supplied to the API Server in response to requests to populate MedicationStatement resources. Fields which are marked as Mandatory in this profile are those that must be supplied to the API Server in content used to populate a resource.
The MedicationStatement resource is derived from the MEDICATE tables in athenaPractice and athenaFlow. Specific detail can be found in the Mappings section below.
The operations supported by this resource are listed below.
Read operations are executed as specified in the HL7 FHIR RESTful API implementation definition. To read a MedicationStatement, an application shall perform an HTTP GET, specifying the identifier of the resources being retrieved.
GET [base]/fhir/MedicationStatement/[id]{?_format=[json|xml]&_summary=[true|data]}
Parameter | Description |
---|---|
[base] | Specifies the base URL of the FHIR Server, e.g., https://cpsapisandbox.virenceaz.com:9443/demoAPIServer |
[id] | Specifies the identifier of the MedicationStatement resource to retrieve |
[_format] | Specifies the format of the output and may be xml or json. When present, the _format value overrides the value of the Accept header in the request. |
[_summary] | Filters the output to include only summary elements (_summary=true) or to omit the generated narrative (_summary=data). Note: If the generated html narrative for the resource is not going to be used by the call, using _summary=data provides slightly improved API response times. |
Response Code | Description |
---|---|
200 OK | The requested resource was found and is contained within the body of the HTTP response. |
401 Unauthorized | Authorization is required for this request, and either the Authorization header is missing or the supplied user credentials in the Authorization header are not valid or have expired. The body of the HTTP response will contain an OperationOutcome resource that indicates that Authorization is required. |
404 Not Found | The requested resource does not exist. The body of the HTTP response will contain an OperationOutcome resource that indicates that the resource could not be found. |
500 Server Error | The server may return other error codes to indicate other error conditions. The body of the HTTP response will contain an OperationOutcome resource that indicates the nature of the error. |
Search operations are executed as specified in the HL7 FHIR RESTful API implementation definition. To search for MedicationStatement resources, an application shall perform an HTTP GET, specifying the query parameters associated with the resource.
GET [base]/fhir/MedicationStatement?{search-parameters}{&_count=[max-results]&_format=[json|xml]&_summary=[true|text|data]}
Parameter | Description |
---|---|
[base] | Specifies the base URL of the FHIR Server, e.g., https://cpsapisandbox.virenceaz.com:9443/demoAPIServer |
[_count] | Specifies the maximum number of search results to return in a single query. Note: The count of results does not limit the number of additional resources returned via the _include parameter. No more than max-results MedicationStatement resources which match the search criteria will be returned. The API Server has default and maximum limits for the value that can be specified for this parameter. These limits may vary depending upon the client application vendors participation level in the AthenaHealth Partner program. Note: The API Server support the HL7 FHIR Paging capability. |
[_format] | Specifies the format of the output and may be xml or json. When present, the _format value overrides the value of the Accept header in the request. |
[_summary] | Filters the output to include only narrative elements (_summary=text), summary elements (_summary=true) or to omit the generated narrative (_summary=data). Note: If the generated html narrative for the resource is not going to be used by the call, using _summary=data provides improved API response times, especially when returning larger result sets. |
_id (token ) | The ID of the resource |
_lastUpdated (date ) | |
_lastUpdated-fromnow (quantity ) | Like _lastUpdated except expressed as a positive or negative offset from the current time in units of time , e.g. _lastUpdated-fromnow=ge7||d for more than seven days in the future or =le-2||mo for less than two months in the past. The unit must be specified. |
_security (token ) | |
_tag (token ) | |
ddid (token ) | |
effectivedate (date ) | Date when patient was taking (or not taking) the medication |
effectivedate-fromnow (quantity ) | Like effectivedate except expressed as a positive or negative offset from the current time in units of time , e.g. effectivedate-fromnow=ge7||d for more than seven days in the future or =le-2||mo for less than two months in the past. The unit must be specified. |
encounter (reference ) | |
encounter-or-historical (reference ) | |
identifier (token ) | Return statements with this external identifier |
medication (reference ) | Return administrations of this medication reference |
ndc (token ) | |
patient (reference ) | The identity of a patient to list statements for |
rxnorm (token ) | |
source (reference ) | Who the information in the statement came from |
status (token ) | Return statements that match the given status |
Response Code | Description |
---|---|
200 OK | The query was performed and any results found are contained within the body of the HTTP response. Note: The search API will return 200 OK when the query itself is successful, regardless of whether or not any matching results were found. |
401 Unauthorized | Authorization is required for this request, and either the Authorization header is missing or the supplied user credentials in the Authorization header are not valid or have expired. The body of the HTTP response will contain an OperationOutcome resource that indicates that Authorization is required. |
500 Server Error | The server may return other error codes to indicate other error conditions. The body of the HTTP response will contain an OperationOutcome resource that indicates the nature of the error. |
Create operations are executed as specified in the HL7 FHIR RESTful API implementation definition. To create a new MedicationStatement resource, an application must perform an HTTP POST, specifying the content of the resource in the body of the request.
POST [base]/fhir/MedicationStatement?{_format=[json|xml]}
Parameter | Description |
---|---|
[_format] | Specifies the format of the output and may be xml or json. When present, the _format value overrides the value of the Accept header in the request. |
Response Code | Description |
---|---|
201 Created | The resource was created at the location specified in the HTTP Location header. Note: Unsupported fields will be accepted in a request but will not be persisted to the database. Some fields may be mapped to database specific codes which closely but not perfectly match the input. See the HL7 FHIR specification for more detail on server permitted changes. |
400 Bad Request | The resource could not be parsed, or failed basic validation rules. The body of the HTTP response will contain an OperationOutcome resource that provide more detail about the reason for the failure. |
401 Unauthorized | Authorization is required for this request, and either the Authorization header is missing or the supplied user credentials in the Authorization header are not valid or have expired. The body of the HTTP response will contain an OperationOutcome resource that indicates that Authorization is required. |
422 Unprocessable Entity | The proposed resource violated server business rules. For example, a required field may be missing or a field may contain a value that is not supported by the API Server. The body of the HTTP response will contain an OperationOutcome resource that provide more detail about the reason for the failure. |
500 Server Error | The server may return other error codes to indicate other error conditions. The body of the HTTP response will contain an OperationOutcome resource that indicates the nature of the error. |
Update operations are executed as specified in the HL7 FHIR RESTful API implementation definition. To create a new MedicationStatement resource, an application must perform an HTTP PUT, specifying the content of the resource in the body of the request.
PUT [base]/fhir/MedicationStatement/[id]?{_format=[json|xml]}
Parameter | Description |
---|---|
[_format] | Specifies the format of the output and may be xml or json. When present, the _format value overrides the value of the Accept header in the request. |
Response Code | Description |
---|---|
200 OK | The resource was updated at the location specified in the HTTP Location header. Note: Unsupported fields will be accepted in a request but will not be persisted to the database. Some fields may be mapped to database specific codes which closely but not perfectly match the input. See the HL7 FHIR specification for more detail on server permitted changes. |
400 Bad Request | The resource could not be parsed, or failed basic validation rules. The body of the HTTP response will contain an OperationOutcome resource that provide more detail about the reason for the failure. |
401 Unauthorized | Authorization is required for this request, and either the Authorization header is missing or the supplied user credentials in the Authorization header are not valid or have expired. The body of the HTTP response will contain an OperationOutcome resource that indicates that Authorization is required. |
422 Unprocessable Entity | The proposed resource violated server business rules. For example, a required field may be missing or a field may contain a value that is not supported by the API Server. The body of the HTTP response will contain an OperationOutcome resource that provide more detail about the reason for the failure. |
500 Server Error | The server may return other error codes to indicate other error conditions. The body of the HTTP response will contain an OperationOutcome resource that indicates the nature of the error. |
The official URL for this profile is:
http://hl7.org/fhir/StructureDefinition/medicationstatement-profile
Record of medication being taken by a patient
Name | Flags | Card. | Type | Description & Constraints | |
---|---|---|---|---|---|
![]() ![]() | ∑ I | 0..* | MedicationStatement | Record of medication being taken by a patient mst-1: Reason not taken is only permitted if wasNotTaken is true mst-2: Reason for use is only permitted if wasNotTaken is false | |
![]() ![]() ![]() | ∑ | 0..1 | Meta | Metadata about the resource | |
![]() ![]() ![]() | ?! ∑ | 0..1 | uri | A set of rules under which this content was created | |
![]() ![]() ![]() | 0..1 | code | Language of the resource content Binding: IETF BCP-47 ![]() | ||
![]() ![]() ![]() | I | 0..1 | Narrative | Text summary of the resource, for human interpretation | |
![]() ![]() ![]() | 0..* | Resource | Contained, inline Resources | ||
![]() ![]() ![]() | 0..1 | CodeableConcept | Extension | ||
![]() ![]() ![]() ![]() | 1..1 | uri | "http://hl7.org/fhir/StructureDefinition/medicationstatement-ndc" | ||
![]() ![]() ![]() ![]() | 1..1 | CodeableConcept | Value of extension | ||
![]() ![]() ![]() | 0..1 | CodeableConcept | Extension | ||
![]() ![]() ![]() ![]() | 1..1 | uri | "http://hl7.org/fhir/StructureDefinition/medicationstatement-ddid" | ||
![]() ![]() ![]() ![]() | 1..1 | CodeableConcept | Value of extension | ||
![]() ![]() ![]() | 0..1 | CodeableConcept | Extension | ||
![]() ![]() ![]() | 0..1 | Reference (Reference) | Extension | ||
![]() ![]() ![]() ![]() | 1..1 | uri | "http://hl7.org/fhir/StructureDefinition/medicationstatement-encounter" | ||
![]() ![]() ![]() ![]() | 1..1 | Reference (Reference) | Value of extension | ||
![]() ![]() ![]() | 0..1 | string | Extension | ||
![]() ![]() ![]() ![]() | 1..1 | uri | "http://hl7.org/fhir/StructureDefinition/medicationstatement-medcategory" | ||
![]() ![]() ![]() ![]() | 1..1 | string | Value of extension | ||
![]() ![]() ![]() | ?! | 0..* | Extension | Extensions that cannot be ignored | |
![]() ![]() ![]() | ∑ | 0..* | Identifier | External identifier | |
![]() ![]() ![]() | ∑ | 1..1 | Reference (Patient ) | Who is/was taking the medication | |
![]() ![]() ![]() | ∑ | 1..1 | Reference (Practitioner ) | ||
![]() ![]() ![]() | ∑ | 0..1 | dateTime | When the statement was asserted? | |
![]() ![]() ![]() | ?! ∑ | 1..1 | code | active | completed | entered-in-error | intended Binding: MedicationStatementStatus (required ) | |
![]() ![]() ![]() | ?! ∑ | 0..1 | boolean | True if medication is/was not being taken | |
![]() ![]() ![]() | ∑ I | 0..* | CodeableConcept | True if asserting medication was not given Binding: Reason Medication Not Given Codes (example ) | |
![]() ![]() ![]() | ∑ | 0..1 | Reference (Condition ) | Binding: Condition/Problem/Diagnosis Codes (example ) | |
![]() ![]() ![]() | ∑ | 1..1 | Period | Over what period was medication consumed? | |
![]() ![]() ![]() | ∑ | 0..1 | string | Further information about the statement | |
![]() ![]() ![]() | ∑ | 0..* | Reference (Resource ) | Additional supporting information | |
![]() ![]() ![]() | ∑ | 1..1 | Reference (Medication ) | What medication was taken | |
![]() ![]() ![]() | ∑ | 0..* | BackboneElement | Details of how medication was taken | |
![]() ![]() ![]() ![]() | 0..* | Extension | Additional Content defined by implementations | ||
![]() ![]() ![]() ![]() | ?! | 0..* | Extension | Extensions that cannot be ignored | |
![]() ![]() ![]() ![]() | ∑ | 0..1 | string | Reported dosage information | |
![]() ![]() ![]() ![]() | ∑ | 0..1 | Timing | When/how often was medication taken | |
![]() ![]() ![]() ![]() | ∑ | 0..1 | boolean , CodeableConcept | Take "as needed" (for x) Binding: (unbound) (example ) | |
![]() ![]() ![]() ![]() | ∑ | 0..1 | CodeableConcept , Reference (BodySite ) | Where (on body) medication is/was administered Binding: SNOMED CT Anatomical Structure for Administration Site Codes (example ) | |
![]() ![]() ![]() ![]() | ∑ | 0..1 | CodeableConcept | How the medication entered the body Binding: SNOMED CT Route Codes (example ) | |
![]() ![]() ![]() ![]() | ∑ | 0..1 | CodeableConcept | Technique used to administer medication Binding: (unbound) (example ) | |
![]() ![]() ![]() ![]() | ∑ I | 0..1 | SimpleQuantity | Amount administered in one dose qty-3: If a code for the unit is present, the system SHALL also be present sqty-1: The comparator is not used on a SimpleQuantity | |
![]() ![]() ![]() ![]() | ∑ | 0..1 | Ratio , Range | Dose quantity per unit of time | |
![]() ![]() ![]() ![]() | ∑ | 0..1 | Ratio | Maximum dose that was consumed per unit of time | |
The mappings in this section represent the how data stored within athenaPractice is served through the product's APIs.
athenaPractice and athenaFlow share a common schema for patient clinical data and only one is shown when these are
the same. Use of this information is subject to the API Server
Terms and Conditions .
MedicationStatement Profile | ||
MedicationStatement | MedicationStatement-Profile | FHIR_MEDICATEVIEW |
├ id | %MEDICATEGROUPID% | |
├ extension | ndc | |
├ extension | ddid | |
├ extension | rxnorm | MakeRxnormExtensionList(%RXNORM%,"http://www.nlm.nih.gov/research/umls/rxnorm",null) |
├ extension | encounter | |
├ extension | medcategory | |
├ identifier | EXTMEDICATEID | MakeIdentifier("U",getSiteIdSystem("ExtMedication"),%EXTMEDICATEID%) |
├ patient | PID | MakeReference("PATIENT",%PID%,"Patient") |
├ informationSource | USRID | MakeReference("USR",%USRID%,"Practitioner") |
├ dateAsserted | DB_CREATE_DATE | %DB_CREATE_DATE% |
├ status | STOPREASON | IsActiveOrMapCode(%STOPDATE%,"active",%STOPREASON%,"MEDSTOPREASON") |
├ wasNotTaken | ANNOTATE | %STOPREASON% |
├ reasonNotTaken | MakeTextConcept(%ANNOTATE%) | |
├ reasonForUseReference | PROBID | MakeReference("PRESCRIB",%PROBID%,"Condition") |
├ effectivePeriod | STARTDATE and STOPDATE | MakePeriod(%STARTDATE%,%STOPDATE%) |
├ note | COMMENTS | %COMMENTS% |
├ supportingInformation | PTID | MakeReferenceList("PRESCRIB",%PTID%,"MedicationOrder") |
└ medicationReference | DDID | MakeReference("MEDINFO",%DDID%,"Medication",%DESCRIPTION%) |
├ text | INSTRUCTIONS | %INSTRUCTIONS% |
├ timing | TIMING | MakeTiming(%PERIOD%,%PERIOD_UNIT%) |
├ route | ROUTE | MapConcept(%ROUTE%,"MEDICATIONROUTE") |
└ quantityQuantity | DOSE and DOSE_UNIT | MakeNonZeroQuantity(%DOSE%,%DOSE_UNIT%) |
The mappings in this section represent the how data stored within athenaFlow is served through the product's APIs.
Use of this information is subject to the API Server
Terms and Conditions .
MedicationStatement Profile | ||
MedicationStatement | MedicationStatement-Profile | FHIR_MEDICATEVIEW |
├ id | %MEDICATEGROUPID% | |
├ extension | ndc | |
├ extension | ddid | |
├ extension | rxnorm | MakeRxnormExtensionList(%RXNORM%,"http://www.nlm.nih.gov/research/umls/rxnorm",null) |
├ extension | encounter | |
├ extension | medcategory | |
├ identifier | EXTMEDICATEID | MakeIdentifier("U",getSiteIdSystem("ExtMedication"),%EXTMEDICATEID%) |
├ patient | PID | MakeReference("PATIENT",%PID%,"Patient") |
├ informationSource | USRID | MakeReference("USR",%USRID%,"Practitioner") |
├ dateAsserted | DB_CREATE_DATE | %DB_CREATE_DATE% |
├ status | STOPREASON | IsActiveOrMapCode(%STOPDATE%,"active",%STOPREASON%,"MEDSTOPREASON") |
├ wasNotTaken | ANNOTATE | %STOPREASON% |
├ reasonNotTaken | MakeTextConcept(%ANNOTATE%) | |
├ reasonForUseReference | PROBID | MakeReference("PRESCRIB",%PROBID%,"Condition") |
├ effectivePeriod | STARTDATE and STOPDATE | MakePeriod(%STARTDATE%,%STOPDATE%) |
├ note | COMMENTS | %COMMENTS% |
├ supportingInformation | PTID | MakeReferenceList("PRESCRIB",%PTID%,"MedicationOrder") |
└ medicationReference | DDID | MakeReference("MEDINFO",%DDID%,"Medication",%DESCRIPTION%) |
├ text | INSTRUCTIONS | %INSTRUCTIONS% |
├ timing | TIMING | MakeTiming(%PERIOD%,%PERIOD_UNIT%) |
├ route | ROUTE | MapConcept(%ROUTE%,"MEDICATIONROUTE") |
└ quantityQuantity | DOSE and DOSE_UNIT | MakeNonZeroQuantity(%DOSE%,%DOSE_UNIT%) |