Get Medical Record Summary
curl --request GET \
--url https://api.sandbox.metriport.com/patient/:id/medical-record \
--header 'x-api-key: <api-key>'import requests
url = "https://api.sandbox.metriport.com/patient/:id/medical-record"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.sandbox.metriport.com/patient/:id/medical-record', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.metriport.com/patient/:id/medical-record",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.metriport.com/patient/:id/medical-record"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.sandbox.metriport.com/patient/:id/medical-record")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.metriport.com/patient/:id/medical-record")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_bodyimport { MetriportMedicalApi } from "@metriport/api-sdk";
const metriport = new MetriportMedicalApi("YOUR_API_KEY");
const metriportPatientId = "018a80c4-292a-7486-a223-6dcbc636c44c";
const url = await metriport.getMedicalRecordSummary(
metriportPatientId,
"pdf"
);
FHIR
Get Medical Record Summary
Get the Medical Record Summary in PDF or HTML formats.
Listen to this pageabout 1 min
GET
/
patient
/
:id
/
medical-record
Get Medical Record Summary
curl --request GET \
--url https://api.sandbox.metriport.com/patient/:id/medical-record \
--header 'x-api-key: <api-key>'import requests
url = "https://api.sandbox.metriport.com/patient/:id/medical-record"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.sandbox.metriport.com/patient/:id/medical-record', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.metriport.com/patient/:id/medical-record",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.metriport.com/patient/:id/medical-record"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.sandbox.metriport.com/patient/:id/medical-record")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.metriport.com/patient/:id/medical-record")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_bodyimport { MetriportMedicalApi } from "@metriport/api-sdk";
const metriport = new MetriportMedicalApi("YOUR_API_KEY");
const metriportPatientId = "018a80c4-292a-7486-a223-6dcbc636c44c";
const url = await metriport.getMedicalRecordSummary(
metriportPatientId,
"pdf"
);
This endpoint returns the URL to download the patient’s Medical Record Summary in the PDF or HTML format, if it exists.
To create a Medical Record Summary, you need to use the Start Consolidated Data Query.
The URL will only be valid for 600 seconds (10 minutes) before you need to request a new one.
Path Params
Query Params
The doc type to convert to. Either
html or pdf.This parameter is to indicate how the medical record should be rendered.
Response
If the Medical Record Summary exists, it will return a JSON object containing the downloadable URL. Otherwise, will throw a NotFoundError.import { MetriportMedicalApi } from "@metriport/api-sdk";
const metriport = new MetriportMedicalApi("YOUR_API_KEY");
const metriportPatientId = "018a80c4-292a-7486-a223-6dcbc636c44c";
const url = await metriport.getMedicalRecordSummary(
metriportPatientId,
"pdf"
);

