---
schema_version: "1"
id: 68da06f86cc8794f51a86b766900294c5538951fce2bdbc2357bff0260dbd327
title: Medication
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/industries-integrations/health/references/generated-api-specs/medication.md
canonical_url: https://developer.salesforce.com/docs/industries/health/references/medication
source_site: developer.salesforce.com
content_type: documentation
content_hash: f794dac096e63f8b1fec73c207204bc68fe8a26f2911bce426c21f4631aa3ec3
products:
  - Salesforce Healthcare API
  - Industries Integrations
---
Medication

# Medication

Use the Medication REST APIs to fetch the medication records from the Salesforce Health Cloud. The data exchange is compliant with the FHIR business APIs enabling you to interpret the medication requests for a patient. The Medication resource defines how a medication is prescribed, dispensed, and administered while also recording statements of its usage. The Medication FHIR resource maps to the ​Medication object in Salesforce​.

**Version:** v1

Protocols: https.

## Operations

### POST Create a medication

`POST /Medication`

Creates a resource using the create interaction from the FHIR resources.

#### Parameters

*   `X-CORRELATION-ID` (header, string)
*   `Accept` (header, string)  
    Allowed values: `application/fhir+json`.

#### Request body

Media type: `application/fhir+json`. Schema: `Medication`.

_Example_

```
{
    "resourceType": "Medication",
    "identifier": [
        {
            "use": "usual",
            "system": "urn:custom:sourcesystem:fhirid",
            "value": "medi2345"
        },
        {
            "value": "12345",
            "system": "http://medication.identifier",
            "type": {
                "coding": [
                    {
                        "system": "http://identifier11b",
                        "version": "1.0",
                        "code": "identifier11b",
                        "display": "medication identifier codeset 1"
                    },
                    {
                        "system": "http://medication.identifier11b",
                        "version": "1.0",
                        "code": "identifier11b",
                        "display": "medication identifier 2"
                    }
                ],
                "text": "Identifier Bundle"
            }
        }
    ],
    "meta": {
        "profile": [
            "http://hl7.org/fhir/us/core/StructureDefinition/us-core-medication"
        ]
    },
    "code": {
        "coding": [
            {
                "system": "http://snomed.info/sct",
                "version": "1.0",
                "code": "3852192344",
                "display": "Injection solution (qualifier value)"
            },
            {
                "system": "http://www.nlm.nih.gov/research/umls/rxnorm1",
                "version": "1.0",
                "code": "10734335",
                "display": "Triamcinolone Oral Paste"
            }
        ],
        "text": "Medication Code 2345"
    },
    "status": "active",
    "manufacturer": {
        "reference": "Organization/001B000001Pjme9IAB"
    },
    "form": {
        "coding": [
            {
                "system": "http://snomed.info/sct",
                "code": "3852191334",
                "display": "Injection solution (qualifier value)"
            }
        ],
        "text": "Medication Form 2345"
    },
    "amount": {
        "numerator": {
            "value": 50.0,
            "unit": "inch"
        },
        "denominator": {
            "value": 12.0,
            "unit": "inch"
        }
    }
}
```

#### Responses

*   **201** No match was found. Resource created.
    
    Headers:
    
    *   `Location` (string, required) Specifies the URL where the resource can be fetched in subsequent requests.  
        Example: `http://xxx/Medication/123`.
    
    Media type: `application/fhir+json`. Schema: `Medication (extended)`.
    
    Includes all fields of `Medication`.
    
    *   `id` (_string_, required) Specifies the Salesforce ID of the created object.  
        Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
    
    _Example_
    
    ```
    {
        "resourceType": "Medication",
        "id": "0itB0000000PDqrIAG",
        "identifier": [
            {
                "use": "usual",
                "value": "medi2345",
                "system": "urn:custom:sourcesystem:fhirid"
            },
            {
                "value": "12345",
                "system": "http://medication.identifier",
                "type": {
                    "coding": [
                        {
                            "system": "http://identifier11b",
                            "version": "1.0",
                            "code": "identifier11b",
                            "display": "medication identifier codeset 1"
                        },
                        {
                            "system": "http://medication.identifier11b",
                            "version": "1.0",
                            "code": "identifier11b",
                            "display": "medication identifier 2"
                        }
                    ],
                    "text": "Identifier Bundle1"
                }
            }
        ],
        "meta": {
            "profile": [
                "http://hl7.org/fhir/us/core/StructureDefinition/us-core-medication"
            ]
        },
        "code": {
            "coding": [
                {
                    "system": "http://snomed.info/sct",
                    "version": "1.0",
                    "code": "3852192344",
                    "display": "Injection solution (qualifier value)"
                },
                {
                    "system": "http://www.nlm.nih.gov/research/umls/rxnorm1",
                    "version": "1.0",
                    "code": "10734335",
                    "display": "Triamcinolone Oral Paste"
                }
            ],
            "text": "Medication Code 2345"
        },
        "status": "active",
        "manufacturer": {
            "reference": "Organization/001B000001Pjme9IAB"
        },
        "form": {
            "coding": [
                {
                    "system": "http://snomed.info/sct",
                    "code": "3852191334",
                    "display": "Injection solution (qualifier value)"
                }
            ],
            "text": "Medication Form 2345"
        },
        "amount": {
            "numerator": {
                "value": 50.0,
                "unit": "inch"
            },
            "denominator": {
                "value": 12.0,
                "unit": "inch"
            }
        }
    }
    ```
    
*   **400** Resource either can’t be parsed or failed basic FHIR validation rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example_
    
    ```
    {
      "resourceType": "OperationOutcome",
      "id": "validationfail",
      "issue": [
        {
          "severity": "fatal",
          "code": "invalid",
          "details": {
            "text": "Error parsing resource JSON (Unknown Content \"label\""
          }
        }
      ]
    }
    ```
    
*   **404** Resource type not supported.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **405** Server denied the request.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **422** The proposed resource violated applicable FHIR profiles or server business rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

### GET Get a medication

`GET /Medication/{id}`

Retrieves the details for a particular object using the ID. This operation is performed using the read interaction from the FHIR resources.

#### Parameters

*   `id` (path, id, required)
*   `X-CORRELATION-ID` (header, string)

#### Responses

*   **200** The request was successful.
    
    Media type: `application/fhir+json`. Schema: `MedicationPut`.
    
    _Example: same as POST /Medication 201 response._
    
*   **404** Search ID not found.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **410** Target resource is no longer available.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

### PUT Update a medication

`PUT /Medication/{id}`

Creates a new current version of an existing resource or creates an initial version if no resource already exists for the given ID. This operation is performed using the update interaction from the FHIR resources.

#### Parameters

*   `id` (path, id, required)
*   `X-CORRELATION-ID` (header, string)
*   `Accept` (header, string)  
    Allowed values: `application/fhir+json`.

#### Request body

Media type: `application/fhir+json`. Schema: `MedicationPut`.

_Example_

```
{
  "resourceType": "Medication",
  "id": "med0310",
  "contained": [
    {
      "resourceType": "Substance",
      "id": "sub03",
      "code": {
        "coding": [
          {
            "system": "http://snomed.info/sct",
            "code": "55452001",
            "display": "Oxycodone (substance)"
          }
        ]
      }
    }
  ],
  "code": {
    "coding": [
      {
        "system": "http://snomed.info/sct",
        "code": "430127000",
        "display": "Oral Form Oxycodone (product)"
      }
    ]
  },
  "form": {
    "coding": [
      {
        "system": "http://snomed.info/sct",
        "code": "385055001",
        "display": "Tablet dose form (qualifier value)"
      }
    ]
  },
  "manufacturer": {
        "reference": "Organization/001B000001Pjme9IAB"
    },
  "amount": {
      "numerator": {
          "value": 50.0,
          "unit": "inch"
      },
      "denominator": {
          "value": 12.0,
          "unit": "inch"
      }
  }
}
```

#### Responses

*   **200** Updated the resource.
    
    Headers:
    
    *   `Location` (string, required) Specifies the URL where the resource can be fetched in subsequent requests.  
        Example: `http://xxx/Medication/123`.
    
    Media type: `application/fhir+json`. Schema: `MedicationPut (extended)`.
    
    Includes all fields of `MedicationPut`.
    
    *   `id` (_string_, required) Specifies the Salesforce ID of the updated or created object.  
        Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
    
    _Example: same as POST /Medication 201 response._
    
*   **201** Created.
    
    Headers:
    
    *   `Location` (string, required) Specifies the URL where the resource can be fetched in subsequent requests.  
        Example: `http://xxx/Medication/123`.
    
    Media type: `application/fhir+json`. Schema: `MedicationPut (extended)`.
    
    Includes all fields of `MedicationPut`.
    
    *   `id` (_string_, required) Specifies the Salesforce ID of the updated or created object.  
        Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
    
    _Example: same as POST /Medication 201 response._
    
