medicationStatementGet
Get a MedicationStatement resource based on the resource ID, or search by ID, patient ID, or status.
/MedicationStatement/
Usage and SDK Samples
curl -X GET\
-H "Accept: application/json,application/xml"\
"//MedicationStatement/?_id=&patient=&status=&effective=&category=&source=&patient.identifer="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.MedicationStatementApi;
import java.io.File;
import java.util.*;
public class MedicationStatementApiExample {
public static void main(String[] args) {
MedicationStatementApi apiInstance = new MedicationStatementApi();
Integer id = 56; // Integer | Resource identifier.
String patient = patient_example; // String | Reference.
String status = status_example; // String | Return statements that match the given status.
date effective = ; // date | Date when patient was taking (or not taking) the medication.
String category = category_example; // String | Returns statements of this category of MedicationStatement.
String source = source_example; // String | Who or where the information in the statement came from.
String patient.identifer = patient.identifer_example; // String | Patient ID.
try {
MedicationStatement result = apiInstance.medicationStatementGet(id, patient, status, effective, category, source, patient.identifer);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling MedicationStatementApi#medicationStatementGet");
e.printStackTrace();
}
}
}
import io.swagger.client.api.MedicationStatementApi;
public class MedicationStatementApiExample {
public static void main(String[] args) {
MedicationStatementApi apiInstance = new MedicationStatementApi();
Integer id = 56; // Integer | Resource identifier.
String patient = patient_example; // String | Reference.
String status = status_example; // String | Return statements that match the given status.
date effective = ; // date | Date when patient was taking (or not taking) the medication.
String category = category_example; // String | Returns statements of this category of MedicationStatement.
String source = source_example; // String | Who or where the information in the statement came from.
String patient.identifer = patient.identifer_example; // String | Patient ID.
try {
MedicationStatement result = apiInstance.medicationStatementGet(id, patient, status, effective, category, source, patient.identifer);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling MedicationStatementApi#medicationStatementGet");
e.printStackTrace();
}
}
}
Integer *id = 56; // Resource identifier. (optional)
String *patient = patient_example; // Reference. (optional)
String *status = status_example; // Return statements that match the given status. (optional)
date *effective = ; // Date when patient was taking (or not taking) the medication. (optional)
String *category = category_example; // Returns statements of this category of MedicationStatement. (optional)
String *source = source_example; // Who or where the information in the statement came from. (optional)
String *patient.identifer = patient.identifer_example; // Patient ID. (optional)
MedicationStatementApi *apiInstance = [[MedicationStatementApi alloc] init];
[apiInstance medicationStatementGetWith:id
patient:patient
status:status
effective:effective
category:category
source:source
patient.identifer:patient.identifer
completionHandler: ^(MedicationStatement output, NSError* error) {
if (output) {
NSLog(@"%@", output);
}
if (error) {
NSLog(@"Error: %@", error);
}
}];
var MedicationStatement = require('medication_statement');
var api = new MedicationStatement.MedicationStatementApi()
var opts = {
'id': 56, // {{Integer}} Resource identifier.
'patient': patient_example, // {{String}} Reference.
'status': status_example, // {{String}} Return statements that match the given status.
'effective': , // {{date}} Date when patient was taking (or not taking) the medication.
'category': category_example, // {{String}} Returns statements of this category of MedicationStatement.
'source': source_example, // {{String}} Who or where the information in the statement came from.
'patient.identifer': patient.identifer_example // {{String}} Patient ID.
};
var callback = function(error, data, response) {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
};
api.medicationStatementGet(opts, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;
namespace Example
{
public class medicationStatementGetExample
{
public void main()
{
var apiInstance = new MedicationStatementApi();
var id = 56; // Integer | Resource identifier. (optional)
var patient = patient_example; // String | Reference. (optional)
var status = status_example; // String | Return statements that match the given status. (optional)
var effective = new date(); // date | Date when patient was taking (or not taking) the medication. (optional)
var category = category_example; // String | Returns statements of this category of MedicationStatement. (optional)
var source = source_example; // String | Who or where the information in the statement came from. (optional)
var patient.identifer = patient.identifer_example; // String | Patient ID. (optional)
try
{
MedicationStatement result = apiInstance.medicationStatementGet(id, patient, status, effective, category, source, patient.identifer);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling MedicationStatementApi.medicationStatementGet: " + e.Message );
}
}
}
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$api_instance = new Swagger\Client\ApiMedicationStatementApi();
$id = 56; // Integer | Resource identifier.
$patient = patient_example; // String | Reference.
$status = status_example; // String | Return statements that match the given status.
$effective = ; // date | Date when patient was taking (or not taking) the medication.
$category = category_example; // String | Returns statements of this category of MedicationStatement.
$source = source_example; // String | Who or where the information in the statement came from.
$patient.identifer = patient.identifer_example; // String | Patient ID.
try {
$result = $api_instance->medicationStatementGet($id, $patient, $status, $effective, $category, $source, $patient.identifer);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling MedicationStatementApi->medicationStatementGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::MedicationStatementApi;
my $api_instance = WWW::SwaggerClient::MedicationStatementApi->new();
my $id = 56; # Integer | Resource identifier.
my $patient = patient_example; # String | Reference.
my $status = status_example; # String | Return statements that match the given status.
my $effective = ; # date | Date when patient was taking (or not taking) the medication.
my $category = category_example; # String | Returns statements of this category of MedicationStatement.
my $source = source_example; # String | Who or where the information in the statement came from.
my $patient.identifer = patient.identifer_example; # String | Patient ID.
eval {
my $result = $api_instance->medicationStatementGet(id => $id, patient => $patient, status => $status, effective => $effective, category => $category, source => $source, patient.identifer => $patient.identifer);
print Dumper($result);
};
if ($@) {
warn "Exception when calling MedicationStatementApi->medicationStatementGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint
# create an instance of the API class
api_instance = swagger_client.MedicationStatementApi()
id = 56 # Integer | Resource identifier. (optional)
patient = patient_example # String | Reference. (optional)
status = status_example # String | Return statements that match the given status. (optional)
effective = # date | Date when patient was taking (or not taking) the medication. (optional)
category = category_example # String | Returns statements of this category of MedicationStatement. (optional)
source = source_example # String | Who or where the information in the statement came from. (optional)
patient.identifer = patient.identifer_example # String | Patient ID. (optional)
try:
api_response = api_instance.medication_statement_get(id=id, patient=patient, status=status, effective=effective, category=category, source=source, patient.identifer=patient.identifer)
pprint(api_response)
except ApiException as e:
print("Exception when calling MedicationStatementApi->medicationStatementGet: %s\n" % e)
Parameters
| Name | Description |
|---|---|
| _id |
Integer
Resource identifier.
|
| patient |
String
Reference.
|
| status |
String
Return statements that match the given status.
|
| effective |
date
Date when patient was taking (or not taking) the medication.
|
| category |
String
Returns statements of this category of MedicationStatement.
|
| source |
String
Who or where the information in the statement came from.
|
| patient.identifer |
String
Patient ID.
|