Flexpa
Developer PortalFeedbackContact usOnboard

Guides

  • Home
  • Quickstart
  • Financial Data

Network

  • Network guide
  • Directory
  • Updates

Consent

  • Link SDK
  • Patient access

Records

  • FHIR API
  • Node SDK
  • FHIR Introduction
  • Usage
  • Terminology
    • AllergyIntolerance
    • Bundle
    • CarePlan
    • CareTeam
    • Condition
    • Coverage
    • Device
    • DiagnosticReport
    • DocumentReference
    • Encounter
    • ExplanationOfBenefit
    • Goal
    • Immunization
    • Location
    • Medication
    • MedicationDispense
    • MedicationRequest
    • Observation
    • OperationOutcome
    • Organization
    • Patient
    • Practitioner
    • PractitionerRole
    • Procedure
    • Provenance

Misc

  • Changelog
  • Support
  • Flexpa OS
  • We're hiring

MedicationRequest

GET https://api.flexpa.com/fhir/MedicationRequest

  • MedicationRequest is a base FHIR Resource ( JSON example)
  • Commonly available via US Core MedicationRequest Profile

MedicationRequest is a FHIR Resource that describes an order or request for both supply of the medication and the instructions for administration of the medication to a patient.

Accessing a patient's medications can aid in workflows such as:

  • Working with the patient to ensure adherence to the medication protocol
  • Understanding a patient’s current medications to prevent drug-to-drug interactions
  • Advising the patient switch to generic medications to reduce overall out-of-pocket cost

Many payers make this available in a basic form derived from a patient's claims, but some also provide a more detailed view of the patient's medication requests if they have a more robust provider-payer clinical data exchange, such as quality measures.

#Search parameters

The full list of search parameters can be found here. Some of the most important are:

Parameters

patientstring

The ID of the patient for whom the medication was requested. We recommend using this search parameter along with the $PATIENT_ID wildcard

statusstring

The status of the medication request.

codestring

The code of the medication that was requested. This is typically an NDC or RxNorm code.

#Sample request

While some servers may support a resource-level search without any parameters, not all do. We recommend using the format below with the patient ID via the $PATIENT_ID wildcard as a search parameter.

This is a sample request using curl

ACCESS_TOKEN=flexpa-link-access-token

curl "https://api.flexpa.com/fhir/MedicationRequest?patient=$PATIENT_ID" \
  -H "Authorization: Bearer $ACCESS_TOKEN"

#Sample response

This is a sample response from Humana using Flexpa API in test mode

#Notable Fields

A MedicationRequest response contains many fields. You can get an exhaustive list and explanation of each field here. Some notable fields:

  • entry - A collection of MedicationRequests (see response type on best practice of checking resourceType)
  • meta.lastUpdated - An ISO8601 string representing the last time the bundle was modified
  • entry[i].resource.status - A string representing the status of the MedicationRequest, including: active, on-hold, stopped, and completed. Medications currently prescribed have status: 'active'.
  • entry[i].resource.medicationCodeableConcept - A coded representation of the medication that the patient was prescribed. Typically this is an NDC and textual name for the medication.
  • entry[i].resource.authoredOn - The date when the medication was prescribed to the patient
  • entry[i].resource.dosageInstruction - Information about how the medication should be taken
Status TwitterGitHub

© 2025 Flexpa. All rights reserved.

On this page
  • Search parameters
  • Sample request
  • Sample response
  • Notable Fields