*   **400** Resource either can’t be parsed or failed basic FHIR validation rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **401** Authorization is required for the interaction that was attempted.
    
    Media type: `application/json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **404** Resource type not supported.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **405** Server denied the request.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **422** The proposed resource violated applicable FHIR profiles or server business rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

### GET Get immunizations

`GET /Immunization`

Retrieves a set of resources by using filters.

#### Parameters

*   `patient` (query, string, required) The patient for the vaccination record.
*   `X-CORRELATION-ID` (header, string)
*   `Accept` (header, string)  
    Allowed values: `*/*`, `application/fhir+json`.

#### Responses

*   **200**
    
    Media type: `application/fhir+json`. Schema: `ImmunizationBundle`.
    
    _Example_
    
    ```
    {
        "resourceType": "Bundle",
        "id": "ff9741e5-3319-4d6c-8b23-47d91e1613a7",
        "meta": {
            "lastUpdated": "2023-04-04T16:28:08.49+05:30"
        },
        "type": "searchset",
        "total": 1,
        "link": [
            {
                "relation": "self",
                "url": "https://localhost:8092/clinical-medications/fhir-r4/v1/Immunization?patient=001RO000004RD5RYAW"
            }
        ],
        "entry": [
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/Immunization/0jKRO000000042R2AQ",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "Immunization",
                    "id": "0jKRO000000042R2AQ",
                    "identifier": [
                        {
                            "use": "usual",
                            "type": {
                                "coding": [
                                    {
                                        "system": "urn:ietf:rfc:4567",
                                        "version": "1.0",
                                        "code": "urn:oid:1.3.6.1.4.1.21367.2006.3.7.4567",
                                        "display": "Vaccine Identifier 1234"
                                    }
                                ],
                                "text": "Identifier Type Bundle"
                            },
                            "system": "urn:custom:sourcesystem:fhirid",
                            "value": "9002"
                        }
                    ],
                    "meta": {
                        "profile": [
                            "http://hl7.org/fhir/us/core/StructureDefinition/us-core-immunization"
                        ]
                    },
                    "status": "not-done",
                    "statusReason": {
                        "coding": [
                            {
                                "system": "http://snomed.info/sct",
                                "version": "1.0",
                                "code": "11840006",
                                "display": "Traveller's Diarrhea (disorder)"
                            },
                            {
                                "system": "http://hl7.org/fhir/sid/ndc",
                                "version": "1.0",
                                "code": "76388-713-25",
                                "display": "Myleran 2mg tablet, film coated"
                            }
                        ],
                        "text": "MedReqReasonBundle"
                    },
                    "vaccineCode": {
                        "coding": [
                            {
                                "system": "urn:oid:1.2.36.1.2001.1005.17",
                                "code": "FLUVAXYZ",
                                "display": "vaccineCode-FLUVAX"
                            }
                        ],
                        "text": "VaccineCode Bundle"
                    },
                    "patient": {
                        "reference": "Patient/001RO000004RD5RYAW"
                    },
                    "encounter": {
                        "reference": "Encounter/0kGRO00000001Ep2AI"
                    },
                    "occurrenceString": "2022-04-2T19:00:00.000Z",
                    "recorded": "2021-04-05T19:00:00.000Z",
                    "primarySource": true,
                    "reportOrigin": {
                        "coding": [
                            {
                                "system": "http://snomed.info/sct",
                                "version": "1.0",
                                "code": "11840006",
                                "display": "Traveller's Diarrhea (disorder)"
                            },
                            {
                                "system": "http://hl7.org/fhir/sid/ndc",
                                "version": "1.0",
                                "code": "76388-713-25",
                                "display": "Myleran 2mg tablet, film coated"
                            }
                        ],
                        "text": "MedReqReasonBundle"
                    },
                    "location": {
                        "reference": "Location/0klRO000000000uYAA"
                    },
                    "lotNumber": "AAJN11K",
                    "expirationDate": "2021-08-19",
                    "site": {
                        "coding": [
                            {
                                "system": "http://terminology.hl7.org/CodeSystem/v3-ActSite",
                                "version": "1.0",
                                "code": "LA",
                                "display": "left arm"
                            }
                        ],
                        "text": "Vaccin Site"
                    },
                    "doseQuantity": {
                        "value": 5.0
                    },
                    "performer": [
                        {
                            "function": {
                                "coding": [
                                    {
                                        "system": "http://Causative.Substance",
                                        "version": "1.0",
                                        "code": "1122",
                                        "display": "CausativeSubstance1"
                                    }
                                ]
                            },
                            "actor": {
                                "reference": "Practitioner/0cmRO00000002dzYAA"
                            }
                        },
                        {
                            "function": {
                                "coding": [
                                    {
                                        "system": "http://Causative.Substance",
                                        "version": "1.0",
                                        "code": "1122",
                                        "display": "CausativeSubstance1"
                                    }
                                ]
                            },
                            "actor": {
                                "reference": "Practitioner/0cmRO00000002dzYAA"
                            }
                        }
                    ],
                    "reasonCode": [
                        {
                            "coding": [
                                {
                                    "system": "http://snomed.info/sct",
                                    "version": "1.0",
                                    "code": "11840006",
                                    "display": "Traveller's Diarrhea (disorder)"
                                },
                                {
                                    "system": "http://hl7.org/fhir/sid/ndc",
                                    "version": "1.0",
                                    "code": "76388-713-25",
                                    "display": "Myleran 2mg tablet, film coated"
                                }
                            ],
                            "text": "MedReqReasonBundle"
                        }
                    ],
                    "isSubpotent": false,
                    "subpotentReason": [{
            "coding": [
                {
                    "system": "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
                    "code": "partialdose",
                    "display": "partialdose"
                }
            ],
            "text": "Sub Potent Reason Bundle"
        }],
        "protocolApplied": [
            {
                "doseNumberPositiveInt": 12.98
            }
        ]
                }
            }
        ]
    }
    ```
    
*   **500** Something went wrong.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

### POST Create an immunization

`POST /Immunization`

Creates a resource using the create interaction from the FHIR resources.

#### Parameters

*   `X-CORRELATION-ID` (header, string)
*   `Accept` (header, string)  
    Allowed values: `application/fhir+json`.

#### Request body

Media type: `application/fhir+json`. Schema: `Immunization`.

_Example_

```
{
    "resourceType": "Immunization",
    "identifier": [
        {
            "use": "usual",
            "system": "urn:custom:sourcesystem:fhirid",
            "value": "01"
        },
        {
            "value": "02",
            "system": "http://identifier1234334455urfr",
            "type": {
                "coding": [
                    {
                        "system": "urn:ietf:rfc:4567",
                        "version": "1.0",
                        "display": "Vaccine Identifier 1234"
                    }
                ],
                "text": "Vaccine Identifier"
            }
        }
    ],
    "meta": {
        "profile": [
            "http://hl7.org/fhir/us/core/StructureDefinition/us-core-immunization"
        ]
    },
    "status": "not-done",
    "statusReason": {
        "coding": [
            {
                "system": "http://snomed.info/sct",
                "version": "1.0",
                "code": "11840006",
                "display": "Traveller's Diarrhea (disorder)"
            },
            {
                "system": "http://hl7.org/fhir/sid/ndc",
                "version": "1.0",
                "code": "76388-713-25",
                "display": "Myleran 2mg tablet, film coated"
            }
        ],
        "text": "MedReqReasonBundle"
    },
    "reportOrigin": {
        "coding": [
            {
                "system": "http://snomed.info/sct",
                "version": "1.0",
                "code": "11840006",
                "display": "Traveller's Diarrhea (disorder)"
            },
            {
                "system": "http://hl7.org/fhir/sid/ndc",
                "version": "1.0",
                "code": "76388-713-25",
                "display": "Myleran 2mg tablet, film coated"
            }
        ],
        "text": "MedReqReasonBundle"
    },
    "vaccineCode": {
        "coding": [
            {
                "system": "urn:oid:1.2.36.1.2001.1005.17",
                "code": "FLUVAX",
                "display": "vaccineCode-FLUVAX"
            }
        ],
        "text": "VaccineCode Bundle"
    },
    "patient": {
        "reference": "Patient/001RO000004RD5RYAW"
    },
    "encounter": {
        "reference": "Encounter/0kGRO00000001Ep2AI"
    },
    "location": {
        "reference": "Location/0klRO000000000uYAA"
    },
    "manufacturer": {
        "reference": "Organization/001RO000004RD5RYAW"
    },
    "occurrenceString": "2022-04-2T19:00:00.000Z",
    "recorded": "2021-04-05T19:00:00.000Z",
    "primarySource": true,
    "lotNumber": "AAJN11K",
    "expirationDate": "2021-08-19",
    "site": {
        "coding": [
            {
                "system": "http://terminology.hl7.org/CodeSystem/v3-ActSite",
                "version": "1.0",
                "display": "left arm"
            }
        ],
        "text": "Vaccine Site"
    },
    "route": {
        "coding": [
            {
                "system": "http://terminology.hl7.org/CodeSystem/v3-RouteOfAdministration",
                "code": "IM",
                "display": "Injection, intramuscular"
            }
        ]
    },
    "doseQuantity": {
        "value": 5.0,
        "system": "http://unitsofmeasure.org",
        "code": "mg"
    },
    "performer": [
        {
            "function": {
                "coding": [
                    {
                        "system": "http://Causative.Substance",
                        "version": "1.0",
                        "display": "CausativeSubstance1"
                    }
                ]
            },
            "actor": {
                "reference": "Practitioner/0cmRO00000002dzYAA"
            }
        },
        {
            "function": {
                "coding": [
                    {
                        "system": "http://Causative.Substance",
                        "version": "1.0",
                        "code": "1122",
                        "display": "CausativeSubstance1"
                    }
                ]
            },
            "actor": {
                "reference": "Practitioner/0cmRO00000002dzYAA"
            }
        }
    ],
    "reasonCode": [
        {
            "coding": [
                {
                    "system": "http://snomed.info/sct",
                    "version": "1.0",
                    "code": "11840006",
                    "display": "Traveller's Diarrhea (disorder)"
                },
                {
                    "system": "http://hl7.org/fhir/sid/ndc",
                    "version": "1.0",
                    "code": "76388-713-25",
                    "display": "Myleran 2mg tablet, film coated"
                }
            ],
            "text": "MedReqReasonBundle"
        }
    ],
    "isSubpotent": false,
    "subpotentReason" : [{
        "coding" : [{
            "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
            "code" : "partialdose"
    },
    {
            "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
            "code" : "Manufacturer Recall"
    }]
    },
    {
        "coding" : [{
            "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
            "code" : "Cold Chain Break"
    },
    {
            "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
            "code" : "Manufacturer Recall"
    }]
    }],
    "protocolApplied": [
        {
            "doseNumberPositiveInt": 12.98
        }
    ]
}
```

#### Responses

*   **201** No match was found. Resource created.
    
    Headers:
    
    *   `Location` (string, required) Specifies the URL where the resource can be fetched in subsequent requests.  
        Example: `http://xxx/Immunization/123`.
    
    Media type: `application/fhir+json`. Schema: `Immunization (extended)`.
    
    Includes all fields of `Immunization`.
    
    *   `id` (_string_, required) Specifies the Salesforce ID of the created object.  
        Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
    
    _Example_
    
    ```
    {
        "resourceType": "Immunization",
        "identifier": [
            {
                "use": "usual",
                "system": "urn:custom:sourcesystem:fhirid",
                "value": "01"
            },
            {
                "value": "02",
                "system": "http://identifier1234334455urfr",
                "type": {
                    "coding": [
                        {
                            "system": "urn:ietf:rfc:4567",
                            "version": "1.0",
                            "display": "Vaccine Identifier 1234"
                        }
                    ],
                    "text": "Vaccine Identifier"
                }
            }
        ],
        "meta": {
            "profile": [
                "http://hl7.org/fhir/us/core/StructureDefinition/us-core-immunization"
            ]
        },
        "status": "not-done",
        "statusReason": {
            "coding": [
                {
                    "system": "http://snomed.info/sct",
                    "version": "1.0",
                    "code": "11840006",
                    "display": "Traveller's Diarrhea (disorder)"
                },
                {
                    "system": "http://hl7.org/fhir/sid/ndc",
                    "version": "1.0",
                    "code": "76388-713-25",
                    "display": "Myleran 2mg tablet, film coated"
                }
            ],
            "text": "MedReqReasonBundle"
        },
        "reportOrigin": {
            "coding": [
                {
                    "system": "http://snomed.info/sct",
                    "version": "1.0",
                    "code": "11840006",
                    "display": "Traveller's Diarrhea (disorder)"
                },
                {
                    "system": "http://hl7.org/fhir/sid/ndc",
                    "version": "1.0",
                    "code": "76388-713-25",
                    "display": "Myleran 2mg tablet, film coated"
                }
            ],
            "text": "MedReqReasonBundle"
        },
        "vaccineCode": {
            "coding": [
                {
                    "system": "urn:oid:1.2.36.1.2001.1005.17",
                    "code": "FLUVAX",
                    "display": "vaccineCode-FLUVAX"
                }
            ],
            "text": "VaccineCode Bundle"
        },
        "patient": {
            "reference": "Patient/001RO000004RD5RYAW"
        },
        "encounter": {
            "reference": "Encounter/0kGRO00000001Ep2AI"
        },
        "location": {
            "reference": "Location/0klRO000000000uYAA"
        },
        "manufacturer": {
            "reference": "Organization/001RO000004RD5RYAW"
        },
        "occurrenceString": "2022-04-2T19:00:00.000Z",
        "recorded": "2021-04-05T19:00:00.000Z",
        "primarySource": true,
        "lotNumber": "AAJN11K",
        "expirationDate": "2021-08-19",
        "site": {
            "coding": [
                {
                    "system": "http://terminology.hl7.org/CodeSystem/v3-ActSite",
                    "version": "1.0",
                    "display": "left arm"
                }
            ],
            "text": "Vaccin Site"
        },
        "route": {
            "coding": [
                {
                    "system": "http://terminology.hl7.org/CodeSystem/v3-RouteOfAdministration",
                    "code": "IM",
                    "display": "Injection, intramuscular"
                }
            ]
        },
        "doseQuantity": {
            "value": 5.0,
            "system": "http://unitsofmeasure.org",
            "code": "mg"
        },
        "performer": [
            {
                "function": {
                    "coding": [
                        {
                            "system": "http://Causative.Substance",
                            "version": "1.0",
                            "display": "CausativeSubstance1"
                        }
                    ]
                },
                "actor": {
                    "reference": "Practitioner/0cmRO00000002dzYAA"
                }
            },
            {
                "function": {
                    "coding": [
                        {
                            "system": "http://Causative.Substance",
                            "version": "1.0",
                            "code": "1122",
                            "display": "CausativeSubstance1"
                        }
                    ]
                },
                "actor": {
                    "reference": "Practitioner/0cmRO00000002dzYAA"
                }
            }
        ],
        "reasonCode": [
            {
                "coding": [
                    {
                        "system": "http://snomed.info/sct",
                        "version": "1.0",
                        "code": "11840006",
                        "display": "Traveller's Diarrhea (disorder)"
                    },
                    {
                        "system": "http://hl7.org/fhir/sid/ndc",
                        "version": "1.0",
                        "code": "76388-713-25",
                        "display": "Myleran 2mg tablet, film coated"
                    }
                ],
                "text": "MedReqReasonBundle"
            }
        ],
        "isSubpotent": false,
        "subpotentReason" : [{
            "coding" : [{
                "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
                "code" : "partialdose"
        },
        {
                "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
                "code" : "Manufacturer Recall"
        }]
        },
        {
            "coding" : [{
                "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
                "code" : "Cold Chain Break"
        },
        {
                "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
                "code" : "Manufacturer Recall"
        }]
        }],
        "protocolApplied": [
            {
                "doseNumberPositiveInt": 12.98
            }
        ],
        "id": "123123"
    }
    ```
    
*   **400** Resource either can’t be parsed or failed basic FHIR validation rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **404** Resource type not supported.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **405** Server denied the request.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **422** The proposed resource violated applicable FHIR profiles or server business rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

### GET Get an immunization

`GET /Immunization/{id}`

Retrieves the details for a particular object using the ID. This operation is performed using the read interaction from the FHIR resources.

#### Parameters

*   `id` (path, id, required)
*   `X-CORRELATION-ID` (header, string)

#### Responses

*   **200** The request was successful.
    
    Media type: `application/fhir+json`. Schema: `Immunization`.
    
    _Example_
    
    ```
    {
        "resourceType": "Immunization",
        "id": "0jKRO000000043o2AA",
        "identifier": [
            {
                "use": "usual",
                "system": "urn:custom:sourcesystem:fhirid",
                "value": "60"
            },
            {
                "system": "http://identifier1234334455urfr",
                "value": "61"
            }
        ],
        "meta": {
            "profile": [
                "http://hl7.org/fhir/us/core/StructureDefinition/us-core-immunization"
            ]
        },
        "status": "not-done",
        "statusReason": {
            "coding": [
                {
                    "system": "http://snomed.info/sct",
                    "version": "1.0",
                    "code": "11840006",
                    "display": "Traveller's Diarrhea (disorder)"
                },
                {
                    "system": "http://hl7.org/fhir/sid/ndc",
                    "version": "1.0",
                    "code": "76388-713-25",
                    "display": "Myleran 2mg tablet, film coated"
                }
            ],
            "text": "MedReqReasonBundle"
        },
        "vaccineCode": {
            "coding": [
                {
                    "system": "urn:oid:1.2.840.114350.1.13.0.1.7.2.696580",
                    "code": "1697",
                    "display": "CBC AND DIFFERENTIAL"
                },
                {
                    "system": "urn:oid:1.2.36.1.2001.1005.17",
                    "code": "FLUVAX",
                    "display": "vaccineCode-FLUVAX"
                }
            ],
            "text": "VaccineCode Bundle"
        },
        "patient": {
            "reference": "Patient/001RO000004RD5RYAW"
        },
        "encounter": {
            "reference": "Encounter/0kGRO00000001Ep2AI"
        },
        "occurrenceDateTime": "2022-04-02T19:00:00.000Z",
        "recorded": "2021-04-05T19:00:00.000Z",
        "primarySource": true,
        "reportOrigin": {
            "coding": [
                {
                    "system": "http://snomed.info/sct",
                    "version": "1.0",
                    "code": "11840006",
                    "display": "Traveller's Diarrhea (disorder)"
                },
                {
                    "system": "http://hl7.org/fhir/sid/ndc",
                    "version": "1.0",
                    "code": "76388-713-25",
                    "display": "Myleran 2mg tablet, film coated"
                }
            ],
            "text": "MedReqReasonBundle"
        },
        "location": {
            "reference": "Location/0klRO000000000uYAA"
        },
        "manufacturer": {
            "reference": "Organization/001RO000004RD5RYAW",
            "type": "Organization"
        },
        "lotNumber": "AAJN11K",
        "expirationDate": "2021-08-19",
        "doseQuantity": {
            "value": 5.0,
            "unit": "mg",
            "code": "mg"
        },
        "performer": [
            {
                "actor": {
                    "reference": "Practitioner/0cmRO00000002dzYAA"
                }
            },
            {
                "function": {
                    "coding": [
                        {
                            "system": "http://Causative.Substance",
                            "version": "1.0",
                            "code": "1122",
                            "display": "CausativeSubstance1"
                        }
                    ]
                },
                "actor": {
                    "reference": "Practitioner/0cmRO00000002dzYAA"
                }
            }
        ],
        "reasonCode": [
            {
                "coding": [
                    {
                        "system": "http://snomed.info/sct",
                        "version": "1.0",
                        "code": "11840006",
                        "display": "Traveller's Diarrhea (disorder)"
                    },
                    {
                        "system": "http://hl7.org/fhir/sid/ndc",
                        "version": "1.0",
                        "code": "76388-713-25",
                        "display": "Myleran 2mg tablet, film coated"
                    }
                ],
                "text": "MedReqReasonBundle"
            }
        ],
        "isSubpotent": false,
        "subpotentReason": [{
            "coding": [
                {
                    "system": "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
                    "code": "partialdose",
                    "display": "partialdose"
                }
            ],
            "text": "Sub Potent Reason Bundle"
        }],
        "protocolApplied": [
            {
                "doseNumberPositiveInt": 12.98
            }
        ]
    }
    ```
    
*   **404** Search ID not found.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **410** Target resource is no longer available.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

### PUT Update an immunization

`PUT /Immunization/{id}`

Creates a new current version of an existing resource or creates an initial version if no resource already exists for the given ID. This operation is performed using the update interaction from the FHIR resources.

#### Parameters

*   `id` (path, id, required)
*   `X-CORRELATION-ID` (header, string)
*   `Accept` (header, string)  
    Allowed values: `application/fhir+json`.

#### Request body

Media type: `application/fhir+json`. Schema: `Immunization`.

_Example_

```
{
    "resourceType": "Immunization",
    "id": "123123",
    "identifier": [
        {
            "use": "usual",
            "system": "urn:custom:sourcesystem:fhirid",
            "value": "01"
        },
        {
            "value": "02",
            "system": "http://identifier1234334455urfr",
            "type": {
                "coding": [
                    {
                        "system": "urn:ietf:rfc:4567",
                        "version": "1.0",
                        "display": "Vaccine Identifier 1234"
                    }
                ],
                "text": "Vaccine Identifier"
            }
        }
    ],
    "meta": {
        "profile": [
            "http://hl7.org/fhir/us/core/StructureDefinition/us-core-immunization"
        ]
    },
    "status": "not-done",
    "statusReason": {
        "coding": [
            {
                "system": "http://snomed.info/sct",
                "version": "1.0",
                "code": "11840006",
                "display": "Traveller's Diarrhea (disorder)"
            },
            {
                "system": "http://hl7.org/fhir/sid/ndc",
                "version": "1.0",
                "code": "76388-713-25",
                "display": "Myleran 2mg tablet, film coated"
            }
        ],
        "text": "MedReqReasonBundle"
    },
    "reportOrigin": {
        "coding": [
            {
                "system": "http://snomed.info/sct",
                "version": "1.0",
                "code": "11840006",
                "display": "Traveller's Diarrhea (disorder)"
            },
            {
                "system": "http://hl7.org/fhir/sid/ndc",
                "version": "1.0",
                "code": "76388-713-25",
                "display": "Myleran 2mg tablet, film coated"
            }
        ],
        "text": "MedReqReasonBundle"
    },
    "vaccineCode": {
        "coding": [
            {
                "system": "urn:oid:1.2.36.1.2001.1005.17",
                "code": "FLUVAX",
                "display": "vaccineCode-FLUVAX"
            }
        ],
        "text": "VaccineCode Bundle"
    },
    "patient": {
        "reference": "Patient/001RO000004RD5RYAW"
    },
    "encounter": {
        "reference": "Encounter/0kGRO00000001Ep2AI"
    },
    "location": {
        "reference": "Location/0klRO000000000uYAA"
    },
    "manufacturer": {
        "reference": "Organization/001RO000004RD5RYAW"
    },
    "occurrenceString": "2022-04-2T19:00:00.000Z",
    "recorded": "2021-04-05T19:00:00.000Z",
    "primarySource": true,
    "lotNumber": "AAJN11K",
    "expirationDate": "2021-08-19",
    "site": {
        "coding": [
            {
                "system": "http://terminology.hl7.org/CodeSystem/v3-ActSite",
                "version": "1.0",
                "display": "left arm"
            }
        ],
        "text": "Vaccine Site"
    },
    "route": {
        "coding": [
            {
                "system": "http://terminology.hl7.org/CodeSystem/v3-RouteOfAdministration",
                "code": "IM",
                "display": "Injection, intramuscular"
            }
        ]
    },
    "doseQuantity": {
        "value": 5.0,
        "system": "http://unitsofmeasure.org",
        "code": "mg"
    },
    "performer": [
        {
            "function": {
                "coding": [
                    {
                        "system": "http://Causative.Substance",
                        "version": "1.0",
                        "display": "CausativeSubstance1"
                    }
                ]
            },
            "actor": {
                "reference": "Practitioner/0cmRO00000002dzYAA"
            }
        },
        {
            "function": {
                "coding": [
                    {
                        "system": "http://Causative.Substance",
                        "version": "1.0",
                        "code": "1122",
                        "display": "CausativeSubstance1"
                    }
                ]
            },
            "actor": {
                "reference": "Practitioner/0cmRO00000002dzYAA"
            }
        }
    ],
    "reasonCode": [
        {
            "coding": [
                {
                    "system": "http://snomed.info/sct",
                    "version": "1.0",
                    "code": "11840006",
                    "display": "Traveller's Diarrhea (disorder)"
                },
                {
                    "system": "http://hl7.org/fhir/sid/ndc",
                    "version": "1.0",
                    "code": "76388-713-25",
                    "display": "Myleran 2mg tablet, film coated"
                }
            ],
            "text": "MedReqReasonBundle"
        }
    ],
    "isSubpotent": false,
    "subpotentReason" : [{
        "coding" : [{
            "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
            "code" : "partialdose"
    },
    {
            "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
            "code" : "Manufacturer Recall"
    }]
    },
    {
        "coding" : [{
            "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
            "code" : "Cold Chain Break"
    },
    {
            "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
            "code" : "Manufacturer Recall"
    }]
    }],
    "protocolApplied": [
        {
            "doseNumberPositiveInt": 12.98
        }
    ]
}
```

#### Responses

*   **200** Updated the resource.
    
    Headers:
    
    *   `Location` (string, required) Specifies the URL where the resource can be fetched in subsequent requests.  
        Example: `http://xxx/Immunization/123`.
    
    Media type: `application/fhir+json`. Schema: `Immunization (extended)`.
    
    Includes all fields of `Immunization`.
    
    *   `id` (_string_, required) Specifies the Salesforce ID of the updated or created object.  
        Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
    
    _Example_
    
    ```
    {
        "resourceType": "Immunization",
        "identifier": [
            {
                "use": "usual",
                "system": "urn:custom:sourcesystem:fhirid",
                "value": "01"
            },
            {
                "value": "02",
                "system": "http://identifier1234334455urfr",
                "type": {
                    "coding": [
                        {
                            "system": "urn:ietf:rfc:4567",
                            "version": "1.0",
                            "display": "Vaccine Identifier 1234"
                        }
                    ],
                    "text": "Vaccine Identifier"
                }
            }
        ],
        "meta": {
            "profile": [
                "http://hl7.org/fhir/us/core/StructureDefinition/us-core-immunization"
            ]
        },
        "status": "not-done",
        "statusReason": {
            "coding": [
                {
                    "system": "http://snomed.info/sct",
                    "version": "1.0",
                    "code": "11840006",
                    "display": "Traveller's Diarrhea (disorder)"
                },
                {
                    "system": "http://hl7.org/fhir/sid/ndc",
                    "version": "1.0",
                    "code": "76388-713-25",
                    "display": "Myleran 2mg tablet, film coated"
                }
            ],
            "text": "MedReqReasonBundle"
        },
        "reportOrigin": {
            "coding": [
                {
                    "system": "http://snomed.info/sct",
                    "version": "1.0",
                    "code": "11840006",
                    "display": "Traveller's Diarrhea (disorder)"
                },
                {
                    "system": "http://hl7.org/fhir/sid/ndc",
                    "version": "1.0",
                    "code": "76388-713-25",
                    "display": "Myleran 2mg tablet, film coated"
                }
            ],
            "text": "MedReqReasonBundle"
        },
        "vaccineCode": {
            "coding": [
                {
                    "system": "urn:oid:1.2.36.1.2001.1005.17",
                    "code": "FLUVAX",
                    "display": "vaccineCode-FLUVAX"
                }
            ],
            "text": "VaccineCode Bundle"
        },
        "patient": {
            "reference": "Patient/001RO000004RD5RYAW"
        },
        "encounter": {
            "reference": "Encounter/0kGRO00000001Ep2AI"
        },
        "location": {
            "reference": "Location/0klRO000000000uYAA"
        },
        "manufacturer": {
            "reference": "Organization/001RO000004RD5RYAW"
        },
        "occurrenceString": "2022-04-2T19:00:00.000Z",
        "recorded": "2021-04-05T19:00:00.000Z",
        "primarySource": true,
        "lotNumber": "AAJN11K",
        "expirationDate": "2021-08-19",
        "site": {
            "coding": [
                {
                    "system": "http://terminology.hl7.org/CodeSystem/v3-ActSite",
                    "version": "1.0",
                    "display": "left arm"
                }
            ],
            "text": "Vaccin Site"
        },
        "route": {
            "coding": [
                {
                    "system": "http://terminology.hl7.org/CodeSystem/v3-RouteOfAdministration",
                    "code": "IM",
                    "display": "Injection, intramuscular"
                }
            ]
        },
        "doseQuantity": {
            "value": 5.0,
            "system": "http://unitsofmeasure.org",
            "code": "mg"
        },
        "performer": [
            {
                "function": {
                    "coding": [
                        {
                            "system": "http://Causative.Substance",
                            "version": "1.0",
                            "display": "CausativeSubstance1"
                        }
                    ]
                },
                "actor": {
                    "reference": "Practitioner/0cmRO00000002dzYAA"
                }
            },
            {
                "function": {
                    "coding": [
                        {
                            "system": "http://Causative.Substance",
                            "version": "1.0",
                            "code": "1122",
                            "display": "CausativeSubstance1"
                        }
                    ]
                },
                "actor": {
                    "reference": "Practitioner/0cmRO00000002dzYAA"
                }
            }
        ],
        "reasonCode": [
            {
                "coding": [
                    {
                        "system": "http://snomed.info/sct",
                        "version": "1.0",
                        "code": "11840006",
                        "display": "Traveller's Diarrhea (disorder)"
                    },
                    {
                        "system": "http://hl7.org/fhir/sid/ndc",
                        "version": "1.0",
                        "code": "76388-713-25",
                        "display": "Myleran 2mg tablet, film coated"
                    }
                ],
                "text": "MedReqReasonBundle"
            }
        ],
        "isSubpotent": false,
        "subpotentReason" : [{
            "coding" : [{
                "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
                "code" : "partialdose"
        },
        {
                "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
                "code" : "Manufacturer Recall"
        }]
        },
        {
            "coding" : [{
                "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
                "code" : "Cold Chain Break"
        },
        {
                "system" : "http://terminology.hl7.org/CodeSystem/immunization-subpotent-reason",
                "code" : "Manufacturer Recall"
        }]
        }],
        "protocolApplied": [
            {
                "doseNumberPositiveInt": 12.98
            }
        ],
         "id": "123123"
    }
    ```
    
*   **201** Created.
    
    Headers:
    
    *   `Location` (string, required) Specifies the URL where the resource can be fetched in subsequent requests.  
        Example: `http://xxx/Immunization/123`.
    
    Media type: `application/fhir+json`. Schema: `Immunization (extended)`.
    
    Includes all fields of `Immunization`.
    
    *   `id` (_string_, required) Specifies the Salesforce ID of the updated or created object.  
        Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
    
    _Example: same as PUT /Immunization/{id} 200 response._
    
*   **400** Resource either can’t be parsed or failed basic FHIR validation rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **401** Authorization is required for the interaction that was attempted.
    
    Media type: `application/json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **404** Resource type not supported.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **405** Server denied the request.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **422** The proposed resource violated applicable FHIR profiles or server business rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

### GET Get medication statements

`GET /MedicationStatement`

Retrieves a set of resources by using filters.

#### Parameters

*   `patient` (query, string, required) Returns the statements for a specific patient.
*   `X-CORRELATION-ID` (header, string)
*   `Accept` (header, string)  
    Allowed values: `*/*`, `application/fhir+json`.

#### Responses

*   **200**
    
    Media type: `application/fhir+json`. Schema: `MedicationStatementBundle (extended)`.
    
    Includes all fields of `MedicationStatementBundle`.
    
    *   `entry` (_array of object_)
        
        Entry in the bundle must have a resource or information.
        
        *   Rule: must be a resource unless there's a request or response.
        *   Rule: fullUrl property can't be a version-specific reference. For bundles of 'document' and 'message' type, the first resource is special and must be Composition or MessageHeader properties respectively. For all bundles, the meaning of the order of entries depends on the bundle type.
        
        Each item:
        
        Entry in the bundle must have a resource or information.
        
        *   Rule: must be a resource unless there's a request or response.
        *   Rule: fullUrl property can't be a version specific reference. For bundles of 'document' and 'message' type, the first resource is special and must be the Composition or MessageHeader properties respectively. For all bundles, the meaning of the order of entries depends on the bundle type.
        
        *   `modifierExtension` (_array of object_) Modifier Extensions
            
            Each item: Optional Extensions Element + Rule Must have either extensions or value\[x\], not both Elements defined in Ancestors id, extension
            
            *   `extension` (_array of any_) Additional Content defined by implementations - from Element: extension (recursive)
            *   `url` (_string_, required) identifies the meaning of the extension
            *   `id` (_string_) Internal id  
                Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
            *   `value` (_object | object | object | object | object | object | object | object | object_) Value of extension
                
                One of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`.
                
                *   _object_
                    
                    Value of extension
                    
                    *   `valueInteger` (_integer_, required) Value of extension.
                *   _object_
                    
                    Value of extension
                    
                    *   `valueDecimal` (_number_, required) Value of extension.
                    *   `valueInteger` (_integer_, required) Value of extension.
                *   _object_
                    
                    Value of extension
                    
                    *   `valueDateTime` (_string_, required) Value of extension.  
                        Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
                    *   `valueInteger` (_integer_, required) Value of extension.
                *   _object_
                    
                    Value of extension
                    
                    *   `valueDecimal` (_number_, required) Value of extension.
                    *   `valueInteger` (_integer_, required) Value of extension.
                *   _object_
                    
                    Value of extension
                    
                    *   `valueDecimal` (_number_, required) Value of extension.
                *   _object_
                    
                    Value of extension
                    
                    *   `valueDateTime` (_string_, required) Value of extension.  
                        Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
                    *   `valueDecimal` (_number_, required) Value of extension.
                *   _object_
                    
                    Value of extension
                    
                    *   `valueDateTime` (_string_, required) Value of extension.  
                        Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
                    *   `valueInteger` (_integer_, required) Value of extension.
                *   _object_
                    
                    Value of extension
                    
                    *   `valueDateTime` (_string_, required) Value of extension.  
                        Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
                    *   `valueDecimal` (_number_, required) Value of extension.
                *   _object_
                    
                    Value of extension
                    
                    *   `valueDateTime` (_string_, required) Value of extension.  
                        Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
        *   `extension` (_array of any_) Additional Content defined by implementations - from Element: extension (recursive)
        *   `fullUrl` (_string_) Specifies the URI for the resource, which is the absolute URL server address, or URI for UUID or OID.
        *   `id` (_string_) Internal id  
            Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
        *   `resource` (_object_, required) Specifies the record of the medication that's provided to a patient. The elements defined in Ancestors are id, meta, implicitRules, language, text, contained, extension, and modifierExtension.
            *   `dateAsserted` (_string_) Specifies the statement assertion date.  
                Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
            *   `basedOn` (_array of object_) Specifies the reference that's used for the plan, proposal, or order.
                
                Each item: Many of the defined elements in a resource are references to other resources. Using these references, the resources combine to build a web of information about healthcare.
                
                *   `reference` (_string_) Literal reference, Relative, internal or absolute URL
            *   `subject` (_object_, required) Specifies who is taking the medication. An update operation isn't supported for subject.
                *   `reference` (_string_) Literal reference, Relative, internal or absolute URL
            *   `meta` (_object_) Specifies the metadata of the resource.
                *   `profile` (_array of string_) Profiles this resource claims to conform to
                    
                    Each item: A URI that refers to a resource by its canonical URL (resources with a url property). The canonical type differs from a uri in that it has special meaning in this specification, and in that it may have a version appended, separated by a vertical bar (|). Note that the type canonical is not used for the actual canonical URLs that are the target of these references, but for the URIs that refer to them, and may have the version suffix in them. Like other URIs, elements of type canonical may also have #fragment references
                    
            *   `context` (_object_) Specifies the encounter or episode associated with the medication statement.
                *   `reference` (_string_) Literal reference, Relative, internal or absolute URL
            *   `identifier` (_array of object_) Specifies the external identifier of the medication statement.
                
                Each item: A numeric or alphanumeric string that is associated with a single object or entity within a given system. Typically, identifiers are used to connect content in resources to external content available in other frameworks or protocols. Identifiers are associated with objects, and may be changed or retired due to human or system process and errors.
                
                *   `use` (_string_) usual | official | temp | secondary (If known)  
                    Allowed values: `usual`, `official`, `temp`, `secondary`, `old`. Pattern: ^\[^\\s\]+(\[\\s\]+\[^\\s\]+)\*$.
                *   `type` (_object_) Description of identifier
                    *   `coding` (_array of object_) Code defined by a terminology system
                        
                        Each item: A Coding is a representation of a defined concept using a symbol from a defined "code system". See [http://hl7.org/fhir/STU3/terminologies.html](http://hl7.org/fhir/STU3/terminologies.html) for more details.
                        
                        *   `system` (_string_) Identity of the terminology system
                        *   `version` (_string_) Version of the system - if relevant
                        *   `code` (_string_) Symbol in syntax defined by the system  
                            Pattern: ^\[^\\s\]+(\[\\s\]+\[^\\s\]+)\*$.
                        *   `display` (_string_) Representation defined by the system
                    *   `text` (_string_) Plain text representation of the concept
                *   `system` (_string_) The namespace for the identifier value
                *   `value` (_string_) The value that is unique
            *   `medication` (_object | object_) Specifies the medication that was taken. The medication data type is mandatory for a MedicationStatement resource. A 'medication' choice data type can have the medicationCodeableConcept field or the medicationReference field in the request.
                
                One of: `object`, `object`.
                
                *   _object_
                    
                    Specifies the medication that was taken. The medication data type is mandatory for a MedicationStatement resource. A 'medication' choice data type can have the medicationCodeableConcept field or the medicationReference field in the request.
                    
                    *   `medicationCodeableConcept` (_object_, required) Specifies the medication that was taken.
                        *   `coding` (_array of object_) Code defined by a terminology system
                            
                            Each item: A Coding is a representation of a defined concept using a symbol from a defined "code system". See [http://hl7.org/fhir/STU3/terminologies.html](http://hl7.org/fhir/STU3/terminologies.html) for more details.
                            
                            *   `system` (_string_) Identity of the terminology system
                            *   `version` (_string_) Version of the system - if relevant
                            *   `code` (_string_) Symbol in syntax defined by the system  
                                Pattern: ^\[^\\s\]+(\[\\s\]+\[^\\s\]+)\*$.
                            *   `display` (_string_) Representation defined by the system
                        *   `text` (_string_) Plain text representation of the concept
                *   _object_
                    
                    Specifies the medication that was taken. The medication data type is mandatory for a MedicationStatement resource. A 'medication' choice data type can have the medicationCodeableConcept field or the medicationReference field in the request.
                    
                    *   `medicationReference` (_object_, required) Specifies the medication that was taken.
                        *   `reference` (_string_) Literal reference, Relative, internal or absolute URL
            *   `id` (_string_) Specifies the ID of the medication record.  
                Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
            *   `informationSource` (_object_) Specifies the person or organization that provided the information about the medication usage.
                *   `reference` (_string_) Literal reference, Relative, internal or absolute URL
            *   `effective` (_object | object_) Specifies the date, time, or frequency of taking the medication.A 'effective' choice data type can have the effectiveDateTime field or the effectivePeriod field in the request.
                
                One of: `object`, `object`.
                
                *   _object_
                    
                    Specifies the date, time, or frequency of taking the medication.A 'effective' choice data type can have the effectiveDateTime field or the effectivePeriod field in the request.
                    
                    *   `effectiveDateTime` (_string_, required) Specifies the date, time, or frequency of taking the medication.  
                        Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
                *   _object_
                    
                    Specifies the date, time, or frequency of taking the medication.A 'effective' choice data type can have the effectiveDateTime field or the effectivePeriod field in the request.
                    
                    *   `effectivePeriod` (_object_, required) Specifies the date, time, or interval when the medication is taken.
                        *   `extension` (_array of any_) Additional Content defined by implementations - from Element: extension (recursive)
                        *   `id` (_string_) Internal id  
                            Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
                        *   `start` (_string_) Starting time with inclusive boundary  
                            Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
                        *   `end` (_string_) End time with inclusive boundary, if not ongoing  
                            Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
            *   `status` (_string_, required) Specifies the status of the medication statement. Possible values are active, completed, entered-in-error, intended, stopped, on-hold, unknown, or not-taken.  
                Allowed values: `active`, `completed`, `entered-in-error`, `intended`, `stopped`, `on-hold`, `unknown`, `not-taken`. Pattern: ^\[^\\s\]+(\[\\s\]+\[^\\s\]+)\*$.
            *   `reasonCode` (_array of object_) Specifies the reason for medication usage.
                
                Each item: A CodeableConcept represents a value that is usually supplied by providing a reference to one or more terminologies or ontologies, but may also be defined by the provision of text. This is a common pattern in healthcare data.
                
                *   `coding` (_array of object_) Code defined by a terminology system
                    
                    Each item: A Coding is a representation of a defined concept using a symbol from a defined "code system". See [http://hl7.org/fhir/STU3/terminologies.html](http://hl7.org/fhir/STU3/terminologies.html) for more details.
                    
                    *   `system` (_string_) Identity of the terminology system
                    *   `version` (_string_) Version of the system - if relevant
                    *   `code` (_string_) Symbol in syntax defined by the system  
                        Pattern: ^\[^\\s\]+(\[\\s\]+\[^\\s\]+)\*$.
                    *   `display` (_string_) Representation defined by the system
                *   `text` (_string_) Plain text representation of the concept
        *   `search` (_object_) Specifies the search-related information.
            *   `modifierExtension` (_array of object_) Modifier Extensions
                
                Each item: Optional Extensions Element + Rule Must have either extensions or value\[x\], not both Elements defined in Ancestors id, extension
                
                *   `extension` (_array of any_) Additional Content defined by implementations - from Element: extension (recursive)
                *   `url` (_string_, required) identifies the meaning of the extension
                *   `id` (_string_) Internal id  
                    Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
                *   `value` (_object | object | object | object | object | object | object | object | object_) Value of extension
                    
                    One of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`.
                    
                    *   _object_
                        
                        Value of extension
                        
                        *   `valueInteger` (_integer_, required) Value of extension.
                    *   _object_
                        
                        Value of extension
                        
                        *   `valueDecimal` (_number_, required) Value of extension.
                        *   `valueInteger` (_integer_, required) Value of extension.
                    *   _object_
                        
                        Value of extension
                        
                        *   `valueDateTime` (_string_, required) Value of extension.  
                            Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
                        *   `valueInteger` (_integer_, required) Value of extension.
                    *   _object_
                        
                        Value of extension
                        
                        *   `valueDecimal` (_number_, required) Value of extension.
                        *   `valueInteger` (_integer_, required) Value of extension.
                    *   _object_
                        
                        Value of extension
                        
                        *   `valueDecimal` (_number_, required) Value of extension.
                    *   _object_
                        
                        Value of extension
                        
                        *   `valueDateTime` (_string_, required) Value of extension.  
                            Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
                        *   `valueDecimal` (_number_, required) Value of extension.
                    *   _object_
                        
                        Value of extension
                        
                        *   `valueDateTime` (_string_, required) Value of extension.  
                            Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
                        *   `valueInteger` (_integer_, required) Value of extension.
                    *   _object_
                        
                        Value of extension
                        
                        *   `valueDateTime` (_string_, required) Value of extension.  
                            Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
                        *   `valueDecimal` (_number_, required) Value of extension.
                    *   _object_
                        
                        Value of extension
                        
                        *   `valueDateTime` (_string_, required) Value of extension.  
                            Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.
            *   `extension` (_array of any_) Additional Content defined by implementations - from Element: extension (recursive)
            *   `mode` (_string_) Specifies why the entry is in the result set. Possible values are match, include, and outcome.  
                Allowed values: `match`, `include`, `outcome`. Pattern: ^\[^\\s\]+(\[\\s\]+\[^\\s\]+)\*$.
            *   `id` (_string_) Internal id  
                Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
    
    _Example_
    
    ```
    {
        "resourceType": "Bundle",
        "id": "0afd2496-b07f-47ab-bba2-c46ea3f612db",
        "meta": {
            "lastUpdated": "2023-04-04T10:44:35.635+05:30"
        },
        "type": "searchset",
        "total": 11,
        "link": [
            {
                "relation": "self",
                "url": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement?patient=001RO0000041r3PYAQ"
            }
        ],
        "entry": [
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001JiYAI",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001JiYAI",
                    "status": "active",
                    "medicationCodeableConcept": {
                        "coding": [
                            {
                                "system": "http://MedicationStatement.CodeSet1",
                                "code": "01",
                                "display": "01"
                            },
                            {
                                "system": "http://MedicationStatement.CodeSet2",
                                "version": "1.0",
                                "code": "02",
                                "display": "02"
                            }
                        ],
                        "text": "Medication Statement Code Bundle"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectiveDateTime": "2021-04-14T19:00:00.000Z",
                    "dateAsserted": "2021-04-21T07:30:00.000Z"
                }
            },
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001KCYAY",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001KCYAY",
                    "status": "active",
                    "identifier": [
                        {
                            "use": "usual",
                            "value": "5040",
                            "system": "urn:custom:sourcesystem:fhirid"
                        },
                        {
                            "use": "usual",
                            "value": "5039",
                            "system": "urn:custom:sourcesystem:fhirid"
                        }
                    ],
                    "medicationReference": {
                        "reference": "0itRO00000000ytYAA"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectivePeriod": {
                        "start": "2021-04-14T19:00:00.000Z",
                        "end": "2021-04-14T19:00:00.000Z"
                    },
                    "dateAsserted": "2021-04-21T07:30:00.000Z",
                    "informationSource": {
                        "reference": "Organization/001RO0000041r3PYAQ",
                        "type": "Organization"
                    },
                    "reasonCode": [
                        {
                            "coding": [
                                {
                                    "system": "http://MedicationStatement.CodeSet3",
                                    "code": "12345",
                                    "display": "Medication Statement CodeSet 1"
                                },
                                {
                                    "system": "http://MedicationStatement.CodeSet4",
                                    "version": "1.0",
                                    "code": "23456",
                                    "display": "Medication Statement CodeSet 2"
                                }
                            ],
                            "text": "Medication Statement Code Bundle 1"
                        }
                    ]
                }
            },
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001K2YAI",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001K2YAI",
                    "status": "active",
                    "identifier": [
                        {
                            "use": "usual",
                            "value": "5036",
                            "system": "urn:custom:sourcesystem:fhirid"
                        },
                        {
                            "use": "usual",
                            "value": "5035",
                            "system": "urn:custom:sourcesystem:fhirid"
                        }
                    ],
                    "medicationCodeableConcept": {
                        "coding": [
                            {
                                "system": "http://MedicationStatement.CodeSet3",
                                "code": "05",
                                "display": "01"
                            },
                            {
                                "system": "http://MedicationStatement.CodeSet4",
                                "version": "1.0",
                                "code": "06",
                                "display": "02"
                            }
                        ],
                        "text": "Medication Statement Code Bundle"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectiveDateTime": "2021-04-14T19:00:00.000Z",
                    "dateAsserted": "2021-04-21T07:30:00.000Z",
                    "informationSource": {
                        "reference": "Organization/001RO0000041r3PYAQ",
                        "type": "Organization"
                    },
                    "reasonCode": [
                        {
                            "coding": [
                                {
                                    "system": "http://MedicationStatement.CodeSet3",
                                    "code": "12345",
                                    "display": "Medication Statement CodeSet 1"
                                },
                                {
                                    "system": "http://MedicationStatement.CodeSet4",
                                    "version": "1.0",
                                    "code": "23456",
                                    "display": "Medication Statement CodeSet 2"
                                }
                            ],
                            "text": "Medication Statement Code Bundle 1"
                        }
                    ]
                }
            },
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001JnYAI",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001JnYAI",
                    "status": "active",
                    "identifier": [
                        {
                            "use": "usual",
                            "value": "5026",
                            "system": "urn:custom:sourcesystem:fhirid"
                        },
                        {
                            "use": "usual",
                            "value": "5025",
                            "system": "urn:custom:sourcesystem:fhirid"
                        }
                    ],
                    "medicationCodeableConcept": {
                        "coding": [
                            {
                                "system": "http://MedicationStatement.CodeSet1",
                                "code": "01",
                                "display": "01"
                            },
                            {
                                "system": "http://MedicationStatement.CodeSet2",
                                "version": "1.0",
                                "code": "02",
                                "display": "02"
                            }
                        ],
                        "text": "Medication Statement Code Bundle"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectiveDateTime": "2021-04-14T19:00:00.000Z",
                    "dateAsserted": "2021-04-21T07:30:00.000Z"
                }
            },
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001JdYAI",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001JdYAI",
                    "status": "active",
                    "medicationCodeableConcept": {
                        "coding": [
                            {
                                "system": "http://MedicationStatement.CodeSet1",
                                "code": "01",
                                "display": "01"
                            },
                            {
                                "system": "http://MedicationStatement.CodeSet2",
                                "version": "1.0",
                                "code": "02",
                                "display": "02"
                            }
                        ],
                        "text": "Medication Statement Code Bundle"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectiveDateTime": "2021-04-14T19:00:00.000Z",
                    "dateAsserted": "2021-04-21T07:30:00.000Z",
                    "informationSource": {
                        "reference": "Organization/001RO0000041r3PYAQ",
                        "type": "Organization"
                    }
                }
            },
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001JTYAY",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001JTYAY",
                    "status": "active",
                    "identifier": [
                        {
                            "use": "usual",
                            "value": "50201",
                            "system": "urn:custom:sourcesystem:fhirid"
                        }
                    ],
                    "medicationCodeableConcept": {
                        "coding": [
                            {
                                "system": "http://MedicationStatement.CodeSet1",
                                "code": "01",
                                "display": "01"
                            },
                            {
                                "system": "http://MedicationStatement.CodeSet2",
                                "version": "1.0",
                                "code": "02",
                                "display": "02"
                            }
                        ],
                        "text": "Medication Statement Code Bundle"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectiveDateTime": "2021-04-14T19:00:00.000Z",
                    "dateAsserted": "2021-04-21T07:30:00.000Z"
                }
            },
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001KHYAY",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001KHYAY",
                    "status": "active",
                    "identifier": [
                        {
                            "use": "usual",
                            "value": "5025",
                            "system": "urn:custom:sourcesystem:fhirid1",
                            "type": {
                                "coding": [
                                    {
                                        "system": "http://MedicationStatement.CodeSet5",
                                        "code": "15",
                                        "display": "01"
                                    },
                                    {
                                        "system": "http://MedicationStatement.CodeSet6",
                                        "version": "1.0",
                                        "code": "16",
                                        "display": "02"
                                    }
                                ],
                                "text": "Medication Statement Identifier Code Bundle 1"
                            }
                        },
                        {
                            "use": "usual",
                            "value": "5026",
                            "system": "urn:custom:sourcesystem:fhirid1",
                            "type": {
                                "coding": [
                                    {
                                        "system": "http://MedicationStatement.CodeSet5",
                                        "code": "13",
                                        "display": "01"
                                    },
                                    {
                                        "system": "http://MedicationStatement.CodeSet6",
                                        "version": "1.0",
                                        "code": "14",
                                        "display": "02"
                                    }
                                ],
                                "text": "Medication Statement Identifier Code Bundle 1"
                            }
                        }
                    ],
                    "medicationReference": {
                        "reference": "0itRO00000000ytYAA"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectivePeriod": {
                        "start": "2021-04-14T19:00:00.000Z",
                        "end": "2021-04-30T19:00:00.000Z"
                    },
                    "dateAsserted": "2021-04-21T07:30:00.000Z",
                    "informationSource": {
                        "reference": "Patient/001RO0000045Ni3YAE",
                        "type": "Patient"
                    },
                    "reasonCode": [
                        {
                            "coding": [
                                {
                                    "system": "http://MedicationStatement.CodeSet1",
                                    "code": "1234",
                                    "display": "Medication Statement CodeSet 1"
                                },
                                {
                                    "system": "http://MedicationStatement.CodeSet2",
                                    "version": "1.0",
                                    "code": "2345",
                                    "display": "Medication Statement CodeSet 2"
                                }
                            ],
                            "text": "Medication Statement Code Bundle"
                        }
                    ]
                }
            },
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001JOYAY",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001JOYAY",
                    "status": "active",
                    "identifier": [
                        {
                            "use": "usual",
                            "value": "5022",
                            "system": "urn:custom:sourcesystem:fhirid"
                        }
                    ],
                    "medicationCodeableConcept": {
                        "coding": [
                            {
                                "system": "http://MedicationStatement.CodeSet2",
                                "version": "1.0",
                                "code": "02",
                                "display": "02"
                            },
                            {
                                "system": "http://MedicationStatement.CodeSet1",
                                "code": "02",
                                "display": "01"
                            }
                        ],
                        "text": "Medication Statement Code Bundle"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectiveDateTime": "2021-04-14T19:00:00.000Z",
                    "dateAsserted": "2021-04-21T07:30:00.000Z"
                }
            },
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001JsYAI",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001JsYAI",
                    "status": "active",
                    "identifier": [
                        {
                            "use": "usual",
                            "value": "5027",
                            "system": "urn:custom:sourcesystem:fhirid"
                        },
                        {
                            "use": "usual",
                            "value": "5028",
                            "system": "urn:custom:sourcesystem:fhirid"
                        }
                    ],
                    "medicationCodeableConcept": {
                        "coding": [
                            {
                                "system": "http://MedicationStatement.CodeSet1",
                                "code": "01",
                                "display": "01"
                            },
                            {
                                "system": "http://MedicationStatement.CodeSet2",
                                "version": "1.0",
                                "code": "02",
                                "display": "02"
                            }
                        ],
                        "text": "Medication Statement Code Bundle"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectiveDateTime": "2021-04-14T19:00:00.000Z",
                    "dateAsserted": "2021-04-21T07:30:00.000Z",
                    "informationSource": {
                        "reference": "Organization/001RO0000041r3PYAQ",
                        "type": "Organization"
                    }
                }
            },
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001K7YAI",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001K7YAI",
                    "status": "active",
                    "identifier": [
                        {
                            "use": "usual",
                            "value": "5037",
                            "system": "urn:custom:sourcesystem:fhirid"
                        },
                        {
                            "use": "usual",
                            "value": "5038",
                            "system": "urn:custom:sourcesystem:fhirid"
                        }
                    ],
                    "medicationCodeableConcept": {
                        "coding": [
                            {
                                "system": "http://MedicationStatement.CodeSet5",
                                "code": "05",
                                "display": "01"
                            },
                            {
                                "system": "http://MedicationStatement.CodeSet6",
                                "version": "1.0",
                                "code": "06",
                                "display": "02"
                            }
                        ],
                        "text": "Medication Statement Code Bundle"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectiveDateTime": "2021-04-14T19:00:00.000Z",
                    "dateAsserted": "2021-04-21T07:30:00.000Z",
                    "informationSource": {
                        "reference": "Organization/001RO0000041r3PYAQ",
                        "type": "Organization"
                    },
                    "reasonCode": [
                        {
                            "coding": [
                                {
                                    "system": "http://MedicationStatement.CodeSet3",
                                    "code": "12345",
                                    "display": "Medication Statement CodeSet 1"
                                },
                                {
                                    "system": "http://MedicationStatement.CodeSet4",
                                    "version": "1.0",
                                    "code": "23456",
                                    "display": "Medication Statement CodeSet 2"
                                }
                            ],
                            "text": "Medication Statement Code Bundle 1"
                        }
                    ]
                }
            },
            {
                "fullUrl": "https://localhost:8092/clinical-medications/fhir-r4/v1/MedicationStatement/0juRO00000001JxYAI",
                "search": {
                    "mode": "match"
                },
                "resource": {
                    "resourceType": "MedicationStatement",
                    "id": "0juRO00000001JxYAI",
                    "status": "active",
                    "identifier": [
                        {
                            "use": "usual",
                            "value": "5033",
                            "system": "urn:custom:sourcesystem:fhirid"
                        },
                        {
                            "use": "usual",
                            "value": "5034",
                            "system": "urn:custom:sourcesystem:fhirid",
                            "type": {
                                "coding": [
                                    {
                                        "system": "urn:ietf:rfc:3986",
                                        "version": "1.0",
                                        "code": "urn:oid:1.3.6.1.4.1.21367.2005.3.7.2122",
                                        "display": "Vaccine Identifier 2022"
                                    }
                                ],
                                "text": "Immunization Identifier Bundle 1"
                            }
                        }
                    ],
                    "medicationCodeableConcept": {
                        "coding": [
                            {
                                "system": "http://MedicationStatement.CodeSet3",
                                "code": "03",
                                "display": "01"
                            },
                            {
                                "system": "http://MedicationStatement.CodeSet4",
                                "version": "1.0",
                                "code": "04",
                                "display": "02"
                            }
                        ],
                        "text": "Medication Statement Code Bundle"
                    },
                    "basedOn": [
                        {
                            "reference": "MedicationRequest/0kmRO000000014iYAA"
                        }
                    ],
                    "context": {
                        "reference": "Encounter/0kGRO00000001Ks2AI"
                    },
                    "subject": {
                        "reference": "Patient/001RO0000041r3PYAQ"
                    },
                    "effectiveDateTime": "2021-04-14T19:00:00.000Z",
                    "dateAsserted": "2021-04-21T07:30:00.000Z",
                    "informationSource": {
                        "reference": "Practitioner/0cmRO0000000266YAA",
                        "type": "Practitioner"
                    },
                    "reasonCode": [
                        {
                            "coding": [
                                {
                                    "system": "http://MedicationStatement.CodeSet3",
                                    "code": "1234",
                                    "display": "Medication Statement CodeSet 1"
                                },
                                {
                                    "system": "http://MedicationStatement.CodeSet4",
                                    "version": "1.0",
                                    "code": "2345",
                                    "display": "Medication Statement CodeSet 2"
                                }
                            ],
                            "text": "Medication Statement Code Bundle 1"
                        }
                    ]
                }
            }
        ]
    }
    ```
    
*   **500** Something went wrong.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

### POST Create a medication statement

`POST /MedicationStatement`

Creates a resource using the create interaction from the FHIR resources.

#### Parameters

*   `X-CORRELATION-ID` (header, string)
*   `Accept` (header, string)  
    Allowed values: `application/fhir+json`.

#### Request body

Media type: `application/fhir+json`. Schema: `MedicationStatement`.

_Example_

```
{
    "resourceType": "MedicationStatement",
    "identifier": [
        {
            "use": "usual",
            "system": "urn:custom:sourcesystem:fhirid",
            "value": "5047",
            "type": {
                "coding": [
                    {
                        "system": "http://MedicationStatement.CodeSet5",
                        "code": "21",
                        "display": "01"
                    },
                    {
                        "system": "http://MedicationStatement.CodeSet6",
                        "version": "1.0",
                        "code": "22",
                        "display": "02"
                    }
                ],
                "text": "Medication Statement Identifier Code Bundle 1"
            }
        },
        {
            "use": "usual",
            "system": "urn:custom:sourcesystem:fhirid",
            "value": "5048",
            "type": {
                "coding": [
                    {
                        "system": "http://MedicationStatement.CodeSet7",
                        "code": "23",
                        "display": "01"
                    },
                    {
                        "system": "http://MedicationStatement.CodeSet8",
                        "version": "1.0",
                        "code": "24",
                        "display": "02"
                    }
                ],
                "text": "Medication Statement Identifier Code Bundle 2"
            }
        }
        
    ],
    "basedOn": [{
        "reference": "MedicationRequest/0kmRO000000014iYAA"
    }],
    "status": "active",
    "medicationCodeableConcept": {
        "coding": [
            {
                "system": "http://MedicationStatement.CodeSet5",
                "code": "07",
                "display": "01"
            },
            {
                "system": "http://MedicationStatement.CodeSet6",
                "version": "1.0",
                "code": "08",
                "display": "02"
            }
        ],
        "text": "Medication Statement Code Bundle"
    },
    "subject": {
        "reference": "Patient/001RO0000045Ni3YAE"
    },
    "context":  {
        "reference": "Encounter/0kGRO00000001Ks2AI"
    },
    "effectiveDateTime": "2021-04-14T19:00:00.000Z",
    "dateAsserted": "2021-04-21T07:30:00.000Z",
    "informationSource": {
        "reference": "Patient/001RO0000045Ni3YAE"
    },
    "reasonCode": [{
        "coding": [
            {
                "system": "http://MedicationStatement.CodeSet3",
                "code": "123456",
                "display": "Medication Statement CodeSet 1"
            },
            {
                "system": "http://MedicationStatement.CodeSet4",
                "version": "1.0",
                "code": "234567",
                "display": "Medication Statement CodeSet 2"
            }
        ],
        "text": "Medication Statement Code Bundle 1"
    },
    {
        "coding": [
            {
                "system": "http://MedicationStatement.CodeSet3",
                "code": "456788",
                "display": "Medication Statement CodeSet 1"
            },
            {
                "system": "http://MedicationStatement.CodeSet4",
                "version": "1.0",
                "code": "567898",
                "display": "Medication Statement CodeSet 2"
            }
        ],
        "text": "Medication Statement Code Bundle 2"
    }]
}
```

#### Responses

*   **201** No match was found. Resource created.
    
    Headers:
    
    *   `Location` (string, required) Specifies the URL where the resource can be fetched in subsequent requests.  
        Example: `http://xxx/MedicationStatement/123`.
    
    Media type: `application/fhir+json`. Schema: `MedicationStatement (extended)`.
    
    Includes all fields of `MedicationStatement`.
    
    *   `id` (_string_, required) Specifies the Salesforce ID of the created object.  
        Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
    
    _Example_
    
    ```
    {
        "resourceType": "MedicationStatement",
        "identifier": [
            {
                "use": "usual",
                "system": "urn:custom:sourcesystem:fhirid",
                "value": "5047",
                "type": {
                    "coding": [
                        {
                            "system": "http://MedicationStatement.CodeSet5",
                            "code": "21",
                            "display": "01"
                        },
                        {
                            "system": "http://MedicationStatement.CodeSet6",
                            "version": "1.0",
                            "code": "22",
                            "display": "02"
                        }
                    ],
                    "text": "Medication Statement Identifier Code Bundle 1"
                }
            },
            {
                "use": "usual",
                "system": "urn:custom:sourcesystem:fhirid",
                "value": "5048",
                "type": {
                    "coding": [
                        {
                            "system": "http://MedicationStatement.CodeSet7",
                            "code": "23",
                            "display": "01"
                        },
                        {
                            "system": "http://MedicationStatement.CodeSet8",
                            "version": "1.0",
                            "code": "24",
                            "display": "02"
                        }
                    ],
                    "text": "Medication Statement Identifier Code Bundle 2"
                }
            }
        ],
        "basedOn": [
            {
                "reference": "MedicationRequest/0kmRO000000014iYAA"
            }
        ],
        "status": "active",
        "medicationCodeableConcept": {
            "coding": [
                {
                    "system": "http://MedicationStatement.CodeSet5",
                    "code": "07",
                    "display": "01"
                },
                {
                    "system": "http://MedicationStatement.CodeSet6",
                    "version": "1.0",
                    "code": "08",
                    "display": "02"
                }
            ],
            "text": "Medication Statement Code Bundle"
        },
        "subject": {
            "reference": "Patient/001RO0000045Ni3YAE"
        },
        "context": {
            "reference": "Encounter/0kGRO00000001Ks2AI"
        },
        "effectiveDateTime": "2021-04-14T19:00:00.000Z",
        "dateAsserted": "2021-04-21T07:30:00.000Z",
        "informationSource": {
            "reference": "Patient/001RO0000045Ni3YAE"
        },
        "reasonCode": [
            {
                "coding": [
                    {
                        "system": "http://MedicationStatement.CodeSet3",
                        "code": "123456",
                        "display": "Medication Statement CodeSet 1"
                    },
                    {
                        "system": "http://MedicationStatement.CodeSet4",
                        "version": "1.0",
                        "code": "234567",
                        "display": "Medication Statement CodeSet 2"
                    }
                ],
                "text": "Medication Statement Code Bundle 1"
            },
            {
                "coding": [
                    {
                        "system": "http://MedicationStatement.CodeSet3",
                        "code": "456788",
                        "display": "Medication Statement CodeSet 1"
                    },
                    {
                        "system": "http://MedicationStatement.CodeSet4",
                        "version": "1.0",
                        "code": "567898",
                        "display": "Medication Statement CodeSet 2"
                    }
                ],
                "text": "Medication Statement Code Bundle 2"
            }
        ],
        "id": "0juRO00000001MNYAY"
    }
    ```
    
*   **400** Resource either can’t be parsed or failed basic FHIR validation rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **404** Resource type not supported.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **405** Server denied the request.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **422** The proposed resource violated applicable FHIR profiles or server business rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

### GET Get a medication statement

`GET /MedicationStatement/{id}`

Retrieves the details for a particular object using the ID. This operation is performed using the read interaction from the FHIR resources.

#### Parameters

*   `id` (path, id, required)
*   `X-CORRELATION-ID` (header, string)

#### Responses

*   **200** The request was successful.
    
    Media type: `application/fhir+json`. Schema: `MedicationStatement`.
    
    _Example_
    
    ```
    {
        "resourceType": "MedicationStatement",
        "id": "0juRO00000001KHYAY",
        "status": "active",
        "identifier": [
            {
                "use": "usual",
                "value": "5025",
                "system": "urn:custom:sourcesystem:fhirid1",
                "type": {
                    "coding": [
                        {
                            "system": "http://MedicationStatement.CodeSet5",
                            "code": "15",
                            "display": "01"
                        },
                        {
                            "system": "http://MedicationStatement.CodeSet6",
                            "version": "1.0",
                            "code": "16",
                            "display": "02"
                        }
                    ],
                    "text": "Medication Statement Identifier Code Bundle 1"
                }
            },
            {
                "use": "usual",
                "value": "5026",
                "system": "urn:custom:sourcesystem:fhirid1",
                "type": {
                    "coding": [
                        {
                            "system": "http://MedicationStatement.CodeSet5",
                            "code": "13",
                            "display": "01"
                        },
                        {
                            "system": "http://MedicationStatement.CodeSet6",
                            "version": "1.0",
                            "code": "14",
                            "display": "02"
                        }
                    ],
                    "text": "Medication Statement Identifier Code Bundle 1"
                }
            }
        ],
        "medicationReference": {
            "reference": "0itRO00000000ytYAA"
        },
        "basedOn": [
            {
                "reference": "MedicationRequest/0kmRO000000014iYAA"
            }
        ],
        "context": {
            "reference": "Encounter/0kGRO00000001Ks2AI"
        },
        "subject": {
            "reference": "Patient/001RO0000041r3PYAQ"
        },
        "effectivePeriod": {
            "start": "2021-04-14T19:00:00.000Z",
            "end": "2021-04-30T19:00:00.000Z"
        },
        "dateAsserted": "2021-04-21T07:30:00.000Z",
        "informationSource": {
            "reference": "Patient/001RO0000045Ni3YAE",
            "type": "Patient"
        },
        "reasonCode": [
            {
                "coding": [
                    {
                        "system": "http://MedicationStatement.CodeSet1",
                        "code": "1234",
                        "display": "Medication Statement CodeSet 1"
                    },
                    {
                        "system": "http://MedicationStatement.CodeSet2",
                        "version": "1.0",
                        "code": "2345",
                        "display": "Medication Statement CodeSet 2"
                    }
                ],
                "text": "Medication Statement Code Bundle"
            }
        ]
    }
    ```
    
*   **404** Search ID not found.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **410** Target resource is no longer available.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

### PUT Update a medication statement

`PUT /MedicationStatement/{id}`

Creates a new current version of an existing resource or creates an initial version if no resource already exists for the given ID. This operation is performed using the update interaction from the FHIR resources.

#### Parameters

*   `id` (path, id, required)
*   `X-CORRELATION-ID` (header, string)
*   `Accept` (header, string)  
    Allowed values: `application/fhir+json`.

#### Request body

Media type: `application/fhir+json`. Schema: `MedicationStatement`.

_Example_

```
{
    "resourceType": "MedicationStatement",
    "id": "0juRO00000001KHYAY",
    "identifier": [
        {
            "use": "usual",
            "system": "urn:custom:sourcesystem:fhirid1",
            "value": "5025",
            "type": {
                "coding": [
                    {
                        "system": "http://MedicationStatement.CodeSet5",
                        "code": "15",
                        "display": "01"
                    },
                    {
                        "system": "http://MedicationStatement.CodeSet6",
                        "version": "1.0",
                        "code": "16",
                        "display": "02"
                    }
                ],
                "text": "Medication Statement Identifier Code Bundle 1"
            }
        },
        {
            "use": "usual",
            "system": "urn:custom:sourcesystem:fhirid1",
            "value": "5026",
            "type": {
                "coding": [
                    {
                        "system": "http://MedicationStatement.CodeSet5",
                        "code": "13",
                        "display": "01"
                    },
                    {
                        "system": "http://MedicationStatement.CodeSet6",
                        "version": "1.0",
                        "code": "14",
                        "display": "02"
                    }
                ],
                "text": "Medication Statement Identifier Code Bundle 1"
            }
        }
        
    ],
    "basedOn": [{
        "reference": "MedicationRequest/0kmRO000000014iYAA"
    }],
    "status": "active",
    "medicationReference":{
        "reference": "Medication/0itRO00000000ytYAA"
    },
    "subject": {
        "reference": "Patient/001RO0000045Ni3YAE"
    },
    "context":  {
        "reference": "Encounter/0kGRO00000001Ks2AI"
    },
    "effectivePeriod": {
        "start" : "2021-04-14T19:00:00.000Z",
        "end" : "2021-04-30T19:00:00.000Z"
    },
    "dateAsserted": "2021-04-21T07:30:00.000Z",
    "informationSource": {
        "reference": "Patient/001RO0000045Ni3YAE"
    },
    "reasonCode": [{
        "coding": [
            {
                "system": "http://MedicationStatement.CodeSet1",
                "code": "1234",
                "display": "Medication Statement CodeSet 1"
            },
            {
                "system": "http://MedicationStatement.CodeSet2",
                "version": "1.0",
                "code": "2345",
                "display": "Medication Statement CodeSet 2"
            }
        ],
        "text": "Medication Statement Code Bundle"
    },
    {
        "coding": [
            {
                "system": "http://MedicationStatement.CodeSet3",
                "code": "4567",
                "display": "Medication Statement CodeSet 1"
            },
            {
                "system": "http://MedicationStatement.CodeSet4",
                "version": "1.0",
                "code": "5678",
                "display": "Medication Statement CodeSet 2"
            }
        ],
        "text": "Medication Statement Code Bundle"
    }]
}
```

#### Responses

*   **200** Updated the resource.
    
    Headers:
    
    *   `Location` (string, required) Specifies the URL where the resource can be fetched in subsequent requests.  
        Example: `http://xxx/MedicationStatement/123`.
    
    Media type: `application/fhir+json`. Schema: `MedicationStatement (extended)`.
    
    Includes all fields of `MedicationStatement`.
    
    *   `id` (_string_, required) Specifies the Salesforce ID of the updated or created object.  
        Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
    
    _Example_
    
    ```
    {
        "resourceType": "MedicationStatement",
        "id": "23414",
        "identifier": [
            {
                "use": "usual",
                "system": "urn:custom:sourcesystem:fhirid",
                "value": "5039",
                "type": {
                    "coding": [
                        {
                            "system": "http://MedicationStatement.CodeSet5",
                            "code": "21",
                            "display": "01"
                        },
                        {
                            "system": "http://MedicationStatement.CodeSet6",
                            "version": "1.0",
                            "code": "22",
                            "display": "02"
                        }
                    ],
                    "text": "Medication Statement Identifier Code Bundle 1"
                }
            },
            {
                "use": "usual",
                "system": "urn:custom:sourcesystem:fhirid",
                "value": "5040",
                "type": {
                    "coding": [
                        {
                            "system": "http://MedicationStatement.CodeSet7",
                            "code": "23",
                            "display": "01"
                        },
                        {
                            "system": "http://MedicationStatement.CodeSet8",
                            "version": "1.0",
                            "code": "24",
                            "display": "02"
                        }
                    ],
                    "text": "Medication Statement Identifier Code Bundle 2"
                }
            }
            
        ],
        "basedOn": [{
            "reference": "MedicationRequest/0kmRN00000003cqYAA"
        }],
        "status": "active",
        "medicationCodeableConcept": {
            "coding": [
                {
                    "system": "http://MedicationStatement.CodeSet5",
                    "code": "07",
                    "display": "01"
                },
                {
                    "system": "http://MedicationStatement.CodeSet6",
                    "version": "1.0",
                    "code": "08",
                    "display": "02"
                }
            ],
            "text": "Medication Statement Code Bundle"
        },
        "subject": {
            "reference": "Patient/001RN0000037I8hYAE"
        },
        "context":  {
            "reference": "Encounter/0kGRN00000000RI2AY"
        },
        "effectiveDateTime": "2021-04-14T19:00:00.000Z",
        "dateAsserted": "2021-04-21T07:30:00.000Z",
        "informationSource": {
            "reference": "Patient/001RN0000037I8hYAE"
        },
        "reasonCode": [{
            "coding": [
                {
                    "system": "http://MedicationStatement.CodeSet3",
                    "code": "123456",
                    "display": "Medication Statement CodeSet 1"
                },
                {
                    "system": "http://MedicationStatement.CodeSet4",
                    "version": "1.0",
                    "code": "234567",
                    "display": "Medication Statement CodeSet 2"
                }
            ],
            "text": "Medication Statement Code Bundle 1"
        },
        {
            "coding": [
                {
                    "system": "http://MedicationStatement.CodeSet3",
                    "code": "456788",
                    "display": "Medication Statement CodeSet 1"
                },
                {
                    "system": "http://MedicationStatement.CodeSet4",
                    "version": "1.0",
                    "code": "567898",
                    "display": "Medication Statement CodeSet 2"
                }
            ],
            "text": "Medication Statement Code Bundle 2"
        }]
    }
    ```
    
*   **201** Created.
    
    Headers:
    
    *   `Location` (string, required) Specifies the URL where the resource can be fetched in subsequent requests.  
        Example: `http://xxx/MedicationStatement/123`.
    
    Media type: `application/fhir+json`. Schema: `MedicationStatement (extended)`.
    
    Includes all fields of `MedicationStatement`.
    
    *   `id` (_string_, required) Specifies the Salesforce ID of the updated or created object.  
        Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.
    
    _Example: same as PUT /MedicationStatement/{id} 200 response._
    
*   **400** Resource either can’t be parsed or failed basic FHIR validation rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **401** Authorization is required for the interaction that was attempted.
    
    Media type: `application/json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **404** Resource type not supported.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **405** Server denied the request.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **422** The proposed resource violated applicable FHIR profiles or server business rules.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    
*   **503** Error connecting Salesforce.
    
    Media type: `application/fhir+json`. Schema: `OperationOutcome`.
    
    _Example: same as POST /Medication 400 response._
    

## Schemas

### Medication

Identify and define a medication resource that describes how a medication is prescribed, dispensed, and administered while also recording statements of its usage. The Medication FHIR resource maps to the ​Medication object in Salesforce​.

Includes all fields of `Resource`.

*   `identifier` (_array of Identifier_) Specifies the business identifier for the medication.
*   `code` (_object_, required) Specifies the code or a set of codes to identify the medication or a textual description if no code is available.
    
    Includes all fields of `CodeableConcept`.
    
*   `status` (_code (string)_) Indicates if the medication is in active use.  
    Allowed values: `active`, `inactive`, `entered-in-error`.
*   `manufacturer` (_object_) Specifies the details of the medication product's manufacturer.
    
    Includes all fields of `Reference`.
    
*   `form` (_object_) Specifies the form of the item, such as powder, tablets, or capsule.
    
    Includes all fields of `CodeableConcept`.
    
*   `amount` (_object_) Specifies the amount of the drug in the package.
    
    Includes all fields of `Ratio`.
    

### OperationOutcome

Information about the success or failure of an action. Elements defined in Ancestors id, meta, implicitRules, language, text, contained, extension, modifierExtension.

Includes all fields of `Resource`.

*   `issue` (_array of object_, required)
    *   `severity` (_code (string)_, required) fatal | error | warning | information  
        Allowed values: `fatal`, `error`, `warning`, `information`.
    *   `code` (_code (string)_, required) Error or warning code  
        Allowed values: `invalid`, `structure`, `required`, `value`, `invariant`, `security`, `login`, `unknown`, `expired`, `forbidden`, `suppressed`, `processing`, `not-supported`, `duplicate`, `multiple-matches`, `not-found`, `deleted`, `too-long`, `code-invalid`, `extension`, `too-costly`, `business-rule`, `conflict`, `transient`, `lock-error`, `no-store`, `exception`, `timeout`, `incomplete`, `throttled`, `informational`.
    *   `details` (_object_) Additional details about the error
        
        Includes all fields of `CodeableConcept`.
        

### id

Any combination of upper or lower case ASCII letters ('A'..'Z', and 'a'..'z', numerals ('0'..'9'), '-' and '.', with a length limit of 64 characters. (This might be an integer, an un-prefixed OID, UUID or any other identifier pattern that meets these constraints.)

Type: `string`.

Pattern: ^\[A-Za-z0-9\\-\\.\]{1,64}$.

### MedicationPut

Identify and define a medication resource that describes how a medication is prescribed, dispensed, and administered while also recording statements of its usage. The Medication FHIR resource maps to the ​Medication object in Salesforce​.

Includes all fields of `Resource`.

*   `identifier` (_array of Identifier_) Specifies the business identifier for the medication.
*   `code` (_object_) Specifies the code or a set of codes to identify the medication or a textual description if no code is available.
    
    Includes all fields of `CodeableConcept`.
    
*   `status` (_code (string)_) Indicates if the medication is in active use.  
    Allowed values: `active`, `inactive`, `entered-in-error`.
*   `manufacturer` (_object_) Specifies the details of the medication product's manufacturer.
    
    Includes all fields of `Reference`.
    
*   `form` (_object_) Specifies the form of the item, such as powder, tablets, or capsule.
    
    Includes all fields of `CodeableConcept`.
    
*   `amount` (_object_) Specifies the amount of the drug in the package.
    
    Includes all fields of `Ratio`.
    

### ImmunizationBundle

Includes all fields of `Bundle`.

*   `entry` (_array of ImmunizationEntry_)

### Immunization

The StructureDefinition-us-core-immunization profile sets minimum expectations for the Immunization resource to record, fetch, and search immunization history associated with a patient. The StructureDefinition-us-core-immunization profile identifies which core elements, extensions, vocabularies, and value sets SHALL be present in the resource when using the profile.

Example Usage Scenarios:

The example usage scenarios for the US Core-Core Immunization profile are:

Query for immunizations belonging to a Patient Record or update immunizations belonging to a Patient Mandatory and Must Support Data Elements The data elements are mandatory or must be supported if the data is present in the sending system (Must Support definition). The Formal Profile Definition below provides the formal summary, definitions, and terminology requirements with profile specific guidance and examples.

Each Immunization must have a status, a vaccine code that identifies the kind of vaccine administered, a date the vaccine was administered, and a patient. Each Immunization must support a status reason if the vaccine wasn’t given. Profile specific implementation guidance includes:

\*Use the status code: FHIR\_commons.not-done to represent that an immunization wasn't given. NDC codes as a translational data element: FHIR\_commons.Based upon the 2015 Edition Certification Requirements, CVX vaccine codes are required, and the NDC vaccine codes must be supported as translations to them. A NDC to CVX ConceptMap is provided and is based upon the CDC’s CVX crosswalk table. A translation is illustrated in this example. Examples Immunization-imm-1 Formal Views of Profile Content Description of Profiles, Differentials, and Snapshots

This profile builds on Immunization.

Includes all fields of `Resource`.

*   `identifier` (_array of Identifier_) Specifies the business identifier.
*   `status` (_code (string)_, required) completed | entered-in-error | not-done Binding: FHIR\_commons.ImmunizationStatusCodes (required)  
    Allowed values: `completed`, `entered-in-error`, `not-done`.
*   `statusReason` (_object_) Specifies the reason for the not-done status. Binding: FHIR\_commons.ImmunizationStatusReasonCodes (example)
    
    Includes all fields of `CodeableConcept`.
    
*   `vaccineCode` (_object_, required) Vaccine Product Type (bind to CVX) Binding: FHIR\_commons.US Core Vaccine Administered Value Set (CVX) (extensible) us-core-1: FHIR\_commons.SHOULD have a translation to the NDC value set.
    
    Includes all fields of `CodeableConcept`.
    
*   `patient` (_object_, required) Specifies the reference (US Core Patient Profile) who was immunized. An update operation isn't supported for a patient.
    
    Includes all fields of `Reference`.
    
*   `encounter` (_object_) Specifies the reference (Encounter) encounter that the immunization was a part of.
    
    Includes all fields of `Reference`.
    
*   `occurrence` (_immunizationoccurrenceDateTime | immunizationoccurrenceString_) Specifies the vaccine administration date. The occurrence data type is mandatory for an Immunization resource and can have the occurrenceDateTime field or the occurrenceString field in the request.
    
    One of: `immunizationoccurrenceDateTime`, `immunizationoccurrenceString`.
    
*   `recorded` (_dateTime (string)_) Specifies when the immunization was first captured in the subject's record.
*   `primarySource` (_boolean_, required) Indicates the context that the data was recorded in.
*   `reportOrigin` (_object_) Indicates the source of a secondarily reported record. Binding: FHIR\_commons.ImmunizationOriginCodes (example)
    
    Includes all fields of `CodeableConcept`.
    
*   `location` (_object_) Specifies the reference (Location) where the immunization occurred.
    
    Includes all fields of `Reference`.
    
*   `manufacturer` (_object_) Specifies the reference (Organization) of the vaccine manufacturer.
    
    Includes all fields of `Reference`.
    
*   `lotNumber` (_string_) Specifies the vaccine lot number.
*   `expirationDate` (_date (string)_) Specifies the vaccine expiration date.
*   `site` (_object_) Specifies the body site where the vaccine was administered. Binding: FHIR\_commons.CodesForImmunizationSiteOfAdministration (example)
    
    Includes all fields of `CodeableConcept`.
    
*   `route` (_object_) Specifies how the vaccine entered the body. Binding: FHIR\_commons.ImmunizationRouteCodes (example)
    
    Includes all fields of `CodeableConcept`.
    
*   `doseQuantity` (_object_) Specifies the quantity of administered vaccine.
    
    Includes all fields of `SimpleQuantity`.
    
*   `performer` (_array of object_) Specifies who performed the event.
    
    Includes all fields of `BackboneElement`.
    
    *   `function` (_object_) Specifies the type of performance. Binding: FHIR\_commons.ImmunizationFunctionCodes (extensible)
        
        Includes all fields of `CodeableConcept`.
        
    *   `actor` (_object_, required) Specifies the reference (Practitioner | PractitionerRole | Organization) individual or organization who performed the event.
        
        Includes all fields of `Reference`.
        
*   `reasonCode` (_array of CodeableConcept_) Specifies why immunization occurred. Binding: FHIR\_commons.ImmunizationReasonCodes (example)
*   `isSubpotent` (_boolean_) Specifies the dose potency.
*   `subpotentReason` (_array of CodeableConcept_) Specifies the reason for being subpotent. Binding: FHIR\_commons.ImmunizationSubpotentReason (example)
*   `protocolApplied` (_array of object_) Specifies the protocol followed by the provider.
    
    Includes all fields of `BackboneElement`.
    
    *   `doseNumber` (_object_) Specifies the dose number within the series. The doseNumber property is a mandatory field under the protocolApplied type.
        
        Includes all fields of `immunizationdoseNumberPositiveInt`.
        

### MedicationStatementBundle

Includes all fields of `Bundle`.

*   `entry` (_array of MedicationStatementEntry_)

### MedicationStatement

Specifies the record of the medication that's provided to a patient. The elements defined in Ancestors are id, meta, implicitRules, language, text, contained, extension, and modifierExtension.

Includes all fields of `Resource`.

*   `identifier` (_array of object_) Specifies the external identifier of the medication statement.
    
    Includes all fields of `Identifier`.
    
*   `basedOn` (_array of object_) Specifies the reference that's used for the plan, proposal, or order.
    
    Includes all fields of `Reference`.
    
*   `status` (_code (string)_, required) Specifies the status of the medication statement. Possible values are active, completed, entered-in-error, intended, stopped, on-hold, unknown, or not-taken.  
    Allowed values: `active`, `completed`, `entered-in-error`, `intended`, `stopped`, `on-hold`, `unknown`, `not-taken`.
*   `medication` (_medicationStatementmedicationCodeableConcept | medicationStatementmedicationReference_) Specifies the medication that was taken. The medication data type is mandatory for a MedicationStatement resource. A 'medication' choice data type can have the medicationCodeableConcept field or the medicationReference field in the request.
    
    One of: `medicationStatementmedicationCodeableConcept`, `medicationStatementmedicationReference`.
    
*   `subject` (_object_, required) Specifies who is taking the medication. An update operation isn't supported for subject.
    
    Includes all fields of `Reference`.
    
*   `context` (_object_) Specifies the encounter or episode associated with the medication statement.
    
    Includes all fields of `Reference`.
    
*   `effective` (_medicationStatementeffectiveDateTime | medicationStatementeffectivePeriod_) Specifies the date, time, or frequency of taking the medication.A 'effective' choice data type can have the effectiveDateTime field or the effectivePeriod field in the request.
    
    One of: `medicationStatementeffectiveDateTime`, `medicationStatementeffectivePeriod`.
    
*   `dateAsserted` (_dateTime (string)_) Specifies the statement assertion date.
*   `informationSource` (_object_) Specifies the person or organization that provided the information about the medication usage.
    
    Includes all fields of `Reference`.
    
*   `reasonCode` (_array of object_) Specifies the reason for medication usage.
    
    Includes all fields of `CodeableConcept`.
    

### Resource

Base Resource

*   `id` (_id (string)_) Specifies the ID of the medication record.
*   `meta` (_object_) Specifies the metadata of the resource.
    
    Includes all fields of `Meta`.
    

### Identifier

A numeric or alphanumeric string that is associated with a single object or entity within a given system. Typically, identifiers are used to connect content in resources to external content available in other frameworks or protocols. Identifiers are associated with objects, and may be changed or retired due to human or system process and errors.

*   `use` (_code (string)_) usual | official | temp | secondary (If known)  
    Allowed values: `usual`, `official`, `temp`, `secondary`, `old`.
*   `type` (_object_) Description of identifier
    
    Includes all fields of `CodeableConcept`.
    
*   `system` (_uri (string)_) The namespace for the identifier value
*   `value` (_string_) The value that is unique

### CodeableConcept

A CodeableConcept represents a value that is usually supplied by providing a reference to one or more terminologies or ontologies, but may also be defined by the provision of text. This is a common pattern in healthcare data.

*   `coding` (_array of Coding_) Code defined by a terminology system
*   `text` (_string_) Plain text representation of the concept

### code

Indicates that the value is taken from a set of controlled strings defined elsewhere (see Using codes for further discussion). Technically, a code is restricted to a string which has at least one character and no leading or trailing whitespace, and where there is no whitespace other than single spaces in the contents.

Type: `string`.

Pattern: ^\[^\\s\]+(\[\\s\]+\[^\\s\]+)\*$.

### Reference

Many of the defined elements in a resource are references to other resources. Using these references, the resources combine to build a web of information about healthcare.

*   `reference` (_string_) Literal reference, Relative, internal or absolute URL

### Ratio

A relationship between two Quantity values expressed as a numerator and a denominator.

Includes all fields of `Element`.

*   `numerator` (_object_) Numerator value
    
    Includes all fields of `Quantity`.
    
*   `denominator` (_object_) Denominator value
    
    Includes all fields of `Quantity`.
    

### Bundle

Includes all fields of `Resource`.

*   `type` (_code (string)_, required) Specifies the type of bundle. Possible values are document, message, transaction, transaction-response, batch, batch-response, history, searchset, and collection.  
    Allowed values: `document`, `message`, `transaction`, `transaction-response`, `batch`, `batch-response`, `history`, `searchset`, `collection`.
*   `total` (_unsignedInt (integer)_) Specifies the number of matches with the search results.
*   `link` (_array of object_) Specifies the links related to the bundle.
    
    Includes all fields of `BackboneElement`.
    
    *   `relation` (_string_, required) Specifies how this bundle link relates at the parent level. See [link relations](http://www.iana.org/assignments/link-relations/link-relations.xhtml#link-relations-1).
    *   `url` (_uri (string)_, required) Specifies the reference details for the link.
*   `entry` (_array of object_)
    
    Entry in the bundle must have a resource or information.
    
    *   Rule: must be a resource unless there's a request or response.
    *   Rule: fullUrl property can't be a version-specific reference. For bundles of 'document' and 'message' type, the first resource is special and must be Composition or MessageHeader properties respectively. For all bundles, the meaning of the order of entries depends on the bundle type.
    
    Includes all fields of `Entry`.
    

### ImmunizationEntry

Includes all fields of `Entry`.

*   `resource` (_Immunization_, required)

### immunizationoccurrenceDateTime

*   `occurrenceDateTime` (_dateTime (string)_, required) Specifies the vaccine administration date.

### immunizationoccurrenceString

*   `occurrenceString` (_string_, required) Specifies the vaccine administration date.

### dateTime

A date, date-time or partial date (e.g. just year or year + month) as used in human communication. If hours and minutes are specified, a time zone SHALL be populated. Seconds must be provided due to schema type constraints but may be zero-filled and may be ignored. Dates SHALL be valid dates. The time "24:00" is not allowed

Type: `string`.

Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\])(T(\[01\]\[0-9\]|2\[0-3\]):\[0-5\]\[0-9\]:\[0-5\]\[0-9\](https://./[0-9/]+)?(Z|(\\+|-)((0\[0-9\]|1\[0-3\]):\[0-5\]\[0-9\]|14:00)))?)?)?$.

### date

A date, or partial date (e.g. just year or year + month) as used in human communication. There is no time zone. Dates SHALL be valid dates

Type: `string`.

Pattern: ^\[0-9\]{4}(-(0\[1-9\]|1\[0-2\])(-(0\[0-9\]|\[1-2\]\[0-9\]|3\[0-1\]))?)?$. Example: `1970-08-07`.

### SimpleQuantity

The comparator is not used on a SimpleQuantity

Includes all fields of `Quantity`.

### BackboneElement

Includes all fields of `Element`.

*   `modifierExtension` (_array of Extension_) Modifier Extensions

### immunizationdoseNumberPositiveInt

*   `doseNumberPositiveInt` (_positiveInt (integer)_, required) Specifies the dose number within the series.

### MedicationStatementEntry

Includes all fields of `Entry`.

*   `resource` (_MedicationStatement_, required)

### medicationStatementmedicationCodeableConcept

*   `medicationCodeableConcept` (_object_, required) Specifies the medication that was taken.
    
    Includes all fields of `CodeableConcept`.
    

### medicationStatementmedicationReference

*   `medicationReference` (_object_, required) Specifies the medication that was taken.
    
    Includes all fields of `Reference`.
    

### medicationStatementeffectiveDateTime

*   `effectiveDateTime` (_dateTime (string)_, required) Specifies the date, time, or frequency of taking the medication.

### medicationStatementeffectivePeriod

*   `effectivePeriod` (_object_, required) Specifies the date, time, or interval when the medication is taken.
    
    Includes all fields of `Period`.
    

### Meta

Each resource contains an element "meta", of type "Meta", which is a set of metadata that provides technical and workflow context to the resource. The metadata items are all optional, though some or all of them may be required in particular implementations or contexts of use.

*   `profile` (_array of object_) Profiles this resource claims to conform to
    
    Each item: A URI that refers to a resource by its canonical URL (resources with a url property). The canonical type differs from a uri in that it has special meaning in this specification, and in that it may have a version appended, separated by a vertical bar (|). Note that the type canonical is not used for the actual canonical URLs that are the target of these references, but for the URIs that refer to them, and may have the version suffix in them. Like other URIs, elements of type canonical may also have #fragment references
    
    Includes all fields of `uri`.
    

### uri

A Uniform Resource Identifier Reference (see: [https://tools.ietf.org/html/rfc3986](https://tools.ietf.org/html/rfc3986)). Note: URIs are case sensitive. For UUID (urn:uuid:53fefa32-fcbb-4ff8-8a92-55ee120877b7) use all lowercase. URIs can be absolute or relative, and may have an optional fragment identifier. Regex: \\S\*

Type: `string`.

### Coding

A Coding is a representation of a defined concept using a symbol from a defined "code system". See [http://hl7.org/fhir/STU3/terminologies.html](http://hl7.org/fhir/STU3/terminologies.html) for more details.

*   `system` (_uri (string)_) Identity of the terminology system
*   `version` (_string_) Version of the system - if relevant
*   `code` (_code (string)_) Symbol in syntax defined by the system
*   `display` (_string_) Representation defined by the system

### Element

*   `id` (_id (string)_) Internal id
*   `extension` (_array of Extension_) Additional Content defined by implementations - from Element: extension (recursive)

### Quantity

A measured amount (or an amount that can potentially be measured).

*   `value` (_decimal (number)_) Numerical value (with implicit precision)
*   `comparator` (_code (string)_) how to understand the value  
    Allowed values: `<`, `<=`, `>=`, `>`.
*   `unit` (_string_) Unit representation
*   `system` (_uri (string)_) System that defines coded unit form
*   `code` (_code (string)_) Coded form of the unit

### unsignedInt

Any non-negative integer (e.g. >= 0) Regex - \[0\]|(\[1-9\]\[0-9\]\*)

Type: `integer`.

Minimum: 0.

### Entry

Entry in the bundle must have a resource or information.

*   Rule: must be a resource unless there's a request or response.
*   Rule: fullUrl property can't be a version specific reference. For bundles of 'document' and 'message' type, the first resource is special and must be the Composition or MessageHeader properties respectively. For all bundles, the meaning of the order of entries depends on the bundle type.

Includes all fields of `BackboneElement`.

*   `resource` (_object_) Specifies a resource in the bundle.
    
    Includes all fields of `Resource`.
    
*   `fullUrl` (_uri (string)_) Specifies the URI for the resource, which is the absolute URL server address, or URI for UUID or OID.
*   `search` (_object_) Specifies the search-related information.
    
    Includes all fields of `BackboneElement`.
    
    *   `mode` (_code (string)_) Specifies why the entry is in the result set. Possible values are match, include, and outcome.  
        Allowed values: `match`, `include`, `outcome`.

### Extension

Optional Extensions Element + Rule Must have either extensions or value\[x\], not both Elements defined in Ancestors id, extension

Includes all fields of `Element`.

*   `url` (_uri (string)_, required) identifies the meaning of the extension
*   `value` (_enumvalueInteger | enumvalueDecimal | enumvalueDateTime_) Value of extension
    
    One of: `enumvalueInteger`, `enumvalueDecimal`, `enumvalueDateTime`.
    

### positiveInt

Any positive integer (e.g. >= 1) Regex - +?\[1-9\]\[0-9\]\*

Type: `integer`.

Minimum: 1.

### Period

A time period defined by a start and end date/time.

Includes all fields of `Element`.

*   `start` (_dateTime (string)_) Starting time with inclusive boundary
*   `end` (_dateTime (string)_) End time with inclusive boundary, if not ongoing

### decimal

Rational numbers that have a decimal representation. See below about the precision of the number. Regex: -?(0|\[1-9\]\[0-9\]\*)(.\[0-9\]+)?(\[eE\]\[+-\]?\[0-9\]+)?

Type: `number`.

### enumvalueInteger

*   `valueInteger` (_integer_, required) Value of extension.

### enumvalueDecimal

*   `valueDecimal` (_decimal (number)_, required) Value of extension.

### enumvalueDateTime

*   `valueDateTime` (_dateTime (string)_, required) Value of extension.